source: trunk/makefile_post.mk@ 1268

Last change on this file since 1268 was 1259, checked in by Steven Levine, 17 years ago

Rework makefile dependencies to avoid target dependent build failures.
Drop support for DEBUG=0 - it does not match what our C code expects.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 1.4 KB
RevLine 
[236]1# makefile_post.mk - common makefile suffix settings for all makefiles
2# $Id: makefile_post.mk 1259 2008-10-26 02:03:41Z stevenhl $
[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
[252]9
[236]10!ifndef MAKERES
11
[691]12# Build executable
13# Common parameters go in .lrf
14# Executable specific paramters go in .def
15
16$(BASE).exe: $(BASE).lrf $(BASE).obj $(BASE).res $(BASE).def .explicit
[719]17 $(LINK) @$(BASE).lrf @$(BASE).def
[691]18 $(RC) $(RCFLAGS2) $(BASE).res $@
[252]19 bldlevel $@
[9]20
[691]21$(BASE).lrf: $(__MAKEFILES__) .explicit
22 @%write $^@ $(LFLAGS)
23 @%append $^@ name $(BASE)
24 @%append $^@ file $(BASE).obj
25!ifdef %EXCEPTQ
26 @%append $^@ file exceptq.lib
27!endif
28 @%append $^@ library dll\fm3dll.lib
29 @%append $^@ library os2386.lib
30
[976]31$(BASE).sym: $(BASE).map
[987]32 @echo Processing: $?
33 -perl debugtools\mapsymw.pl $?
[976]34
[236]35!else
36
[691]37# Replace resources
38$(BASE).exe: $(BASE).res .explicit
[252]39 @if not exist $@ echo $@ missing
[1259]40!ifndef DEBUG
[980]41 lxlite $@ /x+ /b-
42 lxlite $@ /c:minstub
43!endif
[691]44 $(RC) $(RCFLAGS2) $(BASE).res $@
[1259]45!ifndef DEBUG
[252]46 lxlite $@ /x- /b-
[980]47!endif
[252]48 bldlevel $@
[236]49
50!endif
51
[691]52lxlite:: $(BASE).exe .symbolic .explicit
[1259]53!ifndef DEBUG
[310]54 lxlite /x- /b- $?
[980]55!endif
[310]56
[691]57clean:: .symbolic .explicit
[236]58 -del $(BASE).exe
59 -del $(BASE).lrf
60 -del $(BASE).map
61 -del $(BASE).obj
62 -del $(BASE).res
63
[9]64# The end
Note: See TracBrowser for help on using the repository browser.