AAsmModule 15.8 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14
# Copyright 2008 Castle Technology Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
15
# Makefile fragment for assembler modules, previously built using AAsm but now using objasm
16 17 18
# Such modules are characterised by the use of position-independent code
# and multiple source files (if applicable) linked at the assembly stage
# (using LNK and GET directives) rather than at the link stage.
Ben Avison's avatar
Ben Avison committed
19 20 21

INCLUDED_AASMMODULE = YES

22 23 24 25 26
#
# $Id$
#
# This makefile provides the following phony targets:
#
27
#    all     rom           install_rom   rom_link           resources
28 29 30 31 32 33 34
#    export  export_libs   export_hdrs   standalone         install
#    clean   debug         gpa_debug
#
#
# This fragment uses the following macros set by the master makefile.
#
#
Robert Sprowson's avatar
Robert Sprowson committed
35 36
# COMPONENT             (the name of the component)
# TARGET          (opt) (the leafname of the module - otherwise ${COMPONENT})
37 38 39 40 41 42 43 44 45 46 47 48
# ROM_MODULE      (opt) (output filename - otherwise rm.${MACHINE}.${TARGET})
# ROM_OBJECT      (opt) (object file for romming - otherwise o.${MACHINE}.${TARGET})
# ROM_LIBS        (opt) (libraries to link again ROM_OBJECT to generate ROM_MODULE)
# ROM_DEPEND      (opt) (any extra dependency to assert on ROM_MODULE)
# DBG_MODULE      (opt) (output filename for debug - otherwise rm.${MACHINE}.${TARGET}D
# DBG_OBJECT      (opt) (object file for debug - otherwise o.${MACHINE}.${TARGET}D
# DBG_LIBS        (opt) (libraries to link against DBG_OBJECT to generate DBG_MODULE - otherwise ${ROM_LIBS})
# SA_MODULE       (opt) (output filename for softload - otherwise rm.${MACHINE}.${TARGET}SA
# SA_OBJECT       (opt) (object file for softload - otherwise o.${MACHINE}.${TARGET}SA
# SA_LIBS         (opt) (libraries to link against SA_OBJECT to generate SA_MODULE - otherwise ${ROM_LIBS})
# SA_DEPEND       (opt) (any extra dependency to assert on SA_MODULE and DBG_MODULE)
# DIRS            (opt) (magic target to ensure object directories are present - otherwise o._dirs)
Robert Sprowson's avatar
Robert Sprowson committed
49 50
# HEADER[1-3]     (opt) (leafname of file in hdr to copy to <export$dir> on export_hdrs)
# ASMCHEADER[1-3] (opt) (C-from-assembly auto-generated header files to export, no Hdr. prefix - otherwise none)
51
# CHEADER[1-3]    (opt) (C header files to export - otherwise none)
Robert Sprowson's avatar
Robert Sprowson committed
52 53
# C_EXP_HDR       (opt) (C header target directory - otherwise <cexport$dir>.Interface.h)
# EXP_HDR         (opt) (directory for exported assembler interface headers)
54 55 56 57
# INSTRES_FILES   (opt) (extra resource files in addition to Messages - use InstRes specification rules)
# INSTRAM_FILES   (opt) (RAM build specific resources - otherwise ${INSTRES_FILES})
# INSTROM_FILES   (opt) (ROM build specific resources - otherwise ${INSTRES_FILES})
# INSTR??_DEPENDS (opt) (any extra dependency to assert on INSTRES/INSTRAM/INSTROM_FILES)
58
# INSTRES_VERSION (opt) (if set to "Messages", automatically insert version into Messages file during resources phase)
59 60
# MERGEDMSGS      (r/o) (leafname of generated Messages file)
# RESFSDIR        (opt) (actual directory to export resources to - otherwise ${RESDIR}.${TARGET})
61 62 63
# TOKHELPSRC      (opt) (set equal to ${TOKENSOURCE} to indicate that the binary depends on autogenerated tokenised help source file of that name)
# HELPSRC         (opt) (set to filename containing untokenised help messages if ${TOKHELPSRC} = ${TOKENSOURCE})
# TOKENS          (opt) (set to filename containing help message tokens - otherwise Hdr:Tokens)
Robert Sprowson's avatar
Robert Sprowson committed
64
# CUSTOMEXP       (opt) (set to "custom" to override the export rules)
65
# CUSTOMRES       (opt) (set to "custom" to override the resources rules, or "no" for no resources)
Robert Sprowson's avatar
Robert Sprowson committed
66 67 68 69
# CUSTOMROM       (opt) (set to "custom" to override the rom rules)
# CUSTOMSA        (opt) (set to "custom" to override the standalone rules)
# CUSTOMDBG       (opt) (set to "custom" to override the debug rules)
# CUSTOMGPA       (opt) (set to "custom" to override the GPA rules)
70 71 72 73 74 75 76 77 78
#
#
# It relies on the following from the build system:
#
#
# INSTDIR          (installation directory for ROM_MODULE or disc install)
# <Install$Dir>    (if INSTDIR was not specified by the build system)
# RESDIR           (installation directory for resources - cf. RESFSDIR)
# <Export$Dir>     (export directory for assembler interface headers)
79
# <CExport$Dir>    (export directory for C interface headers)
80 81
# CMDHELP          (optional, set to None to exclude syntax errors from Messages)
# PHASE            (export phase discriminator)
82
# INSERTVERSION    (awk script to substitute from VersionNum)
83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100
#
#
# It relies on the following generic tool macros from the Tools makefile
#
# CP + CPFLAGS     (copy, cp etc.)
# AS + ASFLAGS     (assembler)
# MKDIR            (cdir/mkdir -p)
# RM + WIPE        (deletions)
# ECHO
# LD               (linker)
#
#

