summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrick McDermott <patrick.mcdermott@libiquity.com>2020-06-22 12:29:43 (EDT)
committer Patrick McDermott <patrick.mcdermott@libiquity.com>2020-06-22 12:29:43 (EDT)
commit707f65e601a93e4dc6c6b1452efc04d141f3cad2 (patch)
treef9c81d01fd577f4443c5698889df2fa491a7158b
parentd48622850406bd206e75b6d43f6a6b0137dbf3fb (diff)
cmd/build: Pass -a option to opkg
-rw-r--r--NEWS6
-rw-r--r--src/cmd/build.sh7
2 files changed, 12 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index f9d1c64..8299e5e 100644
--- a/NEWS
+++ b/NEWS
@@ -3,6 +3,12 @@ ProteanOS Development Kit version 2.0.1+dev
Released: ????-??-??
+Changes in this release:
+
+ * "prokit build" now passes an "-a" option, if supported, to opkg to
+ install host-architecture non-coinstallable dependencies (such as
+ library development packages) when cross building.
+
ProteanOS Development Kit version 2.0.1
---------------------------------------
diff --git a/src/cmd/build.sh b/src/cmd/build.sh
index 87020ad..48503b7 100644
--- a/src/cmd/build.sh
+++ b/src/cmd/build.sh
@@ -144,7 +144,12 @@ cmd_build_main()
cmd_build_build_deps="$(package_get_build_deps "${arch}" "${plat}")"
if [ "x${cmd_build_build_deps}" != 'x' ]; then
_cmd_build_make_deps_pkg
- session_exec opkg install ../builddeps.opk
+ if session_exec opkg -a "${arch}" print-architecture \
+ 1>/dev/null 2>&1; then
+ session_exec opkg -a "${arch}" install ../builddeps.opk
+ else
+ session_exec opkg install ../builddeps.opk
+ fi
fi
session_exec opkbuild "${@}"