[MacPorts] #36026: gcc46 problem after ld64 upgrade
MacPorts
noreply at macports.org
Sat Sep 15 18:30:27 PDT 2012
#36026: gcc46 problem after ld64 upgrade
-------------------------+------------------------
Reporter: jwhowse4@… | Owner: jeremyhu@…
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.1.2
Resolution: | Keywords:
Port: ld64 |
-------------------------+------------------------
Comment (by jwhowse4@…):
As an experiment I created a new MacPorts installation in addition to my
existing one. I did this in order to obtain a fresh MacPorts installation
with no other packages installed. I then performed the following two
experiments.
{{{
EXPERIMENT #1
tar xvjf MacPorts-2.1.2.tar.bz2
cd MacPorts-2.1.2
setenv PATH /usr/bin:/usr/sbin:/bin:/sbin:/usr/X11/bin:/usr/texbin
./configure --prefix=/opt/macports-test --with-applications-dir=/opt
/macports-test
make
make install
setenv PATH /opt/macports-test/bin:/opt/macports-
test/sbin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/X11/bin:/usr/texbin
port -v selfupdate
port -v install libffi
port -v install llvm_select
port -v install cctools-headers
port -v install dyld-headers
port -v install libunwind-headers
port -v install perl5 +perl5_12
port -v install llvm-3.1
port -v install ld64 +llvm31
}}}
The linker ld from experiment #1 successfully creates executables for my
example program using the gcc46 from my original MacPorts installation. I
then removed the entire directory macports-test and performed the second
experiment.
{{{
EXPERIMENT #2
tar xvjf MacPorts-2.1.2.tar.bz2
cd MacPorts-2.1.2
setenv PATH /usr/bin:/usr/sbin:/bin:/sbin:/usr/X11/bin:/usr/texbin
./configure --prefix=/opt/macports-test --with-applications-dir=/opt
/macports-test
make
make install
setenv PATH /opt/macports-test/bin:/opt/macports-
test/sbin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/X11/bin:/usr/texbin
port -v selfupdate
port -v install perl5 +perl5_12
port -v install libffi
port -v install llvm_select
port -v install cctools-headers
port -v install dyld-headers
port -v install libunwind-headers
port -v install llvm-3.1
port -v install ld64 +llvm31
}}}
The linker ld from experiment #2 fails to create executables for my
example program using the gcc46 from my original MacPorts installation
with the following familiar error message.
{{{
ld: warning: ignoring file test.o, file was built for unsupported file
format ( 0xcf 0xfa 0xed 0xfe 0x 7 0x 0 0x 0 0x 1 0x 3 0x 0 0x 0 0x 0 0x 1
0x 0 0x 0 0x 0 ) which is not the architecture being linked (x86_64):
test.o
ld: file is universal (2 slices) but does not contain a(n) x86_64 slice:
/usr/lib/crt1.10.5.o for architecture x86_64
collect2: ld returned 1 exit status
}}}
I have no idea why this seemingly minor change in the order in which
packages are installed changes the outcome, but I have attached the
linkers generated by these two experiments in the hope that they will be
useful. If you need any other information, please let me know.
--
Ticket URL: <https://trac.macports.org/ticket/36026#comment:48>
MacPorts <http://www.macports.org/>
Ports system for Mac OS
More information about the macports-tickets
mailing list