TARGET     ?= ${COMPONENT}
INSTDIR    ?= <Install$Dir>
ROM_MODULE ?= rm.${MACHINE}.${TARGET}
ROM_SOURCE ?= s.${TARGET}
ROM_OBJECT ?= o.${MACHINE}.${TARGET}
101
DIRS       ?= o._dirs
102 103 104 105
EXP_HDR    ?= <export$dir>
C_EXP_HDR  ?= <cexport$dir>.Interface.h
SA_MODULE  ?= rm.${MACHINE}.${TARGET}SA
SA_OBJECT  ?= o.${MACHINE}.${TARGET}SA
106 107 108 109 110 111 112 113
INSTRAM_FILES   ?= ${INSTRES_FILES}
INSTRAM_DEPENDS ?= ${INSTRES_DEPENDS}
INSTROM_FILES   ?= ${INSTRES_FILES}
INSTROM_DEPENDS ?= ${INSTRES_DEPENDS}
MERGEDRDIR   ?= o._ResData_
MERGEDMSGS   ?= ${MERGEDRDIR}.${TARGET}.Messages
RESFSDIR   ?= ${RESDIR}.${TARGET}
RESAPPDIR  ?= ${RESDIR}.^.Apps.${APP}
Robert Sprowson's avatar
Robert Sprowson committed
114 115 116
ifeq (${CMDHELP},None)
SA_FLAGS   ?= -PD "standalone SETL {TRUE}" -PD "MergedMsgs SETS \"${MERGEDMSGS}\"" -PD "international_help SETL {FALSE}"
else
117
SA_FLAGS   ?= -PD "standalone SETL {TRUE}" -PD "MergedMsgs SETS \"${MERGEDMSGS}\""
Robert Sprowson's avatar
Robert Sprowson committed
118
endif
119 120 121 122 123 124 125 126 127 128 129 130 131
SA_LIBS    ?= ${ROM_LIBS}

DBG_MODULE ?= rm.${MACHINE}.${TARGET}D
DBG_OBJECT ?= o.${MACHINE}.${TARGET}D
DBG_LIBS   ?= ${ROM_LIBS}

GPA_FILE   ?= gpa.${MACHINE}.${TARGET}
GPA_AIF    ?= aif.${MACHINE}.${TARGET}

TOKENS     ?= Hdr:Tokens

TOKENSOURCE ?= s.TokHelpSrc

132 133 134
ifneq (${RESOURCES},)
CUSTOMRES   = ${RESOURCES} # The old name for CUSTOMRES
endif
135

136 137 138 139 140 141 142 143
ifeq ($(filter rom%,${MAKECMDGOALS}),)
RES_FILES_    = ${INSTRAM_FILES}
RES_DEPENDS_  = ${INSTRAM_DEPENDS}
else
RES_FILES_    = ${INSTROM_FILES}
RES_DEPENDS_  = ${INSTROM_DEPENDS}
endif

144 145 146 147 148 149 150 151
#
# Exported headers
#

# Need these to stop complaints about the rules below
ASMCHEADER1 ?= _!_x_!_
ASMCHEADER2 ?= _!_x_!_
ASMCHEADER3 ?= _!_x_!_
152 153 154 155 156
ASMCHEADER4 ?= _!_x_!_
ASMCHEADER5 ?= _!_x_!_
ASMCHEADER6 ?= _!_x_!_
ASMCHEADER7 ?= _!_x_!_
ASMCHEADER8 ?= _!_x_!_
157 158 159 160 161
CHEADER1    ?= _!_x_!_
CHEADER2    ?= _!_x_!_
CHEADER3    ?= _!_x_!_


Ben Avison's avatar
Ben Avison committed
162 163 164 165 166
ifeq ("${INCLUDED_STDTOOLS}","")
include StdTools
endif


167 168 169 170 171 172 173
all: rom debug standalone

${DIRS} ::
        ${MKDIR} o.${MACHINE}
        ${MKDIR} rm.${MACHINE}
        ${TOUCH} $@

174
#
175
# ROM build rules
176
#
177
rom${CUSTOMROM}: ${ROM_MODULE}
178 179
        @${ECHO} ${COMPONENT}: rom module built

180
install_rom${CUSTOMROM}: ${ROM_MODULE}
181
        ${CP} ${ROM_MODULE} ${INSTDIR}.${TARGET} ${CPFLAGS}
182
        ${CP} ${ROM_MODULE}_gpa ${INSTDIR}.${TARGET}_gpa ${CPFLAGS}
183 184
        @${ECHO} ${COMPONENT}: rom module installed

185 186 187 188
rom_link${CUSTOMROM}: ${ROM_MODULE}
        ${LD} -rmf -o ${LINKDIR}.${TARGET} ${ROM_OBJECT} ${ROM_LIBS} -Symbols ${LINKDIR}.${TARGET}_sym -base ${ADDRESS}
        @${ECHO} ${COMPONENT}: rom_link complete

189
${ROM_MODULE}: ${ROM_OBJECT} ${ROM_LIBS} ${DIRS} ${ROM_DEPEND}
190
        ${LD} -rmf -o $@ ${ROM_OBJECT} ${ROM_LIBS}
191 192
        ${LD} -aif -bin -d -Entry 0 -o ${ROM_MODULE}_aif ${ROM_OBJECT} ${ROM_LIBS}
        ${TOGPA} -s ${ROM_MODULE}_aif ${ROM_MODULE}_gpa
193 194

${ROM_OBJECT}: ${ROM_SOURCE} ${TOKHELPSRC} ${DIRS}
195
        ${AS} ${ASFLAGS} -g -o $@ ${ROM_SOURCE}
196 197 198 199

#
# Standalone builds
#
200
standalone${CUSTOMSA}: ${SA_MODULE}
201 202
        @${ECHO} ${COMPONENT}: standalone module built

203
${SA_MODULE}: ${SA_OBJECT} ${SA_LIBS} ${DIRS} ${SA_DEPEND}
204 205 206 207 208 209 210
        ${LD} -rmf -o $@ ${SA_OBJECT} ${SA_LIBS}
        ${MODSQZ} -f ${MODSQZFLAGS} $@
        ${CHMOD} -R a+rx rm

${SA_OBJECT}: ${ROM_SOURCE} ${MERGEDMSGS} ${TOKHELPSRC} ${DIRS}
        ${AS} ${ASFLAGS} -o $@ ${ROM_SOURCE} ${SA_FLAGS}

211 212 213
ifeq ($(filter no custom,${CUSTOMRES}),)
${MERGEDMSGS}:
        ${MKDIR} ${MERGEDRDIR}.${TARGET}
214
        ${TOKENCHECK} LocalRes:Messages
215
        IfThere LocalRes:CmdHelp Then ${TOKENCHECK} LocalRes:CmdHelp
Jeffrey Lee's avatar
Jeffrey Lee committed
216
        IfThere LocalRes:CmdHelp Then ${FAPPEND} $@ LocalRes:Messages LocalRes:CmdHelp Else IfThere LocalRes:Messages Then ${CP} LocalRes:Messages $@ ${CPFLAGS}
217 218 219 220
else
${MERGEDMSGS}::
        @${NOP}
endif
221

