[MacPorts] #40003: wgrib2: build fails when nonexistent universal variant is selected

MacPorts noreply at macports.org
Sun Aug 4 16:45:27 PDT 2013


#40003: wgrib2: build fails when nonexistent universal variant is selected
--------------------------+-----------------------
 Reporter:  ryandesign@…  |      Owner:  takeshi@…
     Type:  defect        |     Status:  new
 Priority:  Normal        |  Milestone:
Component:  ports         |    Version:  2.2.0
 Keywords:  haspatch      |       Port:  wgrib2
--------------------------+-----------------------
 The wgrib2 port advertises no universal variant:

 {{{
 $ port variants wgrib2
 wgrib2 has the variants:
    g95: build iplib with g95 (alpha)
      * conflicts with gcc44 gcc45 gcc46 gcc47 gcc48
    gcc44: build iplib with gcc44 (alpha)
      * conflicts with g95 gcc45 gcc46 gcc47 gcc48
    gcc45: build iplib with gcc45 (alpha)
      * conflicts with g95 gcc44 gcc46 gcc47 gcc48
    gcc46: build iplib with gcc46 (alpha)
      * conflicts with g95 gcc44 gcc45 gcc47 gcc48
    gcc47: build iplib with gcc47 (alpha)
      * conflicts with g95 gcc44 gcc45 gcc46 gcc48
    gcc48: build iplib with gcc48 (alpha)
      * conflicts with g95 gcc44 gcc45 gcc46 gcc47 gcc48
 }}}

 Nevertheless the port tries to build universal when I select the
 (nonexistent) universal variant, and then fails:

 {{{
 ld: warning: ignoring file
 /opt/local/var/macports/build/_Users_rschmidt_macports_dports_science_wgrib2/wgrib2/work/grib2/g2clib-1.4.0/libgrib2c.a,
 file was built for archive which is not the architecture being linked
 (x86_64):
 /opt/local/var/macports/build/_Users_rschmidt_macports_dports_science_wgrib2/wgrib2/work/grib2/g2clib-1.4.0/libgrib2c.a
 Undefined symbols for architecture x86_64:
   "_dec_png", referenced from:
       _unpk_grib in unpk.o
   "_enc_jpeg2000", referenced from:
       _jpeg2000_grib_out in jpeg_pk.o
   "_g2_free", referenced from:
       _main in wgrib2.o
   "_g2_getfld", referenced from:
       _main in wgrib2.o
   "_g2_unpack3", referenced from:
       _f_gdt in GDT.o
 ld: symbol(s) not found for architecture x86_64
 clang: error: linker command failed with exit code 1 (use -v to see
 invocation)
 }}}

 Either add a functional universal variant (perhaps with the help of the
 muniversal portgroup or patches to the build system) or remove the parts
 of the portfile that react to the universal variant selector. The attached
 patch does the latter (and also fixes a problem where the build wasn't
 using `-arch` flags when calling the linker).

-- 
Ticket URL: <https://trac.macports.org/ticket/40003>
MacPorts <http://www.macports.org/>
Ports system for OS X


More information about the macports-tickets mailing list