Hi Ralph, Ralf Wildenhues wrote: > cat >configure.ac <<\EOF > AC_INIT([fortran-test], [1], [devnull]) > AM_INIT_AUTOMAKE([foreign]) > AC_CONFIG_FILES([Makefile]) > AC_PROG_FC > if test $ac_cv_fc_compiler_gnu = yes; then > AC_SUBST([MY_CPPFLAGS], ["-x f95-cpp-input"]) > fi > AC_OUTPUT > EOF > cat >Makefile.am <<\EOF > bin_PROGRAMS = foo > foo_SOURCES = foo.F95 > AM_CPPFLAGS = $(MY_CPPFLAGS) > EOF > cat >foo.F95 <<\EOF > program main > end > EOF > autoreconf -vi > ./configure > make
This works. Thanks. Is there some way to avoid having to use the capital F's? It's not too much of an issue, but I have my project under version control and renaming file names is a bit of a pain. > With respect to portability among compilers, this example is lacking the > flag for source file extensions, AC_FC_SRCEXT([F95]). I omitted it > because Automake does not automatically add support for it yet > (for .f90 and .f95, that has been added in Automake 1.10). If you need > this, write me, and I'll post an updated example. I use the f90 extension regardless of whether the file is f90 or f95, so I don't think I need to add this support. > The address is <automake@gnu.org>, the archives are here at > <http://lists.gnu.org/archive/html/automake/>. Thanks, I'll post further questions here. John _______________________________________________ help-gnu-utils mailing list help-gnu-utils@gnu.org http://lists.gnu.org/mailman/listinfo/help-gnu-utils