204 |
|
$(LexFiles:%.l= %.c) |
205 |
|
|
206 |
|
OtherTargetFiles = $(OtherSourceFiles:%=$(PackageTargetDir)/%) |
207 |
+ |
|
208 |
+ |
########################################################################### |
209 |
+ |
# |
210 |
+ |
# Figure out the names of the module files based on some work done by |
211 |
+ |
# configure. The tr function below is from John Graham-Cumming |
212 |
+ |
# (http://www.jgc.org). |
213 |
+ |
# |
214 |
+ |
# The tr function. Has three arguments: |
215 |
+ |
# |
216 |
+ |
# $1 The list of characters to translate from |
217 |
+ |
# $2 The list of characters to translate to |
218 |
+ |
# $3 The text to translate |
219 |
+ |
# |
220 |
+ |
# For example, $(call tr,A B C,1 2 3,CAPITAL) becomes 21PIT1L. |
221 |
+ |
|
222 |
+ |
tr = $(eval __t := $3) \ |
223 |
+ |
$(foreach c, \ |
224 |
+ |
$(join $(addsuffix :,$1),$2), \ |
225 |
+ |
$(eval __t := \ |
226 |
+ |
$(subst $(word 1,$(subst :, ,$c)),$(word 2,$(subst :, ,$c)), \ |
227 |
+ |
$(__t))))$(__t) |
228 |
+ |
|
229 |
+ |
# Common character classes for use with the tr function. Each of |
230 |
+ |
# these is actually a variable declaration and must be wrapped with |
231 |
+ |
# $() or ${} to be used. |
232 |
+ |
|
233 |
+ |
[A-Z] := A B C D E F G H I J K L M N O P Q R S T U V W X Y Z # |
234 |
+ |
[a-z] := a b c d e f g h i j k l m n o p q r s t u v w x y z # |
235 |
+ |
[0-9] := 0 1 2 3 4 5 6 7 8 9 # |
236 |
+ |
[A-F] := A B C D E F # |
237 |
+ |
|
238 |
+ |
# Upper case and lower case functions. Each function has a single |
239 |
+ |
# argument which is the text to alter |
240 |
+ |
|
241 |
+ |
uc = $(call tr,$([a-z]),$([A-Z]),$1) |
242 |
+ |
lc = $(call tr,$([A-Z]),$([a-z]),$1) |
243 |
+ |
|
244 |
+ |
# OK, now we can actually use these functions to figure out the names |
245 |
+ |
# of the module files: |
246 |
+ |
|
247 |
+ |
ifneq "$(words $(Modules))" "0" |
248 |
+ |
ifeq "$(ModuleCase)" "UPPER" |
249 |
+ |
MODULES = $(call uc,$(Modules)) |
250 |
+ |
else |
251 |
+ |
ifeq "$(ModuleCase)" "lower" |
252 |
+ |
MODULES = $(call lc,$(Modules)) |
253 |
+ |
else |
254 |
+ |
MODULES = $(Modules) |
255 |
+ |
endif |
256 |
+ |
endif |
257 |
+ |
ModuleFiles = $(MODULES:%= $(PackageTargetDir)/%.$(ModSuffix)) |
258 |
+ |
ParallelModuleFiles = $(MODULES:%= $(PackageParallelTargetDir)/%.$(ModSuffix)) |
259 |
+ |
endif |
260 |
+ |
# |
261 |
+ |
########################################################################### |
262 |
|
|
263 |
|
ThirdPartyJarsTmp = $(patsubst %,$(LibDir)/%,$(JavaLibraries)) |
264 |
|
ThirdPartyJars = $(subst $(Space),$(X),$(ThirdPartyJarsTmp)) |
677 |
|
$(Executable) |
678 |
|
endif |
679 |
|
|
680 |
+ |
echo : $(PackageListLoop) |
681 |
+ |
$(Print) Done echo. |
682 |
|
|
683 |
+ |
_echoall : |
684 |
+ |
$(Print) $(Modules) |
685 |
+ |
|
686 |
|
# make clean |
687 |
|
clean : $(PackageListLoop) |
688 |
|
$(Print) Done clean. |
690 |
|
_cleanall : |
691 |
|
$(Delete) \ |
692 |
|
$(ObjectFiles) \ |
693 |
+ |
$(ModuleFiles) \ |
694 |
|
$(ParallelObjectFiles) \ |
695 |
+ |
$(ParallelModuleFiles) \ |
696 |
|
$(JarFile) \ |
697 |
|
$(SharedLibrary) \ |
698 |
|
$(StaticLibrary) \ |