1
###########################################################################
3
# File: Makefile.mingw.common
4
# Does: Common definitions for all Makefile.mingw files
5
# Author: Bob Jamison & the Inkscape Guys
6
###########################################################################
8
####### Sense whether we are on a DOS box or cross-compiling
24
##########################################################################
26
# $(S) will be set to one of these
27
##########################################################################
33
##########################################################################
34
# CROSS / NATIVE SWITCHES
35
##########################################################################
40
##########################################################################
41
# CROSS COMPILER SETTINGS
42
##########################################################################
44
CC = i686-pc-mingw32-gcc
45
CXX = i686-pc-mingw32-g++
46
AS = i686-pc-mingw32-as
47
AR = i686-pc-mingw32-ar
48
RANLIB = i686-pc-mingw32-ranlib
49
WINDRES = i686-pc-mingw32-windres
50
LD = i686-pc-mingw32-ld
51
DLLWRAP = i686-pc-mingw32-dllwrap
52
DLLTOOL = i686-pc-mingw32-dlltool
54
####### file separator
57
####### file manipulation programs
64
####### Where is your GTK directory?
67
####### Same thing, file system style
70
DTG := $(shell date +%y%m%d.%H%M)
74
##########################################################################
75
# NATIVE COMPILER SETTINGS
76
##########################################################################
87
####### file separator
90
####### file manipulation programs
93
####### are we on WinNt and beyond?
94
ifeq ($(DOSSHELL),CMD_EXE)
104
####### Where is your GTK directory?
107
####### Same thing, DOS style
110
####### Command to process .po files --> .mo
111
MSGFMT = $(GTKDOS)$(S)bin$(S)msgfmt
117
##########################################################################
118
# END CROSS / NATIVE SWITCHES
119
##########################################################################
122
###### VERSION NUMBER
123
# VERSION_NR = 0.41+devel
124
# VERSION = \"$(VERSION_NR)-${DTG}\"
126
VERSION_NR = 0.42+pre0
127
VERSION = \"$(VERSION_NR)\"
129
####### the XP_WIN def is necessary for libjs.a
130
CFLAGS = -O3 -Wall -mms-bitfields -DVERSION=$(VERSION) \
131
-DXP_WIN -D_INTL_REDIRECT_INLINE -DHAVE_CONFIG_H
134
####### IMPLICIT RULES
136
$(CXX) $(CFLAGS) $(INC) -c -o $@ $<
139
$(CC) $(CFLAGS) $(INC) -c -o $@ $<
145
##########################################################################
146
# INCLUDES AND LIBRARIES
147
##########################################################################
150
-I$(GTK)/include/glibmm-2.4 -I$(GTK)/lib/glibmm-2.4/include \
151
-I$(GTK)/include/gtkmm-2.4 -I$(GTK)/lib/gtkmm-2.4/include \
152
-I$(GTK)/include/gdkmm-2.4 -I$(GTK)/lib/gdkmm-2.4/include \
153
-I$(GTK)/include/pangomm-1.4 \
154
-I$(GTK)/include/atkmm-1.6 \
155
-I$(GTK)/include/sigc++-2.0 -I$(GTK)/lib/sigc++-2.0/include \
156
-I$(GTK)/include/gtk-2.0 -I$(GTK)/lib/gtk-2.0/include \
157
-I$(GTK)/include/atk-1.0 -I$(GTK)/include/pango-1.0 \
158
-I$(GTK)/include/glib-2.0 -I$(GTK)/lib/glib-2.0/include
161
####### New way with static C++ libs
162
GTKLIB = -L$(GTK)/lib \
163
-lgtkmm-2.4 -lgdkmm-2.4 -lglibmm-2.4 \
164
-latkmm-1.6 -lpangomm-1.4 -lsigc-2.0 \
165
-lgtk-win32-2.0 -lgdk-win32-2.0 -latk-1.0 \
166
-lgdk_pixbuf-2.0 -lm -lpangoft2-1.0 -lpangowin32-1.0 -lpango-1.0 \
167
-lgobject-2.0 -lgmodule-2.0 -lgthread-2.0 -lglib-2.0
170
####### (note: perl's config.h has some nested comments)
171
PERLINC = -Wno-comment -I$(GTK)/perl/lib/CORE
172
PERLLIB = -L$(GTK)/perl/lib/CORE -lperl58
175
PYTHONINC = -I$(GTK)/python/include
176
PYTHONLIB = -L$(GTK)/python/libs -lpython24
177
#PYTHONLIB = -L$(GTK)/python/libs/libpython24.a
179
####### remove -DLIBXML_STATIC
180
INC = -I. -I.. -I../.. $(GTKINC) -I$(GTK)/include \
181
$(PERLINC) $(PYTHONINC) -I$(GTK)/include/libxml2 \
182
-I$(GTK)/include/freetype2 \
185
LIBS = $(GTKLIB) $(PERLLIB) $(PYTHONLIB) -lxml2 \
186
$(GTK)/lib/iconv.lib \
187
-lfreetype6.dll -lfontconfig-1.dll -lpng -lpopt $(GTK)/lib/zdll.lib \
188
-lgc -mwindows -lws2_32 -lintl
191
##########################################################################
192
# END INCLUDES AND LIBRARIES
193
##########################################################################
198
##########################################################################
200
##########################################################################