[Sound-open-firmware] [PATCH 2/2] scripts: fix xt-xcc build with wrong config

Xiuli Pan xiuli.pan at linux.intel.com
Tue Jun 19 12:02:46 CEST 2018


From: Pan Xiuli <xiuli.pan at linux.intel.com>

Need to export XTENSA_SYSTEM and override OBJCOPY and OBJDUMP for xt-xcc
build.

Signed-off-by: Pan Xiuli <xiuli.pan at linux.intel.com>
---
 scripts/xtensa-build-all.sh | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/scripts/xtensa-build-all.sh b/scripts/xtensa-build-all.sh
index 62b94b2..d3991df 100755
--- a/scripts/xtensa-build-all.sh
+++ b/scripts/xtensa-build-all.sh
@@ -121,8 +121,12 @@ do
 		if [ -d $XTENSA_TOOLS_DIR ]
 			then
 				XCC="xt-xcc"
+				XTOBJCOPY="xt-objcopy"
+				XTOBJDUMP="xt-objdump"
 			else
 				XCC="none"
+				XTOBJCOPY="none"
+				XTOBJDUMP="none"
 		fi
 	fi
 
@@ -130,13 +134,14 @@ do
 	if [ $XCC == "xt-xcc" ]
 	then
 		ROOT="$XTENSA_BUILDS_DIR/$XTENSA_CORE/xtensa-elf"
-		XTENSA_SYSTEM=$XTENSA_BUILDS_DIR/$XTENSA_CORE/config
+		export XTENSA_SYSTEM=$XTENSA_BUILDS_DIR/$XTENSA_CORE/config
 		PATH=$XTENSA_TOOLS_DIR/XtensaTools/bin:$OLDPATH
 	else
 		PATH=$pwd/../$HOST/bin:$OLDPATH
 	fi
 
-	./configure --with-arch=xtensa --with-platform=$PLATFORM --with-root-dir=$ROOT --host=$HOST CC=$XCC --with-dsp-core=$XTENSA_CORE
+	./configure --with-arch=xtensa --with-platform=$PLATFORM --with-root-dir=$ROOT --host=$HOST \
+		CC=$XCC OBJCOPY=$XTOBJCOPY OBJDUMP=$XTOBJDUMP --with-dsp-core=$XTENSA_CORE
 
 	make clean
 	make
-- 
2.7.4



More information about the Sound-open-firmware mailing list