summaryrefslogtreecommitdiffstats
path: root/src/Makefile.mingw
diff options
context:
space:
mode:
authorMenTaLguY <mental@rydia.net>2006-01-16 02:36:01 +0000
committermental <mental@users.sourceforge.net>2006-01-16 02:36:01 +0000
commit179fa413b047bede6e32109e2ce82437c5fb8d34 (patch)
treea5a6ac2c1708bd02288fbd8edb2ff500ff2e0916 /src/Makefile.mingw
downloadinkscape-179fa413b047bede6e32109e2ce82437c5fb8d34.tar.gz
inkscape-179fa413b047bede6e32109e2ce82437c5fb8d34.zip
moving trunk for module inkscape
(bzr r1)
Diffstat (limited to 'src/Makefile.mingw')
-rw-r--r--src/Makefile.mingw123
1 files changed, 123 insertions, 0 deletions
diff --git a/src/Makefile.mingw b/src/Makefile.mingw
new file mode 100644
index 000000000..b3afb5cfe
--- /dev/null
+++ b/src/Makefile.mingw
@@ -0,0 +1,123 @@
+###########################################################################
+# $Id$
+###########################################################################
+# Makefile for building with MinGW
+###########################################################################
+
+include ../Makefile.mingw.common
+
+all: generated outputs
+
+###################################
+# G E N E R A T E D F I L E S
+###################################
+
+generated: helper/sp-marshal.h helper/sp-marshal.cpp inkscape_version.h
+
+
+
+helper/sp-marshal.h: helper/sp-marshal.h.mingw
+ $(CP) $(subst /,$(S), $<) $(subst /,$(S), $@)
+
+helper/sp-marshal.cpp: helper/sp-marshal.cpp.mingw
+ $(CP) $(subst /,$(S), $<) $(subst /,$(S), $@)
+
+inkscape_version.h: inkscape_version.h.mingw
+ $(CP) inkscape_version.h.mingw inkscape_version.h
+
+
+###################################
+# D E P E N D E N C I E S
+###################################
+
+include ./make.ofiles
+include ./make.dep
+
+INC += $(INCLUDEPATH)
+
+OBJ = $(OBJECTS)
+
+
+
+###################################
+# O U T P U T S
+###################################
+
+outputs: inkscape.exe inkview.exe
+
+
+RES=inkres.o
+
+inkscape.exe: libinkscape.a main.o winmain.o $(RES)
+ $(CXX) --export-dynamic -o inkscape.exe main.o winmain.o $(RES) libinkscape.a $(LIBS)
+# strip inkscape.exe
+
+# DLL version. we need to make this work
+#inkscape.exe: inkscape.dll main.o winmain.o $(RES)
+# $(CXX) -o inkscape.exe main.o winmain.o $(RES) inkscape.la $(LIBS)
+# strip inkscape.exe
+
+inkview.exe: libinkscape.a inkview.o $(RES)
+ $(CXX) -o inkview.exe inkview.o $(RES) libinkscape.a $(LIBS)
+# strip inkview.exe
+
+# DLL version. we need to make this work
+# inkview.exe: inkscape.dll inkview.o $(RES)
+# $(CXX) -o inkview.exe inkview.o $(RES) libinkscapedll.a $(LIBS)
+# strip inkview.exe
+
+inkres.o: inkscape.rc
+ $(WINDRES) inkscape.rc $(RES)
+
+inkscape.dll: libinkscape.a inkscape.def
+ $(DLLWRAP) --output-lib=inkscape.la \
+ --def=inkscape.def --driver-name=g++ \
+ -o inkscape.dll libinkscape.a $(LIBS)
+
+inkscape.def: libinkscape.a
+ perl makedef.pl
+
+libinkscape.a: $(OBJ)
+ -$(RM) libinkscape.a
+ ar crv libinkscape.a $(OBJ)
+ $(RANLIB) libinkscape.a
+
+inkscape.la: inkscape.dll
+
+
+
+###################################
+# P L U G I N S
+###################################
+
+.o.dll: $<
+ $(DLLWRAP) --def=plugin.def --driver-name=g++ \
+ -o $@ $< $(LIBS)
+
+PLUGS = extension/plugin/gimpgrad.dll
+
+plugins: $(PLUGS)
+
+extension/plugin/gimpgrad.dll: extension/plugin/gimpgrad.o inkscape.la
+ $(DLLWRAP) --def=plugin.def --driver-name=g++ \
+ -dllname $@ $< inkscape.la $(LIBS) -lgc
+ strip $@
+
+
+
+
+###################################
+# C L E A N U P
+###################################
+
+clean:
+ $(foreach a, $(OBJ), $(shell $(RM) $(subst /,$(S), $(a))))
+ -$(RM) main.o winmain.o inkview.o
+ -$(RM) *.a
+ -$(RM) *.la
+ -$(RM) inkscape.def
+ -$(RM) *.dll
+ -$(RM) extension$(S)plugin$(S)*.o
+ -$(RM) extension$(S)plugin$(S)*.dll
+
+