compiling gtk project
- From: Mariusz Bozewicz <plachninka wp pl>
- To: GTK+ Lista dyskusyjna <gtk-app-devel-list gnome org>
- Subject: compiling gtk project
- Date: Sun, 9 Dec 2001 01:04:05 +0100 (CET)
Hi
I have one stupid problem with compiling little project. I put some
own functions (these functions use gtk functions) in other files.
My Makefile looks like this:
CC=gcc
EXECUTE_SCRIPT=`gtk-config --cflags --libs`
model: kolory.o event.o modele.o menu.o area.o main.o
$(CC) -o kolory.o event.o modele.o menu.o area.o main.o
kolory.o: kolory.c modele.h
$(CC) -c kolory.c $(EXECUTE_SCRIPT)
event.o: event.c modele.h
$(CC) -c event.c $(EXECUTE_SCRIPT)
modele.o: modele.c modele.h
$(CC) -c modele.c $(EXECUTE_SCRIPT)
menu.o: menu.c modele.h
$(CC) -c menu.c $(EXECUTE_SCRIPT)
area.o: area.c modele.h
$(CC) -c area.c $(EXECUTE_SCRIPT)
main.o: main.c modele.h
$(CC) -c main.c $(EXECUTE_SCRIPT)
make returns similar warnings for all .o files:
gcc -c kolory.c `gtk-config --cflags --libs`
gcc: -lgtk: linker input file unused since linking not done
gcc: -lgdk: linker input file unused since linking not done
gcc: -lgmodule: linker input file unused since linking not done
gcc: -lglib: linker input file unused since linking not done
gcc: -ldl: linker input file unused since linking not done
gcc: -lXi: linker input file unused since linking not done
gcc: -lXext: linker input file unused since linking not done
gcc: -lX11: linker input file unused since linking not done
gcc: -lm: linker input file unused since linking not done
gcc -o kolory.o event.o modele.o menu.o area.o main.o
and for "model" target it returns:
gcc -o kolory.o event.o modele.o menu.o area.o main.o
event.o: In function `delete_event':
event.o(.text+0x7): undefined reference to `gtk_main_quit'
event.o: In function `on_activate_MODELE':
event.o(.text+0x65): undefined reference to `gdk_draw_rectangle'
event.o(.text+0x93): undefined reference to `gtk_widget_draw'
event.o: In function `on_expose_event':
event.o(.text+0xf8): undefined reference to `gdk_draw_pixmap'
event.o: In function `on_configure_event':
.....
.....
...
and go on.
Any ideas?
Mariusz Bozewicz
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]