Added PURIFY option to makefiles

This commit is contained in:
Harry Moffat 2008-12-30 21:49:41 +00:00
parent 2bfc553cfb
commit b2cf384cea
32 changed files with 135 additions and 74 deletions

View file

@ -15,6 +15,8 @@
INSTALL_TSC = ../../../bin/install_tsc
do_ranlib = @DO_RANLIB@
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
CXX_FLAGS = @CXXFLAGS@ $(CXX_OPT) $(PIC_FLAG)
@ -57,7 +59,7 @@ LCXX_FLAGS = -L$(CANTERA_LIBDIR) @CXXFLAGS@
# how to compile C++ source files to object files
.@CXX_EXT@.@OBJ_EXT@:
$(CXX) -c $< $(CXX_INCLUDES) $(CXX_FLAGS)
$(PURIFY) $(CXX) -c $< $(CXX_INCLUDES) $(CXX_FLAGS)
%.d: Makefile %.o
@CXX_DEPENDS@ $(CXX_FLAGS) $(CXX_INCLUDES) $*.cpp > $*.d
@ -75,7 +77,7 @@ all: $(CTLIB) .depends
$(CTLIB): $(OBJS) $(LIB_DEPS)
$(RM) $(CTLIB)
ifeq ($(shared_ctlib),1)
$(CXX) -o $(CTLIB) $(OBJS) $(LCXX_FLAGS)\
$(PURIFY) $(CXX) -o $(CTLIB) $(OBJS) $(LCXX_FLAGS)\
@SHARED@ $(LINK_OPTIONS) \
$(EXT_LIBS) @LIBS@ $(FORT_LIBS)
else

View file

@ -26,6 +26,9 @@ srcdirtree=1
# Fortran libraries
FORT_LIBS = @FLIBS@
# Purify options
PURIFY=@PURIFY@
# the C++ compiler
CXX = @CXX@
@ -59,7 +62,7 @@ LCXX_FLAGS = -L$(CANTERA_LIBDIR) @LOCAL_LIB_DIRS@ @CXXFLAGS@
# how to compile C++ source files to object files
.@CXX_EXT@.@OBJ_EXT@:
$(CXX) -c $< -I$(CANTERA_INCDIR) $(CXX_FLAGS) $(LOCAL_DEFNS)
$(PURIFY) $(CXX) -c $< -I$(CANTERA_INCDIR) $(CXX_FLAGS) $(LOCAL_DEFNS)
# how to create a dependency file
.@CXX_EXT@.d:
@ -72,7 +75,7 @@ DEPENDS = $(OBJS:.o=.d)
all: $(PROGRAM)
$(PROGRAM): $(OBJS)
$(CXX) -o $(PROGRAM) $(OBJS) $(LCXX_FLAGS) $(CANTERA_LIBS) \
$(PURIFY) $(CXX) -o $(PROGRAM) $(OBJS) $(LCXX_FLAGS) $(CANTERA_LIBS) \
$(LINK_OPTIONS) $(EXT_LIBS) @LIBS@ $(FORT_LIBS) \
$(LCXX_END_LIBS)

View file

