diff options
author | tradke <tradke@17b73243-c579-4c4c-a9d2-2d5706c11dac> | 2005-06-16 10:29:07 +0000 |
---|---|---|
committer | tradke <tradke@17b73243-c579-4c4c-a9d2-2d5706c11dac> | 2005-06-16 10:29:07 +0000 |
commit | f56810b4619bd67c00a35e74cfb53163dbf44e43 (patch) | |
tree | 0b46af45eb14341dcef6638b01e67f256335d428 /lib/make/known-architectures/aix | |
parent | b0a55b75677cc5a807c9dbb16a8c65b9746561bc (diff) |
Detect compiler versions.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@4078 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'lib/make/known-architectures/aix')
-rw-r--r-- | lib/make/known-architectures/aix | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/lib/make/known-architectures/aix b/lib/make/known-architectures/aix index 2a0bd315..485d8688 100644 --- a/lib/make/known-architectures/aix +++ b/lib/make/known-architectures/aix @@ -49,8 +49,7 @@ else exit 1 fi - : ${ARFLAGS="-X$AIX_BITS -rucs"} - + # Fortran compilers : ${F90FLAGS="-q$AIX_BITS -qmaxmem=-1 -qspill=10000"} : ${F77FLAGS="-q$AIX_BITS -qmaxmem=-1 -qfixed"} : ${F90_OPTIMISE_FLAGS='-O5'} @@ -66,14 +65,23 @@ else CCTK_WriteLine make.arch.defn 'AIX_f_FLAGS = -qfixed' FPP='$(PERL) $(CCTK_HOME)/lib/sbin/cpp.pl' + : ${F_DEPEND='$(PERL) $(CCTK_HOME)/lib/sbin/cpp.pl -M $(CPPFLAGS)'} + : ${F77_DEPEND=$F_DEPEND} + + F77_VERSION=`$F77 2>&1 | head -n1` + F90_VERSION=`$F90 2>&1 | head -n1` + + # C/C++ compilers case "$CC" in gcc) : ${C_DEPEND_OUT=' > $@'} + CC_VERSION="`$CC -v 2>&1 | grep -i version | tail -n1`" ;; cc|xlc|xlc_r) : ${C_DEPEND='$(CC) -E -M $(CPPFLAGS)'} : ${C_DEPEND_OUT=' > /dev/null ; mv $(basename $(basename $@)).u $@'} : ${CFLAGS="-q$AIX_BITS -qspill=17000 -qmaxmem=-1 -qlanglvl=stdc99"} + CC_VERSION=`$CC 2>&1 | head -n1` ;; *) ;; @@ -82,19 +90,20 @@ else case "$CXX" in 'g++'|'c++') : ${CXX_DEPEND_OUT=' > $@'} + CXX_VERSION="`$CXX -v 2>&1 | grep -i version | tail -n1`" ;; xlC|xlC_r) : ${CXX_DEPEND='$(CXX) -E -M $(CPPFLAGS)'} : ${CXX_DEPEND_OUT=' > /dev/null ; mv $(basename $(basename $@)).u $@'} : ${CXXFLAGS="-q$AIX_BITS -qspill=10000 -qmaxmem=-1"} + CXX_VERSION=`$CXX 2>&1 | head -n1` ;; *) ;; esac - : ${F_DEPEND='$(PERL) $(CCTK_HOME)/lib/sbin/cpp.pl -M $(CPPFLAGS)'} - : ${F77_DEPEND=$F_DEPEND} - + # Linker + : ${ARFLAGS="-X$AIX_BITS -rucs"} if test -z "$LIBS" -a "$LD" != 'xlf90' ; then LIBS=xlf90 if test -r /usr/lib/libxlopt.a ; then @@ -113,7 +122,6 @@ else fi # MPI stuff - if test -n "$MPI" ; then # must not set linker flags for 64-bit configurations # (LD will figure these out) |