Ignore:
Timestamp:
Jan 16, 2015, 9:20:12 PM (4 years ago)
Author:
dstrubbe@…
Message:

compilers PortGroup: Use variables to allow switching the meaning of +gfortran comprehensively with just one line, to avoid confusion such as that fixed in r131737.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dports/_resources/port1.0/group/compilers-1.0.tcl

    r131737 r131739  
    132132# and lastly we add a gfortran and g95 variant for use with clang*; note that
    133133# we don't need gfortran when we are in an "only-fortran" mode
     134set gfortran_equiv gcc49
    134135set cdb(gfortran,variant)  gfortran
    135 set cdb(gfortran,compiler) gfortran
    136 set cdb(gfortran,descrip)  "Fortran compiler from gcc49"
    137 set cdb(gfortran,depends)  port:gcc49
    138 set cdb(gfortran,dependsl) path:lib/libgcc/libgcc_s.1.dylib:libgcc
    139 set cdb(gfortran,dependsd) ""
    140 set cdb(gfortran,dependsa) ""
    141 set cdb(gfortran,conflict) ""
    142 set cdb(gfortran,cc)       ""
    143 set cdb(gfortran,cxx)      ""
    144 set cdb(gfortran,cpp)      ""
    145 set cdb(gfortran,objc)     ""
    146 set cdb(gfortran,fc)       ${prefix}/bin/gfortran-mp-4.9
    147 set cdb(gfortran,f77)      ${prefix}/bin/gfortran-mp-4.9
    148 set cdb(gfortran,f90)      ${prefix}/bin/gfortran-mp-4.9
     136set cdb(gfortran,compiler) $cdb($gfortran_equiv,compiler)
     137set cdb(gfortran,descrip)  $cdb($gfortran_equiv,descrip)
     138set cdb(gfortran,depends)  $cdb($gfortran_equiv,depends)
     139set cdb(gfortran,dependsl) $cdb($gfortran_equiv,dependsl)
     140set cdb(gfortran,dependsd) $cdb($gfortran_equiv,dependsd)
     141set cdb(gfortran,dependsa) $cdb($gfortran_equiv,dependsa)
     142set cdb(gfortran,conflict) $cdb($gfortran_equiv,conflict)
     143set cdb(gfortran,cc)       $cdb($gfortran_equiv,cc)
     144set cdb(gfortran,cxx)      $cdb($gfortran_equiv,cxx)
     145set cdb(gfortran,cpp)      $cdb($gfortran_equiv,cpp)
     146set cdb(gfortran,objc)     $cdb($gfortran_equiv,objc)
     147set cdb(gfortran,fc)       $cdb($gfortran_equiv,fc)
     148set cdb(gfortran,f77)      $cdb($gfortran_equiv,f77)
     149set cdb(gfortran,f90)      $cdb($gfortran_equiv,f90)
    149150
    150151set cdb(g95,variant)  g95
     
    451452            set myf  [fortran_variant_name]
    452453
    453             # gfortran is nothing more than the fortran compiler from gcc49
     454            # gfortran is nothing more than the fortran compiler from a default version of gcc
    454455            set equiv 0
    455             if {($otf eq "gcc49" || $otf eq "gfortran") && ($myf eq "gcc49" || $myf eq "gfortran")} {
     456            if {($otf eq $gfortran_equiv || $otf eq "gfortran") && ($myf eq $gfortran_equiv || $myf eq "gfortran")} {
    456457                set equiv 1
    457458            }
Note: See TracChangeset for help on using the changeset viewer.