@ -95,7 +95,7 @@ endif
CANTERA_build_lapack= @build_lapack@
CANTERA_build_blas= @build_blas@
CANTERA_BLAS_LAPACK_DIR= @BLAS_LAPACK_DIR@
CANTERA_BLAS_LAPACK_DIR= @ct_libdir@
CANTERA_BLAS_LAPACK_LIBS = -L$(CANTERA_BLAS_LAPACK_DIR) @BLAS_LAPACK_LIBS@
@ -121,11 +121,11 @@ CANTERA_TOTAL_INCLUDES= $(CANTERA_CORE_INCLUDES) $(CANTERA_BOOST_INCLUDES) $(CAN
#
# LIBS and LIBS should be the same ...
#
CANTERA_TOTAL_LIBS2 = @LOCAL_LIB_DIRS@ @LOCAL_LIBS@
CANTERA_TOTAL_LIBS2 = -L$(CANTERA_LIBSDIR) @LOCAL_LIBS@
CANTERA_TOTAL_LIBS= $(CANTERA_CORE_LIBS) $(CANTERA_BOOST_LIBS) \
$(CANTERA_CVODE_LIBS) $(CANTERA_BLAS_LAPACK_LIBS) \
$(CANTERA_F2C_LIBS)
$(CANTERA_F2C_LIBS)
#
# Dependency Line

View file

@ -19,6 +19,8 @@ OBJS = importPhase.o
DEPENDS = $(OBJS:.o=.d)
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
CXX_FLAGS = @CXXFLAGS@ $(CXX_OPT) $(PIC_FLAG)
@ -28,7 +30,7 @@ CXX_INCLUDES = -I../../src/base -I../../src/thermo @CXX_INCLUDES@
# how to compile C++ source files to object files
.cpp.o:
@CXX@ -c $< $(CXX_INCLUDES) $(CXX_FLAGS)
$(PURIFY) @CXX@ -c $< $(CXX_INCLUDES) $(CXX_FLAGS)
%.d: Makefile %.o
@CXX_DEPENDS@ $(CXX_FLAGS) $(CXX_INCLUDES) $*.cpp > $*.d

View file

@ -14,6 +14,7 @@
CXX_FLAGS = @CXXFLAGS@ $(CXX_OPT)
FORT_FLAGS = @F90BUILDFLAGS@
PURIFY=@PURIFY@
CXX_OBJS = fct.o fctxml.o
@ -61,16 +62,16 @@ LCXX_FLAGS = -L$(CANTERA_LIBDIR) @CXXFLAGS@
# how to compile C++ source files to object files
%.o : %.cpp
$(CXX) -c $< $(CXX_INCLUDES) $(CXX_FLAGS)
$(PURIFY) $(CXX) -c $< $(CXX_INCLUDES) $(CXX_FLAGS)
%.o : %.f90
$(F90) -c $< $(FORT_FLAGS)
$(PURIFY) $(F90) -c $< $(FORT_FLAGS)
%.mod : %_interface.f90
$(F90) -c $< $(FORT_FLAGS)
$(PURIFY) $(F90) -c $< $(FORT_FLAGS)
%.mod : %.f90
$(F90) -c $< $(FORT_FLAGS)
$(PURIFY) $(F90) -c $< $(FORT_FLAGS)
LIB_NAME=libfct.a
@ -98,9 +99,11 @@ win-install:
%.d: %.cpp
@CXX_DEPENDS@ $(CXX_INCLUDES) $*.cpp > $*.d
depends: $(DEPENDS)
depends:
$(MAKE) .depends
.depends: $(DEPENDS)
cat *.d > .depends
$(RM) $(DEPENDS)
cantera_thermo.o: fct.mod cantera_xml.mod cantera_thermo.f90
fct.mod: fct_interface.f90

View file

@ -47,7 +47,7 @@ win: _winbuild
_build: $(SRCS) $(LIB_DEPS) Makefile setup.py
touch src/pycantera.cpp
/bin/rm -f _build
(CXX="@CXX@"; export CXX; CC="@CXX@"; export CC; @PYTHON_CMD@ setup.py build)
(CXX="@CXX@"; export CXX; CC="@CXX@"; export CC; PURIFY="@PURIFY@"; export PURIFY; @PYTHON_CMD@ setup.py build)
echo 'ok' > _build
#

View file

@ -22,6 +22,8 @@ else
DEBUG_FLAG=
endif
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
CXX_FLAGS = @CXXFLAGS@ $(LOCAL_DEFS) $(CXX_OPT) $(PIC_FLAG) $(DEBUG_FLAG)
@ -49,7 +51,7 @@ all: $(LIB) .depends
@CXX_DEPENDS@ $(CXX_FLAGS) $(CXX_INCLUDES) $*.cpp > $*.d
.cpp.o:
@CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(LIB): $(BASE_OBJ) $(BASE_H)
@ARCHIVE@ $(LIB) $(BASE_OBJ) > /dev/null

View file

@ -15,6 +15,8 @@ INCDIR = ../../../build/include/cantera/kernel/converters
INSTALL_TSC = ../../../bin/install_tsc
do_ranlib = @DO_RANLIB@
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
CXX_FLAGS = @CXXFLAGS@ $(CXX_OPT) $(PIC_FLAG)
@ -43,7 +45,7 @@ all: .depends $(CONV_LIB)
@CXX_DEPENDS@ $(CXX_FLAGS) $(CXX_INCLUDES) $*.cpp > $*.d
.cpp.o:
@CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(CONV_LIB): $(OBJS)
@ARCHIVE@ $(CONV_LIB) $(OBJS)

View file

@ -16,7 +16,10 @@ INSTALL_TSC = ../../../bin/install_tsc
do_ranlib = @DO_RANLIB@
do_VCSnonideal = @COMPILE_VCSNONIDEAL@
#
# Purify Options - instrument code for debugging and quantitification
#
PURIFY=@PURIFY@
#
# Decide whether ot use the linear programmaing module lookalike
# (from Goodwin's code). Both should produce the same results.
@ -101,10 +104,10 @@ all: $(LIB) $(VLIB) .depends
@CXX_DEPENDS@ $(CXX_FLAGS) $(CXX_INCLUDES) -I../../../ext/f2c_libs $*.c > $*.d
.cpp.o:
@CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
.c.o:
@CC@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES) -I../../../ext/f2c_libs
$(PURIFY) @CC@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES) -I../../../ext/f2c_libs
$(LIB): $(EQUIL_OBJ) $(EQUIL_H) $(VCSNONIDEAL_OBJ) $(VCSNONIDEAL_H)
@ARCHIVE@ $(LIB) $(EQUIL_OBJ) $(VCSNONIDEAL_OBJ) > /dev/null

