Skip to content

Commit 2911fc2

Browse files
committed
configure: error on unsupported target-triples and arm-linux-androideabi fix
1 parent a56ec8c commit 2911fc2

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

configure

+16-1
Original file line numberDiff line numberDiff line change
@@ -536,6 +536,7 @@ fi
536536
CFG_PREFIX=${CFG_PREFIX%/}
537537
CFG_HOST_TRIPLES="$(echo $CFG_HOST_TRIPLES | tr ',' ' ')"
538538
CFG_TARGET_TRIPLES="$(echo $CFG_TARGET_TRIPLES | tr ',' ' ')"
539+
CFG_SUPPORTED_TARGET_TRIPLES="$(grep ^CC_*=* $CFG_SRC_DIR/mk/platform.mk | sed 's,^[^_]*_,,' | sed 's/\([^=]*\).*/\1/' | xargs)"
539540

540541
# copy host-triples to target-triples so that hosts are a subset of targets
541542
V_TEMP=""
@@ -548,8 +549,22 @@ CFG_TARGET_TRIPLES=$V_TEMP
548549
# check target-specific tool-chains
549550
for i in $CFG_TARGET_TRIPLES
550551
do
552+
L_CHECK=false
553+
for j in $CFG_SUPPORTED_TARGET_TRIPLES
554+
do
555+
if [ $i = $j ]
556+
then
557+
L_CHECK=true
558+
fi
559+
done
560+
561+
if [ $L_CHECK = false ]
562+
then
563+
err "unsupported target triples \"$i\" found"
564+
fi
565+
551566
case $i in
552-
arm-unknown-android)
567+
arm-linux-androideabi)
553568

554569
if [ ! -f $CFG_ANDROID_CROSS_PATH/bin/arm-linux-androideabi-gcc ]
555570
then

0 commit comments

Comments
 (0)