222
install${CUSTOMSA}: ${SA_MODULE}
223 224 225 226 227
        ${MKDIR} ${INSTDIR}
        ${CP} ${SA_MODULE} ${INSTDIR}.${TARGET} ${CPFLAGS}
        ${CHMOD} a=rx $@
        @${ECHO} ${COMPONENT}: standalone module installed

228
debug${CUSTOMDBG}: ${DBG_MODULE}
229 230
        @${ECHO} ${COMPONENT}: standalone debug module built

231
${DBG_MODULE}: ${DBG_OBJECT} ${DBG_LIBS} ${DIRS} ${SA_DEPEND}
232 233 234
        ${LD} -rmf -o $@ ${DBG_OBJECT} ${DBG_LIBS}

${DBG_OBJECT}: ${ROM_SOURCE} ${MERGEDMSGS} ${TOKHELPSRC} ${DIRS}
235
        ${AS} ${ASFLAGS} ${ASDFLAGS} -g -pd "debugging SETL {TRUE}" -o $@ ${ROM_SOURCE} ${SA_FLAGS}
236

237
gpa_debug${CUSTOMGPA}: ${GPA_FILE}
238 239 240 241 242 243 244 245 246 247 248 249 250
        @${ECHO} ${COMPONENT}: GPA debug listing generated

${GPA_FILE}: ${GPA_AIF}
        ${MKDIR} gpa.${MACHINE}
        ${TOGPA} -s ${GPA_AIF} ${GPA_FILE}

${GPA_AIF}: ${DBG_OBJECT}
        ${MKDIR} aif.${MACHINE}
        ${LD} -aif -bin -d -o ${GPA_AIF} ${DBG_OBJECT}

#
# Clean the module
#
251
clean ::
252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276
        @IfThere rm.${MACHINE} Then ${ECHO} ${WIPE} rm.${MACHINE} ${WFLAGS}
        @IfThere rm.${MACHINE} Then ${WIPE} rm.${MACHINE} ${WFLAGS}
        @-IfThere rm.* Then Else IfThere rm Then ${ECHO} ${WIPE} rm ${WFLAGS}
        @-IfThere rm.* Then Else IfThere rm Then ${WIPE} rm ${WFLAGS}
        @IfThere o Then ${ECHO} ${WIPE} o ${WFLAGS}
        @IfThere o Then ${WIPE} o ${WFLAGS}
        @IfThere aif.${MACHINE} Then ${ECHO} ${WIPE} aif.${MACHINE} ${WFLAGS}
        @IfThere aif.${MACHINE} Then ${WIPE} aif.${MACHINE} ${WFLAGS}
        @-IfThere aif.* Then Else IfThere aif Then ${ECHO} ${WIPE} aif ${WFLAGS}
        @-IfThere aif.* Then Else IfThere aif Then ${WIPE} aif ${WFLAGS}
        @IfThere gpa Then ${ECHO} ${WIPE} gpa ${WFLAGS}
        @IfThere gpa Then ${WIPE} gpa ${WFLAGS}
        @-${RM} ${TOKENSOURCE}
        @${ECHO} ${COMPONENT}: cleaned

#
# Export phases
#
export_hdrs: ${EXPORTS}
        @If "${HEADER1}"<>"" Then ${ECHO} ${CP} hdr.${HEADER1} ${EXP_HDR}.${HEADER1} ${CPFLAGS}
        @If "${HEADER1}"<>"" Then ${CP} hdr.${HEADER1} ${EXP_HDR}.${HEADER1} ${CPFLAGS}
        @If "${HEADER2}"<>"" Then ${ECHO} ${CP} hdr.${HEADER2} ${EXP_HDR}.${HEADER2} ${CPFLAGS}
        @If "${HEADER2}"<>"" Then ${CP} hdr.${HEADER2} ${EXP_HDR}.${HEADER2} ${CPFLAGS}
        @If "${HEADER3}"<>"" Then ${ECHO} ${CP} hdr.${HEADER3} ${EXP_HDR}.${HEADER3} ${CPFLAGS}
        @If "${HEADER3}"<>"" Then ${CP} hdr.${HEADER3} ${EXP_HDR}.${HEADER3} ${CPFLAGS}