View file

@ -26,6 +26,8 @@ else
DEBUG_FLAG=
endif
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
# LOCAL_DEFS = -DDEBUG_SOLVESP
CXX_FLAGS = @CXXFLAGS@ $(LOCAL_DEFS) $(CXX_OPT) $(PIC_FLAG) $(DEBUG_FLAG)
@ -79,7 +81,7 @@ all: $(LIB) .depends
@CXX_DEPENDS@ $(CXX_FLAGS) $(CXX_INCLUDES) $*.cpp > $*.d
.cpp.o:
@CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(LIB): $(ALLKINETICS_OBJ) $(ALLKINETICS_H)
@ARCHIVE@ $(LIB) $(ALLKINETICS_OBJ) > /dev/null

View file

@ -23,6 +23,9 @@ else
endif
SUNDIALS_INC=@sundials_include@
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
CXX_FLAGS = @CXXFLAGS@ $(LOCAL_DEFS) $(CXX_OPT) $(PIC_FLAG) $(DEBUG_FLAG)
@ -51,7 +54,7 @@ all: .depends $(LIB)
@CXX_DEPENDS@ $(CXX_FLAGS) $(CXX_INCLUDES) $*.cpp > $*.d
.cpp.o:
@CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(LIB): $(NUMERICS_OBJ) $(NUMERICS_H)
@ARCHIVE@ $(LIB) $(NUMERICS_OBJ) > /dev/null
@ -60,14 +63,14 @@ ifeq ($(do_ranlib),1)
endif
ODE_integrators.o:
@CXX@ -c ODE_integrators.cpp $(CXX_INCLUDES) $(SUNDIALS_INC) \
$(PURIFY) @CXX@ -c ODE_integrators.cpp $(CXX_INCLUDES) $(SUNDIALS_INC) \
$(CXX_FLAGS)
ODE_integrators.d: ODE_integrators.cpp Makefile
@CXX_DEPENDS@ $(CXX_FLAGS) ODE_integrators.cpp $(CXX_INCLUDES) $(SUNDIALS_INC) \
> ODE_integrators.d
DAE_solvers.o: DAE_solvers.cpp
@CXX@ -c DAE_solvers.cpp $(CXX_INCLUDES) $(SUNDIALS_INC) $(CXX_FLAGS)
$(PURIFY) @CXX@ -c DAE_solvers.cpp $(CXX_INCLUDES) $(SUNDIALS_INC) $(CXX_FLAGS)
DAE_solvers.d: DAE_solvers.cpp Makefile
@CXX_DEPENDS@ $(CXX_FLAGS) DAE_solvers.cpp $(CXX_INCLUDES) $(SUNDIALS_INC) \
> DAE_solvers.d

View file

@ -15,6 +15,8 @@ INCDIR = ../../../build/include/cantera/kernel
INSTALL_TSC = ../../../bin/install_tsc
do_ranlib = @DO_RANLIB@
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
CXX_FLAGS = @CXXFLAGS@ $(CXX_OPT) $(PIC_FLAG)
@ -35,7 +37,7 @@ DEPENDS = $(OBJS:.o=.d)
@CXX_DEPENDS@ @DEFS@ $(CXX_FLAGS) $(CXX_INCLUDES) $*.cpp > $*.d
.cpp.o:
@CXX@ -c $< @DEFS@ $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CXX@ -c $< @DEFS@ $(CXX_FLAGS) $(CXX_INCLUDES)
all: $(ONED_LIB) .depends
@(@INSTALL@ -d $(INCDIR))

