makefile.msc.in 13.4 KB
Newer Older
Tor Lillqvist's avatar
Tor Lillqvist committed
1 2 3 4 5 6
## Makefile for building the gtk DLL with Microsoft C
## Use: nmake -f makefile.msc

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

7
TOP = ..\..
8
!INCLUDE $(TOP)/glib/build/win32/make.msc
Tor Lillqvist's avatar
Tor Lillqvist committed
9 10 11 12 13 14 15

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

# Possibly override versions from build/win32/module.defs
GTK_VER = @GTK_MAJOR_VERSION@.@GTK_MINOR_VERSION@
GDK_PIXBUF_VER = @GDK_PIXBUF_MAJOR@.@GDK_PIXBUF_MINOR@

16

Tor Lillqvist's avatar
Tor Lillqvist committed
17 18 19
GDK_LIBS = ../gdk/gdk-win32-$(GTK_VER).lib
GTK_LIBS = gtk-win32-$(GTK_VER).lib
GDK_PIXBUF_LIBS = ../gdk-pixbuf/gdk_pixbuf-$(GDK_PIXBUF_VER).lib
20
GTK_BINARY_VERSION = @GTK_MAJOR_VERSION@.@GTK_MINOR_VERSION@.@LT_CURRENT@
Tor Lillqvist's avatar
Tor Lillqvist committed
21 22 23 24 25 26 27

# Perl and awk are needed to generate some source files.
# These generated source files are distribuyted with the Win32 GTk+ source
# distributions, so don't worry if you don't have perl and awk.
PERL = perl
AWK = gawk

Hans Breuer's avatar
Hans Breuer committed
28
INCLUDES = -FImsvc_recommended_pragmas.h -I . -I .. -I ../gdk -I ../gdk-pixbuf
Hans Breuer's avatar
Hans Breuer committed
29
DEPCFLAGS = $(PANGO_CFLAGS) $(GLIB_CFLAGS) $(LIBICONV_CFLAGS) \
30 31
		$(INTL_CFLAGS) $(ATK_CFLAGS)
LDFLAGS = $(ATK_LIBS) /link /machine:ix86 $(LINKDEBUG)
Tor Lillqvist's avatar
Tor Lillqvist committed
32
# Some files use near as an identifier
33
# Don't define GTK_COMPILATION here, because it's for gtk-x.x.dll only
34
DEFINES = $(G_DEBUGGING) -DGTK_DISABLE_COMPAT_H -DG_LOG_DOMAIN=\"Gtk\" -Dnear=xxnear \
Hans Breuer's avatar
Hans Breuer committed
35 36
	-DPANGO_ENABLE_BACKEND \
	-DGTK_VERSION=\"$(GTK_VER)\" -DGTK_BINARY_VERSION=\"$(GTK_BINARY_VERSION)\" \
Hans Breuer's avatar
Hans Breuer committed
37 38
	-DGTK_HOST=\"win32\" \
	-DGTK_FILE_SYSTEM_ENABLE_UNSUPPORTED
Tor Lillqvist's avatar
Tor Lillqvist committed
39 40 41

TOUCH = copy makefile.msc+nul

42 43 44 45 46
gtk-stocks-icons :
	cd stock-icons
	nmake -nologo -f makefile.msc
	cd ..

Tor Lillqvist's avatar
Tor Lillqvist committed
47 48 49
all :						\
	..\config.h				\
	generated				\
50
	gtk-stocks-icons			\
51
	libgtk-win32-$(GTK_VER)-0.dll		\
52
	gtk-query-immodules-$(GTK_VER).exe \
Hans Breuer's avatar
Hans Breuer committed
53 54
#	gtk-win32-$(GTK_VER)s.lib \
#	gtk-x11-$(GTK_VER).dll
Tor Lillqvist's avatar
Tor Lillqvist committed
55

56
gtk_OBJECTS = 					\
Tor Lillqvist's avatar
Tor Lillqvist committed
57 58 59
	fnmatch.obj				\
	gtkaccelgroup.obj			\
	gtkaccellabel.obj			\
60
	gtkaccelmap.obj	\
61
	gtkaccessible.obj \
Hans Breuer's avatar
Hans Breuer committed
62 63
	gtkaction.obj	\
	gtkactiongroup.obj	\
