14.12.2011 10:36, Jędrzej Dudkiewicz kirjoitti:
Hi, I'm building gcc 4.6.2 (C and C++) on AIX 5.2 to compile for AIX 4.3.3. I copied libraries and /usr/ccs/bin (as, nm, ld and others) from 4.3.3 to sysroot/ directory on AIX 5.2. AS_FOR_TARGET=/home/jd/xcomp/sysroot/usr/ccs/bin/as \ LD_FOR_TARGET=/home/jd/xcomp/sysroot/usr/ccs/bin/ld \ STRIP_FOR_TARGET=/home/jd/xcomp/sysroot/usr/ccs/bin/strip \ RANLIB_FOR_TARGET=/home/jd/xcomp/sysroot/usr/ccs/bin/ranlib \ AR_FOR_TARGET=/home/jd/xcomp/sysroot/usr/ccs/bin/ar \ NM_FOR_TARGET=/home/jd/xcomp/sysroot/usr/ccs/bin/nm \
This makes the build to differ from the normal cross GCC case where GNU binutils are used as the target binutils. Here the native AIX 4.3.3 binutils are used on a AIX 5.2 cross host as the target binutils. So my stupid question is whether this choice should work at all?
--with-as=/home/jd/xcomp/sysroot/usr/ccs/bin/as \ --with-ld=/home/jd//xcomp/sysroot/usr/ccs/bin/ld \
These AIX 4.3.3 'as' and 'ld' seemingly don't crash on AIX 5.2 but :
/home/jd/xcomp/build/./gcc/xgcc -B/home/jd/xcomp/build/./gcc/ -B/opt/xgcc/gcc-4.6.2/powerpc-ibm-aix4.3.3.0/bin/ -B/opt/xgcc/gcc-4.6.2/powerpc-ibm-aix4.3.3.0/lib/ -isystem /opt/xgcc/gcc-4.6.2/powerpc-ibm-aix4.3.3.0/include -isystem /opt/xgcc/gcc-4.6.2/powerpc-ibm-aix4.3.3.0/sys-include --sysroot=/home/jd/xcomp/sysroot
what about the native AIX 4.3.3 'ld' understanding where the target library stuff is? What the libgcc configure understood about the target libraries? If behaving normally, building GNU binutils for the AIX 5.2 $host and targeting to the AIX 4.3.3 $target and configuring them using '--with-sysroot=' to search from $sysroot for the AIX 4.3.3, there wouldn't be these suspicicions and stupid questions... And any crash in the build would be a clear bug but it is hard to say what this case really is.