View file

@ -22,6 +22,8 @@ else
DEBUG_FLAG=
endif
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
CXX_FLAGS = @CXXFLAGS@ $(LOCAL_DEFS) $(CXX_OPT) $(PIC_FLAG) $(DEBUG_FLAG)
@ -44,7 +46,7 @@ all: $(LIB) .depends
@CXX_DEPENDS@ $(CXX_FLAGS) $(CXX_INCLUDES) $*.cpp > $*.d
.cpp.o:
@CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(LIB): $(SPECTRA_OBJ) $(SPECTRA_H)
@ARCHIVE@ $(LIB) $(SPECTRA_OBJ) > /dev/null

View file

@ -24,6 +24,9 @@ else
DEBUG_FLAG=
endif
# Purify command - usually this is blank
PURIFY=@PURIFY@
#LOCAL_DEFS=-DDEBUG_MODE
PIC_FLAG=@PIC@
@ -98,7 +101,7 @@ all: $(LIB) .depends
@CXX_DEPENDS@ $(CXX_FLAGS) $(CXX_INCLUDES) $*.cpp > $*.d
.cpp.o:
@CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(LIB): $(CATHERMO_OBJ) $(CATHERMO_H)
@ARCHIVE@ $(LIB) $(CATHERMO_OBJ) > /dev/null

View file

@ -15,6 +15,8 @@ INCDIR = ../../../build/include/cantera/kernel
INSTALL_TSC = ../../../bin/install_tsc
do_ranlib = @DO_RANLIB@
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
debug_mode = @CANTERA_DEBUG_MODE@
@ -49,7 +51,7 @@ all: $(LIB) .depends
@CXX_DEPENDS@ $(CXX_FLAGS) $(CXX_INCLUDES) $*.cpp > $*.d
.cpp.o:
@CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CXX@ -c $< $(CXX_FLAGS) $(CXX_INCLUDES)
$(LIB): $(OBJS) $(TRAN_H)
@ARCHIVE@ $(LIB) $(OBJS) > /dev/null

View file

@ -15,6 +15,8 @@ INCDIR = ../../../build/include/cantera/kernel
INSTALL_TSC = ../../../bin/install_tsc
do_ranlib = @DO_RANLIB@
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
CXX_FLAGS = @CXXFLAGS@ $(CXX_OPT) $(PIC_FLAG)
@ -41,7 +43,7 @@ all: $(ZEROD_LIB) .depends
@CXX_DEPENDS@ @DEFS@ $(CXX_FLAGS) $(CXX_INCLUDES) $*.cpp > $*.d
.cpp.o:
@CXX@ -c $< @DEFS@ $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CXX@ -c $< @DEFS@ $(CXX_FLAGS) $(CXX_INCLUDES)
$(ZEROD_LIB): $(OBJS) $(ZEROD_H)
@ARCHIVE@ $(ZEROD_LIB) $(OBJS) > /dev/null

View file

@ -27,6 +27,8 @@ LINK_OPTIONS = @EXTRA_LINK@
# the Fortran compiler
FORT = @F90@
PURIFY=@PURIFY@
# Fortran compile flags
FORT_FLAGS = @FFLAGS@
@ -87,11 +89,11 @@ LCXX_FLAGS = -L$(CANTERA_LIBDIR) @LOCAL_LIB_DIRS@ @CXXFLAGS@
# how to compile C++ source files to object files
.@CXX_EXT@.@OBJ_EXT@:
$(CXX) -c $< $(CANTERA_INC) $(CXX_FLAGS)
$(PURIFY) $(CXX) -c $< $(CANTERA_INC) $(CXX_FLAGS)
# how to compile Fortran source files to object files
.@F77_EXT@.@OBJ_EXT@:
$(FORT) -c $< $(FORT_FLAGS)
$(PURIFY) $(FORT) -c $< $(FORT_FLAGS)
PROGRAM = ./$(PROG_NAME)$(EXE_EXT)
@ -103,7 +105,7 @@ DEPENDS=$(OBJS:.o=.d)
@CXX_DEPENDS@ $(CANTERA_INC) $(CXX_FLAGS) $*.cpp > $*.d
$(PROGRAM): $(OBJS) $(LIB_DEPS)
$(CXX) -o $(PROGRAM) $(OBJS) $(LCXX_FLAGS) $(CANTERA_LIBS) \
$(PURIFY) $(CXX) -o $(PROGRAM) $(OBJS) $(LCXX_FLAGS) $(CANTERA_LIBS) \
$(LINK_OPTIONS) $(EXT_LIBS) @LIBS@ \
$(LCXX_END_LIBS)

