--- trunk/OOPSE-3.0/make/Makefile.in 2004/11/04 20:55:01 1712 +++ trunk/OOPSE-3.0/make/Makefile.in 2005/03/10 15:10:24 2101 @@ -38,6 +38,7 @@ PackageLibs = \ #packages containing libraries PackageLibs = \ utils \ + visitors \ math \ types \ primitives \ @@ -45,15 +46,19 @@ PackageLibs = \ UseTheForce \ brains \ io \ + integrators\ constraints \ - profiling \ + minimizers \ + selection \ restraints \ #packages containing applications Applications = \ applications/oopse \ applications/dump2Xyz \ - applications/simpleBuilder + applications/simpleBuilder\ + applications/staticProps \ + applications/dynamicProps \ Samples = \ samples/argon \ @@ -70,15 +75,12 @@ IncludeDirs = \ samples/zcons \ IncludeDirs = \ - @SPRNG_INC_DIR@ \ @MPI_INC_DIR@ LibraryDirs = \ - @SPRNG_LIB_DIR@ \ @MPI_LIB_DIR@ Libraries = \ - @SPRNG_LIB@ \ @MPI_LIB@ \ @MPI_F90_LIB@ @@ -122,7 +124,9 @@ Package = $(subst $(shell cd $(SourceDir); pw # /home/maul/gezelter/src/code/src/UseTheForce/Darkside --> UseTheForce/Darkside #Package = $(shell echo $(CurrentDir) | sed -e 's/^.*\/src\/\(.*\)/\1/g') #use shell script to get the absolute path and then rip it off from $(CurrentDir) -Package = $(subst $(shell cd $(SourceDir); pwd)/,,$(CurrentDir)) +#Package = $(subst $(shell cd $(SourceDir); pwd)/,,$(CurrentDir)) +# REMINDER: We are now using the Package line in each subdir makefile. +# This avoids the strange path problem and the subshell PackageList = $(Package) PackageSourceDir = $(SourceDir)/$(Package) @@ -244,7 +248,7 @@ Move = mv # #--------------------------------------------------------------------------- Print = @echo -Move = mv +Move = mv -f Copy = cp CCompiler = @CC@ CppCompiler = @CXX@ @@ -253,7 +257,7 @@ MkDir = @MKINSTALLDIRS@ INSTALL = @INSTALL@ InstallProgram = @INSTALL_PROGRAM@ InstallData = @INSTALL_DATA@ -MkDir = @MKINSTALLDIRS@ +MkDir = @MKINSTALLDIRS@ Delete = rm -fr StaticArchiver = @AR@ DynamicArchiver = @CC@ @@ -284,8 +288,8 @@ CppOptions = $(FrcDeclare) @CXXFLAGS@ -sourcepath $(SourceDir) COptions = $(FrcDeclare) @CFLAGS@ CParallelOptions = $(FrcDeclare) $(ParallelDeclare) @CFLAGS@ -CppOptions = $(FrcDeclare) @CXXFLAGS@ -CppParallelOptions = $(FrcDeclare) $(ParallelDeclare) @CXXFLAGS@ +CppOptions = $(FrcDeclare) @CXXFLAGS@ @OOPSE_TEMPLATE_FLAGS@ +CppParallelOptions = $(FrcDeclare) $(ParallelDeclare) @CXXFLAGS@ @OOPSE_TEMPLATE_FLAGS@ FortranOptions = F90Options = @PREPFLAG@ @F90FLAGS@ @MODDIRFLAG@$(SourceDir) @MODDIRFLAG@$(TargetDir) F90ParallelOptions = @PREPFLAG@ @F90FLAGS@ @MODDIRFLAG@$(SourceDir) @MODDIRFLAG@$(ParallelTargetDir) @PREPDEFFLAG@$(ParallelDeclare) @@ -363,8 +367,11 @@ $(PackageTargetDir) : # Create target directory $(PackageTargetDir) : - $(MakeDir) $@ + $(MkDir) $@ +$(BinDir) : + $(MkDir) $@ + # .c -> .o $(PackageTargetDir)/%.o : %.c $(Print) $@ @@ -418,35 +425,34 @@ $(PackageTargetDir)/%.o : %.F90 # .F90 -> .o $(PackageTargetDir)/%.o : %.F90 $(F90Compiler) $(F90Options) $(IncludePath) -c $< -o $@ - if test -f *.$(ModSuffix); then \ - $(Move) *.$(ModSuffix) $(PackageTargetDir);\ + if test -n "`ls *.$(ModSuffix)`"; then \ + $(Move) `ls *.$(ModSuffix)` $(PackageTargetDir);\ fi $(PackageParallelTargetDir)/%.o : %.F90 $(F90Compiler) $(F90ParallelOptions) $(IncludePath) -c $< -o $@ - if test -f *.$(ModSuffix); then \ - $(Move) *.$(ModSuffix) $(PackageParallelTargetDir);\ + if test -n "`ls *.$(ModSuffix)`"; then \ + $(Move) "`ls *.$(ModSuffix)`" $(PackageParallelTargetDir);\ fi ifeq "$(UseMPI)" "yes" %.o : %.F90 $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@ - if test -f *.$(ModSuffix); then \ - $(Move) *.$(ModSuffix) $(PackageTargetDir);\ - fi + if test -n "`ls *.$(ModSuffix)`"; then\ + $(Move) "`ls *.$(ModSuffix)`" $(PackageTargetDir);\ + fi $(MAKE) $(MakeOptions) $(PackageParallelTargetDir)/$@ - if test -f *.$(ModSuffix); then \ - $(Move) *.$(ModSuffix) $(PackageParallelTargetDir);\ + if test -n "`ls *.$(ModSuffix)`"; then\ + $(Move) "`ls *.$(ModSuffix)`" $(PackageTargetDir);\ fi else %.o : %.F90 $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@ - if test -f *.$(ModSuffix); then \ - $(Move) *.$(ModSuffix) $(PackageTargetDir);\ - fi - + if test -n "`ls *.$(ModSuffix)`"; then\ + $(Move) "`ls *.$(ModSuffix)`" $(PackageTargetDir);\ + fi endif @@ -566,11 +572,11 @@ $(Executable) : $(CombinedStaticLib) $(ObjectFiles) $(Ranlib) $(CombinedParallelStaticLib) # Executable -$(Executable) : $(CombinedStaticLib) $(ObjectFiles) - $(Linker) $(ObjectFiles) $(LinkOptions) $(LibDirs) $(CombinedStaticLib) $(Libraries) -o $@ +$(Executable) : $(CombinedStaticLib) $(ObjectFiles) $(BinDir) + $(Linker) $(ObjectFiles) $(CombinedStaticLib) $(LinkOptions) $(LibDirs) $(Libraries) -o $@ -$(ParallelExecutable) : $(CombinedParallelStaticLib) $(ParallelObjectFiles) - $(Linker) $(ParallelObjectFiles) $(ParallelLinkOptions) $(LibDirs) $(CombinedParallelStaticLib) $(Libraries) -o $@ +$(ParallelExecutable) : $(CombinedParallelStaticLib) $(ParallelObjectFiles) $(BinDir) + $(Linker) $(ParallelObjectFiles) $(CombinedParallelStaticLib) $(ParallelLinkOptions) $(LibDirs) $(Libraries) -o $@ # Anything else is just copied from source to target $(PackageTargetDir)/% : $(PackageSourceDir)/% @@ -619,25 +625,26 @@ _cleanall : $(Print) Done clean. _cleanall : - $(Delete) $(ObjectFiles) $(ParallelObjectFiles) + $(Delete) \ + $(ObjectFiles) \ + $(ParallelObjectFiles) \ + $(JarFile) \ + $(SharedLibrary) \ + $(StaticLibrary) \ + $(ParallelSharedLibrary) \ + $(ParallelStaticLibrary) \ + $(CombinedStaticLib) \ + $(CombinedParallelStaticLib) # make distclean distclean : $(PackageListLoop) $(Print) Done clean. -_distcleanall : - $(Delete) $(ObjectFiles) \ - $(ParallelObjectFiles) \ - $(JarFile) \ - $(SharedLibrary) \ - $(StaticLibrary) \ - $(ParallelSharedLibrary) \ - $(ParallelStaticLibrary) \ - $(Executable) \ +_distcleanall : _cleanall + $(Delete) $(Executable) \ $(ParallelExecutable) \ $(DependencyFile) - # make depend depend : $(PackageListLoop) $(Print) Done dependencies. @@ -715,7 +722,7 @@ endif ifneq "$(words $(InstallFiles))" "0" $(InstallData) $(InstallFiles) $(MyInstallDir) endif - + # make statistics _statisticsall : @$(Print) $(patsubst %,$(CurrentDir)/%,$(SourceFiles)) >> $(DEV_ROOT)/files.tmp