Tor Lillqvist's avatar
Tor Lillqvist committed
64 65 66 67 68 69 70 71 72 73
	gtkadjustment.obj			\
	gtkalignment.obj			\
	gtkarrow.obj				\
	gtkaspectframe.obj			\
	gtkbin.obj				\
	gtkbindings.obj				\
	gtkbbox.obj				\
	gtkbox.obj				\
	gtkbutton.obj				\
	gtkcalendar.obj				\
Hans Breuer's avatar
Hans Breuer committed
74
	gtkcelleditable.obj			\
75
	gtkcelllayout.obj			\
76 77 78 79
	gtkcellrenderer.obj			\
	gtkcellrenderertext.obj			\
	gtkcellrenderertoggle.obj		\
	gtkcellrendererpixbuf.obj		\
Hans Breuer's avatar
Hans Breuer committed
80 81 82
	gtkcellrendererseptext.obj		\
	gtkcellview.obj		\
	gtkcellviewmenuitem.obj	\
Tor Lillqvist's avatar
Tor Lillqvist committed
83 84 85 86
	gtkcheckbutton.obj			\
	gtkcheckmenuitem.obj			\
	gtkclipboard.obj			\
	gtkclist.obj				\
87
	gtkcolorbutton.obj				\
Tor Lillqvist's avatar
Tor Lillqvist committed
88 89 90
	gtkcolorsel.obj				\
	gtkcolorseldialog.obj			\
	gtkcombo.obj				\
Hans Breuer's avatar
Hans Breuer committed
91 92
	gtkcombobox.obj			\
	gtkcomboboxentry.obj		\
Tor Lillqvist's avatar
Tor Lillqvist committed
93 94 95 96 97 98 99 100
	gtkcontainer.obj			\
	gtkctree.obj				\
	gtkcurve.obj				\
	gtkdialog.obj				\
	gtkdnd.obj				\
	gtkdrawingarea.obj			\
	gtkeditable.obj				\
	gtkentry.obj				\
101
	gtkentrycompletion.obj		\
Tor Lillqvist's avatar
Tor Lillqvist committed
102
	gtkeventbox.obj				\
103
	gtkexpander.obj			\
Hans Breuer's avatar
Hans Breuer committed
104 105 106
	gtkfilechooser.obj			\
	gtkfilechooserdefault.obj			\
	gtkfilechooserdialog.obj			\
107
	gtkfilechooserembed.obj		\
Hans Breuer's avatar
Hans Breuer committed
108 109 110 111
	gtkfilechooserentry.obj			\
	gtkfilechooserutils.obj			\
	gtkfilechooserwidget.obj			\
	gtkfilefilter.obj			\
Tor Lillqvist's avatar
Tor Lillqvist committed
112
	gtkfilesel.obj				\
Hans Breuer's avatar
Hans Breuer committed
113 114 115
	gtkfilesystem.obj				\
	gtkfilesystemmodel.obj				\
	gtkfilesystemwin32.obj				\
Tor Lillqvist's avatar
Tor Lillqvist committed
116 117
	gtkfixed.obj				\
	gtkfontsel.obj				\
118
	gtkfontbutton.obj				\
Tor Lillqvist's avatar
Tor Lillqvist committed
119 120 121 122 123 124 125 126 127 128 129 130 131
	gtkframe.obj				\
	gtkgamma.obj				\
	gtkgc.obj				\
	gtkhandlebox.obj			\
	gtkhbbox.obj				\
	gtkhbox.obj				\
	gtkhpaned.obj				\
	gtkhruler.obj				\
	gtkhscale.obj				\
	gtkhscrollbar.obj			\
	gtkhseparator.obj			\
	gtkhsv.obj				\
	gtkiconfactory.obj			\
132 133
	gtkicontheme.obj			\
	gtkiconthemeparser.obj			\
Tor Lillqvist's avatar
Tor Lillqvist committed
134
	gtkimage.obj				\
135
	gtkimagemenuitem.obj	\
Tor Lillqvist's avatar
Tor Lillqvist committed
136 137
	gtkimcontext.obj			\
	gtkimcontextsimple.obj			\
Tor Lillqvist's avatar
Tor Lillqvist committed
138
	gtkimmodule.obj				\
Tor Lillqvist's avatar
Tor Lillqvist committed
139 140 141 142 143
	gtkimmulticontext.obj			\
	gtkinputdialog.obj			\
	gtkinvisible.obj			\
	gtkitem.obj				\
	gtkitemfactory.obj			\
