Build and install a uClibc cross-ldd.

Based on a patch by Joachim NILSSON: http://sourceware.org/ml/crossgcc/2008-11/msg00025.html

 /trunk/scripts/build/libc/uClibc.sh |   28    27     1     0 +++++++++++++++++++++++++++-
 1 file changed, 27 insertions(+), 1 deletion(-)
This commit is contained in:
Yann E. MORIN" 2008-11-17 18:46:09 +00:00
parent 4f5952aebf
commit 620b980474

View File

@ -148,7 +148,33 @@ do_libc() {
# This function is used to install those components needing the final C compiler
do_libc_finish() {
:
# Build and install host-side ldd
CT_DoStep INFO "Finishing C library"
mkdir -p "${CT_BUILD_DIR}/build-libc-finish"
cd "${CT_BUILD_DIR}/build-libc-finish"
# Simply copy files until uClibc has the ablity to build out-of-tree
CT_DoLog EXTRA "Copying sources to build dir"
{ cd "${CT_SRC_DIR}/${CT_LIBC_FILE}"; tar cf - .; } |tar xf -
# Retrieve the config file
cp "${CT_BUILD_DIR}/uClibc.config" .config
CT_DoLog EXTRA "Applying configuration"
CT_DoYes "" |CT_DoExecLog ALL \
make CROSS=${CT_TARGET}- \
PREFIX="${CT_SYSROOT_DIR}/" \
oldconfig
CT_DoLog EXTRA "Installing C library host utils"
CT_DoExecLog ALL \
make PREFIX="${CT_SYSROOT_DIR}/" \
${CT_LIBC_UCLIBC_VERBOSITY} \
-C utils hostutils
CT_DoExecLog ALL install -m 0755 utils/ldd.host "${CT_PREFIX_DIR}/bin/${CT_TARGET}-ldd"
CT_EndStep
}
# Initialises the .config file to sensible values