277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302
        @If "${HEADER4}"<>"" Then ${ECHO} ${CP} hdr.${HEADER4} ${EXP_HDR}.${HEADER4} ${CPFLAGS}
        @If "${HEADER4}"<>"" Then ${CP} hdr.${HEADER4} ${EXP_HDR}.${HEADER4} ${CPFLAGS}
        @If "${HEADER5}"<>"" Then ${ECHO} ${CP} hdr.${HEADER5} ${EXP_HDR}.${HEADER5} ${CPFLAGS}
        @If "${HEADER5}"<>"" Then ${CP} hdr.${HEADER5} ${EXP_HDR}.${HEADER5} ${CPFLAGS}
        @If "${HEADER6}"<>"" Then ${ECHO} ${CP} hdr.${HEADER6} ${EXP_HDR}.${HEADER6} ${CPFLAGS}
        @If "${HEADER6}"<>"" Then ${CP} hdr.${HEADER6} ${EXP_HDR}.${HEADER6} ${CPFLAGS}
        @If "${HEADER7}"<>"" Then ${ECHO} ${CP} hdr.${HEADER7} ${EXP_HDR}.${HEADER7} ${CPFLAGS}
        @If "${HEADER7}"<>"" Then ${CP} hdr.${HEADER7} ${EXP_HDR}.${HEADER7} ${CPFLAGS}
        @If "${HEADER8}"<>"" Then ${ECHO} ${CP} hdr.${HEADER8} ${EXP_HDR}.${HEADER8} ${CPFLAGS}
        @If "${HEADER8}"<>"" Then ${CP} hdr.${HEADER8} ${EXP_HDR}.${HEADER8} ${CPFLAGS}
        @If "${HEADER9}"<>"" Then ${ECHO} ${CP} hdr.${HEADER9} ${EXP_HDR}.${HEADER9} ${CPFLAGS}
        @If "${HEADER9}"<>"" Then ${CP} hdr.${HEADER9} ${EXP_HDR}.${HEADER9} ${CPFLAGS}
        @If "${HEADER10}"<>"" Then ${ECHO} ${CP} hdr.${HEADER10} ${EXP_HDR}.${HEADER10} ${CPFLAGS}
        @If "${HEADER10}"<>"" Then ${CP} hdr.${HEADER10} ${EXP_HDR}.${HEADER10} ${CPFLAGS}
        @If "${HEADER11}"<>"" Then ${ECHO} ${CP} hdr.${HEADER11} ${EXP_HDR}.${HEADER11} ${CPFLAGS}
        @If "${HEADER11}"<>"" Then ${CP} hdr.${HEADER11} ${EXP_HDR}.${HEADER11} ${CPFLAGS}
        @If "${HEADER12}"<>"" Then ${ECHO} ${CP} hdr.${HEADER12} ${EXP_HDR}.${HEADER12} ${CPFLAGS}
        @If "${HEADER12}"<>"" Then ${CP} hdr.${HEADER12} ${EXP_HDR}.${HEADER12} ${CPFLAGS}
        @If "${HEADER13}"<>"" Then ${ECHO} ${CP} hdr.${HEADER13} ${EXP_HDR}.${HEADER13} ${CPFLAGS}
        @If "${HEADER13}"<>"" Then ${CP} hdr.${HEADER13} ${EXP_HDR}.${HEADER13} ${CPFLAGS}
        @If "${HEADER14}"<>"" Then ${ECHO} ${CP} hdr.${HEADER14} ${EXP_HDR}.${HEADER14} ${CPFLAGS}
        @If "${HEADER14}"<>"" Then ${CP} hdr.${HEADER14} ${EXP_HDR}.${HEADER14} ${CPFLAGS}
        @If "${HEADER15}"<>"" Then ${ECHO} ${CP} hdr.${HEADER15} ${EXP_HDR}.${HEADER15} ${CPFLAGS}
        @If "${HEADER15}"<>"" Then ${CP} hdr.${HEADER15} ${EXP_HDR}.${HEADER15} ${CPFLAGS}
        @If "${HEADER16}"<>"" Then ${ECHO} ${CP} hdr.${HEADER16} ${EXP_HDR}.${HEADER16} ${CPFLAGS}
        @If "${HEADER16}"<>"" Then ${CP} hdr.${HEADER16} ${EXP_HDR}.${HEADER16} ${CPFLAGS}
303 304 305 306 307
        @${ECHO} ${COMPONENT}: header export complete

export_libs:
        @${ECHO} ${COMPONENT}: library export complete