Hans Breuer's avatar
Hans Breuer committed
144
	gtkkeyhash.obj	\
Tor Lillqvist's avatar
Tor Lillqvist committed
145 146 147 148
	gtklabel.obj				\
	gtklayout.obj				\
	gtklist.obj				\
	gtklistitem.obj				\
149
	gtkliststore.obj				\
Tor Lillqvist's avatar
Tor Lillqvist committed
150
	gtkmain.obj				\
151 152
	gtkmarshalers.obj		\
	gtkmarshal.obj		\
Tor Lillqvist's avatar
Tor Lillqvist committed
153 154 155 156 157 158 159 160
	gtkmenu.obj				\
	gtkmenubar.obj				\
	gtkmenuitem.obj				\
	gtkmenushell.obj			\
	gtkmessagedialog.obj			\
	gtkmisc.obj				\
	gtknotebook.obj				\
	gtkobject.obj				\
Tor Lillqvist's avatar
Tor Lillqvist committed
161
	gtkoldeditable.obj			\
Tor Lillqvist's avatar
Tor Lillqvist committed
162 163
	gtkoptionmenu.obj			\
	gtkpaned.obj				\
164
	gtkpathbar.obj				\
Tor Lillqvist's avatar
Tor Lillqvist committed
165
	gtkpixmap.obj				\
166
#	gtkplug.obj				\
Tor Lillqvist's avatar
Tor Lillqvist committed
167 168 169
	gtkpreview.obj				\
	gtkprogress.obj				\
	gtkprogressbar.obj			\
Hans Breuer's avatar
Hans Breuer committed
170
	gtkradioaction.obj			\
Tor Lillqvist's avatar
Tor Lillqvist committed
171
	gtkradiobutton.obj			\
172
	gtkradiotoolbutton.obj			\
Tor Lillqvist's avatar
Tor Lillqvist committed
173 174
	gtkradiomenuitem.obj			\
	gtkrange.obj				\
175
	gtkrbtree.obj	\
Tor Lillqvist's avatar
Tor Lillqvist committed
176 177 178 179 180 181 182
	gtkrc.obj				\
	gtkruler.obj				\
	gtkscale.obj				\
	gtkscrollbar.obj			\
	gtkscrolledwindow.obj			\
	gtkselection.obj			\
	gtkseparator.obj			\
183
	gtkseparatormenuitem.obj \
184
	gtkseparatortoolitem.obj \
185
	gtksettings.obj \
Tor Lillqvist's avatar
Tor Lillqvist committed
186
	gtksignal.obj				\
187
	gtksizegroup.obj \
188
#	gtksocket.obj				\
Tor Lillqvist's avatar
Tor Lillqvist committed
189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206
	gtkspinbutton.obj			\
	gtkstyle.obj				\
	gtkstatusbar.obj			\
	gtkstock.obj				\
	gtktable.obj				\
	gtktearoffmenuitem.obj			\
	gtktext.obj				\
	gtktextbtree.obj			\
	gtktextbuffer.obj			\
	gtktextchild.obj			\
	gtktextdisplay.obj			\
	gtktextiter.obj				\
	gtktextlayout.obj			\
	gtktextmark.obj				\
	gtktextsegment.obj			\
	gtktexttag.obj				\
	gtktexttagtable.obj			\
	gtktexttypes.obj			\
207
	gtktextutil.obj	\
Tor Lillqvist's avatar
Tor Lillqvist committed
208 209 210
	gtktextview.obj				\
	gtkthemes.obj				\
	gtktipsquery.obj			\
Hans Breuer's avatar
Hans Breuer committed
211
	gtktoggleaction.obj			\
Tor Lillqvist's avatar
Tor Lillqvist committed
212
	gtktogglebutton.obj			\
213
	gtktoggletoolbutton.obj			\
Tor Lillqvist's avatar
Tor Lillqvist committed
214
	gtktoolbar.obj				\
215 216
	gtktoolbutton.obj				\
	gtktoolitem.obj				\
Tor Lillqvist's avatar
Tor Lillqvist committed
217 218
	gtktooltips.obj				\
	gtktree.obj				\
219 220
	gtktreedatalist.obj	\
	gtktreednd.obj				\
Tor Lillqvist's avatar
Tor Lillqvist committed
221
	gtktreeitem.obj				\
Tor Lillqvist's avatar
Tor Lillqvist committed
222
	gtktreemodel.obj			\
223
	gtktreemodelfilter.obj			\
224 225
	gtktreemodelsort.obj			\
	gtktreeselection.obj			\
226
	gtktreesortable.obj \
227 228 229
	gtktreestore.obj			\
	gtktreeview.obj			\
	gtktreeviewcolumn.obj			\
Tor Lillqvist's avatar
Tor Lillqvist committed
230
	gtktypeutils.obj			\
231
	gtktypebuiltins.obj \
Hans Breuer's avatar
Hans Breuer committed
232
	gtkuimanager.obj	\
Tor Lillqvist's avatar
Tor Lillqvist committed
233 234 235 236 237 238 239 240 241
	gtkvbbox.obj				\
	gtkvbox.obj				\
	gtkviewport.obj				\
	gtkvpaned.obj				\
	gtkvruler.obj				\
	gtkvscale.obj				\
	gtkvscrollbar.obj			\
	gtkvseparator.obj			\
	gtkwidget.obj				\
242 243
	gtkwindow.obj				\
	gtkwindow-decorate.obj
Tor Lillqvist's avatar
Tor Lillqvist committed
244 245

# Source headers which are non-autogenerated headers
246
gtk_public_h_sources =		\
Tor Lillqvist's avatar
Tor Lillqvist committed
247 248 249
	gtk.h			\
	gtkaccelgroup.h		\
	gtkaccellabel.h		\
250
	gtkaccelmap.h		\
251
	gtkaccessible.h \
252 253
	gtkaction.h		\
	gtkactiongroup.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
254 255 256 257
	gtkadjustment.h		\
	gtkalignment.h		\
	gtkarrow.h		\
	gtkaspectframe.h	\
258
	gtkbbox.h		\
Tor Lillqvist's avatar
Tor Lillqvist committed
259 260 261 262 263
	gtkbin.h		\
	gtkbindings.h		\
	gtkbox.h		\
	gtkbutton.h		\
	gtkcalendar.h		\
264 265 266 267 268 269
	gtkcelleditable.h	\
	gtkcelllayout.h		\
	gtkcellrenderer.h	\
	gtkcellrendererpixbuf.h	\
	gtkcellrenderertext.h	\
	gtkcellrenderertoggle.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
270 271
	gtkcheckbutton.h	\
	gtkcheckmenuitem.h	\
272
	gtkclipboard.h		\
Tor Lillqvist's avatar
Tor Lillqvist committed
273
	gtkclist.h		\
274
	gtkclipboard.h		\
275
	gtkcolorbutton.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
276 277 278
	gtkcolorsel.h		\
	gtkcolorseldialog.h	\
	gtkcombo.h		\
279 280
	gtkcombobox.h		\
	gtkcomboboxentry.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
281 282 283 284 285 286 287 288 289
	gtkcontainer.h		\
	gtkctree.h		\
	gtkcurve.h		\
	gtkdebug.h		\
	gtkdialog.h		\
	gtkdnd.h		\
	gtkdrawingarea.h	\
	gtkeditable.h		\
	gtkentry.h		\
290
	gtkentrycompletion.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
291 292
	gtkenums.h		\
	gtkeventbox.h		\
293
	gtkexpander.h		\
Hans Breuer's avatar
Hans Breuer committed
294 295 296 297
	gtkfilechooser.h        \
	gtkfilechooserdialog.h  \
	gtkfilechooserwidget.h  \
	gtkfilefilter.h		\
Tor Lillqvist's avatar
Tor Lillqvist committed
298 299
	gtkfilesel.h		\
	gtkfixed.h		\
300
	gtkfontbutton.h		\
Tor Lillqvist's avatar
Tor Lillqvist committed
301 302 303 304 305 306 307 308 309 310 311 312 313
	gtkfontsel.h		\
	gtkframe.h		\
	gtkgamma.h		\
	gtkgc.h			\
	gtkhandlebox.h		\
	gtkhbbox.h		\
	gtkhbox.h		\
	gtkhpaned.h		\
	gtkhruler.h		\
	gtkhscale.h		\
	gtkhscrollbar.h		\
	gtkhseparator.h		\
	gtkhsv.h		\
314
	gtkiconfactory.h	\
315
	gtkicontheme.h		\
Tor Lillqvist's avatar
Tor Lillqvist committed
316
	gtkimage.h		\
317
	gtkimagemenuitem.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
318
	gtkimcontext.h		\
319
	gtkimcontextsimple.h	\
