toby.m@mail.utexas.edu
2005-Nov-11 17:33 UTC
[Rd] configure on solaris 2.9 with non GNU compilers (PR#8300)
Full_Name: Toby Muhlhofer Version: 2.2.0, 2.1.1 OS: Solaris 2.9 Submission from: (NULL) (128.83.62.46) I'm trying to compile R on a Solaris machine. The default C compiler is cc (although gcc is available) and the default Fortran compiler is f95 (although g77 is available). Without defining the F77 environment variable, configure defaults to f95 as a Fortran compiler and eventually fails with the following output: --------------------------------- checking whether mixed C/Fortran code can be run... configure: WARNING: cannot run mixed C/Fortan code configure: error: Maybe check LDFLAGS for paths to Fortran libraries? --------------------------------- Setting LDFLAGS to the path where the Fortran libraries sit makes the C compiler complain. If I give the value g77 (or the full path to g77) to F77, there are two interesting issues: 1) ------------------------- defining F77 to be g77 checking whether we are using the GNU Fortran 77 compiler... no checking whether g77 accepts -g... yes ------------------------- Why does configure think we are not using the GNU Fortran 77 compiler? But more importantly 2) ------------------------------------- checking how to get verbose linking output from g77... configure: WARNING: compilation failed checking for Fortran libraries of g77... checking how to get verbose linking output from cc... -### checking for C libraries of cc... -L/usr/local/lib -lthread checking for dummy main to link with Fortran libraries... none checking for Fortran name-mangling scheme... configure: error: cannot compile a simple Fortran program ------------------------------------- I tried to compile a simple "Hello World" program with either Fortran compiler and both work without a problem.