summaryrefslogtreecommitdiff
path: root/gdk/makefile.cygwin
blob: 3bb8f57856386bc93f2d40a4910ad162b996f1b6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
## Makefile for building the GDK DLL with gcc-2.95 or later on cygwin
## Use: make -f makefile.cygwin

## You must first build the Win32-dependent sources in the win32 subdirectory.

## There is no install target, you have to decide where and 
## how to install for yourself.

OPTIMIZE = -g -O

################################################################

# Nothing much configurable below

CC = gcc -mno-cygwin -mpentium -fnative-struct

CP = cp
LD = ld

GLIB_VER=1.3
GTK_VER=1.3

GLIB = ../../glib
CFLAGS = $(OPTIMIZE) -I . -I .. -I $(GLIB) -DG_ENABLE_DEBUG -DHAVE_CONFIG_H -DGDK_VERSION=\"$(GTK_VER)\"

all: \
	../config.h \
	gdkconfig.h \
	gdk-$(GTK_VER).dll

gdk_OBJECTS = \
	gdk.o		\
	gdkcolor.o	\
	gdkdraw.o	\
	gdkevents.o     \
	gdkfont.o	\
	gdkgc.o		\
	gdkglobals.o	\
	gdkimage.o	\
	gdkrgb.o	\
	gdkrectangle.o	\
	gdkwindow.o

../config.h : ../config.h.win32
	$(CP) ../config.h.win32 ../config.h

gdkconfig.h : gdkconfig.h.win32
	$(CP) gdkconfig.h.win32 gdkconfig.h

gdk-$(GTK_VER).dll : $(gdk_OBJECTS) gdk.def win32/libgdk-win32.a
	$(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 

.SUFFIXES: .c .o .i

.c.o :
	$(CC) $(CFLAGS) -c -DGDK_COMPILATION -DG_LOG_DOMAIN=\"Gdk\" $<

.c.i :
	$(CC) $(CFLAGS) -E -DGDK_COMPILATION -DG_LOG_DOMAIN=\"Gdk\" $< >$@

clean:
	-rm *.exe *.o *.dll *.a *.exp *.base