library not found for -lgfortran

Mark Brethen mark.brethen at gmail.com
Tue Jul 8 17:40:48 PDT 2014


On Jul 8, 2014, at 6:31 PM, Mark Brethen <mark.brethen at gmail.com> wrote:

> 
> On Jul 8, 2014, at 11:56 AM, Sean Farley <sean at macports.org> wrote:
> 
>> +gfortran
> 
> I get this error:
> 
> Error: Unable to open port: no such compiler: +gfortran
> 
> Mark
> 
> 
> 
> 

Nevermind, can't use '+'.  I now have in the portfile

compilers.choose        gfortran
compilers.setup         require_fortran

if {![fortran_variant_isset]} {
    default_variants-append +gcc48
}

configure.ldflags-append "-L${prefix}/lib/gcc48 -lgfortran"


I did some digging in the freecad source and found this in 'CMakeLists';

################
# Check Fortran#
################
INCLUDE(CMakeDetermineFortranCompiler)

This module can be found in /opt/local/share/cmake-3.0/Modules

Not sure why it doesn't work. 

The c++ compiler is used for linking.



Mark






More information about the macports-dev mailing list