50 |
|
constraints \ |
51 |
|
minimizers \ |
52 |
|
selection \ |
53 |
+ |
restraints \ |
54 |
|
|
55 |
|
#packages containing applications |
56 |
|
Applications = \ |
57 |
|
applications/oopse \ |
58 |
|
applications/dump2Xyz \ |
59 |
|
applications/simpleBuilder\ |
60 |
+ |
applications/staticProps \ |
61 |
+ |
applications/dynamicProps \ |
62 |
+ |
applications/nanoRodBuilder \ |
63 |
|
|
64 |
|
Samples = \ |
65 |
|
samples/argon \ |
76 |
|
samples/zcons \ |
77 |
|
|
78 |
|
IncludeDirs = \ |
75 |
– |
@SPRNG_INC_DIR@ \ |
79 |
|
@MPI_INC_DIR@ |
80 |
|
|
81 |
|
LibraryDirs = \ |
79 |
– |
@SPRNG_LIB_DIR@ \ |
82 |
|
@MPI_LIB_DIR@ |
83 |
|
|
84 |
|
Libraries = \ |
83 |
– |
@SPRNG_LIB@ \ |
85 |
|
@MPI_LIB@ \ |
86 |
|
@MPI_F90_LIB@ |
87 |
|
|
205 |
|
$(LexFiles:%.l= %.c) |
206 |
|
|
207 |
|
OtherTargetFiles = $(OtherSourceFiles:%=$(PackageTargetDir)/%) |
208 |
+ |
|
209 |
+ |
########################################################################### |
210 |
+ |
# |
211 |
+ |
# Figure out the names of the module files based on some work done by |
212 |
+ |
# configure. The tr function below is from John Graham-Cumming |
213 |
+ |
# (http://www.jgc.org). |
214 |
+ |
# |
215 |
+ |
# The tr function. Has three arguments: |
216 |
+ |
# |
217 |
+ |
# $1 The list of characters to translate from |
218 |
+ |
# $2 The list of characters to translate to |
219 |
+ |
# $3 The text to translate |
220 |
+ |
# |
221 |
+ |
# For example, $(call tr,A B C,1 2 3,CAPITAL) becomes 21PIT1L. |
222 |
+ |
|
223 |
+ |
tr = $(eval __t := $3) \ |
224 |
+ |
$(foreach c, \ |
225 |
+ |
$(join $(addsuffix :,$1),$2), \ |
226 |
+ |
$(eval __t := \ |
227 |
+ |
$(subst $(word 1,$(subst :, ,$c)),$(word 2,$(subst :, ,$c)), \ |
228 |
+ |
$(__t))))$(__t) |
229 |
+ |
|
230 |
+ |
# Common character classes for use with the tr function. Each of |
231 |
+ |
# these is actually a variable declaration and must be wrapped with |
232 |
+ |
# $() or ${} to be used. |
233 |
+ |
|
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 |
+ |
[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 # |
236 |
+ |
[0-9] := 0 1 2 3 4 5 6 7 8 9 # |
237 |
+ |
[A-F] := A B C D E F # |
238 |
+ |
|
239 |
+ |
# Figure out whether we have $(eval) or not (GNU Make 3.80 and above) |
240 |
+ |
# if we do not then we need to use the shell version of tr, and not the |
241 |
+ |
# faster tr function above: |
242 |
+ |
|
243 |
+ |
__have_eval := $(false) |
244 |
+ |
__ignore := $(eval __have_eval := $(true)) |
245 |
+ |
|
246 |
+ |
ifndef __have_eval |
247 |
+ |
uc = $(shell echo $1 | tr "a-z" "A-Z") |
248 |
+ |
lc = $(shell echo $1 | tr "A-Z" "a-z") |
249 |
+ |
else |
250 |
+ |
uc = $(call tr,$([a-z]),$([A-Z]),$1) |
251 |
+ |
lc = $(call tr,$([A-Z]),$([a-z]),$1) |
252 |
+ |
endif |
253 |
+ |
|
254 |
+ |
# OK, now we can actually use these functions to figure out the names |
255 |
+ |
# of the module files: |
256 |
+ |
|
257 |
+ |
ifneq "$(words $(Modules))" "0" |
258 |
+ |
ifeq "$(ModuleCase)" "UPPER" |
259 |
+ |
MODULES = $(call uc,$(Modules)) |
260 |
+ |
else |
261 |
+ |
ifeq "$(ModuleCase)" "lower" |
262 |
+ |
MODULES = $(call lc,$(Modules)) |
263 |
+ |
else |
264 |
+ |
MODULES = $(Modules) |
265 |
+ |
endif |
266 |
+ |
endif |
267 |
+ |
ModuleFiles = $(MODULES:%= $(PackageTargetDir)/%.$(ModSuffix)) |
268 |
+ |
ParallelModuleFiles = $(MODULES:%= $(PackageParallelTargetDir)/%.$(ModSuffix)) |
269 |
+ |
endif |
270 |
+ |
# |
271 |
+ |
########################################################################### |
272 |
|
|
273 |
|
ThirdPartyJarsTmp = $(patsubst %,$(LibDir)/%,$(JavaLibraries)) |
274 |
|
ThirdPartyJars = $(subst $(Space),$(X),$(ThirdPartyJarsTmp)) |
281 |
|
#if Main is defined, do not build library. It may not be true sometimes |
282 |
|
ifneq "$(words $(ObjectFiles) $(ParallelObjectFiles))" "0" |
283 |
|
DependencyFile = $(PackageSourceDir)/Makedepend |
284 |
< |
ifneq "$(Main)" "" |
284 |
> |
ifneq "$(words $(Main))" "0" |
285 |
|
Executable = $(BinDir)/$(Main) |
286 |
< |
ParallelExecutable = $(BinDir)/$(Main)_MPI |
286 |
> |
ifeq "$(BuiltParallelExe)" "1" |
287 |
> |
ParallelExecutable = $(BinDir)/$(Main)_MPI |
288 |
> |
endif |
289 |
|
else |
290 |
|
SharedLibrary = $(LibDir)/lib$(subst /,,$(patsubst %,oopse_%,$(Package)))_UP.so |
291 |
|
StaticLibrary = $(LibDir)/lib$(subst /,,$(patsubst %,oopse_%,$(Package)))_UP.a |
323 |
|
MakeDepend = makedepend |
324 |
|
INSTALL = @INSTALL@ |
325 |
|
InstallProgram = @INSTALL_PROGRAM@ |
326 |
+ |
InstallScript = @INSTALL_SCRIPT@ |
327 |
|
InstallData = @INSTALL_DATA@ |
328 |
|
MkDir = @MKINSTALLDIRS@ |
329 |
|
Delete = rm -fr |
686 |
|
$(JarFile) \ |
687 |
|
$(Executable) |
688 |
|
endif |
689 |
+ |
|
690 |
+ |
echo : $(PackageListLoop) |
691 |
+ |
$(Print) Done echo. |
692 |
|
|
693 |
+ |
_echoall : |
694 |
+ |
$(Print) $(Modules) |
695 |
|
|
696 |
|
# make clean |
697 |
|
clean : $(PackageListLoop) |
698 |
|
$(Print) Done clean. |
699 |
|
|
700 |
|
_cleanall : |
701 |
< |
$(Delete) $(ObjectFiles) $(ParallelObjectFiles) |
701 |
> |
$(Delete) \ |
702 |
> |
$(ObjectFiles) \ |
703 |
> |
$(ModuleFiles) \ |
704 |
> |
$(ParallelObjectFiles) \ |
705 |
> |
$(ParallelModuleFiles) \ |
706 |
> |
$(JarFile) \ |
707 |
> |
$(SharedLibrary) \ |
708 |
> |
$(StaticLibrary) \ |
709 |
> |
$(ParallelSharedLibrary) \ |
710 |
> |
$(ParallelStaticLibrary) \ |
711 |
> |
$(CombinedStaticLib) \ |
712 |
> |
$(CombinedParallelStaticLib) |
713 |
|
|
714 |
|
# make distclean |
715 |
|
distclean : $(PackageListLoop) |
716 |
|
$(Print) Done clean. |
717 |
|
|
718 |
< |
_distcleanall : |
719 |
< |
$(Delete) $(ObjectFiles) \ |
636 |
< |
$(ParallelObjectFiles) \ |
637 |
< |
$(JarFile) \ |
638 |
< |
$(SharedLibrary) \ |
639 |
< |
$(StaticLibrary) \ |
640 |
< |
$(ParallelSharedLibrary) \ |
641 |
< |
$(ParallelStaticLibrary) \ |
642 |
< |
$(Executable) \ |
718 |
> |
_distcleanall : _cleanall |
719 |
> |
$(Delete) $(Executable) \ |
720 |
|
$(ParallelExecutable) \ |
721 |
|
$(DependencyFile) |
722 |
|
|
646 |
– |
|
723 |
|
# make depend |
724 |
|
depend : $(PackageListLoop) |
725 |
|
$(Print) Done dependencies. |
795 |
|
_installdata : $(MyInstallDir) |
796 |
|
$(Print) $(InstallFiles) |
797 |
|
ifneq "$(words $(InstallFiles))" "0" |
798 |
< |
$(InstallData) $(InstallFiles) $(MyInstallDir) |
798 |
> |
$(InstallCommand) $(InstallFiles) $(MyInstallDir) |
799 |
|
endif |
800 |
|
|
801 |
|
# make statistics |