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