View file

@ -9,6 +9,8 @@ BLASLIB = @buildlib@/libctblas.a
SUFFIXES=
SUFFIXES= .f .o
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
F_FLAGS = @FFLAGS@ $(PIC_FLAG)
@ -67,7 +69,7 @@ ifeq ($(do_ranlib),1)
endif
%.o : %.f
@F77@ -c $< $(F_FLAGS)
$(PURIFY) @F77@ -c $< $(F_FLAGS)
clean:
$(RM) $(OBJS) $(BLASLIB)

View file

@ -23,6 +23,8 @@ do_ranlib = @DO_RANLIB@
all: @buildlib@/libcvode.a
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
COMPILER = @CC@
@ -43,54 +45,54 @@ endif
source/cvode.o: source/cvode.c include/cvode.h include/llnltyps.h \
include/nvector.h include/llnlmath.h
(cd source; $(COMPILER) $(OPTS) -c cvode.c)
(cd source; $(PURIFY) $(COMPILER) $(OPTS) -c cvode.c)
source/cvdense.o: source/cvdense.c include/cvdense.h include/cvode.h \
include/dense.h include/llnltyps.h include/nvector.h \
include/llnlmath.h
(cd source; $(COMPILER) $(OPTS) -c cvdense.c)
(cd source; $(PURIFY) $(COMPILER) $(OPTS) -c cvdense.c)
source/dense.o: source/dense.c include/dense.h include/llnltyps.h \
include/nvector.h include/llnlmath.h
(cd source; $(COMPILER) $(OPTS) -c dense.c)
(cd source; $(PURIFY) $(COMPILER) $(OPTS) -c dense.c)
source/cvband.o: source/cvband.c include/cvband.h include/cvode.h \
include/band.h include/llnltyps.h include/nvector.h \
include/llnlmath.h
(cd source; $(COMPILER) $(OPTS) -c cvband.c)
(cd source; $(PURIFY) $(COMPILER) $(OPTS) -c cvband.c)
source/band.o: source/band.c include/band.h include/llnltyps.h \
include/nvector.h include/llnlmath.h
(cd source; $(COMPILER) $(OPTS) -c band.c)
(cd source; $(PURIFY) $(COMPILER) $(OPTS) -c band.c)
source/cvdiag.o: source/cvdiag.c include/cvdiag.h include/cvode.h \
include/llnltyps.h include/nvector.h
(cd source; $(COMPILER) $(OPTS) -c cvdiag.c)
(cd source; $(PURIFY) $(COMPILER) $(OPTS) -c cvdiag.c)
source/cvspgmr.o: source/cvspgmr.c include/cvspgmr.h include/cvode.h \
include/llnltyps.h include/nvector.h include/llnlmath.h \
include/iterativ.h include/spgmr.h
(cd source; $(COMPILER) $(OPTS) -c cvspgmr.c)
(cd source; $(PURIFY) $(COMPILER) $(OPTS) -c cvspgmr.c)
source/spgmr.o: source/spgmr.c include/spgmr.h include/iterativ.h \
include/llnltyps.h include/nvector.h include/llnlmath.h
(cd source; $(COMPILER) $(OPTS) -c spgmr.c)
(cd source; $(PURIFY) $(COMPILER) $(OPTS) -c spgmr.c)
source/iterativ.o: source/iterativ.c include/iterativ.h include/llnltyps.h \
include/nvector.h include/llnlmath.h
(cd source; $(COMPILER) $(OPTS) -c iterativ.c)
(cd source; $(PURIFY) $(COMPILER) $(OPTS) -c iterativ.c)
source/cvbandpre.o: source/cvbandpre.c include/cvbandpre.h include/cvode.h \
include/nvector.h include/llnltyps.h include/llnlmath.h \
include/band.h
(cd source; $(COMPILER) $(OPTS) -c cvbandpre.c)
(cd source; $(PURIFY) $(COMPILER) $(OPTS) -c cvbandpre.c)
source/nvector.o: source/nvector.c include/nvector.h include/llnltyps.h \
include/llnlmath.h
(cd source; $(COMPILER) $(OPTS) -c nvector.c)
(cd source; $(PURIFY) $(COMPILER) $(OPTS) -c nvector.c)
source/llnlmath.o: source/llnlmath.c include/llnlmath.h include/llnltyps.h
(cd source; $(COMPILER) $(OPTS) -c llnlmath.c)
(cd source; $(PURIFY) $(COMPILER) $(OPTS) -c llnlmath.c)
$(OBJS): Makefile

