[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: flags for different fortran compilers
From: |
Eve-Marie Devaliere |
Subject: |
Re: flags for different fortran compilers |
Date: |
Tue, 01 Feb 2011 15:39:14 -0500 |
User-agent: |
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 |
Thanks Ralph.
> > Which kinds of flags do you need support for?
lots... :(
For example, in their original make.macros they had
# Compiler settings for DEBUG builds
LINUX_COMMON_FLAGS_GFORTRAN_DEBUG = -pg
LINUX_FLAGS_GFORTRAN_DEBUG =
"FC_FLAGS= -c \
-fbounds-check \
-fconvert=big-endian \
-ffpe-trap=overflow,zero \
-ffree-form \
-fno-second-underscore \
-frecord-marker=4 \
-ggdb \
-static \
-Wall \
${INCLUDES} \
${LINUX_COMMON_FLAGS_GFORTRAN_DEBUG}" \
# Compiler settings for DEBUG builds
LINUX_COMMON_FLAGS_GFORTRAN_PROD =
LINUX_FLAGS_GFORTRAN_PROD =
"FC_FLAGS= -c \
-O3 \
-fconvert=big-endian \
-ffast-math \
-ffree-form \
-fno-second-underscore \
-frecord-marker=4 \
-funroll-loops \
-ggdb \
-static \
-Wall \
${INCLUDES} \
${LINUX_COMMON_FLAGS_GFORTRAN_PROD}" \
I should be able to work with them to figure out what is really needed,
hopefully....
> > The "Autoconf Way" of implementing things, when there isn't a predefined
> > macro for some feature, is to try out a set of known compiler switches
> > and select the first one that has the desired features. For example,
> > the AC_FC_FREEFORM macro tries to compile a small free-form source file,
> > and passes one of a few known compiler flags that enable free form. It
> > picks the first one that works.
ok, yes I think I have seen explanations about that... from what I tried
though, if I say
AC_FC_FREEFORM()
nothing happens as far as creating a 'free flag'... I thought it would
find the appropriate one...?
I need to say AC_FC_FREEFORM([],[FCFLAGS="$FCFLAGS -free"]) to add it
but of course that will work for intel compiler but not for others....
DId I miss something?
> > If you can formulate your needs in such a way, then the next hurdle is
> > to overcome the M4 language and a few Autoconf building block macros
> > like AC_COMPILE_IFELSE and AC_LINK_IFELSE. We can help with the latter
> > if the former is clear.
Thanks. I tried to do a locate to see if I could figure out what is done
for AC_FC_FREEFORM but I couldn't find it.... would you have an example
to suggest to put me on the way?
Thank you so much for all the help!
Cheers,
Eve-Marie
> > Cheers,
> > Ralf
- Re: flags for different fortran compilers,
Eve-Marie Devaliere <=