308
export${CUSTOMEXP}: export_${PHASE}
309
        @${NOP}
310 311
        
export_:: export_libs export_hdrs
312
        @${NOP}
313 314 315 316 317 318 319 320 321 322

${C_EXP_HDR}.${ASMCHEADER1} :: hdr.${ASMCHEADER1}
        ${HDR2H} hdr.${ASMCHEADER1} $@

${C_EXP_HDR}.${ASMCHEADER2} :: hdr.${ASMCHEADER2}
        ${HDR2H} hdr.${ASMCHEADER2} $@

${C_EXP_HDR}.${ASMCHEADER3} :: hdr.${ASMCHEADER3}
        ${HDR2H} hdr.${ASMCHEADER3} $@

323 324 325 326 327 328 329 330 331 332 333 334 335 336 337
${C_EXP_HDR}.${ASMCHEADER4} :: hdr.${ASMCHEADER4}
        ${HDR2H} hdr.${ASMCHEADER4} $@

${C_EXP_HDR}.${ASMCHEADER5} :: hdr.${ASMCHEADER5}
        ${HDR2H} hdr.${ASMCHEADER5} $@

${C_EXP_HDR}.${ASMCHEADER6} :: hdr.${ASMCHEADER6}
        ${HDR2H} hdr.${ASMCHEADER6} $@

${C_EXP_HDR}.${ASMCHEADER7} :: hdr.${ASMCHEADER7}
        ${HDR2H} hdr.${ASMCHEADER7} $@

${C_EXP_HDR}.${ASMCHEADER8} :: hdr.${ASMCHEADER8}
        ${HDR2H} hdr.${ASMCHEADER8} $@

338 339 340 341 342 343 344 345 346 347
${C_EXP_HDR}.${CHEADER1} :: h.${CHEADER1}
        ${CP} h.${CHEADER1} $@ ${CPFLAGS}

${C_EXP_HDR}.${CHEADER2} :: h.${CHEADER2}
        ${CP} h.${CHEADER2} $@ ${CPFLAGS}

${C_EXP_HDR}.${CHEADER3} :: h.${CHEADER3}
        ${CP} h.${CHEADER3} $@ ${CPFLAGS}

#
348
# Resources rules
349
#
350
resources${CUSTOMRES}:: resources-${CMDHELP}
351 352 353 354 355 356
        @${ECHO} ${COMPONENT}: resources copied to Messages module

ifeq (${CUSTOMRES},no)
resources:
        @${ECHO} ${COMPONENT}: no resources to export
endif        
357

358 359 360 361 362 363 364 365
resources_extra: ${RES_DEPENDS_}
ifneq (${RES_FILES_},)
        ${INSTRES} -I Resources.${USERIF}.${LOCALE},Resources.${USERIF}.UK,Resources.${LOCALE},Resources.UK,Resources ${RESFSDIR} ${RES_FILES_}
endif
ifneq (,$(filter Messages,${INSTRES_VERSION}))
        ${INSERTVERSION} ${RESFSDIR}.Messages > ${RESFSDIR}._Awk_
        ${CP} ${RESFSDIR}._Awk_ ${RESFSDIR}.Messages ${CPFLAGS}
        ${RM} ${RESFSDIR}._Awk_
366
        ${TOUCH} -r LocalRes:Messages ${RESFSDIR}.Messages
367 368 369 370
endif
        @${NOP}

resources_common:
371 372 373
        ${MKDIR} ${RESFSDIR}
        ${TOKENCHECK} LocalRes:Messages
        ${CP} LocalRes:Messages ${RESFSDIR}.Messages ${CPFLAGS}
374

375
resources_cmdhelp:
376
        IfThere LocalRes:CmdHelp Then ${TOKENCHECK} LocalRes:CmdHelp
377
        IfThere LocalRes:CmdHelp Then ${FAPPEND} ${RESFSDIR}.Messages LocalRes:Messages LocalRes:CmdHelp
378

379 380 381 382 383
resources-None: resources_extra resources_common
        @${NOP}

resources-: resources_extra resources_cmdhelp resources_common
        @${NOP}
384 385 386 387 388 389 390 391 392

#
# Build the help tokens
#
${TOKENSOURCE}: ${HELPSRC} ${TOKENS}
        ${TOKENISE} ${TOKENS} ${HELPSRC} $@

EOFSTDMAKEFILE=$Id$
# EOF