summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/buildsystem.sh13
-rw-r--r--src/oh-architecture.sh2
2 files changed, 8 insertions, 7 deletions
diff --git a/lib/buildsystem.sh b/lib/buildsystem.sh
index 8207bcc..ffdba86 100644
--- a/lib/buildsystem.sh
+++ b/lib/buildsystem.sh
@@ -140,17 +140,18 @@ oh_buildsystem_arch()
local bs_arch=
local system=
- if [ ${#} -eq 1 ]; then
+ if [ ${#} -eq 2 ]; then
arch="${1}"
+ system="${2}"
+ else
+ return 125
+ fi
+
+ if [ "x${system}" = 'x' ]; then
system="$(oh_buildsystem_find 'configure')"
if [ ${?} -ne 0 ]; then
return 1
fi
- elif [ ${#} -eq 2 ]; then
- arch="${1}"
- system="${2}"
- else
- return 125
fi
# Try to find a suitable build system host arch.
diff --git a/src/oh-architecture.sh b/src/oh-architecture.sh
index 4ba5929..003b625 100644
--- a/src/oh-architecture.sh
+++ b/src/oh-architecture.sh
@@ -48,7 +48,7 @@ main()
oh_buildsystems_init
- oh_buildsystem_arch "${1}"
+ oh_buildsystem_arch "${1}" ''
}
main "${@}"