source: trunk/makefile_post.mk@ 1281

Last change on this file since 1281 was 1281, checked in by John Small, 17 years ago

Ticket 297: Various build improvements/corrections

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 1.5 KB
RevLine 
[236]1# makefile_post.mk - common makefile suffix settings for all makefiles
2# $Id: makefile_post.mk 1281 2008-11-18 17:19:46Z jbs $
[9]3
[252]4# 16 Aug 05 SHL Clean up
[310]5# 16 Apr 06 SHL Add lxlite target
[691]6# 02 Jun 07 SHL Convert to OpenWatcom
[976]7# 23 Feb 08 JBS Add support for building SYM files (Ticket 226)
[1259]8# 25 Oct 08 JBS Rework DEBUG usage to match what C code expects
[1281]9# 18 Nov 08 JBS Ticket 297: Various build improvements/corrections
[252]10
[236]11!ifndef MAKERES
12
[691]13# Build executable
14# Common parameters go in .lrf
15# Executable specific paramters go in .def
16
17$(BASE).exe: $(BASE).lrf $(BASE).obj $(BASE).res $(BASE).def .explicit
[719]18 $(LINK) @$(BASE).lrf @$(BASE).def
[1281]19 @echo. & echo Compiling resource: $@ & echo.
[691]20 $(RC) $(RCFLAGS2) $(BASE).res $@
[252]21 bldlevel $@
[9]22
[691]23$(BASE).lrf: $(__MAKEFILES__) .explicit
24 @%write $^@ $(LFLAGS)
25 @%append $^@ name $(BASE)
26 @%append $^@ file $(BASE).obj
27!ifdef %EXCEPTQ
28 @%append $^@ file exceptq.lib
29!endif
30 @%append $^@ library dll\fm3dll.lib
31 @%append $^@ library os2386.lib
32
[976]33$(BASE).sym: $(BASE).map
[987]34 @echo Processing: $?
35 -perl debugtools\mapsymw.pl $?
[976]36
[236]37!else
38
[691]39# Replace resources
40$(BASE).exe: $(BASE).res .explicit
[252]41 @if not exist $@ echo $@ missing
[1259]42!ifndef DEBUG
[980]43 lxlite $@ /x+ /b-
44 lxlite $@ /c:minstub
45!endif
[1281]46 @echo. & echo Compiling resource: $@ & echo.
[691]47 $(RC) $(RCFLAGS2) $(BASE).res $@
[1259]48!ifndef DEBUG
[252]49 lxlite $@ /x- /b-
[980]50!endif
[252]51 bldlevel $@
[236]52
53!endif
54
[691]55lxlite:: $(BASE).exe .symbolic .explicit
[1259]56!ifndef DEBUG
[310]57 lxlite /x- /b- $?
[980]58!endif
[310]59
[691]60clean:: .symbolic .explicit
[236]61 -del $(BASE).exe
62 -del $(BASE).lrf
63 -del $(BASE).map
64 -del $(BASE).obj
65 -del $(BASE).res
66
[9]67# The end
Note: See TracBrowser for help on using the repository browser.