Skip to content

Commit f2abcc1

Browse files
bwhacksmasahir0y
authored andcommitted
builddeb: Skip architecture detection when KBUILD_DEBARCH is set
If KBUILD_DEBARCH is set then we will not use the result of architecture detection, and we may also warn unnecessarily. Move the check for KBUILD_DEBARCH further up to avoid this. Signed-off-by: Ben Hutchings <ben@decadent.org.uk> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
1 parent 43fee2b commit f2abcc1

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

‎scripts/package/mkdebian‎

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@
77
set -e
88

99
set_debarch() {
10+
if [ -n "$KBUILD_DEBARCH" ] ; then
11+
debarch="$KBUILD_DEBARCH"
12+
return
13+
fi
14+
1015
# Attempt to find the correct Debian architecture
1116
case "$UTS_MACHINE" in
1217
i386|ia64|alpha)
@@ -46,10 +51,8 @@ set_debarch() {
4651
echo "Falling back to using your current userspace instead!" >&2
4752
echo "Please add support for $UTS_MACHINE to ${0} ..." >&2
4853
echo "" >&2
54+
;;
4955
esac
50-
if [ -n "$KBUILD_DEBARCH" ] ; then
51-
debarch="$KBUILD_DEBARCH"
52-
fi
5356
}
5457

5558
# Some variables and settings used throughout the script

0 commit comments

Comments
 (0)