Skip to content

Commit df70dca

Browse files
committed
Fix symbol separation on cross-compile builds
1 parent 4fca631 commit df70dca

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

compile.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,7 @@ fi
129129
export CXX="g++"
130130
#export AR="gcc-ar"
131131
export RANLIB=ranlib
132+
export STRIP="strip"
132133
#fi
133134

134135
COMPILE_FOR_ANDROID=no
@@ -459,6 +460,7 @@ if [ "$TOOLCHAIN_PREFIX" != "" ]; then
459460
export RANLIB="$TOOLCHAIN_PREFIX-ranlib"
460461
export CPP="$TOOLCHAIN_PREFIX-cpp"
461462
export LD="$TOOLCHAIN_PREFIX-ld"
463+
export STRIP="$TOOLCHAIN_PREFIX-strip"
462464
fi
463465

464466
echo "#include <stdio.h>" > test.c
@@ -1376,7 +1378,7 @@ function separate_symbols {
13761378
output_dirname="$SYMBOLS_DIR/$(dirname $libname)"
13771379
mkdir -p "$output_dirname" >> "$DIR/install.log" 2>&1
13781380
cp "$libname" "$SYMBOLS_DIR/$libname.debug" >> "$DIR/install.log" 2>&1
1379-
strip -S "$libname" >> "$DIR/install.log" 2>&1 || rm "$SYMBOLS_DIR/$libname.debug" #if this fails, this probably isn't an executable binary
1381+
"$STRIP" -S "$libname" >> "$DIR/install.log" 2>&1 || rm "$SYMBOLS_DIR/$libname.debug" #if this fails, this probably isn't an executable binary
13801382
}
13811383

13821384
if [ "$SEPARATE_SYMBOLS" != "no" ]; then

0 commit comments

Comments
 (0)