source: trunk/warpin/makefile @ 703

Last change on this file since 703 was 703, checked in by John Small, 13 years ago
  • Watcom handles macros differently so some of the previous

warpin/makefile code has been broken since the conversion.
So the code was improved and moved to the base makefile to
make it work better.

  • fm2.wis was added as a dependant to the WPI target in the

warpin/makefile file.

File size: 2.3 KB
Line 
1# warpin\makefile - build the FM/2 Warpin installation file: FM2.WIS
2# $Id: $
3
4# 28 Apr 07 SHL Add clean target
5# 13 May 07 SHL Tweak macro handling to work as documented
6# 13 May 07 SHL Correct clean target
7# 08 Jun 07 JBS Corrected BUILD_FM2UTILS code so that it is actually
8#               possible to disable the build of the FM2UTILS*.WPI file
9# 22 Jun 07 JBS Reworked the code related to macros in both this file
10#               and the base makefile. Also made the fm2.wis file a
11#               dependant of the WPI target.
12
13
14all: wpi .symbolic
15
16!ifeq BUILD_FM2UTILS 0
17wpi: checkfiles fm2.wis fm2$(FM2_VER).wpi .symbolic
18!else
19wpi: checkfiles fm2.wis fm2$(FM2_VER).wpi fm2utils$(FM2UTILS_VER).wpi .symbolic
20!endif
21
22
23checkfiles: .symbolic
24   @echo Checking to see if files have been changed...
25    ckfiles fm2$(FM2_VER).wpi
26
27fm2.wis: fm2.wis.in fm2utils\fm2utils.doc fm2utils\license.txt
28#  sed -e "s/@@@FM2UTILS_VER@@@/$(FM2UTILS_VER)/" -e "/@@@include fm2utils.doc@@@/r fm2utils\fm2utils.doc" -e "s/@@@include fm2utils.doc@@@//g" -e "/@@@include license.txt@@@/r fm2utils\license.txt" -e "s/@@@include license.txt@@@//g" fm2.wis.in >fm2.wis
29   sed -e "s/@@@FM2UTILS_VER@@@/$(FM2UTILS_VER)/" -e "/@@@include fm2utils.doc@@@/r fm2utils\fm2utils.doc" -e "s/@@@include fm2utils.doc@@@//" -e "/@@@include license.txt@@@/r fm2utils\license.txt" -e "s/@@@include license.txt@@@//" fm2.wis.in >fm2.wis
30
31fm2$(FM2_VER).wpi:: bld_fm2_wpidirs.in
32   @echo Staging files for WPI file...
33   bld_fm2_wpidirs
34   @echo Creating/updating the WPI file
35   bld_fm2_wpi fm2$(FM2_VER).wpi
36
37fm2$(FM2_VER).wpi:: fm2.wis
38   @echo Inserting the new Warpin script into the WPI file...
39   bld_fm2_wpi fm2$(FM2_VER).wpi /SCRIPT
40
41fm2utils$(FM2UTILS_VER).wpi: bld_fm2utils_wpi.cmd fm2utils.wis fm2utils\fm2utils.doc fm2utils\license.txt ..\shdwmgr.cmd
42   @echo Building FM2Utils
43   bld_fm2utils_wpi fm2utils$(FM2UTILS_VER).wpi
44
45clean: .symbolic
46  -if exist fm2$(FM2_VER).wpi del fm2$(FM2_VER).wpi
47  -if exist fm2utils$(FM2UTILS_VER).wpi del fm2utils$(FM2UTILS_VER).wpi
48  -if exist bld_fm2_wpidirs.in del bld_fm2_wpidirs.in
49  clean_wpidirs
50
51# fixme to decide if these should be cleaned and not distcleaned
52distclean: clean .symbolic
53  -if exist fm2.wis del fm2.wis
54
55# The end
56
57
Note: See TracBrowser for help on using the repository browser.