View file

@ -13,6 +13,8 @@
do_ranlib = @DO_RANLIB@
PURIFY=@PURIFY@
# the directory where the Cantera libraries are located
CANTERA_LIBDIR=@buildlib@
@ -41,7 +43,7 @@ CXX_INCLUDES=-I../f2c_libs
# How to compile a C file
.c.o:
@CC@ -c $< @DEFS@ $(CFLAGS) $(CXX_INCLUDES)
$(PURIFY) @CC@ -c $< @DEFS@ $(CFLAGS) $(CXX_INCLUDES)
# -----------------------------------------------

View file

@ -11,6 +11,8 @@
do_ranlib = @DO_RANLIB@
PURIFY=@PURIFY@
# the directory where the Cantera libraries are located
CANTERA_LIBDIR=@buildlib@
@ -35,7 +37,7 @@ CXX_INCLUDES=-I../f2c_libs
@CXX_DEPENDS@ $(CFLAGS) $(CXX_INCLUDES) $*.c > $*.d
.c.o:
@CC@ -c $< $(CFLAGS) $(CXX_INCLUDES)
$(PURIFY) @CC@ -c $< $(CFLAGS) $(CXX_INCLUDES)
# -----------------------------------------------

View file

@ -10,6 +10,9 @@
.SUFFIXES : .c .cpp .d .o
do_ranlib = @DO_RANLIB@
PURIFY=@PURIFY@
# the directory where the Cantera libraries are located
CANTERA_LIBDIR=@buildlib@
@ -39,11 +42,11 @@ CXX_INCLUDES=-I../f2c_libs
# How to compile a C file
.c.o:
@CC@ -c $< @DEFS@ $(CFLAGS) $(CXX_INCLUDES)
$(PURIFY) @CC@ -c $< @DEFS@ $(CFLAGS) $(CXX_INCLUDES)
# How to compile a Cpp file
.cpp.o:
@CXX@ -c $< @DEFS@ $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CXX@ -c $< @DEFS@ $(CXX_FLAGS) $(CXX_INCLUDES)
# -----------------------------------------------

View file

@ -11,6 +11,8 @@
do_ranlib = @DO_RANLIB@
PURIFY=@PURIFY@
# the directory where the Cantera libraries are located
CANTERA_LIBDIR=@buildlib@
@ -36,7 +38,7 @@ CXX_INCLUDES=-I../f2c_libs
# How to compile a C file
.c.o:
@CC@ -c $< @DEFS@ $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CC@ -c $< @DEFS@ $(CXX_FLAGS) $(CXX_INCLUDES)
# -----------------------------------------------

View file

@ -10,6 +10,8 @@ LAPACKLIB = @buildlib@/libctlapack.a
do_ranlib = @DO_RANLIB@
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
F_FLAGS = @FFLAGS@ $(PIC_FLAG)
@ -78,7 +80,7 @@ ifeq ($(do_ranlib),1)
endif
%.o : %.f
@F77@ -c $< $(F77_INCLUDES) $(F_FLAGS)
$(PURIFY) @F77@ -c $< $(F77_INCLUDES) $(F_FLAGS)
$(OBJS): Makefile

View file

@ -13,6 +13,9 @@ do_ranlib = @DO_RANLIB@
LIB = @buildlib@/libctmath.a
all: $(LIB)
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
F_FLAGS = @FFLAGS@ $(PIC_FLAG)
@ -50,13 +53,13 @@ ifeq ($(do_ranlib),1)
endif
%.o : %.c
@CXX@ -c $< @DEFS@ @CXXFLAGS@ @PIC@ -I../.. $(INCLUDES)
$(PURIFY) @CXX@ -c $< @DEFS@ @CXXFLAGS@ @PIC@ -I../.. $(INCLUDES)
%.o : %.cpp
@CXX@ -c $< @DEFS@ @CXXFLAGS@ @PIC@ $(INCLUDES)
$(PURIFY) @CXX@ -c $< @DEFS@ @CXXFLAGS@ @PIC@ $(INCLUDES)
%.o : %.f
@F77@ -c $< $(F_FLAGS)
$(PURIFY) @F77@ -c $< $(F_FLAGS)
$(OBJS): Makefile

