diff options
author | P. J. McDermott <pj@pehjota.net> | 2015-09-06 12:39:50 (EDT) |
---|---|---|
committer | P. J. McDermott <pj@pehjota.net> | 2015-09-06 12:43:22 (EDT) |
commit | 0d955b1f5f21967fb9b80b7ecb9455a2f8391f3d (patch) | |
tree | 065bd99094c2b1a1b7ed25a2ad37ec5f646eca1d | |
parent | 55b9c5e5dd730cdd88a192ce1533a98db7d7d3f7 (diff) |
Manage lspci with update-alternatives
-rwxr-xr-x | build | 1 | ||||
-rw-r--r-- | changelog | 6 | ||||
-rw-r--r-- | pciutils.pkg/files | 2 | ||||
-rw-r--r-- | pciutils.pkg/postinst | 6 | ||||
-rw-r--r-- | pciutils.pkg/prerm | 5 |
5 files changed, 19 insertions, 1 deletions
@@ -22,6 +22,7 @@ install: build PREFIX=/usr \ LIBDIR=/usr/lib/$(OPK_HOST_ARCH) \ SHARED=yes + mv dest/usr/bin/lspci dest/usr/bin/lspci.pciutils # pci.ids is provided by the pciids package. rm -f dest/usr/bin/update-pciids rm -f dest/usr/share/misc/pci.ids* @@ -1,3 +1,9 @@ +pciutils (3.3.1-2) trunk + + * Manage lspci with update-alternatives. + + -- "P. J. McDermott" <pj@pehjota.net> Sun, 06 Sep 2015 12:39:15 -0400 + pciutils (3.3.1-1) trunk * Initial release. diff --git a/pciutils.pkg/files b/pciutils.pkg/files index 0e77f82..9d67372 100644 --- a/pciutils.pkg/files +++ b/pciutils.pkg/files @@ -1,2 +1,2 @@ -/usr/bin/lspci +/usr/bin/lspci.pciutils /usr/bin/setpci diff --git a/pciutils.pkg/postinst b/pciutils.pkg/postinst new file mode 100644 index 0000000..12f7a19 --- /dev/null +++ b/pciutils.pkg/postinst @@ -0,0 +1,6 @@ +#!/bin/sh + +if [ "x${1}" = 'xconfigure' ]; then + update-alternatives --install /usr/bin/lspci lspci \ + /usr/bin/lspci.pciutils 20 +fi diff --git a/pciutils.pkg/prerm b/pciutils.pkg/prerm new file mode 100644 index 0000000..94877d1 --- /dev/null +++ b/pciutils.pkg/prerm @@ -0,0 +1,5 @@ +#!/bin/sh + +if [ "x${1}" = 'xremove' ]; then + update-alternatives --remove lspci /usr/bin/lspci.pciutils +fi |