ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE-4/make/Makefile.in
(Generate patch)

Comparing trunk/OOPSE-4/make/Makefile.in (file contents):
Revision 1535 by gezelter, Wed Oct 6 21:22:43 2004 UTC vs.
Revision 1712 by tim, Thu Nov 4 20:55:01 2004 UTC

# Line 41 | Line 41 | PackageLibs = \
41          math \
42          types \
43          primitives \
44        visitors \
44          UseTheForce/DarkSide \
45          UseTheForce \
46          brains \
47          io \
49        integrators \
50        minimizers \
48          constraints \
49          profiling \
50          restraints \
# Line 86 | Line 83 | ForceParamDir   = @OOPSE_HOME@/share/forceFields/
83          @MPI_F90_LIB@
84  
85   OopseHome       = @OOPSE_HOME@
86 < ForceParamDir   = @OOPSE_HOME@/share/forceFields/
87 < SampleSimDir    = @OOPSE_HOME@/share/samples/
86 > ForceParamDir   = $(OopseHome)/share/forceFields
87 > SampleSimDir    = $(OopseHome)/share/samples
88 > InstallBinDir   = $(OopseHome)/bin
89 > DocDir          = $(OopseHome)/doc
90   FrcDeclare      = -DFRC_PATH="$(ForceParamDir)"
91   F90Declare      = -D__FORTRAN90
92   ParallelDeclare = -DIS_MPI
# Line 223 | Line 222 | endif
222      ParallelStaticLibrary  = $(LibDir)/lib$(subst /,,$(patsubst %,oopse_%,$(Package)))_MPI.a
223    endif
224   endif
225 +
226   #
227   # Misc
228   #
# Line 250 | Line 250 | Install                = @INSTALL@
250   CppCompiler            = @CXX@
251   Linker                 = @CXX@
252   MakeDepend             = makedepend
253 < Install                = @INSTALL@
253 > INSTALL                = @INSTALL@
254   InstallProgram         = @INSTALL_PROGRAM@
255   InstallData            = @INSTALL_DATA@
256 < MakeDir                = @MKINSTALLDIRS@
256 > MkDir                = @MKINSTALLDIRS@
257   Delete                 = rm -fr
258   StaticArchiver         = @AR@
259   DynamicArchiver        = @CC@
# Line 272 | Line 272 | Ranlib                 = @RANLIB@
272   Yacc                   = @YACC@
273   Lex                    = @LEX@
274   Ranlib                 = @RANLIB@
275 + Doxygen                = @DOXYGEN@
276  
276
277   MakeOptions            = -k
278   MakeDependOptions      =
279   StaticArchiverOptions  = rc
# Line 282 | Line 282 | COptions               = $(FrcDeclare)
282   JniOptions             =
283   RmiOptions             = -d $(TargetDir) -classpath $(ClassPath) \
284                           -sourcepath $(SourceDir)
285 < COptions               = $(FrcDeclare)
286 < CParallelOptions       = $(FrcDeclare) $(ParallelDeclare)
287 < CppOptions             = $(FrcDeclare)
288 < CppParallelOptions     = $(FrcDeclare) $(ParallelDeclare)
285 > COptions               = $(FrcDeclare) @CFLAGS@
286 > CParallelOptions       = $(FrcDeclare) $(ParallelDeclare) @CFLAGS@
287 > CppOptions             = $(FrcDeclare) @CXXFLAGS@
288 > CppParallelOptions     = $(FrcDeclare) $(ParallelDeclare) @CXXFLAGS@
289   FortranOptions         =
290 < F90Options             =  @PREPFLAG@ @F90FLAGS@ @MODDIRFLAG@$(SourceDir) -module $(TargetDir)
291 < F90ParallelOptions     =  @PREPFLAG@ @F90FLAGS@ @MODDIRFLAG@$(SourceDir) -module $(ParallelTargetDir)  @PREPDEFFLAG@$(ParallelDeclare)
290 > F90Options             =  @PREPFLAG@ @F90FLAGS@ @MODDIRFLAG@$(SourceDir) @MODDIRFLAG@$(TargetDir)
291 > F90ParallelOptions     =  @PREPFLAG@ @F90FLAGS@ @MODDIRFLAG@$(SourceDir) @MODDIRFLAG@$(ParallelTargetDir)  @PREPDEFFLAG@$(ParallelDeclare)
292   JavaCompilerOptions    = -d $(TargetDir) -classpath $(ClassPath) \
293                           -sourcepath $(SourceDir) -deprecation
294   JavaRunOptions         = -classpath $(ClassPath)
# Line 314 | Line 314 | Space                  = $(Empty) $(Empty)
314  
315   #---------------------------------------------------------------------------
316   #
317 + #  Install
318 + #
319 + #---------------------------------------------------------------------------
320 +
321 + ifneq "$(words $(SampleFiles))" "0"
322 +  MySample                 = $(subst $(shell cd $(DEV_ROOT)/samples; pwd)/,,$(CurrentDir))
323 +  MyInstallDir             = $(SampleSimDir)/$(MySample)
324 +  InstallFiles             = $(SampleFiles)
325 +  InstallCommand           = $(InstallData)
326 + endif
327 +
328 + ifneq "$(words $(Main))" "0"
329 +  MyInstallDir             = $(InstallBinDir)
330 +  ifeq "$(UseMPI)" "yes"
331 +    InstallFiles             = $(Executable) $(ParallelExecutable)
332 +  else
333 +    InstallFiles             = $(Executable)
334 +  endif
335 +  InstallCommand           = $(InstallProgram)
336 + endif
337 +
338 + ifneq "$(words $(ForcefieldFiles))" "0"
339 +  MyInstallDir             = $(ForceParamDir)
340 +  InstallFiles             = $(ForcefieldFiles)
341 +  InstallCommand           = $(InstallData)
342 + endif
343 +
344 + ifneq "$(words $(InstallFiles))" "0"
345 +  InstallList            =
346 + else
347 +  InstallList            = $(patsubst %,$(DEV_ROOT)/%,$(Samples)) $(DEV_ROOT)/forceFields $(patsubst %, $(SourceDir)/%,$(Applications))
348 + endif
349 +
350 + InstallListLoop          = $(patsubst %,$(SourceDir)/%/.install,$(PackageList))  $(patsubst %,%/.install,$(InstallList))
351 +
352 +
353 +
354 + #---------------------------------------------------------------------------
355 + #
356   # Rules
357   #
358   #---------------------------------------------------------------------------
# Line 379 | Line 418 | $(PackageTargetDir)/%.o : %.F90
418   # .F90 -> .o
419   $(PackageTargetDir)/%.o : %.F90
420          $(F90Compiler) $(F90Options) $(IncludePath) -c $< -o $@
421 +        if test -f *.$(ModSuffix); then \
422 +          $(Move) *.$(ModSuffix) $(PackageTargetDir);\
423 +        fi
424  
425   $(PackageParallelTargetDir)/%.o : %.F90
426          $(F90Compiler) $(F90ParallelOptions) $(IncludePath) -c $< -o $@
427 +        if test -f *.$(ModSuffix); then \
428 +          $(Move) *.$(ModSuffix) $(PackageParallelTargetDir);\
429 +        fi
430  
431   ifeq "$(UseMPI)" "yes"
432   %.o : %.F90
433          $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@
434 +        if test -f *.$(ModSuffix); then \
435 +          $(Move) *.$(ModSuffix) $(PackageTargetDir);\
436 +        fi
437 +
438          $(MAKE) $(MakeOptions) $(PackageParallelTargetDir)/$@
439 +        if test -f *.$(ModSuffix); then \
440 +          $(Move) *.$(ModSuffix) $(PackageParallelTargetDir);\
441 +        fi
442 +
443   else
444   %.o : %.F90
445          $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@
446 +        if test -f *.$(ModSuffix); then \
447 +          $(Move) *.$(ModSuffix) $(PackageTargetDir);\
448 +        fi
449 +
450   endif
451  
452  
# Line 486 | Line 543 | $(PackageTargetDir)/%_Skel.class : $(PackageTargetDir)
543   %_Skel.class : %.class
544          $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@
545  
546 + document :
547 +        $(Print) Generate Documentation for OOPSE-2.0
548 +        @cd $(DEV_ROOT)/src    
549 +        $(Doxygen) $(DEV_ROOT)/make/Doxyfile
550 +
551   #GUN make funtions to merge the libraries
552   find_objs = $(shell $(StaticArchiver) -t $(1))
553   extract_objs = $(shell $(StaticArchiver) -x $(1) $(call find_objs, $(1)))
# Line 521 | Line 583 | ifeq "$(UseMPI)" "yes"
583  
584   _all : _buildall
585  
586 + _buildall :
587   ifeq "$(UseMPI)" "yes"
588   _buildall : \
589          $(DependencyFile) \
# Line 586 | Line 649 | ifneq "$(words $(CppFiles))" "0"
649          @cd $(PackageSourceDir)
650  
651   ifneq "$(words $(CppFiles))" "0"
652 <        $(CppCompiler) $(CppOptions) $(IncludePath) -MM $(CppFiles) > Make.cpptemp
653 <        cat Make.cpptemp | sed 's/^[a-zA-Z0-9]/$$\(TargetDir\)\/&/g' >> $(DependencyFile)
652 >        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(TargetDir)/' -MM $(CppFiles)>> Make.cpptemp
653 >        @cat Make.cpptemp  >> $(DependencyFile)
654          $(Delete) Make.cpptemp
655 <        $(CppCompiler) $(CppParallelOptions) $(IncludePath) -MM $(CppFiles) > Make.cpptemp
656 <        cat Make.cpptemp | sed 's/^[a-zA-Z0-9]/$$\(ParallelTargetDir\)\/&/g' >> $(DependencyFile)
657 <        $(Delete) Make.cpptemp
655 >
656 >  ifeq "$(UseMPI)" "yes"
657 >        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(ParallelTargetDir)/' $(ParallelDeclare) -MM $(CppFiles)>> Make.cpptemp
658 >        @cat Make.cpptemp  >> $(DependencyFile)
659 >        @$(Delete) Make.cpptemp
660 >  endif
661 >
662   endif
663  
664   ifneq "$(words $(CFiles))" "0"
665 <        $(CCompiler) $(COptions) $(IncludePath) -MM $(CFiles) $(DerivedCFiles) > Make.ctemp
666 <        cat Make.ctemp | sed 's/^[a-zA-Z0-9]/$$\(TargetDir\)\/&/g' >> $(DependencyFile)
665 >        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(TargetDir)/'  -MM $(CFiles) $(DerivedCFiles)  >> Make.ctemp
666 >        @cat Make.ctemp  >> $(DependencyFile)
667          $(Delete) Make.ctemp
668 <        $(CCompiler) $(CParallelOptions) $(IncludePath) -MM $(CFiles) $(DerivedCFiles) > Make.ctemp
669 <        cat Make.ctemp | sed 's/^[a-zA-Z0-9]/$$\(ParallelTargetDir\)\/&/g' >> $(DependencyFile)
670 <        $(Delete) Make.ctemp
668 >
669 >  ifeq "$(UseMPI)" "yes"
670 >        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(ParallelTargetDir)/' $(ParallelDeclare) -MM $(CFiles) $(DerivedCFiles)  >> Make.ctemp
671 >        @cat Make.ctemp  >> $(DependencyFile)
672 >        @$(Delete) Make.ctemp
673 >  endif
674 >
675   endif
676  
677   ifneq "$(words $(F90Files))" "0"
678 <        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(TargetDir)/' $(F90Declare)  $(F90Files) > Make.ftemp
679 <        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(ParallelTargetDir)/' $(ParallelDeclare) $(F90Declare)  $(F90Files) >> Make.ftemp
680 <        cat Make.ftemp >> $(DependencyFile)
681 <        $(Delete) Make.ftemp
678 >        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(TargetDir)/' $(F90Declare) -MM -mc $(ModuleCase) -ms $(ModSuffix) $(F90Files) > Make.ftemp
679 >        @cat Make.ftemp >> $(DependencyFile)
680 >        @$(Delete) Make.ftemp
681 >
682 >  ifeq "$(UseMPI)" "yes"
683 >        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(ParallelTargetDir)/' $(ParallelDeclare) $(F90Declare) -MM -mc $(ModuleCase) -ms $(ModSuffix)  $(F90Files) >> Make.ftemp
684 >        @cat Make.ftemp >> $(DependencyFile)
685 >        @$(Delete) Make.ftemp
686 >  endif
687 >
688   endif
689  
690   # make lib
# Line 621 | Line 698 | jarsign : $(JarFile)
698   jarsign : $(JarFile)
699          $(JarSigner) -keystore GeoSoftKeystore $(JarFile) myself
700  
701 + #make install
702 + %.install :
703 +        @$(MAKE) $(MakeOptions) -C $(subst .install,,$@) _installall    
704 +
705 + install : $(InstallListLoop)
706 +        $(Print) Done Install
707 +
708 + _installall : _buildall _installdata
709 +
710 + $(MyInstallDir) :
711 +        $(MkDir) $@
712 +
713 + _installdata :  $(MyInstallDir)
714 +        $(Print) $(InstallFiles)
715 + ifneq "$(words $(InstallFiles))" "0"
716 +        $(InstallData) $(InstallFiles) $(MyInstallDir)
717 + endif      
718 +        
719   # make statistics
720   _statisticsall :
721          @$(Print) $(patsubst %,$(CurrentDir)/%,$(SourceFiles)) >> $(DEV_ROOT)/files.tmp

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines