Ignore:
Timestamp:
09/10/11 09:10:51 (14 years ago)
Author:
Eric.Larour
Message:

Separated Dakota compilation from the rest

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk/src/ad/Makefile.am

    r9727 r9757  
    66#Compilation can still be blocked if user has not activated --with-adic compilation
    77
     8#Library declaration {{{1
     9
    810if NOPARALLEL
    911lib_LIBRARIES =
    1012else
     13lib_LIBRARIES = libpISSM.a   libOverload.a
     14endif
     15
    1116if AD
    12 lib_LIBRARIES = libpISSM.a  libAD.a libOverload.a
    13 else
    14 lib_LIBRARIES =
    15 endif
    16 endif
    17 
    18 #Overload library, to overload any non-standard symbols.
     17lib_LIBRARIES += libAD.a
     18endif
     19
     20if DAKOTA
     21lib_LIBRARIES += libDAKOTA.a
     22endif
     23
     24#}}}
     25#Overload library, to overload any non-standard symbols. {{{1
    1926libOverload_a_SOURCES = ./shared/String/stricmp.c
    2027libOverload_a_CFLAGS = -fPIC -D_PARALLEL_   -D_C_ $(COPTFLAGS)
    21 
    22 #AD library, for automatic differentiation
    23 if AD
    24 #libAD_a_SOURCES = ./mini1.ad.c
    25 libAD_a_SOURCES =
    26 else
    27 libAD_a_SOURCES =
    28 endif
    29 libAD_a_CFLAGS = -fPIC -D_PARALLEL_   -D_C_ $(COPTFLAGS)
    30 
     28#}}}
    3129#ISSM library  {{{1
    3230libpISSM_a_SOURCES = ./include/macros.h\
    3331                                        ./include/typedefs.h\
    3432                                        ./include/types.h\
    35                                         ./include/globals.h\
    3633                                        ./include/include.h\
    3734                                        ./objects/objects.h\
     
    202199                                        ./shared/Alloc/alloc.h\
    203200                                        ./shared/Alloc/alloc.cpp\
    204                                         ./shared/Matlab/matlabshared.h\
    205                                         ./shared/Matlab/PrintfFunction.cpp\
    206                                         ./shared/Matlab/ModuleBoot.cpp\
    207                                         ./shared/Matlab/mxGetAssignedField.cpp\
    208                                         ./shared/Matlab/mxGetField.cpp\
    209                                         ./shared/Matlab/CheckNumMatlabArguments.cpp\
    210201                                        ./shared/Matrix/matrix.h\
    211202                                        ./shared/Matrix/MatrixUtils.cpp\
     
    238229                                        ./shared/Elements/GetGlobalDofList.cpp\
    239230                                        ./shared/Elements/GetNumberOfDofs.cpp\
    240                                         ./shared/String/DescriptorIndex.cpp\
    241231                                        ./shared/String/sharedstring.h\
    242232                                        ./toolkits/petsc\
     
    283273                                        ./io/Disk/pfopen.cpp\
    284274                                        ./io/Disk/pfclose.cpp\
    285                                         ./io/Matlab/matlabio.h\
    286                                         ./io/Matlab/WriteMatlabData.cpp\
    287                                         ./io/Matlab/FetchMatlabData.cpp\
    288                                         ./io/Matlab/OptionParse.cpp\
     275                                        ./io/PrintfFunction.cpp\
    289276                                        ./EnumDefinitions/EnumDefinitions.h\
    290277                                        ./EnumDefinitions/EnumToModelField.cpp\
     
    455442                                        ./modules/HoleFillerx/HoleFillerx.cpp\
    456443                                        ./modules/HoleFillerx/HoleFillerx.h\
    457                                         ./modules/AverageFilterx/AverageFilterx.cpp\
    458                                         ./modules/AverageFilterx/AverageFilterx.h\
    459                                         ./modules/AverageOntoPartitionx/AverageOntoPartitionx.cpp\
    460                                         ./modules/AverageOntoPartitionx/AverageOntoPartitionx.h\
    461444                                        ./modules/MeshPartitionx/MeshPartitionx.cpp\
    462445                                        ./modules/MeshPartitionx/MeshPartitionx.h\
     
    561544                                        ./solvers/solver_thermal_nonlinear.cpp
    562545
     546
     547libpISSM_a_CXXFLAGS = -fPIC -D_PARALLEL_   -D_C_ $(CXXOPTFLAGS)
    563548#}}}
    564 
    565 libpISSM_a_CXXFLAGS = -fPIC -D_PARALLEL_   -D_C_ $(CXXOPTFLAGS)
     549#AD library, for automatic differentiation {{{1
     550if AD
     551#libAD_a_SOURCES = ./mini1.ad.c
     552libAD_a_SOURCES =
     553libAD_a_CFLAGS = -fPIC -D_PARALLEL_   -D_C_ $(COPTFLAGS)
     554
     555
     556#Automatic differentiation rules:
     557%.ad.c: %.c
     558        adic2 -mforward  $< --nary
     559endif
     560#}}}
     561#DAKOTA library  {{{1
     562
     563if DAKOTA
     564libDAKOTA_a_SOURCES = ./objects/DakotaPlugin.h\
     565                                          ./objects/DakotaPlugin.cpp\
     566                                          ./modules/InputUpdateFromDakotax/InputUpdateFromDakotax.h\
     567                                          ./modules/InputUpdateFromDakotax/InputUpdateFromDakotax.cpp\
     568                                          ./modules/DakotaResponsesx/DakotaResponsesx.h\
     569                                          ./modules/DakotaResponsesx/DakotaResponsesx.cpp\
     570                                          ./modules/InputUpdateFromVectorDakotax/InputUpdateFromVectorDakotax.h\
     571                                          ./modules/InputUpdateFromVectorDakotax/InputUpdateFromVectorDakotax.cpp\
     572                                          ./modules/AverageOntoPartitionx/AverageOntoPartitionx.cpp\
     573                                          ./modules/AverageOntoPartitionx/AverageOntoPartitionx.h\
     574                                          ./modules/Dakotax/Dakotax.h\
     575                                          ./modules/Dakotax/Dakotax.cpp\
     576                                          ./modules/Dakotax/DakotaMPI_Bcast.cpp\
     577                                          ./modules/Dakotax/DakotaFree.cpp\
     578                                          ./modules/Dakotax/SpawnCore.cpp\
     579                                          ./modules/Dakotax/SpawnCoreParallel.cpp\
     580                                          ./modules/Dakotax/DescriptorIndex.cpp\
     581                                          ./modules/AverageOntoPartitionx/AverageOntoPartitionx.cpp\
     582                                          ./modules/AverageOntoPartitionx/AverageOntoPartitionx.h
     583
     584
     585libDAKOTA_a_CXXFLAGS = -fPIC -D_PARALLEL_   -D_C_ $(CXXOPTFLAGS)
     586endif
     587
     588#}}}
     589#Executable {{{1
    566590
    567591if NOPARALLEL
     
    571595endif
    572596
    573 LDADD =    ./libpISSM.a $(PETSCLIB) $(TAOLIB) $(FLIBS) $(PLAPACKLIB)  $(MUMPSLIB) $(SCALAPACKLIB)  $(BLACSLIB) $(HYPRELIB) $(MLLIB) $(DAKOTALIB) $(METISLIB) $(CHACOLIB) $(SCOTCHLIB) $(BLASLAPACKLIB)  $(MKLLIB) $(MPILIB) $(MATHLIB) $(FORTRANLIB) $(GRAPHICSLIB) libOverload.a $(MULTITHREADINGLIB) $(ADICLIB) libAD.a
     597#Standard library
     598LDADD =    ./libpISSM.a  ./libOverload.a
     599
     600if AD
     601LDADD +=    ./libAD.a
     602endif
     603
     604if DAKOTA
     605LDADD +=    ./libDAKOTA.a
     606endif
     607
     608#External packages
     609LDADD += $(PETSCLIB) $(TAOLIB) $(FLIBS) $(PLAPACKLIB)  $(MUMPSLIB) $(SCALAPACKLIB)  $(BLACSLIB) $(HYPRELIB) $(MLLIB) $(DAKOTALIB) $(METISLIB) $(CHACOLIB) $(SCOTCHLIB) $(BLASLAPACKLIB)  $(MKLLIB) $(MPILIB) $(MATHLIB) $(FORTRANLIB) $(GRAPHICSLIB) $(MULTITHREADINGLIB) $(ADICLIB)
     610
    574611
    575612issm_exe_SOURCES = solutions/issm.cpp
    576613issm_exe_CXXFLAGS= -fPIC -D_PARALLEL_  $(CXXOPTFLAGS) $(COPTFLAGS)
    577614
    578 #Automatic differentiation rules:
    579 %.ad.c: %.c
    580         adic2 -mforward  $< --nary
     615#}}}
Note: See TracChangeset for help on using the changeset viewer.