320
	gtkimmodule.h		\
Tor Lillqvist's avatar
Tor Lillqvist committed
321 322 323 324 325 326 327 328 329
	gtkimmulticontext.h	\
	gtkinputdialog.h	\
	gtkinvisible.h		\
	gtkitem.h		\
	gtkitemfactory.h	\
	gtklabel.h		\
	gtklayout.h		\
	gtklist.h		\
	gtklistitem.h		\
330
	gtkliststore.h		\
Tor Lillqvist's avatar
Tor Lillqvist committed
331
	gtkmain.h		\
332
	gtkmarshal.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
333 334 335 336
	gtkmenu.h		\
	gtkmenubar.h		\
	gtkmenuitem.h		\
	gtkmenushell.h		\
337
	gtkmessagedialog.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
338 339 340
	gtkmisc.h		\
	gtknotebook.h		\
	gtkobject.h		\
341
	gtkoldeditable.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
342 343 344 345 346 347 348 349
	gtkoptionmenu.h		\
	gtkpaned.h		\
	gtkpixmap.h		\
	gtkplug.h		\
	gtkpreview.h		\
	gtkprivate.h		\
	gtkprogress.h		\
	gtkprogressbar.h	\
350
	gtkradioaction.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
351 352
	gtkradiobutton.h	\
	gtkradiomenuitem.h	\
353
	gtkradiotoolbutton.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
354 355 356 357 358 359 360 361
	gtkrange.h		\
	gtkrc.h			\
	gtkruler.h		\
	gtkscale.h		\
	gtkscrollbar.h		\
	gtkscrolledwindow.h	\
	gtkselection.h		\
	gtkseparator.h		\
362 363 364 365
	gtkseparatormenuitem.h	\
	gtkseparatortoolitem.h	\
	gtksettings.h		\
	gtksignal.h		\
366
	gtksizegroup.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
367 368 369 370
	gtksignal.h		\
	gtksocket.h		\
	gtkspinbutton.h		\
	gtkstatusbar.h		\
371
	gtkstock.h		\
372
	gtkstyle.h		\
Tor Lillqvist's avatar
Tor Lillqvist committed
373 374
	gtktable.h		\
	gtktearoffmenuitem.h	\
375
	gtktext.h		\
Tor Lillqvist's avatar
Tor Lillqvist committed
376
	gtktextbuffer.h		\
377 378
	gtktextchild.h		\
	gtktextdisplay.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
379
	gtktextiter.h		\
380
	gtktextlayout.h		\
Tor Lillqvist's avatar
Tor Lillqvist committed
381 382 383 384 385
	gtktextmark.h		\
	gtktexttag.h		\
	gtktexttagtable.h	\
	gtktextview.h		\
	gtktipsquery.h		\
386
	gtktoggleaction.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
387
	gtktogglebutton.h	\
388
	gtktoggletoolbutton.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
389
	gtktoolbar.h		\
390 391
	gtktoolbutton.h		\
	gtktoolitem.h		\
Tor Lillqvist's avatar
Tor Lillqvist committed
392 393
	gtktooltips.h		\
	gtktree.h		\
394
	gtktreednd.h		\
Tor Lillqvist's avatar
Tor Lillqvist committed
395
	gtktreeitem.h		\
396
	gtktreemodel.h		\
397
	gtktreemodelfilter.h	\
398
	gtktreemodelsort.h	\
399
	gtktreeselection.h	\
400
	gtktreesortable.h	\
401 402 403
	gtktreestore.h		\
	gtktreeview.h		\
	gtktreeviewcolumn.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
404
	gtktypeutils.h		\
405
	gtkuimanager.h	\
Tor Lillqvist's avatar
Tor Lillqvist committed
406 407 408 409 410 411 412 413 414 415 416
	gtkvbbox.h		\
	gtkvbox.h		\
	gtkviewport.h		\
	gtkvpaned.h		\
	gtkvruler.h		\
	gtkvscale.h		\
	gtkvscrollbar.h		\
	gtkvseparator.h		\
	gtkwidget.h		\
	gtkwindow.h

417 418
# these aren't use here, but listed for reference
gtk_extra_sources = \
419
	gtkversion.h		\
420 421 422
	gtk-boxed.defs		\
	gtkmarshal.list		\

Tor Lillqvist's avatar
Tor Lillqvist committed
423 424 425
..\config.h : ..\config.h.win32
	copy ..\config.h.win32 ..\config.h

Hans Breuer's avatar
Hans Breuer committed
426 427
# Removed: gtk.defs 
GENERATED = gtktypebuiltins.h gtktypebuiltins.c gtkmarshal.h gtkmarshal.c gtkmarshalers.h gtkmarshalers.c
Tor Lillqvist's avatar
Tor Lillqvist committed
428 429 430 431 432 433 434

#
# Generated source files:
#
generated : $(GENERATED)
	$(TOUCH) generated

Hans Breuer's avatar
Hans Breuer committed
435
gtk.defs : $(gtk_public_h_sources) makefile.msc
436 437 438 439 440 441 442
	$(PERL) $(GLIB)\gobject\glib-mkenums \
		--comments ";; @comment@" \
		--fprod "; enumerations from \"@filename@\"\n " \
		--vhead "(define-@type@ @EnumName@" \
		--vprod "   (@valuenick@ @VALUENAME@)" \
		--vtail ")" \
		$(gtk_public_h_sources) > xgen-gdef
Hans Breuer's avatar
Hans Breuer committed
443
	copy xgen-gdef gtk.defs
Tor Lillqvist's avatar
Tor Lillqvist committed
444 445

# generate type identifier header (GTK_TYPE_WIDGET_FLAGS)
446 447 448 449 450 451 452 453 454 455 456
# use 'echo' to work around 'command line too long'
gtktypebuiltins.h: $(gtk_public_h_sources) makefile.msc
	echo #ifndef __GTK_TYPE_BUILTINS_H__ > gtktypebuiltins.h
	echo #define __GTK_TYPE_BUILTINS_H__ >> gtktypebuiltins.h
	echo #include "glib-object.h" >> gtktypebuiltins.h
	echo G_BEGIN_DECLS >> gtktypebuiltins.h
	$(PERL) $(GLIB)\gobject\glib-mkenums \
		--fprod "/* enumerations from \"@filename@\" */\n" \
		--vhead "GType @enum_name@_get_type (void);\n#define GTK_TYPE_@ENUMSHORT@ (@enum_name@_get_type())\n" \
		--ftail "G_END_DECLS\n\n#endif /* __GTK_TYPE_BUILTINS_H__ */" \
		$(gtk_public_h_sources) >> gtktypebuiltins.h
Tor Lillqvist's avatar
Tor Lillqvist committed
457

458 459 460 461 462 463 464 465 466
gtktypebuiltins.c: $(gtk_public_h_sources) makefile.msc
	$(PERL) $(GLIB)\gobject\glib-mkenums \
		--fhead "#define GTK_ENABLE_BROKEN\n#include \"gtk.h\"\n#include \"gtkprivate.h\"" \
		--fprod "\n/* enumerations from \"@filename@\" */" \
		--vhead "GType\n@enum_name@_get_type (void)\n{\n  static GType etype = 0;\n  if (etype == 0) {\n    static const G@Type@Value values[] = {" \
		--vprod "      { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
		--vtail "      { 0, NULL, NULL }\n    };\n    etype = g_@type@_register_static (\"@EnumName@\", values);\n  }\n  return etype;\n}\n" \
		$(gtk_public_h_sources) > xgen-gtbc
	copy xgen-gtbc gtktypebuiltins.c
Tor Lillqvist's avatar
Tor Lillqvist committed
467

468 469 470 471 472 473 474 475
# private marshalers
gtkmarshalers.h : gtkmarshalers.list
	$(GLIB)\gobject\glib-genmarshal --prefix=_gtk_marshal gtkmarshalers.list --header >>gtkmarshalers.h

gtkmarshalers.c : gtkmarshalers.list
	$(GLIB)\gobject\glib-genmarshal --prefix=_gtk_marshal gtkmarshalers.list --body >gtkmarshalers.c

# public, deprecated marshalers
Tor Lillqvist's avatar
Tor Lillqvist committed
476
gtkmarshal.h : gtkmarshal.list
477 478 479
	echo #ifndef GTK_DISABLE_DEPRECATED >gtkmarshal.h
	$(GLIB)\gobject\glib-genmarshal --prefix=gtk_marshal gtkmarshal.list --header >>gtkmarshal.h
	echo #endif /* GTK_DISABLE_DEPRECATED */ >>gtkmarshal.h
Tor Lillqvist's avatar
Tor Lillqvist committed
480 481

