Ticket #38271: Portfile.diff

File Portfile.diff, 815 bytes (added by daitakahashi, 11 years ago)

disable AVX to enable optimized build on newer machines

  • Portfile

     
    8585}
    8686
    8787platform darwin i386 {
    88     if { [variant_isset optimize] && ( [variant_isset gcc43] || [variant_isset gcc44] || [variant_isset gcc45] || [variant_isset gcc46] || [variant_isset gcc47] ) } {
    89         configure.cflags-append "-march=native"
     88    if { [variant_isset optimize] } {
     89        if { [variant_isset gcc43] } {
     90            configure.cflags-append "-march=native"
     91        } elseif { [variant_isset gcc44] || [variant_isset gcc45] || [variant_isset gcc46] || [variant_isset gcc47] } {
     92            # Currently, gcc cannot compile AVX instructions on OSX
     93            configure.cflags-append "-march=native -mno-avx"
     94        }
    9095    }
    9196}
    9297