View file

@ -9,6 +9,9 @@
LIB = @buildlib@/librecipes.a
do_ranlib = @DO_RANLIB@
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
F_FLAGS = @FFLAGS@ $(PIC_FLAG)
@ -25,7 +28,7 @@ ifeq ($(do_ranlib),1)
endif
%.o : %.f
@F77@ -c $< $(F_FLAGS)
$(PURIFY) @F77@ -c $< $(F_FLAGS)
clean:
$(RM) $(OBJS) $(LIB)

View file

@ -6,6 +6,9 @@
.SUFFIXES : .cpp .d .o
do_ranlib = @DO_RANLIB@
PURIFY=@PURIFY@
PIC_FLAG=@PIC@
CXX_FLAGS = @CXXFLAGS@ $(CXX_OPT) $(PIC_FLAG)
@ -24,10 +27,10 @@ all: $(TPLIB) .depends
@CXX_DEPENDS@ $(CXX_INCLUDES) $*.cpp > $*.d
.cpp.o:
@CXX@ -c $< @DEFS@ $(CXX_FLAGS) $(CXX_INCLUDES)
$(PURIFY) @CXX@ -c $< @DEFS@ $(CXX_FLAGS) $(CXX_INCLUDES)
.f.o:
@F77@ -c $< $(F77_FLAGS)
$(PURIFY) @F77@ -c $< $(F77_FLAGS)
$(TPLIB): $(COBJS) $(FOBJS)
@ARCHIVE@ $(TPLIB) $(COBJS) $(FOBJS) > /dev/null

View file

@ -9,17 +9,11 @@
* $Revision$
*/
#ifdef SRCDIRTREE
#include "ct_defs.h"
#include "logger.h"
#include "HMWSoln.h"
#else
#include "Cantera.h"
#include "kernel/logger.h"
#include "HMWSoln.h"
#endif
#include <cstdio>

View file

@ -23,6 +23,8 @@ LINK_OPTIONS = @EXTRA_LINK@
#############################################################################
PURIFY=@PURIFY@
# Check to see whether we are in the msvc++ environment
os_is_win = @OS_IS_WIN@
@ -56,7 +58,7 @@ LCXX_FLAGS = -L$(CANTERA_LIBDIR) @LOCAL_LIB_DIRS@ @CXXFLAGS@
# How to compile C++ source files to object files
.@CXX_EXT@.@OBJ_EXT@: Interface.h
$(CXX) -c $< -I$(CANTERA_INCDIR) $(CXX_FLAGS)
$(PURIFY) $(CXX) -c $< -I$(CANTERA_INCDIR) $(CXX_FLAGS)
# How to compile the dependency file
.cpp.d:
@ -73,7 +75,7 @@ all: $(PROGRAM)
# Rule to make the program
$(PROGRAM): $(OBJS) $(CANTERA_LIBDIR)/libctbase.a
$(CXX) -o $(PROGRAM) $(OBJS) $(LCXX_FLAGS) $(LINK_OPTIONS) \
$(PURIFY) $(CXX) -o $(PROGRAM) $(OBJS) $(LCXX_FLAGS) $(LINK_OPTIONS) \
$(CANTERA_LIBS) @LIBS@ $(FORT_LIBS) \
$(LCXX_END_LIBS)

View file

@ -33,6 +33,8 @@ else
FORT_LIBS =
endif
PURIFY=@PURIFY@
# the C++ compiler
CXX = @CXX@
@ -56,7 +58,7 @@ LCXX_FLAGS = -L$(CANTERA_LIBDIR) @LOCAL_LIB_DIRS@ @CXXFLAGS@
# How to compile C++ source files to object files
.@CXX_EXT@.@OBJ_EXT@:
$(CXX) -c $< -I$(CANTERA_INCDIR) @CXX_INCLUDES@ $(CXX_FLAGS)
$(PURIFY) $(CXX) -c $< -I$(CANTERA_INCDIR) @CXX_INCLUDES@ $(CXX_FLAGS)
# How to compile the dependency file
.cpp.d:
@ -68,10 +70,10 @@ DEPENDS=$(OBJS:.o=.d)
# Program Name
PROGRAM = $(PROG_NAME)$(EXE_EXT)
all: $(PROGRAM)
all: .depends $(PROGRAM)
$(PROGRAM): $(OBJS) $(CANTERA_LIBDIR)/libctbase.a
$(CXX) -o $(PROGRAM) $(OBJS) $(LCXX_FLAGS) $(LINK_OPTIONS) \
$(PURIFY) $(CXX) -o $(PROGRAM) $(OBJS) $(LCXX_FLAGS) $(LINK_OPTIONS) \
$(CANTERA_LIBS) @LIBS@ $(FORT_LIBS) \
$(LCXX_END_LIBS)

