Ticket #34297 (closed defect: fixed)
ld64: /usr/bin/ld: unknown flag: -exported_symbol
| Reported by: | ryandesign@… | Owned by: | jeremyhu@… |
|---|---|---|---|
| Priority: | Normal | Milestone: | |
| Component: | ports | Version: | 2.0.4 |
| Keywords: | tiger powerpc | Cc: | interface@… |
| Port: | ld64 |
Description
I can't build ld64 97.17 on Tiger ppc. It says:
make: Entering directory `/mp/var/macports/build/_Volumes_data_macports_ports_devel_ld64/ld64/work/ld64-97.17' /mp/bin/g++-apple-4.2 -Os -O2 -arch ppc -Isrc/abstraction -Isrc/ld -I/mp/include -c -o src/other/ObjectDump.o src/other/ObjectDump.cpp /mp/bin/gcc-apple-4.2 -Os -O2 -arch ppc -Isrc/abstraction -Isrc/ld -I/mp/include -c -o src/ld/debugline.o src/ld/debugline.c /mp/bin/g++-apple-4.2 -L/mp/lib -arch ppc src/other/ObjectDump.o src/ld/debugline.o -o ObjectDump /usr/bin/ld: warning multiple definitions of symbol _atexit /mp/lib/apple-gcc42/gcc/powerpc-apple-darwin8/4.2.1/crt3.o private external definition of _atexit in section (__TEXT,__text) /usr/lib/libSystem.dylib(atexit.So) definition of _atexit /usr/bin/ld: warning multiple definitions of symbol ___cxa_atexit /mp/lib/apple-gcc42/gcc/powerpc-apple-darwin8/4.2.1/crt3.o private external definition of ___cxa_atexit in section (__TEXT,__text) /usr/lib/libSystem.dylib(atexit.So) definition of ___cxa_atexit /mp/bin/g++-apple-4.2 -Os -O2 -arch ppc -Isrc/abstraction -Isrc/ld -I/mp/include -c -o src/other/dyldinfo.o src/other/dyldinfo.cpp /mp/bin/g++-apple-4.2 -L/mp/lib -arch ppc -Wl,-exported_symbol,__mh_execute_header src/other/dyldinfo.o -o dyldinfo /usr/bin/ld: unknown flag: -exported_symbol
Attachments
Change History
comment:1 Changed 14 months ago by ryandesign@…
In fact I have a previous version installed, ld64 @62.1_4; if I try to upgrade while that version is active, then the error is:
ld64-62.1 failed: unknown option: -exported_symbol
comment:4 Changed 13 months ago by jeremyhu@…
- Status changed from new to assigned
Install the ld64 port.
I welcome testing of the apple-gcc42 port in my overlay, which should take care of this issue without breaking Tiger:
comment:5 Changed 13 months ago by jeremyhu@…
Oh wait... this is in building ld64...
chicken, meet egg... crap...
comment:6 Changed 13 months ago by jeremyhu@…
Please give this a try:
Index: Portfile
===================================================================
--- Portfile (revision 92790)
+++ Portfile (working copy)
@@ -92,6 +92,11 @@
}
}
}
+
+ post-patch {
+ reinplace "s:-Wl,-exported_symbol,__mh_execute_header::g" \
+ ${worksrcpath}/Makefile
+ }
}
if {${configure.compiler} == "gcc-4.0"} {
Note: See
TracTickets for help on using
tickets.

