X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/cc77c86d1e71bae248f59f83904971d83e78c1a5..e4d47fbd6f53b11276dde270e325b339393e9702:/distrib/msw/tmake/b32.t diff --git a/distrib/msw/tmake/b32.t b/distrib/msw/tmake/b32.t index fec308a4d3..4201fc3f53 100644 --- a/distrib/msw/tmake/b32.t +++ b/distrib/msw/tmake/b32.t @@ -13,12 +13,20 @@ IncludeTemplate("filelist.t"); #! now transform these hashes into $project tags - foreach $file (sort keys %wxGeneric) { - my $tag = ""; - next if $wxGeneric{$file} =~ /\b(PS|G|16|U)\b/; + foreach $file (sort keys %wxUNIV) { + next if $wxUNIV{$file} =~ /\T\b/; $file =~ s/cp?p?$/obj/; - $project{"WXGENERICOBJS"} .= "\$(MSWDIR)\\" . $file . " " + $obj = "\$(UNIVDIR)\\" . $file . " "; + $project{"WXUNIVOBJS"} .= "\$(MSWDIR)\\" . $file . " " + } + + foreach $file (sort keys %wxUNIV) { + next unless $wxUNIV{$file} =~ /\T\b/; + + $file =~ s/cp?p?$/obj/; + $obj = "\$(UNIVTHEMEDIR)\\" . $file . " "; + $project{"WXUNIVTHEMEOBJS"} .= "\$(MSWDIR)\\" . $file . " " } foreach $file (sort keys %wxHTML) { @@ -38,6 +46,7 @@ $project{"WXCOBJS"} .= $obj if $isCFile; } +#! MSW dir for native port foreach $file (sort keys %wxMSW) { next if $wxMSW{$file} =~ /\b16\b/; @@ -61,6 +70,57 @@ } $project{"WXCOBJS"} .= $obj if $isCFile; } + +#! Now do MSW dir for UNIV + foreach $file (sort keys %wxMSW) { + next unless $wxMSW{$file} =~ /\b(L|B)\b/; + +#! if ( $file =~ /^automtn/ ) { +#! #! comment in old makefile.b32 seems to imply that this file can not +#! #! be compiled with Borland (leads to crash in oleauto sample) +#! No longer true, at least for BC++ 5.2 +#! next; +#! } + + $isCFile = $file =~ /\.c$/; + + my $isOleObj = $wxMSW{$file} =~ /\bO\b/; + $file =~ s/cp?p?$/obj/; + my $obj = "\$(MSWDIR)\\" . $file . " "; + + $project{"WXMSWUNIVOBJS"} .= $obj; + if ( $isOleObj ) { + #! remember that this file is in ole subdir + $project{"WXOLEUNIVOBJS"} .= $obj; + } + $project{"WXCUNIVOBJS"} .= $obj if $isCFile; + } + +#! Generic Dir for Native Port + foreach $file (sort keys %wxGeneric) { + my $tag = ""; + next if $wxGeneric{$file} =~ /\b(PS|G|16|U)\b/; + + $file =~ s/cp?p?$/obj/; + $project{"WXGENERICOBJS"} .= "\$(MSWDIR)\\" . $file . " " + } + +#! Generic Dir for UNIV Port + foreach $file (sort keys %wxGeneric) { + my $filereal = $file; + if ( $file =~ /^([^.]+)g.cpp$/ ) { + $filereal = "$1.cpp"; + } + $file =~ s/cp?p?$/obj/; + $filereal =~ s/cp?p?$/obj/; + + next if $project{"WXMSWUNIVOBJS"} =~ /\b$filereal\b/ || + $project{"WXUNIVOBJS"} =~ /\b$filereal\b/; + + + $project{"WXGENERICUNIVOBJS"} .= "\$(MSWDIR)\\" . $file . " " + } + #$} # This file was automatically generated by tmake @@ -87,6 +147,7 @@ WXDIR = $(WXWIN) THISDIR = $(WXDIR)\src\msw + # Set all these to 1 if you want to build a dynamic library !if "$(DLL)" == "1" WXMAKINGDLL=1 @@ -128,31 +189,35 @@ GENDIR=..\generic COMMDIR=..\common HTMLDIR=..\html OLEDIR=.\ole +UNIVDIR=..\univ +UNIVTHEMEDIR=..\univ\themes MSWDIR=. DOCDIR = $(WXDIR)\docs GENERICOBJS= #$ ExpandList("WXGENERICOBJS"); -# Not needed: -# $(MSWDIR)\colrdlgg.obj \ -# $(MSWDIR)\fontdlgg.obj \ -# $(MSWDIR)\msgdlgg.obj \ -# $(MSWDIR)\printps.obj \ -# $(MSWDIR)\prntdlgg.obj \ -# $(MSWDIR)\listctrl.obj \ -# $(MSWDIR)\notebook.obj \ -# $(MSWDIR)\treectrl.obj +MSWOBJS = #$ ExpandList("WXMSWOBJS"); -COMMONOBJS = \ - $(MSWDIR)\y_tab.obj \ - #$ ExpandList("WXCOMMONOBJS"); +GENERICUNIVOBJS= #$ ExpandList("WXGENERICUNIVOBJS"); -MSWOBJS = #$ ExpandList("WXMSWOBJS"); +MSWUNIVOBJS = #$ ExpandList("WXMSWUNIVOBJS"); + +UNIVOBJS = #$ ExpandList("WXUNIVOBJS"); + +UNIVTHEMEOBJS = #$ ExpandList("WXUNIVTHEMEOBJS"); HTMLOBJS = #$ ExpandList("WXHTMLOBJS"); +COMMONOBJS = \ + $(MSWDIR)\y_tab.obj \ + #$ ExpandList("WXCOMMONOBJS"); + +!if "$(WXUSINGUNIV)" == "1" +OBJECTS = $(COMMONOBJS) $(GENERICUNIVOBJS) $(MSWUNIVOBJS) $(HTMLOBJS) $(UNIVOBJS) $(UNIVTHEMEOBJS) +!else OBJECTS = $(COMMONOBJS) $(GENERICOBJS) $(MSWOBJS) $(HTMLOBJS) +!endif default: wx @@ -168,12 +233,13 @@ makesetuph: # Copy include\wx\msw\setup.h to the architecture-specific location makearchsetuph: - copy $(WXDIR)\include\wx\msw\setup.h $(ARCHSETUPH) + copy $(SETUPSRCDIR)\setup.h $(ARCHSETUPH) cd $(WXDIR)\src\msw $(ARCHINCDIR)\wx: -mkdir $(ARCHINCDIR) -mkdir $(ARCHINCDIR)\wx + -erase $(CFG) !if "$(DLL)" == "0" @@ -218,6 +284,27 @@ $(COMMDIR)\lex_yy.c: $(COMMDIR)\doslex.c # $(OBJECTS): $(WXDIR)\include\wx\setup.h +!if "$(WXUSINGUNIV)" == "1" +######################################################## +# MSW objects (compile Native or UNIV) - UNIV + +#${ + $_ = $project{"WXMSWUNIVOBJS"}; + my @objs = split; + foreach (@objs) { + $text .= $_ . ": "; + if ( $project{"WXOLEOBJS"} =~ /\Q$_/ ) { s/MSWDIR/OLEDIR/; } + $suffix = $project{"WXCUNIVOBJS"} =~ /\Q$_/ ? "c" : '$(SRCSUFF)'; + s/obj$/$suffix/; + $text .= $_ . "\n\n"; + } +#$} + + +!else +######################################################## +# MSW objects (compile Native or UNIV) - Native + #${ $_ = $project{"WXMSWOBJS"}; my @objs = split; @@ -229,6 +316,38 @@ $(COMMDIR)\lex_yy.c: $(COMMDIR)\doslex.c $text .= $_ . "\n\n"; } #$} +!endif + +!if "$(WXUSINGUNIV)" == "1" +######################################################## +# UNIV objects +#${ + $_ = $project{"WXUNIVOBJS"}; + my @objs = split; + foreach (@objs) { + $text .= $_ . ": "; + s/MSWDIR/UNIVDIR/; + s/obj$/\$(SRCSUFF)/; + $text .= $_ . "\n\n"; + } +#$} + + +######################################################## +# UNIV THEME objects + +#${ + $_ = $project{"WXUNIVTHEMEOBJS"}; + my @objs = split; + foreach (@objs) { + $text .= $_ . ": "; + s/MSWDIR/UNIVTHEMEDIR/; + s/obj$/\$(SRCSUFF)/; + $text .= $_ . "\n\n"; + } +#$} + +!endif ######################################################## # Common objects (always compiled) @@ -245,9 +364,29 @@ $(COMMDIR)\lex_yy.c: $(COMMDIR)\doslex.c } #$} +!if "$(WXUSINGUNIV)" == "1" ######################################################## # Generic objects (not always compiled, depending on # whether platforms have native implementations) +# Native + + +#${ + $_ = $project{"WXGENERICUNIVOBJS"}; + my @objs = split; + foreach (@objs) { + $text .= $_ . ": "; + s/MSWDIR/GENDIR/; + s/obj$/\$(SRCSUFF)/; + $text .= $_ . "\n\n"; + } +#$} + +!else +######################################################## +# Generic objects (not always compiled, depending on +# whether platforms have native implementations) +# Native #${ $_ = $project{"WXGENERICOBJS"}; @@ -259,6 +398,7 @@ $(COMMDIR)\lex_yy.c: $(COMMDIR)\doslex.c $text .= $_ . "\n\n"; } #$} +!endif ######################################################## # HTML objects (always compiled) @@ -292,7 +432,7 @@ all_execs: png: $(CFG) cd $(WXDIR)\src\png - ${MAKE} -f makefile.b32 + ${MAKE} -f makefile.b32 FINAL=$(FINAL) cd $(WXDIR)\src\msw clean_png: @@ -302,7 +442,7 @@ clean_png: zlib: $(CFG) cd $(WXDIR)\src\zlib - ${MAKE} -f makefile.b32 lib + ${MAKE} -f makefile.b32 FINAL=$(FINAL) lib cd $(WXDIR)\src\msw clean_zlib: @@ -312,7 +452,7 @@ clean_zlib: jpeg: $(CFG) cd $(WXDIR)\src\jpeg - ${MAKE} -f makefile.b32 + ${MAKE} -f makefile.b32 FINAL=$(FINAL) cd $(WXDIR)\src\msw clean_jpeg: @@ -322,7 +462,7 @@ clean_jpeg: regex: $(CFG) cd $(WXDIR)\src\regex - ${MAKE} -f makefile.b32 lib + ${MAKE} -f makefile.b32 FINAL=$(FINAL) lib cd $(WXDIR)\src\msw clean_regex: @@ -332,7 +472,7 @@ clean_regex: tiff: $(CFG) cd $(WXDIR)\src\tiff - ${MAKE} -f makefile.b32 lib + ${MAKE} -f makefile.b32 FINAL=$(FINAL) lib cd $(WXDIR)\src\msw clean_tiff: @@ -359,7 +499,7 @@ $(CFG): makefile.b32 -L$(BCCDIR)\lib;$(BCCDIR)\lib\psdk -D__WXWIN__ --D__WXMSW__ +-D$(PORT) -D__WINDOWS__ -DWIN32 $(OPT) @@ -368,14 +508,11 @@ $(WIN95FLAG) ! $(CFG) clean: $(PERIPH_CLEAN_TARGET) - -erase $(LIBTARGET) - -erase $(WXLIBDIR)\wx.dll -erase $(WXLIBDIR)\wx.tds -erase $(WXLIBDIR)\wx.il? -erase *.obj -erase *.pch -erase *.csm - -erase *.cfg -erase "wx32.#??" -erase ..\common\y_tab.c -erase ..\common\lex_yy.c