View file

@ -5,6 +5,8 @@ INCDIR = -I@ctroot@/Cantera/src/
BINDIR = @buildbin@
build_ck = @BUILD_CK@
PURIFY=@PURIFY@
LCXX_FLAGS = -L$(LIBDIR) @LOCAL_LIB_DIRS@ @CXXFLAGS@
LOCAL_LIBS = @LOCAL_LIBS@ #-lcantera -ltpx -lctcxx
#LOCAL_LIBS = -lcantera @math_libs@ @BLAS_LAPACK_LIBS@ -lctcxx
@ -26,7 +28,7 @@ exes = $(progs)
endif
.cpp.o:
@CXX@ -c $< @DEFS@ $(INCDIR)base $(INCDIR)converters @CXX_INCLUDES@ @CXXFLAGS@ $(CXX_FLAGS)
$(PURIFY) @CXX@ -c $< @DEFS@ $(INCDIR)base $(INCDIR)converters @CXX_INCLUDES@ @CXXFLAGS@ $(CXX_FLAGS)
all: $(exes)
@ -34,17 +36,17 @@ ck: $(BINDIR)/ck2cti
$(BINDIR)/ck2cti: ck2cti.o $(CONVLIB_DEP)
$(RM) $(BINDIR)/ck2cti
@CXX@ -o $(BINDIR)/ck2cti ck2cti.o $(LCXX_FLAGS) \
$(PURIFY) @CXX@ -o $(BINDIR)/ck2cti ck2cti.o $(LCXX_FLAGS) \
-lconverters -lctbase -ltpx -lctcxx $(LOCAL_LIBS) $(LCXX_END_LIBS)
$(BINDIR)/cti2ctml: cti2ctml.o
$(RM) $(BINDIR)/cti2ctml
@CXX@ -o $(BINDIR)/cti2ctml cti2ctml.o $(LCXX_FLAGS) $(LOCAL_LIBS) \
$(PURIFY) @CXX@ -o $(BINDIR)/cti2ctml cti2ctml.o $(LCXX_FLAGS) $(LOCAL_LIBS) \
$(LCXX_END_LIBS)
$(BINDIR)/fixtext: fixtext.o
$(RM) $(BINDIR)/fixtext
@CXX@ -o $(BINDIR)/fixtext fixtext.o $(LCXX_FLAGS) \
$(PURIFY) @CXX@ -o $(BINDIR)/fixtext fixtext.o $(LCXX_FLAGS) \
$(LOCAL_LIBS) $(LCXX_END_LIBS)
$(CONVLIB_DEP):

View file

@ -6,6 +6,8 @@ BINDIR = @ctroot@/bin
BBINDIR = @buildbin@
build_ck = @BUILD_CK@
PURIFY=@PURIFY@
LCXX_FLAGS = -L$(LIBDIR) @LOCAL_LIB_DIRS@ @CXXFLAGS@
LOCAL_LIBS = -lcantera -lckreader @math_libs@ @LAPACK_LIBRARY@ @BLAS_LIBRARY@ -lctcxx
@ -22,12 +24,12 @@ CONFIGDEFS=@DEFS@
# not be needed here anyway.
.cpp.o:
@CXX@ -c $< -I$(INCDIR) @CXXFLAGS@ -O0
$(PURIFY) @CXX@ -c $< -I$(INCDIR) @CXXFLAGS@ -O0
all: $(BINDIR)/csvdiff $(BBINDIR)/csvdiff
$(BINDIR)/csvdiff: mdp_allo.o csvdiff.o tok_input_util.o
@CXX@ -o $(BINDIR)/csvdiff mdp_allo.o csvdiff.o tok_input_util.o \
$(PURIFY) @CXX@ -o $(BINDIR)/csvdiff mdp_allo.o csvdiff.o tok_input_util.o \
$(LCXX_FLAGS) $(LCXX_END_LIBS)
$(BBINDIR)/csvdiff: $(BINDIR)/csvdiff