NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
re: toolchain/40170: gcc -m32 issues with NEEDED
The following reply was made to PR toolchain/40170; it has been noted by GNATS.
From: matthew green <mrg%eterna.com.au@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc: toolchain-manager%netbsd.org@localhost, gnats-admin%netbsd.org@localhost,
netbsd-bugs%netbsd.org@localhost
Subject: re: toolchain/40170: gcc -m32 issues with NEEDED
Date: Mon, 15 Dec 2008 12:35:12 +1100
this patch fixes half of the problem -- making ld have the right
SEARCH_DIRS for the 32 bit scripts. it's pretty ugly but i'm not
sure of a nicer way off hand.
it leaves the other half of the problem remaining, however, as
can be demonstrated by the pr40170.tar from jared.
.mrg.
Index: gnu/usr.bin/binutils/ld/Makefile
===================================================================
RCS file: /cvsroot/src/gnu/usr.bin/binutils/ld/Makefile,v
retrieving revision 1.27
diff -p -r1.27 Makefile
*** Makefile 13 Oct 2008 22:36:55 -0000 1.27
--- Makefile 15 Dec 2008 01:32:24 -0000
*************** ${PROG}.info: configdoc.texi
*** 74,86 ****
DPSRCS+= .depend.${f} e${f}.c
CLEANFILES+= .depend.${f} e${f}.c
e${f}.c: ${DIST}/ld/genscripts.sh ${.CURDIR}/Makefile stringify.sed
${_MKTARGET_CREATE}
unset MACHINE || true; \
! LIB_PATH=/usr/lib
${HOST_SH} ${DIST}/ld/genscripts.sh ${DIST}/ld ${LIBDIR} "/usr"
\
${G_target_alias} ${G_target_alias} ${G_target_alias} \
! ${G_EMUL} ${LIBDIR} no ${f} "${G_target_alias}"
.if ${MACHINE_ARCH} == "x86_64" || ${MACHINE_ARCH} == "sparc64"
FILES+= ${f}.x ${f}.xbn ${f}.xn ${f}.xr ${f}.xu
--- 74,97 ----
DPSRCS+= .depend.${f} e${f}.c
CLEANFILES+= .depend.${f} e${f}.c
+ EMUL_LIB_PATH:=/usr/lib
+ # XXX super hack
+ . if (${MACHINE_ARCH} == "x86_64" && \
+ (${f} == "elf_i386" || ${f} == "i386nbsd"))
+ EMUL_LIB_PATH:=/usr/lib/i386
+ . endif
+ . if (${MACHINE_ARCH} == "sparc64" && \
+ (${f} == "elf32_sparc " || ${f} == "sparcnbsd"))
+ EMUL_LIB_PATH:=/usr/lib/sparc
+ . endif
+
e${f}.c: ${DIST}/ld/genscripts.sh ${.CURDIR}/Makefile stringify.sed
${_MKTARGET_CREATE}
unset MACHINE || true; \
! LIB_PATH=${EMUL_LIB_PATH} \
${HOST_SH} ${DIST}/ld/genscripts.sh ${DIST}/ld ${LIBDIR} "/usr"
\
${G_target_alias} ${G_target_alias} ${G_target_alias} \
! ${G_EMUL} ${LIBDIR} yes ${f} "${G_target_alias}"
.if ${MACHINE_ARCH} == "x86_64" || ${MACHINE_ARCH} == "sparc64"
FILES+= ${f}.x ${f}.xbn ${f}.xn ${f}.xr ${f}.xu
Home |
Main Index |
Thread Index |
Old Index