]> Pileus Git - ~andy/gtk/blob - gdk/makefile.cygwin
028e7857430bf8279ec273ac5e7d1ebca4d17c71
[~andy/gtk] / gdk / makefile.cygwin
1 ## Makefile for building the GDK DLL with gcc-2.95 or later on cygwin
2 ## Use: make -f makefile.cygwin
3
4 ## You must first build the Win32-dependent sources in the win32 subdirectory.
5
6 ## There is no install target, you have to decide where and 
7 ## how to install for yourself.
8
9 OPTIMIZE = -g -O
10
11 ################################################################
12
13 # Nothing much configurable below
14
15 CC = gcc -mno-cygwin -mpentium -fnative-struct
16
17 CP = cp
18 LD = ld
19
20 GLIB_VER=1.3
21 GTK_VER=1.3
22
23 GLIB = ../../glib
24 CFLAGS = $(OPTIMIZE) -I . -I .. -I $(GLIB) -DG_ENABLE_DEBUG -DHAVE_CONFIG_H -DGDK_VERSION=\"$(GTK_VER)\"
25
26 all: \
27         ../config.h \
28         gdkconfig.h \
29         gdk-$(GTK_VER).dll
30
31 gdk_OBJECTS = \
32         gdk.o           \
33         gdkcolor.o      \
34         gdkcursor.o     \
35         gdkdraw.o       \
36         gdkevents.o     \
37         gdkfont.o       \
38         gdkgc.o         \
39         gdkglobals.o    \
40         gdkimage.o      \
41         gdkrgb.o        \
42         gdkrectangle.o  \
43         gdkwindow.o
44
45 ../config.h : ../config.h.win32
46         $(CP) ../config.h.win32 ../config.h
47
48 gdkconfig.h : gdkconfig.h.win32
49         $(CP) gdkconfig.h.win32 gdkconfig.h
50
51 gdk-$(GTK_VER).dll : $(gdk_OBJECTS) gdk.def win32/libgdk-win32.a win32/gdk-win32res.o
52         $(GLIB)/build-dll gdk $(GTK_VER) gdk.def $(gdk_OBJECTS) -L win32 -lgdk-win32 -lwntab32x -L $(GLIB) -lglib-$(GLIB_VER) -lgdi32 -luser32 -limm32 -lshell32 -lole32 -luuid $(LDFLAGS) win32/gdk-win32res.o 
53
54 .SUFFIXES: .c .o .i
55
56 .c.o :
57         $(CC) $(CFLAGS) -c -DGDK_COMPILATION -DG_LOG_DOMAIN=\"Gdk\" $<
58
59 .c.i :
60         $(CC) $(CFLAGS) -E -DGDK_COMPILATION -DG_LOG_DOMAIN=\"Gdk\" $< >$@
61
62 clean:
63         -rm *.exe *.o *.dll *.a *.exp *.base