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

Comparing trunk/OOPSE-3.0/make/Makefile.in (file contents):
Revision 1518 by tim, Sat Oct 2 04:22:07 2004 UTC vs.
Revision 2101 by chrisfen, Thu Mar 10 15:10:24 2005 UTC

# Line 34 | Line 34 | IS_UNIX=1
34   #
35   #---------------------------------------------------------------------------
36   IS_UNIX=1
37 < #packages to be made
38 < Packages = \
37 >
38 > #packages containing libraries
39 > PackageLibs = \
40          utils \
41 +        visitors \
42          math \
43          types \
44          primitives \
43        visitors \
45          UseTheForce/DarkSide \
46          UseTheForce \
47          brains \
48          io \
49 <        integrators \
49 <        minimizers \
49 >        integrators\
50          constraints \
51 <        profiling \
51 >        minimizers \
52 >        selection \
53          restraints \
54 +
55 + #packages containing applications
56 + Applications = \
57          applications/oopse \
58          applications/dump2Xyz \
59 <        applications/simpleBuilder \
59 >        applications/simpleBuilder\
60 >        applications/staticProps \
61 >        applications/dynamicProps \
62  
63 < #packages contain libraries
64 < PackageLibs = \
65 <        utils \
66 <        math \
67 <        types \
68 <        primitives \
69 <        visitors \
70 <        UseTheForce/DarkSide \
71 <        UseTheForce \
72 <        brains \
73 <        io \
74 <        integrators \
75 <        minimizers \
70 <        constraints \
71 <        profiling \
72 <        restraints \
63 > Samples = \
64 >        samples/argon \
65 >        samples/water/dimer \
66 >        samples/water/spce \
67 >        samples/water/ssd \
68 >        samples/water/ssde \
69 >        samples/water/tip3p_ice \
70 >        samples/water/tip4p \
71 >        samples/lipid \
72 >        samples/alkane \
73 >        samples/minimizer \
74 >        samples/metals \
75 >        samples/zcons \
76  
77   IncludeDirs = \
78 <        /usr/include \
76 <        /usr/local/include
78 >        @MPI_INC_DIR@
79  
80   LibraryDirs = \
81 <        /usr/lib \
80 <        /usr/local/mpich/lib \
81 <        /usr/local/lib \
82 <        /usr/local/intel/compiler81/lib \
81 >        @MPI_LIB_DIR@
82  
83   Libraries = \
84 <        mpich \
85 <        sprng \
87 <        ifcore \
84 >        @MPI_LIB@ \
85 >        @MPI_F90_LIB@
86  
87 + OopseHome       = @OOPSE_HOME@
88 + ForceParamDir   = $(OopseHome)/share/forceFields
89 + SampleSimDir    = $(OopseHome)/share/samples
90 + InstallBinDir   = $(OopseHome)/bin
91 + DocDir          = $(OopseHome)/doc
92 + FrcDeclare      = -DFRC_PATH="$(ForceParamDir)"
93 + F90Declare      = -D__FORTRAN90
94 + ParallelDeclare = -DIS_MPI
95 + UseMPI          = @USE_MPI@
96 + ModuleCase      = @F90_MODULE_NAMES@
97 + ModSuffix       = @MOD@
98 + LinkOptions = \
99 +        @F90LIBS@
100 +
101 + ParallelLinkOptions = \
102 +        @F90LIBS@
103 +
104 +
105   #---------------------------------------------------------------------------
106   #
107   #  Directories
# Line 100 | Line 116 | CurrentDir        = $(CURDIR)
116   BinDir            = $(DEV_ROOT)/bin
117   DocsDir           = $(DEV_ROOT)/docs
118   CurrentDir        = $(CURDIR)
119 + CombinedStaticLib = $(LibDir)/libOOPSE.a
120 + CombinedParallelStaticLib = $(LibDir)/libOOPSE_MPI.a
121  
122   ifdef Source
123   #get the relative path of current package to source directory
124   # /home/maul/gezelter/src/code/src/UseTheForce/Darkside --> UseTheForce/Darkside
125   #Package          = $(shell echo $(CurrentDir) | sed -e 's/^.*\/src\/\(.*\)/\1/g')
126   #use shell script to get the absolute path and then rip it off from $(CurrentDir)
127 < Package          = $(subst $(shell cd $(SourceDir); pwd)/,,$(CurrentDir))
127 > #Package          = $(subst $(shell cd $(SourceDir); pwd)/,,$(CurrentDir))
128 > # REMINDER: We are now using the Package line in each subdir makefile.
129 > # This avoids the strange path problem and the subshell
130  
131   PackageList              = $(Package)
132   PackageSourceDir         = $(SourceDir)/$(Package)
# Line 114 | Line 134 | PackageList              = $(Packages) $(JavaPackages)
134   PackageParallelTargetDir = $(ParallelTargetDir)
135   JavaMainClass            = $(subst /,.,$(Package)).$(Main)
136   else
137 < PackageList              = $(Packages) $(JavaPackages)
137 > PackageList              = $(PackageLibs) $(JavaPackages) $(Applications)
138   endif
139  
140   PackageListLoop          = $(patsubst %,$(SourceDir)/%/.loop,$(PackageList))
# Line 165 | Line 185 | ObjectFiles            = $(CFiles:%.c=        $(Packag
185   JniHeaders             = $(JniSource:%.java=  $(PackageSourceDir)/%.h)
186   ObjectFiles            = $(CFiles:%.c=        $(PackageTargetDir)/%.o)\
187                           $(CppFiles:%.cpp=    $(PackageTargetDir)/%.o)\
188 <                                     $(FortranFiles:%.f=  $(PackageTargetDir)/%.o)\
189 <                                     $(F90Files:%.F90=    $(PackageTargetDir)/%.o)\
190 <                                     $(LexFiles:%.l=      $(PackageTargetDir)/%.o)\
191 <                                     $(YaccFiles:%.y=     $(PackageTargetDir)/%.o)
188 >                         $(FortranFiles:%.f=  $(PackageTargetDir)/%.o)\
189 >                         $(F90Files:%.F90=    $(PackageTargetDir)/%.o)\
190 >                         $(LexFiles:%.l=      $(PackageTargetDir)/%.o)\
191 >                         $(YaccFiles:%.y=     $(PackageTargetDir)/%.o)
192   ParallelObjectFiles    = $(CFiles:%.c=        $(PackageParallelTargetDir)/%.o)\
193 <                                     $(CppFiles:%.cpp=    $(PackageParallelTargetDir)/%.o)\
194 <                                     $(FortranFiles:%.f=  $(PackageParallelTargetDir)/%.o)\
195 <                                     $(F90Files:%.F90=    $(PackageParallelTargetDir)/%.o)\
196 <                                     $(LexFiles:%.l=      $(PackageParallelTargetDir)/%.o)\
197 <                                     $(YaccFiles:%.y=     $(PackageParallelTargetDir)/%.o)
193 >                         $(CppFiles:%.cpp=    $(PackageParallelTargetDir)/%.o)\
194 >                         $(FortranFiles:%.f=  $(PackageParallelTargetDir)/%.o)\
195 >                         $(F90Files:%.F90=    $(PackageParallelTargetDir)/%.o)\
196 >                         $(LexFiles:%.l=      $(PackageParallelTargetDir)/%.o)\
197 >                         $(YaccFiles:%.y=     $(PackageParallelTargetDir)/%.o)
198  
199   DerivedSource          = $(YaccFiles:%.y=    %.h) \
200 <                               $(YaccFiles:%.y=    %.c) \
201 <                               $(LexFiles:%.l=     %.c)
200 >                         $(YaccFiles:%.y=    %.c) \
201 >                         $(LexFiles:%.l=     %.c)
202  
203   DerivedCFiles          = $(YaccFiles:%.y=    %.c) \
204 <                               $(LexFiles:%.l=     %.c)
204 >                         $(LexFiles:%.l=     %.c)
205  
206   OtherTargetFiles       = $(OtherSourceFiles:%=$(PackageTargetDir)/%)
207  
# Line 200 | Line 220 | ifneq  "$(words $(ObjectFiles) $(ParallelObjectFiles))
220      Executable             = $(BinDir)/$(Main)
221      ParallelExecutable     = $(BinDir)/$(Main)_MPI
222    else
223 <    SharedLibrary          = $(LibDir)/lib$(subst /,,$(patsubst %,oopse_%,$(Package))).so
224 <    StaticLibrary          = $(LibDir)/lib$(subst /,,$(patsubst %,oopse_%,$(Package))).a
223 >    SharedLibrary          = $(LibDir)/lib$(subst /,,$(patsubst %,oopse_%,$(Package)))_UP.so
224 >    StaticLibrary          = $(LibDir)/lib$(subst /,,$(patsubst %,oopse_%,$(Package)))_UP.a
225      ParallelSharedLibrary  = $(LibDir)/lib$(subst /,,$(patsubst %,oopse_%,$(Package)))_MPI.so
226      ParallelStaticLibrary  = $(LibDir)/lib$(subst /,,$(patsubst %,oopse_%,$(Package)))_MPI.a
227    endif
228   endif
229 +
230   #
231   # Misc
232   #
# Line 213 | Line 234 | LocalLibs        = $(subst /,,$(patsubst %, oopse_%, $
234   JavaPackageNames = $(subst /,.,$(JavaPackages))
235   IncludePath      = -I$(SourceDir) $(IncludeDirs:%=-I%)
236   LibDirs          = -L$(LibDir)    $(LibraryDirs:%=-L%)
237 < LocalLibs        = $(subst /,,$(patsubst %, oopse_%, $(PackageLibs)))
238 < LibList          = $(LocalLibs:%=-l%) $(Libraries:%=-l%)
237 > LocalLibs        = $(subst /,,$(patsubst %, oopse_%_UP, $(PackageLibs)))
238 > ParallelLocalLibs= $(subst /,,$(patsubst %, oopse_%_MPI, $(PackageLibs)))
239 > LibList          = $(LocalLibs:%=-l%) $(Libraries)
240 > LibNames         = $(LocalLibs:%=$(LibDir)/lib%.a)
241 > ParallelLibList  = $(ParallelLocalLibs:%=-l%) $(Libraries)
242 > ParallelLibNames = $(ParallelLocalLibs:%=$(LibDir)/lib%.a)
243  
244  
245   #---------------------------------------------------------------------------
# Line 223 | Line 248 | Move                   = mv
248   #
249   #---------------------------------------------------------------------------
250   Print                  = @echo
251 < Move                   = mv
251 > Move                   = mv -f
252   Copy                   = cp
253   CCompiler              = @CC@
254   CppCompiler            = @CXX@
255   Linker                 = @CXX@
256   MakeDepend             = makedepend
257 < Install                = @INSTALL@
257 > INSTALL                = @INSTALL@
258   InstallProgram         = @INSTALL_PROGRAM@
259   InstallData            = @INSTALL_DATA@
260 < MakeDir                = @MKINSTALLDIRS@
260 > MkDir                  = @MKINSTALLDIRS@
261   Delete                 = rm -fr
262   StaticArchiver         = @AR@
263   DynamicArchiver        = @CC@
# Line 250 | Line 275 | Lex                    = @LEX@
275   List                   = cat
276   Yacc                   = @YACC@
277   Lex                    = @LEX@
278 + Ranlib                 = @RANLIB@
279 + Doxygen                = @DOXYGEN@
280  
254
281   MakeOptions            = -k
282   MakeDependOptions      =
283   StaticArchiverOptions  = rc
# Line 260 | Line 286 | FortranOptions         =
286   JniOptions             =
287   RmiOptions             = -d $(TargetDir) -classpath $(ClassPath) \
288                           -sourcepath $(SourceDir)
289 + COptions               = $(FrcDeclare) @CFLAGS@
290 + CParallelOptions       = $(FrcDeclare) $(ParallelDeclare) @CFLAGS@
291 + CppOptions             = $(FrcDeclare) @CXXFLAGS@ @OOPSE_TEMPLATE_FLAGS@
292 + CppParallelOptions     = $(FrcDeclare) $(ParallelDeclare) @CXXFLAGS@ @OOPSE_TEMPLATE_FLAGS@
293   FortranOptions         =
294 < F90Options             =  -I$(SourceDir) -module $(TargetDir)
294 > F90Options             =  @PREPFLAG@ @F90FLAGS@ @MODDIRFLAG@$(SourceDir) @MODDIRFLAG@$(TargetDir)
295 > F90ParallelOptions     =  @PREPFLAG@ @F90FLAGS@ @MODDIRFLAG@$(SourceDir) @MODDIRFLAG@$(ParallelTargetDir)  @PREPDEFFLAG@$(ParallelDeclare)
296   JavaCompilerOptions    = -d $(TargetDir) -classpath $(ClassPath) \
297                           -sourcepath $(SourceDir) -deprecation
298   JavaRunOptions         = -classpath $(ClassPath)
# Line 287 | Line 318 | Space                  = $(Empty) $(Empty)
318  
319   #---------------------------------------------------------------------------
320   #
321 + #  Install
322 + #
323 + #---------------------------------------------------------------------------
324 +
325 + ifneq "$(words $(SampleFiles))" "0"
326 +  MySample                 = $(subst $(shell cd $(DEV_ROOT)/samples; pwd)/,,$(CurrentDir))
327 +  MyInstallDir             = $(SampleSimDir)/$(MySample)
328 +  InstallFiles             = $(SampleFiles)
329 +  InstallCommand           = $(InstallData)
330 + endif
331 +
332 + ifneq "$(words $(Main))" "0"
333 +  MyInstallDir             = $(InstallBinDir)
334 +  ifeq "$(UseMPI)" "yes"
335 +    InstallFiles             = $(Executable) $(ParallelExecutable)
336 +  else
337 +    InstallFiles             = $(Executable)
338 +  endif
339 +  InstallCommand           = $(InstallProgram)
340 + endif
341 +
342 + ifneq "$(words $(ForcefieldFiles))" "0"
343 +  MyInstallDir             = $(ForceParamDir)
344 +  InstallFiles             = $(ForcefieldFiles)
345 +  InstallCommand           = $(InstallData)
346 + endif
347 +
348 + ifneq "$(words $(InstallFiles))" "0"
349 +  InstallList            =
350 + else
351 +  InstallList            = $(patsubst %,$(DEV_ROOT)/%,$(Samples)) $(DEV_ROOT)/forceFields $(patsubst %, $(SourceDir)/%,$(Applications))
352 + endif
353 +
354 + InstallListLoop          = $(patsubst %,$(SourceDir)/%/.install,$(PackageList))  $(patsubst %,%/.install,$(InstallList))
355 +
356 +
357 +
358 + #---------------------------------------------------------------------------
359 + #
360   # Rules
361   #
362   #---------------------------------------------------------------------------
# Line 297 | Line 367 | $(PackageTargetDir) :
367  
368   # Create target directory
369   $(PackageTargetDir) :
370 <        $(MakeDir) $@
370 >        $(MkDir) $@
371  
372 + $(BinDir) :
373 +        $(MkDir) $@
374 +
375   # .c -> .o
376   $(PackageTargetDir)/%.o : %.c
377          $(Print) $@
378          $(CCompiler) $(COptions) -c $(IncludePath) $< -o $@
379  
380 + $(PackageParallelTargetDir)/%.o : %.c
381 +        $(Print) $@
382 +        $(CCompiler) $(CParallelOptions) -c $(IncludePath) $< -o $@
383 +
384 + ifeq "$(UseMPI)" "yes"
385   %.o : %.c
386          $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@
387 +        $(MAKE) $(MakeOptions) $(PackageParallelTargetDir)/$@
388 + else
389 + %.o : %.c
390 +        $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@
391 + endif
392  
393   # .cpp -> .o
394   $(PackageTargetDir)/%.o : %.cpp
395          $(CppCompiler) $(CppOptions) -c $(IncludePath) $< -o $@
396  
397 + $(PackageParallelTargetDir)/%.o : %.cpp
398 +        $(CppCompiler) $(CppParallelOptions) -c $(IncludePath) $< -o $@
399 +
400 + ifeq "$(UseMPI)" "yes"
401   %.o : %.cpp
402          $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@
403 +        $(MAKE) $(MakeOptions) $(PackageParallelTargetDir)/$@
404 + else
405 + %.o : %.cpp
406 +        $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@
407 + endif
408  
409   # .f -> .o
410   $(PackageTargetDir)/%.o : %.f
411          $(FortranCompiler) $(FortranOptions) -c $< -o $@
412  
413 + $(PackageParallelTargetDir)/%.o : %.f
414 +        $(FortranCompiler) $(FortranParallelOptions) -c $< -o $@
415 +
416 + ifeq "$(UseMPI)" "yes"
417   %.o : %.f
418          $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@
419 +        $(MAKE) $(MakeOptions) $(PackageParallelTargetDir)/$@
420 + else
421 + %.o : %.f
422 +        $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@
423 + endif
424  
425   # .F90 -> .o
426   $(PackageTargetDir)/%.o : %.F90
427 <        $(F90Compiler) $(F90Options) -c $< -o $@
427 >        $(F90Compiler) $(F90Options) $(IncludePath) -c $< -o $@
428 >        if test -n "`ls *.$(ModSuffix)`"; then \
429 >          $(Move) `ls *.$(ModSuffix)` $(PackageTargetDir);\
430 >        fi
431  
432 + $(PackageParallelTargetDir)/%.o : %.F90
433 +        $(F90Compiler) $(F90ParallelOptions) $(IncludePath) -c $< -o $@
434 +        if test -n "`ls *.$(ModSuffix)`"; then \
435 +          $(Move) "`ls *.$(ModSuffix)`" $(PackageParallelTargetDir);\
436 +        fi
437 +
438 + ifeq "$(UseMPI)" "yes"
439   %.o : %.F90
440          $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@
441 +        if test -n "`ls *.$(ModSuffix)`"; then\
442 +          $(Move) "`ls *.$(ModSuffix)`" $(PackageTargetDir);\
443 +        fi
444  
445 +        $(MAKE) $(MakeOptions) $(PackageParallelTargetDir)/$@
446 +        if test -n "`ls *.$(ModSuffix)`"; then\
447 +          $(Move) "`ls *.$(ModSuffix)`" $(PackageTargetDir);\
448 +        fi
449 +
450 + else
451 + %.o : %.F90
452 +        $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@
453 +        if test -n "`ls *.$(ModSuffix)`"; then\
454 +          $(Move) "`ls *.$(ModSuffix)`" $(PackageTargetDir);\
455 +        fi
456 + endif
457 +
458 +
459   # .java -> .class
460   $(PackageTargetDir)/%.class : $(PackageSourceDir)/%.java
461          $(JavaCompiler) $(JavaCompilerOptions) $<
# Line 361 | Line 489 | $(LibDir)/%.a : $(ObjectFiles)
489          @$(Lex) -o$@ $?
490  
491   # .o -> .a
492 < $(LibDir)/%.a : $(ObjectFiles)
492 >
493 > $(LibDir)/%_UP.a : $(ObjectFiles)
494          $(StaticArchiver) $(StaticArchiverOptions) $@ $(ObjectFiles)
495 +        @touch $(LibDir)/.stamp_UP
496  
497 < %.a : $(ObjectFiles)
368 <        $(MAKE) $(MakeOptions) $(LibDir)/$@
369 <
370 < $(LibDir)/%_MPI.a : $(ParallelObjectFiles)
497 > $(LibDir)/%_MPI.a: $(ParallelObjectFiles)
498          $(StaticArchiver) $(StaticArchiverOptions) $@ $(ParallelObjectFiles)
499 +        @touch $(LibDir)/.stamp_MPI
500  
501 + %_UP.a : $(ObjectFiles)
502 +        $(MAKE) $(MakeOptions) $(LibDir)/$@
503 +
504   %_MPI.a : $(ParallelObjectFiles)
505          $(MAKE) $(MakeOptions) $(LibDir)/$@
506  
507   # .o -> .so
508 < $(LibDir)/%.so : $(ObjectFiles)
508 > $(LibDir)/%_UP.so : $(ObjectFiles)
509          $(DynamicArchiver) $(ObjectFiles) $(DynamicArchiverOptions) -o $@
510  
380 %.so : $(ObjectFiles)
381        $(MAKE) $(MakeOptions) $(LibDir)/$@
382
511   $(LibDir)/%_MPI.so : $(ParallelObjectFiles)
512          $(DynamicArchiver) $(ParallelObjectFiles) $(DynamicArchiverOptions) -o $@
513  
514 + %_UP.so : $(ObjectFiles)
515 +        $(MAKE) $(MakeOptions) $(LibDir)/$@
516 +
517   %_MPI.so : $(ParallelObjectFiles)
518          $(MAKE) $(MakeOptions) $(LibDir)/$@
519  
# Line 418 | Line 549 | $(PackageTargetDir)/%_Skel.class : $(PackageTargetDir)
549   %_Skel.class : %.class
550          $(MAKE) $(MakeOptions) $(PackageTargetDir)/$@
551  
552 + document :
553 +        $(Print) Generate Documentation for OOPSE-2.0
554 +        @cd $(DEV_ROOT)/src    
555 +        $(Doxygen) $(DEV_ROOT)/make/Doxyfile
556 +
557 + #GUN make funtions to merge the libraries
558 + find_objs = $(shell $(StaticArchiver) -t $(1))
559 + extract_objs = $(shell $(StaticArchiver) -x $(1) $(call find_objs, $(1)))
560 + create_archive = $(shell  $(StaticArchiver) $(StaticArchiverOptions) $(2) $(call find_objs, $(1)))
561 + remove_objs = $(shell $(Delete) $(call find_objs, $(1)))
562 + do_create = $(call extract_objs,$(1))$(call create_archive,$(1),$(2))$(call remove_objs,$(1))  
563 +
564 + $(CombinedStaticLib) : $(LibDir)/.stamp_UP
565 +        $(Print) create $@      
566 +        $(foreach thisLib,$(LibNames),$(call do_create,$(thisLib),$@))
567 +        $(Ranlib) $(CombinedStaticLib)
568 +
569 + $(CombinedParallelStaticLib) : $(LibDir)/.stamp_MPI
570 +        $(Print) create $@
571 +        $(foreach thisLib,$(ParallelLibNames), $(call do_create, $(thisLib), $@))
572 +        $(Ranlib) $(CombinedParallelStaticLib)
573 +
574   # Executable
575 < $(Executable) : $(ObjectFiles)
576 <        $(Linker) $(LinkOptions) $(LibDirs) $(LibList) $(ObjectFiles) -o $@
575 > $(Executable) : $(CombinedStaticLib) $(ObjectFiles) $(BinDir)
576 >        $(Linker) $(ObjectFiles) $(CombinedStaticLib) $(LinkOptions) $(LibDirs) $(Libraries) -o $@
577  
578 < $(ParallelExecutable) : $(ParallelObjectFiles)
579 <        $(Linker) $(LinkOptions) $(LibDirs) $(LibList) $(ParallelObjectFiles) -o $@
578 > $(ParallelExecutable) : $(CombinedParallelStaticLib) $(ParallelObjectFiles) $(BinDir)
579 >        $(Linker) $(ParallelObjectFiles) $(CombinedParallelStaticLib) $(ParallelLinkOptions) $(LibDirs) $(Libraries) -o $@
580  
581   # Anything else is just copied from source to target
582   $(PackageTargetDir)/% : $(PackageSourceDir)/%
# Line 436 | Line 589 | _buildall : \
589  
590   _all : _buildall
591  
592 + _buildall :
593 + ifeq "$(UseMPI)" "yes"
594   _buildall : \
595          $(DependencyFile) \
596          $(PackageTargetDir) \
597          $(ObjectFiles) \
598 +        $(ParallelObjectFiles) \
599          $(JavaClassFiles) \
600          $(RmiStubFiles) \
601          $(RmiSkeletonFiles) \
602          $(OtherTargetFiles) \
447        $(SharedLibrary) \
603          $(StaticLibrary) \
604 +        $(ParallelStaticLibrary) \
605          $(JarFile) \
606 <        $(Executable)
607 <        
606 >        $(Executable) \
607 >        $(ParallelExecutable)
608 > else
609 > _buildall : \
610 >        $(DependencyFile) \
611 >        $(PackageTargetDir) \
612 >        $(ObjectFiles) \
613 >        $(JavaClassFiles) \
614 >        $(RmiStubFiles) \
615 >        $(RmiSkeletonFiles) \
616 >        $(OtherTargetFiles) \
617 >        $(StaticLibrary) \
618 >        $(JarFile) \
619 >        $(Executable)
620 > endif
621  
622 +
623   # make clean
624   clean : $(PackageListLoop)
625          $(Print) Done clean.    
626  
627   _cleanall :
628 <        $(Delete) $(ObjectFiles) $(ParallelObjectFiles)
628 >        $(Delete) \
629 >                $(ObjectFiles) \
630 >                $(ParallelObjectFiles) \
631 >                $(JarFile) \
632 >                $(SharedLibrary) \
633 >                $(StaticLibrary) \
634 >                $(ParallelSharedLibrary) \
635 >                $(ParallelStaticLibrary) \
636 >                $(CombinedStaticLib) \
637 >                $(CombinedParallelStaticLib)
638  
639   # make distclean
640   distclean : $(PackageListLoop)
641          $(Print) Done clean.    
642  
643 < _distcleanall :
644 <        $(Delete) $(ObjectFiles) \
466 <                  $(ParallelObjectFiles) \
467 <                  $(JarFile) \
468 <                  $(SharedLibrary) \
469 <                  $(StaticLibrary) \
470 <                  $(ParallelSharedLibrary) \
471 <                  $(ParallelStaticLibrary) \
472 <                  $(Executable) \
643 > _distcleanall : _cleanall
644 >        $(Delete) $(Executable) \
645                    $(ParallelExecutable) \
646 <                  $(DependencyFile)
646 >                  $(DependencyFile)
647  
476
648   # make depend
649   depend : $(PackageListLoop)
650          $(Print) Done dependencies.
# Line 484 | Line 655 | $(DependencyFile) : $(DerivedSource)
655          $(Print) $@
656          @cd $(PackageSourceDir)
657  
487        touch Make.ctemp
488        touch Make.ctemp
489
658   ifneq "$(words $(CppFiles))" "0"
659 <        $(CppCompiler) $(IncludePath) -MM $(CppFiles)  > Make.cpptemp
660 <        cat Make.cpptemp | sed 's/^[a-zA-Z0-9]/$$\(DEV_ROOT\)\/obj\/&/g' >> $(DependencyFile)
661 <        cat Make.cpptemp | sed 's/^[a-zA-Z0-9]/$$\(DEV_ROOT\)\/MPIobj\/&/g' >> $(DependencyFile)
659 >        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(TargetDir)/' -MM $(CppFiles)>> Make.cpptemp
660 >        @cat Make.cpptemp  >> $(DependencyFile)
661 >        $(Delete) Make.cpptemp
662 >
663 >  ifeq "$(UseMPI)" "yes"
664 >        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(ParallelTargetDir)/' $(ParallelDeclare) -MM $(CppFiles)>> Make.cpptemp
665 >        @cat Make.cpptemp  >> $(DependencyFile)
666 >        @$(Delete) Make.cpptemp
667 >  endif
668 >
669   endif
670  
671   ifneq "$(words $(CFiles))" "0"
672 <        $(CCompiler)   $(IncludePath) -MM $(CFiles) $(DerivedCFiles)   > Make.ctemp
673 <        cat Make.ctemp | sed 's/^[a-zA-Z0-9]/$$\(DEV_ROOT\)\/obj\/&/g' >> $(DependencyFile)
674 <        cat Make.ctemp | sed 's/^[a-zA-Z0-9]/$$\(DEV_ROOT\)\/MPIobj\/&/g' >> $(DependencyFile)
672 >        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(TargetDir)/'  -MM $(CFiles) $(DerivedCFiles)  >> Make.ctemp
673 >        @cat Make.ctemp  >> $(DependencyFile)
674 >        $(Delete) Make.ctemp
675  
676 +  ifeq "$(UseMPI)" "yes"
677 +        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(ParallelTargetDir)/' $(ParallelDeclare) -MM $(CFiles) $(DerivedCFiles)  >> Make.ctemp
678 +        @cat Make.ctemp  >> $(DependencyFile)
679 +        @$(Delete) Make.ctemp
680 +  endif
681 +
682   endif
683  
684   ifneq "$(words $(F90Files))" "0"
685 <        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(DEV_ROOT)/obj/' -D__F90  *.F90 > Make.ftemp
686 <        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(DEV_ROOT)/MPIobj/' -DIS_MPI -D__F90  *.F90 >> Make.ftemp
687 <        cat Make.ftemp >> $(DependencyFile)
685 >        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(TargetDir)/' $(F90Declare) -MM -mc $(ModuleCase) -ms $(ModSuffix) $(F90Files) > Make.ftemp
686 >        @cat Make.ftemp >> $(DependencyFile)
687 >        @$(Delete) Make.ftemp
688 >
689 >  ifeq "$(UseMPI)" "yes"
690 >        $(DEV_ROOT)/scripts/filepp  -I $(DEV_ROOT)/src -od '$$(ParallelTargetDir)/' $(ParallelDeclare) $(F90Declare) -MM -mc $(ModuleCase) -ms $(ModSuffix)  $(F90Files) >> Make.ftemp
691 >        @cat Make.ftemp >> $(DependencyFile)
692 >        @$(Delete) Make.ftemp
693 >  endif
694 >
695   endif
508        $(Delete) Make.cpptemp Make.ctemp Make.ftemp
696  
697   # make lib
698   lib    : $(PackageListLoop)
# Line 518 | Line 705 | jarsign : $(JarFile)
705   jarsign : $(JarFile)
706          $(JarSigner) -keystore GeoSoftKeystore $(JarFile) myself
707  
708 + #make install
709 + %.install :
710 +        @$(MAKE) $(MakeOptions) -C $(subst .install,,$@) _installall    
711 +
712 + install : $(InstallListLoop)
713 +        $(Print) Done Install
714 +
715 + _installall : _buildall _installdata
716 +
717 + $(MyInstallDir) :
718 +        $(MkDir) $@
719 +
720 + _installdata :  $(MyInstallDir)
721 +        $(Print) $(InstallFiles)
722 + ifneq "$(words $(InstallFiles))" "0"
723 +        $(InstallData) $(InstallFiles) $(MyInstallDir)
724 + endif      
725 +
726   # make statistics
727   _statisticsall :
728 <        @$(Print) $(SourceFiles) >> $(DEV_ROOT)/files.tmp
728 >        @$(Print) $(patsubst %,$(CurrentDir)/%,$(SourceFiles)) >> $(DEV_ROOT)/files.tmp
729  
730   statistics : $(PackageListLoop)
731          @$(List) $(DEV_ROOT)/files.tmp | xargs $(WordCount) $(WordCountOptions)
# Line 534 | Line 739 | pure : $(Executable).pure
739  
740   pure : $(Executable).pure
741  
742 + #make cvslog
743 + cvslog:
744 +        $(DEV_ROOT)/scripts/cvs2cl.pl
745 +
746   # Execute
747   _runexe :
748          $(Executable) $(RunParameters)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines