# # !!NOTES!! # Include this file in local ccaffeine Makefiles only after CCAFE_HOME is set. # Not for public external consumption -- # (public should see MakeIncl.CCAFE_Component) # @SET_MAKE@ SHELL=@SHELL@ # swap to select mpi or not CCA_USEMPI=@USEMPI@ # swap to select rational purify or not CCA_USEPURE=1 CCA_USEPURE=0 # swap to select parasoft insure or not CCA_USECW=1 CCA_USEPS=0 #CCA_USEPS=1 # attempt to turn on/off threads (hah!) CCA_USE_PTHREADS=0 CCA_USE_PTHREADS=1 # isis link and pvm/cumulus want to know the architecture # ARCH=solaris # ARCH=LINUX OS_ARCH=@OS_ARCH@ #define extra objects that need to build for threads to work properly ifeq "$(OS_ARCH)" "OS_MACOSX" EXTRA_THREAD_OBJS=pth_rwlock.o endif # choose the compiler tool set you are using TOOLS=sgi TOOLS=solaris TOOLS=portland TOOLS=kai-alpha TOOLS=aix TOOLS=gnu ifeq "$(OS_ARCH)" "OS_AIX" TOOLS=aix endif ifeq "$(OS_ARCH)" "OS_IRIX5" ifeq "$(CXX)" "CC" TOOLS=sgi endif endif ifeq "$(OS_ARCH)" "OS_IRIX64" ifeq "$(CXX)" "CC" TOOLS=sgi endif endif BASE_BINDING_DIRS= BUILD_DYNALOAD=no # where are the little things include $(CCAFE_HOME)/Makefile.Vars # where is classic neo stuff, if we need it. ifeq "$(CLASSIC_CCA_INSTALLED)" "1" CCA_ROOT=@CCA_ROOT@ include @CLASSIC_CCA_CONFIG@ CLASSIC_BINDING_DIRS=classic component CCAFE_PRINTF_FLAGS="-DHAVE_PRINTFPORT=$(CLASSIC_HAVE_PRINTFPORT)" CLASSIC_LIBRARY=$(CCAFE_HOME)/dc/classic/ccafe-bind/libClsCcafe.a CLASSIC_LIBRARY_COMPONENTS=$(CCAFE_HOME)/dc/component/libcomponent$(VER_SUFFIX)$(PROGRAM_SUFFIX).a CLASSIC_LIBRARY_NAME=libClsCcafe.a CLASSIC_LIBRARY_COMPONENTS_NAME=libcomponent$(VER_SUFFIX)$(PROGRAM_SUFFIX).a CCAFE_CLASSIC_LIBS= \ $(CCAFE_HOME)/dc/babel/babel-cca/server/libccaffeine$(VER_SUFFIX)$(PROGRAM_SUFFIX).a \ $(CCAFE_HOME)/dc/babel/ccafe-bind/libBblCcafe.a CCAFE_CLASSIC_LIBNAMES= \ BUILD_DYNALOAD=yes endif # where are the big things include $(CCAFE_HOME)/../Makefile.conf.dl # how do we do dynamic loading include $(CCAFE_HOME)/../Makefile.dl # where is the neo stuff, if we need it. ifeq "$(NEO_CCA_INSTALLED)" "1" include @NEO_CCA_CONFIG@ CSNRUNTIMEFLAGS=-R$(NEOCCA_libdir) CSNLFLAGS=-L$(NEOCCA_libdir) $(NEOCCA_LIB_L) $(CSNRUNTIMEFLAGS) NEO_BINDING_DIRS=neo NEO_LIBRARY=$(CCAFE_HOME)/dc/neo/ccafe-bind/libNeoCcafe.a NEO_LIBRARY_NAME=libNeoCcafe.a BUILD_DYNALOAD=yes endif # where is the babel stuff, if we need it. ifeq "$(HAVE_BABEL)" "1" include @BABEL_CCA_CONFIG@ CSBLFLAGS=-L$(CCASPEC_libdir) $(CCASPEC_LIB_L) -L$(CCASPEC_BABEL_libdir) -lsidl BABEL_INC=-I$(CCASPEC_BABEL_includedir) BABEL_BINDING_DIRS=babel CCAFE_BABEL_LIBS= \ $(CCAFE_HOME)/dc/babel/babel-cca/server/libccaffeine$(VER_SUFFIX)$(PROGRAM_SUFFIX).a \ $(CCAFE_HOME)/dc/babel/ccafe-bind/libBblCcafe.a CCAFE_BABEL_LIBNAMES= \ libccaffeine$(VER_SUFFIX)$(PROGRAM_SUFFIX).a \ libBblCcafe.a # we want -I/where/is/cca-spec-babel-headers, unless it's in a standard place BABEL_CCA_INC=-I$(CCASPEC_BABEL_HEADERS) BABEL_CCA_LIBS=$(CCASPEC_libdir)/$(CCASPEC_SHARED_LIB) BABEL_RPATH=-Wl,-rpath,$(BABEL_ROOT)/lib -Wl,-rpath,$(CCASPEC_libdir) ifeq "$(OS_ARCH)" "OS_AIX" BABEL_RPATH= BABEL_CCA_LIBS=$(CCASPEC_libdir)/$(CCASPEC_SHARED_LIB) endif BABEL_LIB=-L$(BABEL_ROOT)/lib $(BABEL_RPATH) -lsidl ifeq "$(CCASPEC_BABEL_HEADERS)" "/usr/local/include" BABEL_CCA_INC= BABEL_LIB= endif ifeq "$(CCASPEC_BABEL_HEADERS)" "/usr/include" BABEL_CCA_INC= BABEL_LIB= endif endif OPAQUE_BINDING_DIRS= $(BASE_BINDING_DIRS) $(CLASSIC_BINDING_DIRS) $(BABEL_BINDING_DIRS) $(NEO_BINDING_DIRS) ARCH=$(MPI_ARCH) CCA_CXX_HM= $(CCA_CXX_HOME) CCA_JAVA_HM= $(CCA_JAVA_HOME) ################################################################### ################################################################### # You shouldn't have to edit below here. # anything you might need to edit probably has a --with-FOO # switch on configure; see ../configure --help. ################################################################### ################################################################### # Use $(CCA_VIS) if you need to build a file with pvm/cumulvs dependency. # make a separate target for it and include $(CCA_VIS) # in the compiler flags. # Use $(CCA_PLLFLAGS) if you need to build a file with MPI dependency. # make a separate target for it and include $(CCA_PLLFLAGS) # in the compiler flags. # Don't do anything special for linking pvm/mpi/cumulvs # (other than install them and set the right pointers # in the pvm and mpi sections below. # Don't putz with the c++ compiler unless desperate. #CXX= # save the compiler in case we need to build pieces without debugging tools. CXX_NOPS=$(CXX) # replace c++ compiler with insure if using parasoft. ifeq "$(CCA_USEPS)" "1" ifeq "$(CCA_USECW)" "1" CXX=codewizard else CXX=insure endif endif ################### bug babel stuff ###################### # this next bit works until the babel array api changes yet again ifeq "$(HAVE_BABEL)" "1" ifeq "$(CCASPEC_BABEL_VERSION)" "0.9.2" CCAFE_BABEL_BUGS= -DHAVE_BABEL=092 endif ifeq "$(CCASPEC_BABEL_VERSION)" "0.9.3" CCAFE_BABEL_BUGS= -DHAVE_BABEL=093 endif ifeq "$(CCASPEC_BABEL_VERSION)" "0.9.4" CCAFE_BABEL_BUGS= -DHAVE_BABEL=094 endif ifeq "$(CCASPEC_BABEL_VERSION)" "0.9.5" CCAFE_BABEL_BUGS= -DHAVE_BABEL=095 endif ifeq "$(CCASPEC_BABEL_VERSION)" "0.9.6" CCAFE_BABEL_BUGS= -DHAVE_BABEL=096 endif ifeq "$(CCASPEC_BABEL_VERSION)" "0.9.8" CCAFE_BABEL_BUGS= -DHAVE_BABEL=098 endif ifeq "$(CCASPEC_BABEL_VERSION)" "0.10.0" CCAFE_BABEL_BUGS= -DHAVE_BABEL=0100 endif ifeq "$(CCASPEC_BABEL_VERSION)" "0.10.2" CCAFE_BABEL_BUGS= -DHAVE_BABEL=0102 endif ifeq "$(CCASPEC_BABEL_VERSION)" "0.10.3" CCAFE_BABEL_BUGS= -DHAVE_BABEL=0103 endif endif ################### end bug babel stuff ###################### ################### xml stuff ###################### # if have xml, then dependency list entries $(XMLBUILD) # will be followed. ifeq "x$(HAVE_XML)" "x1" XMLBUILD=xmlbuild XMLFLAGS= else XMLBUILD= XMLFLAGS=-D_NO_XML endif ################### end xml stuff ###################### ################### mpicxx, even if mpi not used ############### ifeq "x$(MPICXX)" "x" MPICXX=$(CXX) MPI_LD=$(CXX) endif ifeq "x$(MPICC)" "x" MPICC=$(CC) endif ################### bug viz stuff ###################### ifeq "x$(EYES2_ROOT)" "x" # eyes2root undefined. no bug viz crap. TXT_LDFLAGS= TXT_COMPONENT= TXT_COMPONENT_INCL= else # what are the details for compiling/linking textview include $(EYES2_ROOT)/ccaComponent/MakeIncl.TextView_Component endif ################### end bug viz Stuff ###################### ################### new viz stuff ###################### #ifeq "x$(STV_ROOT)" "x" ifeq "x" "x" # stvroot undefined. no viz crap. STV_LDFLAGS= STV_ULIB= STV_COMPONENT= STV_COMPONENT_INCL= else # what are the details for compiling/linking viz-stv include $(EYES_ROOT)/ccaComponent/MakeIncl.CUMULVS_Component endif ifeq "x$(PVM_ROOT)" "x" # pvmroot undefined. stv probably in trouble if present. else PVM_ARCH := $(shell $(PVM_ROOT)/lib/pvmgetarch) CCA_PVM_LIBS = $(PVM_ROOT)/lib/$(ARCH)/libpvm3.a \ $(PVM_ROOT)/lib/$(ARCH)/libgpvm3.a endif ################### end viz Stuff ###################### ################### new esi stuff ###################### ifeq "x$(ESI_ROOT)" "x" # esiroot undefined. no adapter crap, can't use isis/petsc. else # what are the details for compiling/linking esi include $(ESI_ROOT)/ccaComponent/MakeIncl.ESI_Component # ccaffeine doesn't need esi directly, but isis/petsc do. # the 'ccaComponent' directories of both assume someone # else takes care of ESI_ROOT. ########## new snlcpp stuff ############### ifeq "x$(SNLCPP_ROOT)" "x" # snl-cpp root undefined. no snl/ca math crap. else # what are the details for compiling/linking snl include $(SNLCPP_ROOT)/MakeIncl.SNLOBJ_Component endif ########## end snlcpp Stuff ############### ########## new isis stuff ############### ifeq "x$(ISIS_ROOT)" "x" # isisroot undefined. no snl/ca math crap. else # what are the details for compiling/linking isis include $(ISIS_ROOT)/ccaComponent/MakeIncl.ISIS_Component CCAFE_ISIS_FLAGS = -D_ISIS endif ########## end isis Stuff ############### endif ################### end esi Stuff ###################### ############################## mpi ####################### ifeq "$(CCA_USEMPI)" "1" # special case for mpCC family. sigh. CCA_PLLFLAGS = @MPI_INC@ -D_CCAMPI ifeq "$(OS_ARCH)" "OS_AIX" CCA_PLLLDFLAGS = \ $(STV_LDFLAGS) $(STV_ULIB) \ $(PVM_LIBS) else CCA_PLLLDFLAGS = $(MPILIB) \ $(STV_LDFLAGS) $(STV_ULIB) \ $(PVM_LIBS) endif else CCA_PLLFLAGS = CCA_PLLLDFLAGS = $(STV_LDFLAGS) $(STV_ULIB) \ $(PVM_LIBS) CCAFE_MPI_FLAGS= $(CCA_PLLFLAGS) endif ################### end mpi configs ###################### ################### pthreads ###################### ifeq "$(CCA_USE_PTHREADS)" "1" include $(CCAFE_HOME)/../Makefile.pthreads endif ################### end pthreads ###################### ################### sockets ###################### SOCKETLIBS=@LIBS@ ################### END sockets ###################### ################### readline ###################### ifeq "$(HAVE_LIBREADLINE)" "1" ifeq "$(HAVE_READLINE_READLINE_H)" "1" READLINE_DEFS= -DHAVE_LIBREADLINE=1 -DHAVE_READLINE_READLINE_H=1 else ifeq "$(HAVE_READLINE_H)" "1" READLINE_DEFS= -DHAVE_LIBREADLINE=1 -DHAVE_READLINE_H=1 else READLINE_DEFS= -DHAVE_LIBREADLINE=1 endif endif ifeq "$(HAVE_READLINE_HISTORY)" "1" ifeq "$(HAVE_READLINE_HISTORY_H)" "1" HISTORY_DEFS= -DHAVE_READLINE_HISTORY=1 -DHAVE_READLINE_HISTORY_H=1 else ifeq "$(HAVE_HISTORY_H)" "1" HISTORY_DEFS= -DHAVE_READLINE_HISTORY=1 -DHAVE_HISTORY_H=1 else HISTORY_DEFS= -DHAVE_READLINE_HISTORY=1 endif endif else HISTORY_DEFS= endif endif READLINE_FLAGS=$(HISTORY_DEFS) $(READLINE_DEFS) ################### END readline ###################### # swap next 2 to use/ignore purified executables ifeq "$(CCA_USEPURE)" "0" PURIFY= else PCACHE=-cache-dir=/tmp/baallan-cache -always-use-cache-dir PURIFY= purify -windows=no -log-file=plog $(PCACHE) PURIFY= purify -log-file=plog PURIFY= purify $(PCACHE) endif CLASSIC_CCA_INC=$(CCA_INC) # package roots here: INCLUDES = -I$(CCAFE_HOME) $(CLASSIC_CCA_INC) \ $(BABEL_INC) $(BABEL_CCA_INC) $(NEOCCA_INC) \ $(XMLINC) \ $(STV_COMPONENT_INCL) $(TXT_COMPONENT_INCL) # CCA_LIB is defined in MakeIncl.CCA_Component # stuff we define when expecting to link various packages PACKAGE_OPTS = \ $(CCAFE_ISIS_FLAGS) \ $(CCAFE_MPI_FLAGS) \ $(CCAFE_PRINTF_FLAGS) \ $(CCAFE_BABEL_BUGS) # we want -I/where/is/boost, unless it's in a standard place BOOST_INC= @BOOST_INC@ @BOOST_FLAGS@ ifeq "$(BOOST_ROOT)" "/usr/local/include" BOOST_INC= @BOOST_FLAGS@ endif ifeq "$(BOOST_ROOT)" "/usr/include" BOOST_INC= @BOOST_FLAGS@ endif # generically supported c++ options CXXOPTS = -g $(ENV_CXXFLAGS) $(PACKAGE_OPTS) $(CXX_TEMPLATES) -D_FREEFREE -D_EATGNU CXXOPTS = -g $(PACKAGE_OPTS) $(CXX_TEMPLATES) -D$(OS_ARCH) -DCCAFE_SPEW=$(CCAFE_SPEW) $(BOOST_INC) $(NOT_HAVE_CXX_LIMITS) # gnu options (-fall-virtual is broken) GPPOPTS = -Wall -fall-virtual -Woverloaded-virtual -D_ODEBUG GPPOPTS = -Wall -Woverloaded-virtual -pedantic -ansi -W GPPOPTS = -Wall -fPIC GPPOPTS = -Wall # how to use efence hackery EFENCE=@EFENCE@ EFENCE_LIB= $(CCA_PLLLDFLAGS) $(F77LIBS) $(EFENCE) $(MPILDFLAGS) EFENCE_INC= @EFENCE_INC@ # kai c++ options KCCOPTS = -tall -migrate --exceptions # pg c++ options PGCCOPTS = # solaris options SOLOPTS= -v SOLOPTS= +w2 -features=except -features=conststrings # sgi options SGIOPTS= @EXTRA_CFLAGS@ # per ben AIXOPTS=-DPIC -DHAVE_BOOLEAN -G -qstaticinline -qrtti=all # per sameer AIXOPTS=-G -qstaticinline -qrtti=all -DHAVE_BOOLEAN AIXOPTS= -qrtti=all -DHAVE_BOOLEAN ARFLAGS= -rv # c++ flags # default value CXXFLAGS = $(CXXOPTS) $(INCLUDES) # tool specific values ifeq "$(TOOLS)" "portland" CXXFLAGS = $(CXXOPTS) $(PGCCOPTS) $(INCLUDES) endif ifeq "$(TOOLS)" "kai-alpha" CXXFLAGS = $(CXXOPTS) $(KCCOPTS) $(INCLUDES) endif ifeq "$(TOOLS)" "gnu" CXXFLAGS = $(CXXOPTS) $(GPPOPTS) $(EFENCE_INC) $(INCLUDES) endif ifeq "$(TOOLS)" "solaris" CXXFLAGS = $(CXXOPTS) $(SOLOPTS) $(INCLUDES) endif ifeq "$(TOOLS)" "sgi" CXXFLAGS = $(CXXOPTS) $(SGIOPTS) $(INCLUDES) endif # for aix, override cca-spec-classic dynamic linker # crap. ifeq "$(TOOLS)" "aix" CXXFLAGS = $(CXXOPTS) $(AIXOPTS) $(INCLUDES) CCAFE_SHLIB_LD=$(CXX) -G #per ben #CCAFE_SHLIB_LDFLAGS=-bbigtoc -qmkshrobj -bnoentry -DPIC -G -bI:/cca/baallan/src/genimports # per sameer CCAFE_SHLIB_LDFLAGS= CCAFE_AIX_EXE_LDFLAGS=-brtl -bexpall endif # last uncommented definition of CXXLDFLAGS wins CXXLDFLAGS = -g $(CCA_PLLLDFLAGS) $(CCAFE_AIX_EXE_LDFLAGS) # dependency generation scripts ifeq "$(TOOLS)" "portland" DEPEND = $(CCAFE_HOME)/util/g++depinclude_nosys -E DEPENDSYS = $(CCAFE_HOME)/util/g++depinclude -E endif ifeq "$(TOOLS)" "gnu" DEPEND = $(CCAFE_HOME)/util/g++depinclude_nosys -E DEPENDSYS = $(CCAFE_HOME)/util/g++depinclude -E endif ifeq "$(TOOLS)" "solaris" DEPEND = $(CCAFE_HOME)/util/SOLdepinclude_nosys DEPENDSYS = $(CCAFE_HOME)/util/SOLdepinclude endif ifeq "$(TOOLS)" "kai-alpha" DEPEND = $(CCAFE_HOME)/util/g++depinclude_nosys DEPENDSYS = $(CCAFE_HOME)/util/OSFdepinclude endif ifeq "$(TOOLS)" "sgi" DEPEND = $(CCAFE_HOME)/util/SGIdepinclude_nosys DEPENDSYS = $(CCAFE_HOME)/util/SGIdepinclude endif ifeq "$(TOOLS)" "aix" DEPEND = $(CCAFE_HOME)/util/xlcdepinclude_nosys DEPENDSYS = $(CCAFE_HOME)/util/xlcdepinclude endif