summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mk/build.mk4
-rw-r--r--scripts/rstrip.sh9
-rw-r--r--target/packages/pkg-available/test1
-rw-r--r--toolchain/glibc/Makefile7
-rw-r--r--toolchain/musl/Makefile7
-rw-r--r--toolchain/uClibc/Makefile7
6 files changed, 21 insertions, 14 deletions
diff --git a/mk/build.mk b/mk/build.mk
index 37f27b12b..8c1e73743 100644
--- a/mk/build.mk
+++ b/mk/build.mk
@@ -561,8 +561,8 @@ test-framework:
for libc in uclibc glibc musl;do \
mkdir -p $(TOPDIR)/firmware/$(SYSTEM)_$(ARCH)_$$libc; \
( \
- for arch in arm mips mipsel x86 x86_64;do \
- tarch=$$(echo $$arch|sed -e "s#el##" -e "s#eb##" -e "s#mips64.*#mips#"); \
+ for arch in arm mips mipsel i686 x86_64;do \
+ tarch=$$(echo $$arch|sed -e "s#el##" -e "s#eb##" -e "s#mips64.*#mips#" -e "s#i686#x86#"); \
echo === building qemu-$$arch for $$libc with $$tarch on $$(date); \
$(GMAKE) prereq && \
$(GMAKE) ARCH=$$tarch SYSTEM=qemu-$$arch LIBC=$$libc FS=archive COLLECTION=test defconfig; \
diff --git a/scripts/rstrip.sh b/scripts/rstrip.sh
index bacf25ca7..46a4586da 100644
--- a/scripts/rstrip.sh
+++ b/scripts/rstrip.sh
@@ -5,10 +5,6 @@
SELF=${0##*/}
-if [[ -z $debug ]];then
- debug=1
-fi
-
if [[ -z $prefix ]]; then
echo >&2 "$SELF: strip command not defined ('prefix' variable not set)"
exit 1
@@ -64,12 +60,13 @@ find $TARGETS -type f -a -exec file {} \; | \
echo "$SELF: $V:$S"
echo "-> $T $F"
eval "chmod u+w $F"
- if [[ $debug -eq 1 ]];then
+ if [[ $debug -ne 0 ]];then
+ echo "mkdir for $D" >> /tmp/debug
eval "mkdir -p $D/usr/lib/debug/$Q"
eval "$O --only-keep-debug $F $D/usr/lib/debug/$P.debug"
fi
eval "$T $F"
- if [[ $debug -eq 1 ]];then
+ if [[ $debug -ne 0 ]];then
eval "cd $D/usr/lib/debug/$Q && $O --add-gnu-debuglink=$R.debug $F"
fi
done
diff --git a/target/packages/pkg-available/test b/target/packages/pkg-available/test
index 8af24a816..d7bbcf26a 100644
--- a/target/packages/pkg-available/test
+++ b/target/packages/pkg-available/test
@@ -3,6 +3,7 @@ config ADK_PKG_TEST
default n
select ADK_PACKAGE_STRACE
select ADK_PACKAGE_SOCAT
+ select ADK_PACKAGE_MAKE
help
Package collection used to build adk-test-framework root
filesystem.
diff --git a/toolchain/glibc/Makefile b/toolchain/glibc/Makefile
index 00bd67cbc..41987bada 100644
--- a/toolchain/glibc/Makefile
+++ b/toolchain/glibc/Makefile
@@ -73,8 +73,11 @@ $(WRKBUILD)/.fixup:
-find $(STAGING_TARGET_DIR) -type f -name \*_pic\* -delete
rm -rf $(STAGING_TARGET_DIR)/usr/share/locale $(STAGING_TARGET_DIR)/usr/share/i18n
rm -rf $(STAGING_TARGET_DIR)/usr/lib/gconv
- PATH="$(TARGET_PATH)" debug='' prefix='${TARGET_CROSS}' ${BASH} ${SCRIPT_DIR}/rstrip.sh $(STAGING_TARGET_DIR)
- debug='' prefix=' ' ${BASH} ${SCRIPT_DIR}/rstrip.sh $(STAGING_HOST_DIR)/bin $(STAGING_HOST_DIR)/$(GNU_TARGET_NAME)/
+ifeq ($(ADK_TOOLCHAIN),y)
+ # strip target libs and host tools for toolchain builds
+ PATH="$(TARGET_PATH)" debug='0' prefix='${TARGET_CROSS}' ${BASH} ${SCRIPT_DIR}/rstrip.sh $(STAGING_TARGET_DIR)
+ debug='0' prefix=' ' ${BASH} ${SCRIPT_DIR}/rstrip.sh $(STAGING_HOST_DIR)/bin $(STAGING_HOST_DIR)/$(GNU_TARGET_NAME)/
+endif
touch $@
include ${TOPDIR}/mk/toolchain.mk
diff --git a/toolchain/musl/Makefile b/toolchain/musl/Makefile
index abb7af366..d675dc4cc 100644
--- a/toolchain/musl/Makefile
+++ b/toolchain/musl/Makefile
@@ -59,8 +59,11 @@ $(WRKBUILD)/.fixup:
$(MAKE) -C $(WRKBUILD) DESTDIR=$(STAGING_TARGET_DIR) install
# cleanup toolchain
-find $(STAGING_TARGET_DIR) $(STAGING_HOST_DIR) -name \*.la -delete
- PATH="$(TARGET_PATH)" debug='' prefix='${TARGET_CROSS}' ${BASH} ${SCRIPT_DIR}/rstrip.sh $(STAGING_TARGET_DIR)
- debug='' prefix=' ' ${BASH} ${SCRIPT_DIR}/rstrip.sh $(STAGING_HOST_DIR)
+ifeq ($(ADK_TOOLCHAIN),y)
+ # strip target libs and host tools for toolchain builds
+ PATH="$(TARGET_PATH)" debug='0' prefix='${TARGET_CROSS}' ${BASH} ${SCRIPT_DIR}/rstrip.sh $(STAGING_TARGET_DIR)
+ debug='0' prefix=' ' ${BASH} ${SCRIPT_DIR}/rstrip.sh $(STAGING_HOST_DIR)
+endif
touch $@
include ${TOPDIR}/mk/toolchain.mk
diff --git a/toolchain/uClibc/Makefile b/toolchain/uClibc/Makefile
index 7e53b5d21..4ee9af510 100644
--- a/toolchain/uClibc/Makefile
+++ b/toolchain/uClibc/Makefile
@@ -120,8 +120,11 @@ endif
ln -s libc.so.0 $(STAGING_TARGET_DIR)/lib/libc.so
# cleanup toolchain
-find $(STAGING_TARGET_DIR) $(STAGING_HOST_DIR) -name \*.la -delete
- PATH="$(TARGET_PATH)" debug='' prefix='${TARGET_CROSS}' ${BASH} ${SCRIPT_DIR}/rstrip.sh $(STAGING_TARGET_DIR)
- debug='' prefix=' ' ${BASH} ${SCRIPT_DIR}/rstrip.sh $(STAGING_HOST_DIR)
+ifeq ($(ADK_TOOLCHAIN),y)
+ # strip target libs and host tools for toolchain builds
+ PATH="$(TARGET_PATH)" debug='0' prefix='${TARGET_CROSS}' ${BASH} ${SCRIPT_DIR}/rstrip.sh $(STAGING_TARGET_DIR)
+ debug='0' prefix=' ' ${BASH} ${SCRIPT_DIR}/rstrip.sh $(STAGING_HOST_DIR)
+endif
touch $@
include ${TOPDIR}/mk/toolchain.mk