[MacPorts] #36667: HandBrakeCLI @0.10.0_0: cannot link to libiconv

MacPorts noreply at macports.org
Thu Dec 6 02:15:15 UTC 2018


#36667: HandBrakeCLI @0.10.0_0: cannot link to libiconv
---------------------------+-------------------------
  Reporter:  stanimura     |      Owner:  larryv
      Type:  defect        |     Status:  assigned
  Priority:  Normal        |  Milestone:
 Component:  ports         |    Version:  2.1.2
Resolution:                |   Keywords:  snowleopard
      Port:  HandBrakeCLI  |
---------------------------+-------------------------

Comment (by kencu):

 {{{
 /Developer/usr/bin/g++-4.2 -arch x86_64 -isysroot
 /Developer/SDKs/MacOSX10.6.sdk
 -L/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_multimedia_HandBrake/HandBrakeCLI/work/HandBrake-0.10.0/build/xroot
 -L/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_multimedia_HandBrake/HandBrakeCLI/work/HandBrake-0.10.0/build/libhb
 -L/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_multimedia_HandBrake/HandBrakeCLI/work/HandBrake-0.10.0/build/contrib/lib
 -F/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_multimedia_HandBrake/HandBrakeCLI/work/HandBrake-0.10.0/build/xroot
 -filelist
 /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_multimedia_HandBrake/HandBrakeCLI/work/HandBrake-0.10.0/build/xroot/HandBrakeCLI.build
 /Objects-normal/x86_64/HandBrakeCLI.LinkFileList -mmacosx-version-min=10.6
 -filelist
 /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_multimedia_HandBrake/HandBrakeCLI/work/HandBrake-0.10.0/build/macosx/osl.filelist.txt
 -framework AudioToolbox -framework CoreServices -framework IOKit -lbz2
 -liconv -lz -lhandbrake -lass -lavcodec -lavformat -lavresample -lavutil
 -lbluray -ldvdnav -ldvdread -lfontconfig -lfreetype -lfribidi -lmp3lame
 -logg -lsamplerate -lswscale -ltheora -lvorbis -lvorbisenc -lvpx -lx264
 -lxml2 -prebind -o
 /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_multimedia_HandBrake/HandBrakeCLI/work/HandBrake-0.10.0/build/xroot/HandBrakeCLI

 Undefined symbols:
   "_libiconv_close", referenced from:
       _decsrtClose in libhandbrake.a(decsrtsub.o)
   "_x264_encoder_open_142", referenced from:
       _encx264Init in libhandbrake.a(encx264.o)
   "_libiconv", referenced from:
       _decsrtWork in libhandbrake.a(decsrtsub.o)
   "_libiconv_open", referenced from:
       _decsrtInit in libhandbrake.a(decsrtsub.o)
 ld: symbol(s) not found
 collect2: ld returned 1 exit status
 ** BUILD FAILED **
 }}}

 this error on 10.6.8 occurs because xcodebuild is trying link against the
 libiconv.dylib in the SDK
 {{{
 $ nm libiconv.dylib | grep close
                  U _fclose
 000000000000bd17 T _iconv_close
 }}}
 instead of the one in `/opt/local/lib'
 {{{
 $ nm libiconv.dylib | grep close
 000000000000c927 T _libiconv_close
 }}}
 So xcodebuild has to be forced to use the link libraries in /opt/local/lib
 preferentially, and fall back to the SDK.

-- 
Ticket URL: <https://trac.macports.org/ticket/36667#comment:17>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list