summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrick McDermott <patrick.mcdermott@libiquity.com>2019-04-04 17:50:07 (EDT)
committer Patrick McDermott <patrick.mcdermott@libiquity.com>2019-04-04 17:50:07 (EDT)
commite08b239f3d46501546e2f68fcdaf199890dc665c (patch)
tree58ec1fafd2cabed1e5d50643b948cbb28d8ff4ba
parente3cfa8bfcfdbca6b6efae1be1832a020df712b86 (diff)
opkg-common: Manage opkg-key and u-a with u-a
So meta.
-rwxr-xr-xbuild3
-rw-r--r--changelog2
-rw-r--r--opkg-common.pkg/files4
-rw-r--r--opkg-common.pkg/postinst8
4 files changed, 15 insertions, 2 deletions
diff --git a/build b/build
index f8a6270..a233356 100755
--- a/build
+++ b/build
@@ -31,6 +31,9 @@ install: build
oh-autoinstall -B obj-opkg-gpg
mv dest/usr/bin/opkg-cl dest/usr/bin/opkg-gpg
oh-autoinstall -B obj-opkg
+ mv dest/usr/bin/opkg-key dest/usr/bin/opkg-key-orig
+ mv dest/usr/bin/update-alternatives \
+ dest/usr/bin/update-alternatives-orig
rm -Rf dest/usr/include/ \
dest/usr/lib/$(OPK_HOST_ARCH)/pkgconfig/ \
dest/usr/lib/$(OPK_HOST_ARCH)/libopkg.a \
diff --git a/changelog b/changelog
index 680bae6..efb1b14 100644
--- a/changelog
+++ b/changelog
@@ -1,5 +1,7 @@
opkg (0.2.4-2) trunk
+ * opkg-common: Manage opkg-key and update-alternatives with
+ update-alternatives.
* opkg, opkg-gpg: Conflict with opkg-lede (<< 0+git20190131.d4ba162-2).
-- Patrick McDermott <patrick.mcdermott@libiquity.com> Thu, 04 Apr 2019 17:42:46 -0400
diff --git a/opkg-common.pkg/files b/opkg-common.pkg/files
index 0adb8fd..ba783fc 100644
--- a/opkg-common.pkg/files
+++ b/opkg-common.pkg/files
@@ -1,4 +1,4 @@
/usr/bin/opkg-check-config
-/usr/bin/opkg-key
-/usr/bin/update-alternatives
+/usr/bin/opkg-key-orig
+/usr/bin/update-alternatives-orig
/usr/share/opkg
diff --git a/opkg-common.pkg/postinst b/opkg-common.pkg/postinst
new file mode 100644
index 0000000..5f90662
--- /dev/null
+++ b/opkg-common.pkg/postinst
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+if [ x"${1}" = x'configure' ]; then
+ for f in opkg-key update-alternatives; do
+ update-alternatives --install "/usr/bin/${f}" "${f}" \
+ "/usr/bin/${f}-orig" 20
+ done
+fi