gtkmarshal.c : gtkmarshal.list
482 483 484 485
	$(GLIB)\gobject\glib-genmarshal --prefix=gtk_marshal gtkmarshal.list --body >gtkmarshal.c

gtksignal.obj : gtksignal.c gtkmarshal.c gtkmarshal.h
	$(CC) $(CFLAGS) -GD -c -DGTK_COMPILATION -DG_LOG_DOMAIN=\"Gtk\" gtksignal.c
Tor Lillqvist's avatar
Tor Lillqvist committed
486

487 488
gtk-win32.res : gtk-win32.rc
	rc -DBUILDNUMBER=0 -r -fo gtk-win32.res gtk-win32.rc
Hans Breuer's avatar
Hans Breuer committed
489

Tor Lillqvist's avatar
Tor Lillqvist committed
490 491 492
#
# Linking:
#
493
libgtk-win32-$(GTK_VER)-0.dll : $(gtk_OBJECTS) gtk.def gtk-win32.res
Hans Breuer's avatar
Hans Breuer committed
494
	$(CC) $(CFLAGS) -LD -Fm -Fe$@ $(gtk_OBJECTS) gtk.res \
495
	$(GDK_LIBS) $(GDK_PIXBUF_LIBS) $(PANGO_LIBS) $(INTL_LIBS) $(GLIB_LIBS) \
496
	gdi32.lib user32.lib advapi32.lib wsock32.lib shell32.lib \
497
	$(LDFLAGS) /implib:gtk-win32-$(GTK_VER).lib /def:gtk.def
498 499 500

gtk-win32-$(GTK_VER)s.lib : $(gtk_OBJECTS)
	lib /out:gtk-win32-$(GTK_VER)s.lib $(gtk_OBJECTS)
Tor Lillqvist's avatar
Tor Lillqvist committed
501

502 503 504
gtk-query-immodules-$(GTK_VER).exe : queryimmodules.obj
	$(CC) $(CFLAGS) -Fe$@ queryimmodules.obj $(GTK_LIBS) $(GLIB_LIBS) $(PANGO_LIBS) $(LDFLAGS)

Hans Breuer's avatar
Hans Breuer committed
505 506 507
gtk-x11-$(GTK_VER).dll : $(gtk_OBJECTS) gtk.def
	$(CC) $(CFLAGS) -LD -Fm -Fegtk-x11-$(GTK_VER).dll $(gtk_OBJECTS) ../gdk/gdk-x11-$(GTK_VER).lib $(GDK_PIXBUF_LIBS) $(PANGO_LIBS) $(INTL_LIBS) $(GLIB_LIBS) gdi32.lib user32.lib advapi32.lib $(LDFLAGS) /def:gtk.def

Tor Lillqvist's avatar
Tor Lillqvist committed
508 509 510 511
# General rule for compiling the objects into the DLL
.c.obj :
	$(CC) $(CFLAGS) -GD -c -DGTK_COMPILATION -DG_LOG_DOMAIN=\"Gtk\" $<

512 513 514 515 516 517
$(EXAMPLE).obj : ..\examples\$(EXAMPLE)\$(EXAMPLE).c
	$(CC) $(CFLAGS) -c -DG_LOG_DOMAIN=\"$(EXAMPLE)\" ..\examples\$(EXAMPLE)\$(EXAMPLE).c

$(EXAMPLE).exe : $(EXAMPLE).obj
	$(CC) $(CFLAGS) $(EXAMPLE).obj $(GTK_LIBS) $(GDK_LIBS) $(GLIB_LIBS) $(LDFLAGS)

Tor Lillqvist's avatar
Tor Lillqvist committed
518 519 520
makefile.msc: makefile.msc.in
	sed -e s,@GTK[_]MAJOR_VERSION@,@GTK_MAJOR_VERSION@, \
	    -e s,@GTK[_]MINOR_VERSION@,@GTK_MINOR_VERSION@, \
Tor Lillqvist's avatar
Tor Lillqvist committed
521
	    -e 's,@GTK[_]VERSION@,@GTK_VERSION@,' \
Tor Lillqvist's avatar
Tor Lillqvist committed
522 523
	    -e 's,@GDK_PIXBUF[_]MAJOR@,@GDK_PIXBUF_MAJOR@,' \
	    -e 's,@GDK_PIXBUF[_]MINOR@,@GDK_PIXBUF_MINOR@,'  <makefile.msc.in >$@