summaryrefslogtreecommitdiffstats
path: root/build
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2012-11-12 20:08:43 (EST)
committer P. J. McDermott <pjm@nac.net>2012-11-12 20:08:43 (EST)
commitb58571165cded4daad6ccbc4f8055212e2b38a67 (patch)
tree607ef0d9eb8548272bea3588895eb247c8dfc622 /build
parent8ff195bf413d6ef55b3a4892629ac0f1fd076c79 (diff)
ldscripts are host- and target-arch specific.
Diffstat (limited to 'build')
-rwxr-xr-xbuild9
1 files changed, 6 insertions, 3 deletions
diff --git a/build b/build
index 3810319..f9c9ca6 100755
--- a/build
+++ b/build
@@ -76,14 +76,17 @@ build: configure
install: build
# Install everything.
# * scriptdir contains target ldscripts.
- # * ldscripts should be independent of the host architecture and therefore
- # coinstallable with themselves across host architectures (I hope).
+ # * ldscripts are specific to both the host and target architectures.
+ # - If host != target, only target-specific paths are passed as
+ # arguments to SEARCH_DIR commands in ldscripts. (See the LIB_PATH
+ # stuff in the "configure" target above.)
# * All of these macro settings are effective thanks to
# `patches/01_pass-some-dirs-to-child-makes.patch`.
for target in $$(cat ../targets); do \
oh-autoinstall -B "build-$${target}" -d "binutils-$${target}.data" \
CFLAGS='$(CFLAGS)' \
- tooldir='/usr/tool' scriptdir="/usr/lib/$${target}" \
+ tooldir='/usr/tool' \
+ scriptdir="/usr/lib/$(OPK_HOST_ARCH)/$${target}" \
bfdlibdir="/usr/lib/$(OPK_HOST_ARCH)/$${target}" \
bfdincludedir="/usr/include/$(OPK_HOST_ARCH)/$${target}" || \
exit 1; \