summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexey Neyman <stilor@att.net>2016-12-16 23:56:32 (GMT)
committerAlexey Neyman <stilor@att.net>2017-01-10 18:38:08 (GMT)
commit1f84e9caf4f0a0d7c362b108d3c303078c1bbe97 (patch)
tree8d3f2725e90bdca4d0d25f1cb245a1acc537215d
parent8e7ac5fcd94d68cdd7cc7ad4638bdc0e48e9baf5 (diff)
Point FOR_BUILD flags to buildtools/{include,lib}.
Similarly to FOR_HOST; recent change in 100-gcc.sh that switched FOR_HOST->FOR_BUILD broke simple cross configurations on macos. Signed-off-by: Alexey Neyman <stilor@att.net>
-rw-r--r--scripts/crosstool-NG.sh.in11
1 files changed, 6 insertions, 5 deletions
diff --git a/scripts/crosstool-NG.sh.in b/scripts/crosstool-NG.sh.in
index bbefb1f..5037c86 100644
--- a/scripts/crosstool-NG.sh.in
+++ b/scripts/crosstool-NG.sh.in
@@ -478,21 +478,22 @@ if [ -z "${CT_RESTART}" ]; then
# Help build gcc
# Explicitly optimise, else the lines below will overide the
# package's default optimisation flags
- CT_CFLAGS_FOR_BUILD="-O2 -g"
+ CT_CFLAGS_FOR_BUILD="-O2 -g -I${CT_BUILDTOOLS_PREFIX_DIR}/include"
CT_CFLAGS_FOR_BUILD+=" ${CT_EXTRA_CFLAGS_FOR_BUILD}"
- CT_LDFLAGS_FOR_BUILD=
+ CT_LDFLAGS_FOR_BUILD="-L${CT_BUILDTOOLS_PREFIX_DIR}/lib"
CT_LDFLAGS_FOR_BUILD+=" ${CT_EXTRA_LDFLAGS_FOR_BUILD}"
+ CT_DoLog DEBUG "CFLAGS for build compiler: '${CT_CFLAGS_FOR_BUILD}'"
+ CT_DoLog DEBUG "LDFLAGS for build compiler: '${CT_LDFLAGS_FOR_BUILD}'"
# Help host gcc
# Explicitly optimise, else the lines below will overide the
# package's default optimisation flags
CT_CFLAGS_FOR_HOST="-O2 -g"
[ "${CT_USE_PIPES}" = "y" ] && CT_CFLAGS_FOR_HOST+=" -pipe"
+ CT_CFLAGS_FOR_HOST+=" -I${CT_HOST_COMPLIBS_DIR}/include"
CT_CFLAGS_FOR_HOST+=" ${CT_EXTRA_CFLAGS_FOR_HOST}"
- CT_LDFLAGS_FOR_HOST=
+ CT_LDFLAGS_FOR_HOST="-L${CT_HOST_COMPLIBS_DIR}/lib"
CT_LDFLAGS_FOR_HOST+=" ${CT_EXTRA_LDFLAGS_FOR_HOST}"
- CT_CFLAGS_FOR_HOST+=" -I${CT_HOST_COMPLIBS_DIR}/include"
- CT_LDFLAGS_FOR_HOST+=" -L${CT_HOST_COMPLIBS_DIR}/lib"
CT_DoLog DEBUG "CFLAGS for host compiler: '${CT_CFLAGS_FOR_HOST}'"
CT_DoLog DEBUG "LDFLAGS for host compiler: '${CT_LDFLAGS_FOR_HOST}'"