[MacPorts] #70386: glib2 @2.78.4_0+x11: ld: unknown option: -export_dynamic

MacPorts noreply at macports.org
Wed Jul 17 09:28:46 UTC 2024


#70386: glib2 @2.78.4_0+x11: ld: unknown option: -export_dynamic
-------------------------------+--------------------
 Reporter:  nathanpc           |      Owner:  (none)
     Type:  defect             |     Status:  new
 Priority:  Normal             |  Milestone:
Component:  ports              |    Version:  2.9.3
 Keywords:  leopard ppc64 ppc  |       Port:  glib2
-------------------------------+--------------------
 While trying to upgrade all the outdated packages in my Power Mac G5
 running Mac OS X 10.5.8 Leopard, I wasn't able to proceed due to a build
 error in the `glib2` package. Since this is quite an important package I'm
 a bit worried. I've also attached the build logs, but the crucial part is
 this:

 {{{
 :debug:build system:  cd
 "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_devel_glib2/glib2/work/build"
 && /opt/local/bin/ninja -j2 --verbose -v
 :info:build [1/268] /opt/local/bin/gcc-mp-7  -o gmodule/tests/module-test-
 library gmodule/tests/module-test-library.p/module-test.c.o
 -L/opt/local/lib -I/opt/local/include -Wl,-dead_strip_dylibs
 -Wl,-headerpad_max_install_names -Wl,-export_dynamic
 -Wl,-headerpad_max_install_names -lresolv -bind_at_load
 -lMacportsLegacySupport -arch ppc -pipe -Os -Wno-deprecated-declarations
 -arch ppc -Wl,-rpath, at loader_path/../../glib -Wl,-rpath, at loader_path/..
 glib/libglib-2.0.0.dylib gmodule/libgmodule-2.0.0.dylib -lm -lintl
 :info:build FAILED: gmodule/tests/module-test-library
 :info:build /opt/local/bin/gcc-mp-7  -o gmodule/tests/module-test-library
 gmodule/tests/module-test-library.p/module-test.c.o -L/opt/local/lib
 -I/opt/local/include -Wl,-dead_strip_dylibs
 -Wl,-headerpad_max_install_names -Wl,-export_dynamic
 -Wl,-headerpad_max_install_names -lresolv -bind_at_load
 -lMacportsLegacySupport -arch ppc -pipe -Os -Wno-deprecated-declarations
 -arch ppc -Wl,-rpath, at loader_path/../../glib -Wl,-rpath, at loader_path/..
 glib/libglib-2.0.0.dylib gmodule/libgmodule-2.0.0.dylib -lm -lintl
 :info:build ld: unknown option: -export_dynamic
 :info:build collect2: error: ld returned 1 exit status
 :info:build [2/268] /opt/local/bin/gcc-mp-7  -o gmodule/tests/module-test-
 plugin gmodule/tests/module-test-plugin.p/module-test.c.o -L/opt/local/lib
 -I/opt/local/include -Wl,-dead_strip_dylibs
 -Wl,-headerpad_max_install_names -Wl,-export_dynamic
 -Wl,-headerpad_max_install_names -lresolv -bind_at_load
 -lMacportsLegacySupport -arch ppc -pipe -Os -Wno-deprecated-declarations
 -arch ppc -Wl,-rpath, at loader_path/../../glib -Wl,-rpath, at loader_path/..
 glib/libglib-2.0.0.dylib gmodule/libgmodule-2.0.0.dylib -lm -lintl
 :info:build FAILED: gmodule/tests/module-test-plugin
 :info:build /opt/local/bin/gcc-mp-7  -o gmodule/tests/module-test-plugin
 gmodule/tests/module-test-plugin.p/module-test.c.o -L/opt/local/lib
 -I/opt/local/include -Wl,-dead_strip_dylibs
 -Wl,-headerpad_max_install_names -Wl,-export_dynamic
 -Wl,-headerpad_max_install_names -lresolv -bind_at_load
 -lMacportsLegacySupport -arch ppc -pipe -Os -Wno-deprecated-declarations
 -arch ppc -Wl,-rpath, at loader_path/../../glib -Wl,-rpath, at loader_path/..
 glib/libglib-2.0.0.dylib gmodule/libgmodule-2.0.0.dylib -lm -lintl
 :info:build ld: unknown option: -export_dynamic
 :info:build collect2: error: ld returned 1 exit status
 :info:build ninja: build stopped: subcommand failed.
 }}}

 I was able to find a related ticket:53150, which led me to do the
 following operation in order to try and fix this:

 {{{
 $ /opt/local/bin/ld -v
 @(#)PROGRAM:ld  PROJECT:ld64-97.17
 configured to support archs: i386 x86_64 ppc ppc64 armv6 armv7
 LTO support using: LLVM version 3.3
 $ sudo port -v -f deactivate ld64
 --->  Unable to deactivate ld64 @3_6+ld64_97, the following ports depend
 on it:
 --->    gcc7 @7.5.0_4
 Warning: Deactivate forced.  Proceeding despite dependencies.
 --->  Deactivating ld64 @3_6+ld64_97
 --->  Cleaning ld64
 --->  Removing work directory for ld64
 $ sudo port -v install ld64 -ld64_97
 --->  Computing dependencies for ld64.Warning: All compilers are either
 blacklisted or unavailable; defaulting to first fallback option
 .
 Error: Cannot install ld64-latest for the arch 'powerpc' because
 Error: its dependency libtapi does not build for the required arch by
 default
 Error: and the configured universal_archs 'i386 ppc' are not sufficient.
 Error: Follow https://guide.macports.org/#project.tickets if you believe
 there is a bug.
 Error: Processing of port ld64 failed
 }}}

 What would be the next steps in order to resolve this issue?

-- 
Ticket URL: <https://trac.macports.org/ticket/70386>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list