X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/205b0c9c6aa69c02a7774846e677910bf1609a53..9c112555198f51fcec71106530cddba95a17f3dc:/src/makeprog.wat?ds=inline diff --git a/src/makeprog.wat b/src/makeprog.wat index d52cc801e1..d2f8809d86 100644 --- a/src/makeprog.wat +++ b/src/makeprog.wat @@ -1,22 +1,36 @@ +# +# Changelist: 2003-02-25 - Juergen Ulbts - update from wxWindows 2.5.x/HEAD branch +# +# $+ .. $- means we get the result directly +THISDIR = $+ $(%cdrive):$(%cwd) $- + WXDIR = $(%WXWIN) +!ifndef EXEDIR +OUTPUTDIR = $(THISDIR)\Watcom +!else +OUTPUTDIR = $(THISDIR)\$(EXEDIR) +!ifeq EXEDIR "." +OUTPUTDIR = $(THISDIR) +!endif +!endif !include $(WXDIR)\src\makewat.env WXLIB = $(WXDIR)\lib -LNK = $(OUTPUTDIR)$(PROGRAM).lnk +LNK = $(OUTPUTDIR)\$(PROGRAM).lnk -all: $(OUTPUTDIR) $(OUTPUTDIR)$(PROGRAM).exe $(EXTRATARGETS) .SYMBOLIC +all: MAKEDIR $(OUTPUTDIR)\$(PROGRAM).exe $(EXTRATARGETS) .SYMBOLIC -$(OUTPUTDIR): - @if not exist $^@ mkdir $^@ +MAKEDIR: .SYMBOLIC + @if not exist $(OUTPUTDIR) mkdir $(OUTPUTDIR) !ifeq wxUSE_GUI 0 RESFILE= !else -RESFILE=$(OUTPUTDIR)$(PROGRAM).res +RESFILE=$(OUTPUTDIR)\$(PROGRAM).res !endif -$(OUTPUTDIR)$(PROGRAM).exe : $(OBJECTS) $(RESFILE) $(LNK) $(WXLIB)\$(LIBNAME).lib +$(OUTPUTDIR)\$(PROGRAM).exe : $(OBJECTS) $(RESFILE) $(LNK) $(WXLIB)\$(LIBNAME).lib wlink @$(LNK) !ifneq wxUSE_GUI 0 $(BINDCOMMAND) $(RESFILE) @@ -27,26 +41,26 @@ $(RESFILE): $(PROGRAM).rc $(WXDIR)\include\wx\msw\wx.rc $(RC) $(RESFLAGS) /fo=$(RESFILE) $(PROGRAM).rc !endif -$(LNK) : makefile.wat +$(LNK) : .SYMBOLIC %create $(LNK) @%append $(LNK) $(LDFLAGS) @%append $(LNK) $(DEBUGINFO) @%append $(LNK) system $(LINKSYSTEM) @%append $(LNK) $(STACK) - @%append $(LNK) name $(OUTPUTDIR)$(PROGRAM).exe + @%append $(LNK) name $(OUTPUTDIR)\$(PROGRAM).exe @for %i in ($(OBJECTS)) do @%append $(LNK) file %i @for %i in ($(LIBS)) do @%append $(LNK) lib %i @for %i in ($(EXTRALIBS)) do @%append $(LNK) lib %i clean: .SYMBOLIC - -erase $(OUTPUTDIR)*.obj - -erase $(OUTPUTDIR)*.bak - -erase $(OUTPUTDIR)*.err - -erase $(OUTPUTDIR)*.pch - -erase $(OUTPUTDIR)*.lib + -erase $(OUTPUTDIR)\*.obj + -erase $(OUTPUTDIR)\*.bak + -erase $(OUTPUTDIR)\*.err + -erase $(OUTPUTDIR)\*.pch + -erase $(OUTPUTDIR)\*.lib -erase $(LNK) - -erase $(OUTPUTDIR)*.res - -erase $(OUTPUTDIR)*.exe - -erase $(OUTPUTDIR)*.lbc + -erase $(OUTPUTDIR)\*.res + -erase $(OUTPUTDIR)\*.exe + -erase $(OUTPUTDIR)\*.lbc -rmdir $(OUTPUTDIR)