summaryrefslogtreecommitdiff
path: root/scripts/build/binutils/binutils.sh
diff options
context:
space:
mode:
authorAlexey Neyman <stilor@att.net>2017-05-30 05:32:38 (GMT)
committerAlexey Neyman <stilor@att.net>2017-07-08 17:57:56 (GMT)
commit567277099a487508fd228a4c56f3583db3fa96c9 (patch)
tree19b7f40c0f6e4e6284e799dbac1098bd8805dc2d /scripts/build/binutils/binutils.sh
parent57426168ad2c7e8367786ed466c86f6aeb49b3c3 (diff)
Fix the references to old config variables
Signed-off-by: Alexey Neyman <stilor@att.net>
Diffstat (limited to 'scripts/build/binutils/binutils.sh')
-rw-r--r--scripts/build/binutils/binutils.sh44
1 files changed, 9 insertions, 35 deletions
diff --git a/scripts/build/binutils/binutils.sh b/scripts/build/binutils/binutils.sh
index f378b4f..74139bc 100644
--- a/scripts/build/binutils/binutils.sh
+++ b/scripts/build/binutils/binutils.sh
@@ -4,44 +4,18 @@
# Download binutils
do_binutils_get() {
- if [ "${CT_BINUTILS_CUSTOM}" = "y" ]; then
- CT_GetCustom "binutils" "${CT_BINUTILS_CUSTOM_VERSION}" \
- "${CT_BINUTILS_CUSTOM_LOCATION}"
- else
- case "${CT_BINUTILS_VERSION}" in
- linaro-*)
- CT_GetLinaro "binutils" "${CT_BINUTILS_VERSION}"
- ;;
- *)
- CT_GetFile "binutils-${CT_BINUTILS_VERSION}" \
- {http,ftp}://{ftp.gnu.org/gnu,ftp.kernel.org/pub/linux/devel}/binutils \
- ftp://{sourceware.org,gcc.gnu.org}/pub/binutils/{releases,snapshots}
- ;;
- esac
- fi
-
+ CT_Fetch BINUTILS
if [ -n "${CT_ARCH_BINFMT_FLAT}" ]; then
- if [ "${CT_ELF2FLT_CUSTOM}" = "y" ]; then
- CT_GetCustom "elf2flt" "${CT_ELF2FLT_CUSTOM_VERSION}" \
- "${CT_ELF2FLT_CUSTOM_LOCATION}"
- else
- CT_GetGit elf2flt "${CT_ELF2FLT_GIT_CSET}" https://github.com/uclinux-dev/elf2flt.git
- fi
+ CT_Fetch ELF2FLT
fi
}
# Extract binutils
do_binutils_extract() {
- CT_Extract "binutils-${CT_BINUTILS_VERSION}"
- CT_Patch "binutils" "${CT_BINUTILS_VERSION}"
-
+ # TBD handle xtensa overlays in CT_ExtractPatch
+ CT_ExtractPatch BINUTILS
if [ -n "${CT_ARCH_BINFMT_FLAT}" ]; then
- CT_Extract "elf2flt-${CT_ELF2FLT_GIT_CSET}"
- CT_Patch "elf2flt" "${CT_ELF2FLT_GIT_CSET}"
- fi
-
- if [ -n "${CT_ARCH_XTENSA_CUSTOM_NAME}" ]; then
- CT_ConfigureXtensa "binutils" "${CT_BINUTILS_VERSION}"
+ CT_ExtractPatch ELF2FLT
fi
}
@@ -67,7 +41,7 @@ do_binutils_for_build() {
if [ -n "${CT_ARCH_BINFMT_FLAT}" ]; then
# We re-use binutils' options, plus our owns
- binutils_opts+=( "binutils_src=${CT_SRC_DIR}/binutils-${CT_BINUTILS_VERSION}" )
+ binutils_opts+=( "binutils_src=${CT_SRC_DIR}/binutils" )
binutils_opts+=( "binutils_bld=${CT_BUILD_DIR}/build-binutils-build-${CT_BUILD}" )
CT_mkdir_pushd "${CT_BUILD_DIR}/build-elf2flt-build-${CT_BUILD}"
@@ -100,7 +74,7 @@ do_binutils_for_host() {
if [ -n "${CT_ARCH_BINFMT_FLAT}" ]; then
# We re-use binutils' options, plus our owns
- binutils_opts+=( "binutils_src=${CT_SRC_DIR}/binutils-${CT_BINUTILS_VERSION}" )
+ binutils_opts+=( "binutils_src=${CT_SRC_DIR}/binutils" )
binutils_opts+=( "binutils_bld=${CT_BUILD_DIR}/build-binutils-host-${CT_HOST}" )
CT_mkdir_pushd "${CT_BUILD_DIR}/build-elf2flt-host-${CT_HOST}"
@@ -207,7 +181,7 @@ do_binutils_backend() {
CXXFLAGS="${cflags}" \
LDFLAGS="${ldflags}" \
${CONFIG_SHELL} \
- "${CT_SRC_DIR}/binutils-${CT_BINUTILS_VERSION}/configure" \
+ "${CT_SRC_DIR}/binutils/configure" \
--build=${CT_BUILD} \
--host=${host} \
--target=${CT_TARGET} \
@@ -351,7 +325,7 @@ do_binutils_for_target() {
CT_DoExecLog CFG \
${CONFIG_SHELL} \
- "${CT_SRC_DIR}/binutils-${CT_BINUTILS_VERSION}/configure" \
+ "${CT_SRC_DIR}/binutils/configure" \
--build=${CT_BUILD} \
--host=${CT_TARGET} \
--target=${CT_TARGET} \