mirror of
https://github.com/crosstool-ng/crosstool-ng.git
synced 2024-12-25 07:21:05 +00:00
45747a6453
- merge Linux and uClinux back to a single kernel - add ARCH_USE_MMU and acquainted config options that architectures can auto-select - make binutils and elf2flt two "Binary utilities" that go in a single common sub-{menu,directory} structure -------- diffstat follows -------- /trunk/scripts/build/kernel/uclinux.sh | 2 0 2 0 - /trunk/scripts/build/kernel/linux.sh | 206 204 2 0 +++++++++++++++++++++++++++++ /trunk/scripts/build/kernel/linux-common.sh | 198 0 198 0 ---------------------------- /trunk/scripts/build/binutils.sh | 232 0 232 0 -------------------------------- /trunk/scripts/build/elf2flt.sh | 150 0 150 0 --------------------- /trunk/scripts/crosstool-NG.sh.in | 6 4 2 0 + /trunk/config/kernel/linux.in | 249 249 0 0 +++++++++++++++++++++++++++++++++++ /trunk/config/kernel/linux.in-common | 252 0 252 0 ----------------------------------- /trunk/config/kernel/uclinux.in | 21 0 21 0 --- /trunk/config/target.in | 23 22 1 0 +++ /trunk/config/elf2flt.in | 49 0 49 0 ------- /trunk/config/libc/glibc.in | 2 1 1 0 /trunk/config/libc/eglibc.in | 2 1 1 0 /trunk/config/config.in | 1 0 1 0 - /trunk/config/arch/sh.in | 1 1 0 0 + /trunk/config/arch/arm.in | 2 1 1 0 /trunk/config/arch/powerpc.in | 1 1 0 0 + /trunk/config/arch/ia64.in | 1 1 0 0 + /trunk/config/arch/alpha.in | 1 1 0 0 + /trunk/config/arch/x86.in | 1 1 0 0 + /trunk/config/arch/mips.in | 1 1 0 0 + /trunk/config/arch/powerpc64.in | 1 1 0 0 + 22 files changed, 489 insertions(+), 913 deletions(-)
70 lines
2.8 KiB
Bash
70 lines
2.8 KiB
Bash
# This file adds functions to build elf2flt
|
|
# Copyright 2009 John Williams
|
|
# Copyright 2007 Yann E. MORIN
|
|
# Licensed under the GPL v2. See COPYING in the root of this package
|
|
|
|
# Download elf2flt
|
|
do_elf2flt_get() {
|
|
CT_GetCVS "elf2flt-cvs-${CT_ELF2FLT_VERSION}" \
|
|
":pserver:anonymous@cvs.uclinux.org:/var/cvs" \
|
|
"elf2flt" \
|
|
"" \
|
|
"elf2flt-cvs-${CT_ELF2FLT_VERSION}"
|
|
}
|
|
|
|
# Extract elf2flt
|
|
do_elf2flt_extract() {
|
|
CT_Extract "elf2flt-cvs-${CT_ELF2FLT_VERSION}"
|
|
CT_Patch "elf2flt-cvs-${CT_ELF2FLT_VERSION}"
|
|
}
|
|
|
|
# Build elf2flt
|
|
do_elf2flt() {
|
|
[ -z ${CT_KERNEL_UCLINUX_BINFMT_FLAT} ] && return 0
|
|
mkdir -p "${CT_BUILD_DIR}/build-elf2flt"
|
|
cd "${CT_BUILD_DIR}/build-elf2flt"
|
|
|
|
CT_DoStep INFO "Installing elf2flt"
|
|
|
|
elf2flt_opts=
|
|
binutils_bld=${CT_BUILD_DIR}/build-binutils
|
|
binutils_src=${CT_SRC_DIR}/binutils-${CT_BINUTILS_VERSION}
|
|
|
|
CT_DoLog EXTRA "Configuring elf2flt"
|
|
CFLAGS="${CT_CFLAGS_FOR_HOST}" \
|
|
CT_DoExecLog ALL \
|
|
"${CT_SRC_DIR}/elf2flt-cvs-${CT_ELF2FLT_VERSION}/configure" \
|
|
--build=${CT_BUILD} \
|
|
--host=${CT_HOST} \
|
|
--target=${CT_TARGET} \
|
|
--prefix=${CT_PREFIX_DIR} \
|
|
--with-bfd-include-dir=${binutils_bld}/bfd \
|
|
--with-binutils-include-dir=${binutils_src}/include \
|
|
--with-libbfd=${binutils_bld}/bfd/libbfd.a \
|
|
--with-libiberty=${binutils_bld}/libiberty/libiberty.a \
|
|
${elf2flt_opts} \
|
|
${CT_ELF2FLT_EXTRA_CONFIG}
|
|
|
|
CT_DoLog EXTRA "Building elf2flt"
|
|
CT_DoExecLog ALL make ${PARALLELMFLAGS}
|
|
|
|
CT_DoLog EXTRA "Installing elf2flt"
|
|
CT_DoExecLog ALL make install
|
|
|
|
# Make those new tools available to the core C compilers to come.
|
|
# Note: some components want the ${TARGET}-{ar,as,ld,strip} commands as
|
|
# well. Create that.
|
|
mkdir -p "${CT_CC_CORE_STATIC_PREFIX_DIR}/${CT_TARGET}/bin"
|
|
mkdir -p "${CT_CC_CORE_STATIC_PREFIX_DIR}/bin"
|
|
mkdir -p "${CT_CC_CORE_SHARED_PREFIX_DIR}/${CT_TARGET}/bin"
|
|
mkdir -p "${CT_CC_CORE_SHARED_PREFIX_DIR}/bin"
|
|
for t in elf2flt flthdr; do
|
|
ln -sv "${CT_PREFIX_DIR}/bin/${CT_TARGET}-${t}" "${CT_CC_CORE_STATIC_PREFIX_DIR}/${CT_TARGET}/bin/${t}"
|
|
ln -sv "${CT_PREFIX_DIR}/bin/${CT_TARGET}-${t}" "${CT_CC_CORE_STATIC_PREFIX_DIR}/bin/${CT_TARGET}-${t}"
|
|
ln -sv "${CT_PREFIX_DIR}/bin/${CT_TARGET}-${t}" "${CT_CC_CORE_SHARED_PREFIX_DIR}/${CT_TARGET}/bin/${t}"
|
|
ln -sv "${CT_PREFIX_DIR}/bin/${CT_TARGET}-${t}" "${CT_CC_CORE_SHARED_PREFIX_DIR}/bin/${CT_TARGET}-${t}"
|
|
done 2>&1 |CT_DoLog ALL
|
|
|
|
CT_EndStep
|
|
}
|