From 1545df229338ec2213b008e9589084cf726fefb3 Mon Sep 17 00:00:00 2001 From: goodale Date: Mon, 11 Oct 1999 13:49:09 +0000 Subject: Added a "preferred-compilers" section to the known-architecture stuff. Added detection of NULL device, 'though not added a symbol for it yet. Fixed a bug in the dependencies for AIX. Tom git-svn-id: http://svn.cactuscode.org/flesh/trunk@1013 17b73243-c579-4c4c-a9d2-2d5706c11dac --- lib/make/known-architectures/aix | 37 ++++++---- lib/make/known-architectures/cygwin | 65 +++++++++++------ lib/make/known-architectures/hp-ux | 21 ++++-- lib/make/known-architectures/irix | 140 ++++++++++++++++++++---------------- lib/make/known-architectures/linux | 78 +++++++++++--------- lib/make/known-architectures/osf | 11 ++- lib/make/known-architectures/unicos | 25 ++++--- 7 files changed, 230 insertions(+), 147 deletions(-) (limited to 'lib/make/known-architectures') diff --git a/lib/make/known-architectures/aix b/lib/make/known-architectures/aix index 3fb90b2e..279a610e 100644 --- a/lib/make/known-architectures/aix +++ b/lib/make/known-architectures/aix @@ -9,24 +9,31 @@ # @version $Header$ # @@*/ -: ${F90FLAGS="-g -O2 -qfixed"} -: ${F77FLAGS="-g -O2 -qfixed"} +if test "$CCTK_CONFIG_STAGE" = "preferred-compilers" ; then -: ${C_DEPEND_OUT=' > $@'} -: ${CXX_DEPEND_OUT=' > $@'} -: ${F_DEPEND_OUT=' > /dev/null ; mv $(basename $(@)).u $@'} -: ${F77_DEPEND_OUT=' > /dev/null ; mv $(basename $(@)).u $@'} +: -: ${LIBS="xlf90"} +else + : ${F90FLAGS="-g -O2 -qfixed"} + : ${F77FLAGS="-g -O2 -qfixed"} -# MPI stuff + : ${C_DEPEND_OUT=' > $@'} + : ${CXX_DEPEND_OUT=' > $@'} + : ${F_DEPEND_OUT=' > /dev/null ; mv $(basename $(basename $@)).u $@'} + : ${F77_DEPEND_OUT=' > /dev/null ; mv $(basename $(basename $@)).u $@'} + + : ${LIBS="xlf90"} + + + # MPI stuff -if test -n "$MPI" ; then - if test "$MPI" = "NATIVE" ; then - MPI_LIBS="mpi" - MPI_LIB_DIRS="/usr/lpp/ppe.poe/lib" - MPI_INC_DIRS="/usr/lpp/ppe.poe/include" - fi -fi + if test -n "$MPI" ; then + if test "$MPI" = "NATIVE" ; then + MPI_LIBS="mpi" + MPI_LIB_DIRS="/usr/lpp/ppe.poe/lib" + MPI_INC_DIRS="/usr/lpp/ppe.poe/include" + fi + fi +fi diff --git a/lib/make/known-architectures/cygwin b/lib/make/known-architectures/cygwin index 44f19770..440e16a0 100644 --- a/lib/make/known-architectures/cygwin +++ b/lib/make/known-architectures/cygwin @@ -10,55 +10,76 @@ # @version $Header$ # @@*/ +if test "$CCTK_CONFIG_STAGE" = "preferred-compilers" ; then -echo Setting compiler to cl -CC="cl" -CXX="cl" + if test -z "$CC"; then + echo Setting C compiler to cl + CC="cl" + fi -echo Setting linker to f90 -LD="f90" + if test -z "$CXX"; then + echo Setting C++ compiler to cl + CXX="cl" + fi + + if test -z "$LD"; then + echo Setting linker to f90 + LD="f90" + fi + +else # /Gd means use __cdecl, it's /Gz for __stdcall -CFLAGS="/nologo /Oxy- /Gd" -CXXFLAGS="/nologo /TP /Oxy- /Gd" -F90FLAGS="/fast /iface:cref" + if test -z "$CFLAGS"; then + CFLAGS="/nologo /Oxy- /Gd" + fi + + if test -z "CXXFLAGS" ; then + CXXFLAGS="/nologo /TP /Oxy- /Gd" + fi -CCOMPILEONLY="/c /Fo" -FCOMPILEONLY="/compile_only /object:" + if test -z "CXXFLAGS" ; then + F90FLAGS="/fast /iface:cref" + fi -CREATEEXE="-exe:" + CCOMPILEONLY="/c /Fo" + FCOMPILEONLY="/compile_only /object:" -SYS_INC_DIRS="/PROGRA~/MICROS~1/VC98/INCLUDE" + CREATEEXE="-exe:" -DIRSEP="\\\\" + SYS_INC_DIRS="/PROGRA~/MICROS~1/VC98/INCLUDE" -OPTIONSEP="# not even a single a single space under cygwin" + DIRSEP="\\\\" + + OPTIONSEP="# not even a single a single space under cygwin" # Convert //a to a: -GET_WD="pwd | sed 's,^//\(.\)/,\1:/,' | sed 's,/,\\\\\\,g' " + GET_WD="pwd | sed 's,^//\(.\)/,\1:/,' | sed 's,/,\\\\\\,g' " -C_DEPEND='$(CPP) -E -MM -nostdinc $(CPPFLAGS) ' + C_DEPEND='$(CPP) -E -MM -nostdinc $(CPPFLAGS) ' -CXX_DEPEND='$(CPP) -E -MM -nostdinc $(CPPFLAGS) ' + CXX_DEPEND='$(CPP) -E -MM -nostdinc $(CPPFLAGS) ' -MKDIR="mkdir " -MKDIRFLAGS=" -p " + MKDIR="mkdir " + MKDIRFLAGS=" -p " -CACTUSLIBLINKLINE='$(addsuffix .a,$(addprefix $(subst /,$(DIRSEP),$(CCTK_LIBDIR))$(DIRSEP)lib,$(notdir $(ALLCACTUSLIBS))))' + CACTUSLIBLINKLINE='$(addsuffix .a,$(addprefix $(subst /,$(DIRSEP),$(CCTK_LIBDIR))$(DIRSEP)lib,$(notdir $(ALLCACTUSLIBS))))' # Windows libraries have to explicitly appear on the link line with full name # So ignore the LIBDIRS variable and don't put flags on. -GENERAL_LIBRARIES='$(LIBS)' + GENERAL_LIBRARIES='$(LIBS)' -cat >> cctk_archdefs.h <> cctk_archdefs.h <&1 | grep -i f90 | grep -i vast`" ; then LINUX_F90_COMP=pacific elif test "`$F90 -V 2>&1 | grep -i f90 | grep -i absoft`" ; then @@ -32,44 +38,52 @@ if test -n "$F90" ; then echo ad send the updated file to CactusMaint echo We will try anyway ... fi -else + else LINUX_F90_COMP=none -fi + fi #Set the appropriate flags -case "$LINUX_F90_COMP" in + case "$LINUX_F90_COMP" in pacific) - : ${LIBS="vast90 g2c m"} ;; + : ${LIBS="vast90 g2c m"} ;; absoft) - : ${LIBS="f90math fio f77math m"} - F90FLAGS="-s -O" - # Test if it is a version of the absoft compiler which has the library in a custom place. - if test -n "$ABSOFT" ; then - : ${LIBDIRS='$(ABSOFT)/lib'} - fi ;; + : ${LIBS="f90math fio f77math m"} + F90FLAGS="-s -O" + # Test if it is a version of the absoft compiler which has the library in a custom place. + if test -n "$ABSOFT" ; then + : ${LIBDIRS='$(ABSOFT)/lib'} + fi + ;; absoft77) - : ${LIBS="fio f77math m"} - F90FLAGS="-f" - # Test if it is a version of the absoft compiler which has the library in a custom place. - if test -n "$ABSOFT" ; then - : ${LIBDIRS='$(ABSOFT)/lib'} - fi ;; + : ${LIBS="fio f77math m"} + F90FLAGS="-f" + # Test if it is a version of the absoft compiler which has the library in a custom place. + if test -n "$ABSOFT" ; then + : ${LIBDIRS='$(ABSOFT)/lib'} + fi + ;; nag) - : ${LIBS="f90 nagfl90 nag m"} - F90FLAGS="$F90FLAGS -N140" ;; + : ${LIBS="f90 nagfl90 nag m"} + F90FLAGS="$F90FLAGS -N140" + ;; portland) - : ${LIBS="pgf90 pgf90_rpm1 pghpf2 pgf90rtl pgc m"} - : ${LIBDIRS='$(PGI)/linux86/lib'} ;; + : ${LIBS="pgf90 pgf90_rpm1 pghpf2 pgf90rtl pgc m"} + : ${LIBDIRS='$(PGI)/linux86/lib'} + ;; fujitsu) - : ${LIBS="fj9i6 fj9e6 fj9f6"} ;; + : ${LIBS="fj9i6 fj9e6 fj9f6"} + ;; none) - : ${LIBS="m"} ;; - *) - echo Unknown Linux f90 compiler. - echo Please add appropriate information to - echo $srcdir/known-architectures/linux-gnu - echo and send the updated file to CactusMaint - echo We will try anyway ... - ;; -esac + : ${LIBS="m"} + ;; + *) + echo Unknown Linux f90 compiler. + echo Please add appropriate information to + echo $srcdir/known-architectures/linux-gnu + echo and send the updated file to CactusMaint + echo We will try anyway ... + ;; + esac + +fi diff --git a/lib/make/known-architectures/osf b/lib/make/known-architectures/osf index 87c8a71b..8649cafb 100644 --- a/lib/make/known-architectures/osf +++ b/lib/make/known-architectures/osf @@ -6,8 +6,15 @@ # @desc # # @enddesc -# @version $Header: /mnt/data2/cvs2svn/cvs-repositories/Cactus/lib/make/known-architectures/osf,v 1.1 1999-04-22 13:21:59 allen Exp $ +# @version $Header: /mnt/data2/cvs2svn/cvs-repositories/Cactus/lib/make/known-architectures/osf,v 1.2 1999-10-11 13:49:09 goodale Exp $ # @@*/ -: ${LIBS="for"} +if test "$CCTK_CONFIG_STAGE" = "preferred-compilers" ; then +: + +else + + : ${LIBS="for"} + +fi \ No newline at end of file diff --git a/lib/make/known-architectures/unicos b/lib/make/known-architectures/unicos index 9749c5b5..b524e144 100644 --- a/lib/make/known-architectures/unicos +++ b/lib/make/known-architectures/unicos @@ -6,23 +6,32 @@ # @desc # # @enddesc -# @version $Header: /mnt/data2/cvs2svn/cvs-repositories/Cactus/lib/make/known-architectures/unicos,v 1.3 1999-07-06 20:19:13 goodale Exp $ +# @version $Header: /mnt/data2/cvs2svn/cvs-repositories/Cactus/lib/make/known-architectures/unicos,v 1.4 1999-10-11 13:49:09 goodale Exp $ # @@*/ -# The T3E F90 compiler uses -b if you want to supply a name for a .o file. -: ${FCOMPILEONLY="-b"} +if test "$CCTK_CONFIG_STAGE" = "preferred-compilers" ; then -# The T3E fortran compiler puts module info in .o files by default. -: ${F90FLAGS="-O scalar3,noieeeconform,unroll2,inline3 -dp -em"} +: -: ${LIBS="_ereg _perf_mjp _util _vect"} +else -: ${LIBDIRS='$(CCTK_HOME)/lib/archlibs/t3e'} + # The T3E F90 compiler uses -b if you want to supply a name for a .o file. + : ${FCOMPILEONLY="-b"} -cat >> cctk_archdefs.h <> cctk_archdefs.h <