Changeset 703


Ignore:
Timestamp:
Jun 23, 2007, 4:32:51 AM (13 years ago)
Author:
John Small
Message:
  • 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.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/makefile

    r698 r703  
    1313# 26 Aug 06 SHL Add rest of lxlite support
    1414# 14 Jun 07 SHL Convert to OpenWatcom
     15# 22 Jun 07 JBS Moved some macro-handling code to this
     16#               file from warpin\makefile because of some
     17#               differences in how Watcom handles macros.
    1518
    1619# Environment:
    1720
    18 # DEBUG 0 = release build, 1 = debug build
     21# DEBUG 0 = release build, 1 = debug build
    1922
    2023BASE = fm3
     24
     25# FM2_VER defines fm/2 WPI file name suffix
     26# e.g. FM2_VER=-3-5-9 results in FM2-3-5-9.wpi being built
     27# If FM2_VER is empty, then FM2.wpi is built
     28# NOTE: Start the variable with '-'
     29
     30!ifndef FM2_VER                  # if defined on wmake command, use it
     31FM2_VER=-3-6-0                   # default value
     32!ifdef %FM2_VER                  # if defined via env. var.
     33FM2_VER=$(%FM2_VER)              #     use the env. var.
     34!endif
     35!endif
     36
     37# FM2UTILS_VER defines the fm2utils WPI file name suffix.
     38# e.g. FM2UTILS_VER=-1-0 results in FM2Utils-1.0.wpi being built
     39# If FM2UTILS_VER is empty, then FM2UTILS.wpi is built
     40# NOTE: Start the variable with '-'
     41
     42!ifndef FM2UTILS_VER             # if defined on wmake command, use it
     43FM2UTILS_VER=-1-1                # default value
     44!ifdef %FM2UTILS_VER             # if defined via env. var.
     45FM2UTILS_VER=$(%FM2UTILS_VER)    #     use the env. var.
     46!endif
     47!endif
     48
     49# If BUILD_FM2UTILS = 1, build FM2UTILS*.wpi and FM2*.wpi
     50# Otherwise build just FM2*.wpi
     51
     52!ifndef BUILD_FM2UTILS           # if defined on wmake command, use it
     53!ifdef %BUILD_FM2UTILS           # else if defined via env. var.
     54!ifneq %BUILD_FM2UTILS 1         #     if env. var. is anything but 1
     55BUILD_FM2UTILS=0                 #     use a value of 0
     56!else
     57BUILD_FM2UTILS=1
     58!endif
     59!else
     60BUILD_FM2UTILS=0                 # use default value if not defined via env. or command line
     61!endif
     62!endif
    2163
    2264!include makefile_pre.mk
     
    5193wpi: .symbolic
    5294   cd warpin
    53    $(MAKE) $(__MAKEOPTS__)
     95   $(MAKE) $(__MAKEOPTS__) FM2_VER=$(FM2_VER) FM2UTILS_VER=$(FM2UTILS_VER) BUILD_FM2UTILS=$(BUILD_FM2UTILS)
    5496   cd ..
    5597
  • trunk/warpin/makefile

    r699 r703  
    77# 08 Jun 07 JBS Corrected BUILD_FM2UTILS code so that it is actually
    88#               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.
    912
    10 # Environment:
    11 
    12 # DEBUG  0 = release build, 1 = debug build
    13 
    14 # If BUILD_FM2UTILS defined, build FM2UTILS*.wpi and FM2*.wpi
    15 # Otherwise build just FM2*.wpi
    16 !ifndef BUILD_FM2UTILS
    17 BUILD_FM2UTILS=1
    18 !endif
    19 
    20 # FM2_VER defines fm/2 WPI file name suffix
    21 # e.g. FM2_VER=-3-5-9 results in FM2-3-5-9.wpi being built
    22 # If FM2_VER is empty, then FM2.wpi is built
    23 # NOTE: Start the variable with '-'
    24 
    25 !ifndef FM2_VER
    26 FM2_VER=-3-5-9
    27 !endif
    28 
    29 # FM2UTILS_VER defines the fm2utils WPI file name suffix.
    30 # e.g. FM2UTILS_VER=-1-0 results in FM2Utils-1.0.wpi being built
    31 # If FM2UTILS_VER is empty, then FM2UTILS.wpi is built
    32 # NOTE: Start the variable with '-'
    33 
    34 !ifndef FM2UTILS_VER
    35 FM2UTILS_VER=-1-0-1
    36 !endif
    3713
    3814all: wpi .symbolic
    3915
    40 !if $(BUILD_FM2UTILS) == 0
    41 wpi: checkfiles fm2$(FM2_VER).wpi .symbolic
     16!ifeq BUILD_FM2UTILS 0
     17wpi: checkfiles fm2.wis fm2$(FM2_VER).wpi .symbolic
    4218!else
    43 wpi: checkfiles fm2$(FM2_VER).wpi fm2utils$(FM2UTILS_VER).wpi .symbolic
     19wpi: checkfiles fm2.wis fm2$(FM2_VER).wpi fm2utils$(FM2UTILS_VER).wpi .symbolic
    4420!endif
    4521
Note: See TracChangeset for help on using the changeset viewer.