s/retrive/retrieve/
[platform/upstream/glib.git] / gmodule / makefile.mingw.in
1 ## Makefile for building the gmodule DLL with gcc for mingw. The build
2 ## uses tools running on cygwin, however.
3
4 ## Use: make -f makefile.mingw
5
6 TOP = ../..
7
8 include ../build/win32/make.mingw
9
10 ################################################################
11
12 # Nothing much configurable below
13
14 INCLUDES = -I .. -I ../glib -I .
15 DEFINES = -DHAVE_CONFIG_H -DG_LOG_DOMAIN=\"GModule\" -DG_ENABLE_DEBUG
16
17 all : \
18         gmoduleconf.h \
19         libgmodule-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@.a \
20         testgmodule.exe \
21         libgplugin_a.dll libgplugin_b.dll
22
23 gmodule_OBJECTS = \
24         gmodule.o
25
26 gmoduleconf.h: gmoduleconf.h.win32
27         cp $< $@
28
29 ################ The gmodule DLL
30
31 libgmodule-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@.a : $(gmodule_OBJECTS) gmodule.def gmodule-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@.rc
32         $(BUILD_DLL) gmodule-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@ @LT_CURRENT@:@LT_REVISION@:@LT_AGE@ $(CFLAGS) gmodule.def $(gmodule_OBJECTS) -L ../glib -lglib-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@
33
34 gmodule-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@.rc : gmodule.rc
35         cp $< $@
36
37 ################ test prog
38
39 testgmodule.exe : libgmodule-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@.a testgmodule.o 
40 # We have to generate an .exp file separately with dlltool, and link
41 # with that. Sigh.
42         dlltool --output-exp testgmodule.exp testgmodule.o
43         $(CC) $(CFLAGS) -o testgmodule.exe testgmodule.o testgmodule.exp -L ../glib -lglib-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@ -L . -lgmodule-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@ $(LFLAGS)
44
45 libgplugin_a.dll : libgplugin_a.o
46         $(BUILD_DLL) libgplugin_a - libgplugin_a.o -L ../glib -lglib-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@ -L . -lgmodule-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@
47
48 libgplugin_b.dll : libgplugin_b.o
49         $(BUILD_DLL) libgplugin_b - libgplugin_b.o -L ../glib -lglib-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@ -L . -lgmodule-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@
50
51 ################ Other stuff
52
53 clean::
54         -rm gmoduleconf.h