Mercurial > hg > aboriginal
changeset 854:3794d9a0be4c
Add SKIP_STRIP configuration option to do what it says on the tin, and stop blanking CFLAGS and CFLAGSXX so "export CFLAGS=-g" can pass through to package builds.
author | Rob Landley <rob@landley.net> |
---|---|
date | Mon, 19 Oct 2009 00:40:08 -0500 |
parents | 330442bbed6e |
children | 8a1c6271bbeb |
files | config cross-compiler.sh root-filesystem.sh sources/include.sh |
diffstat | 4 files changed, 22 insertions(+), 14 deletions(-) [+] |
line wrap: on
line diff
--- a/config Thu Oct 15 22:00:29 2009 -0500 +++ b/config Mon Oct 19 00:40:08 2009 -0500 @@ -129,5 +129,9 @@ # export BINARY_PACKAGE_TARBALLS=1 +# Set this (and CFLAGS="-g") if you want debug symbols in your binaries. + +# export SKIP_STRIP=1 + # Define the C library used here. Default is uClibc # export C_LIBRARY=uClibc
--- a/cross-compiler.sh Thu Oct 15 22:00:29 2009 -0500 +++ b/cross-compiler.sh Mon Oct 19 00:40:08 2009 -0500 @@ -30,6 +30,8 @@ HOST_UTILS=1 build_section $C_LIBRARY +exit + cat > "${STAGE_DIR}"/README << EOF && Cross compiler for $ARCH From http://impactlinux.com/fwl @@ -45,11 +47,14 @@ # Strip the binaries -cd "$STAGE_DIR" -for i in `find bin -type f` `find "$CROSS_TARGET" -type f` -do - strip "$i" 2> /dev/null -done +if [ -z "$SKIP_STRIP" ] +then + cd "$STAGE_DIR" + for i in `find bin -type f` `find "$CROSS_TARGET" -type f` + do + strip "$i" 2> /dev/null + done +fi # Tar it up
--- a/root-filesystem.sh Thu Oct 15 22:00:29 2009 -0500 +++ b/root-filesystem.sh Mon Oct 19 00:40:08 2009 -0500 @@ -173,14 +173,17 @@ fi # End of NATIVE_TOOLCHAIN != only -# Delete some unneeded files +if [ -z "$SKIP_STRIP" ] +then + # Delete some unneeded files -rm -rf "$ROOT_TOPDIR"/{info,man,libexec/gcc/*/*/install-tools} + rm -rf "$ROOT_TOPDIR"/{info,man,libexec/gcc/*/*/install-tools} -# Clean up and package the result + # Clean up and package the result -"${ARCH}-strip" "$ROOT_TOPDIR"/{bin/*,sbin/*,libexec/gcc/*/*/*} -"${ARCH}-strip" --strip-unneeded "$ROOT_TOPDIR"/lib/*.so + "${ARCH}-strip" "$ROOT_TOPDIR"/{bin/*,sbin/*,libexec/gcc/*/*/*} + "${ARCH}-strip" --strip-unneeded "$ROOT_TOPDIR"/lib/*.so +fi create_stage_tarball
--- a/sources/include.sh Thu Oct 15 22:00:29 2009 -0500 +++ b/sources/include.sh Mon Oct 19 00:40:08 2009 -0500 @@ -14,10 +14,6 @@ [ -e config ] && source config source sources/functions.sh -# The rest of this file is devoted to setting environment variables. - -unset CFLAGS CXXFLAGS - # What host compiler should we use? [ -z "$CC" ] && export CC=cc