summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMirco Tischler2017-02-11 15:07:29 +0100
committerMirco Tischler2017-02-11 15:07:29 +0100
commit9714fe0477236e6340455662dfeac168791951f3 (patch)
tree5e5a711f260a39836d165e774ab15a4e7f6d70d8
parent5d7990db4f1b7b340be43b48eff37490af7f0ab5 (diff)
downloadaur-9714fe0477236e6340455662dfeac168791951f3.tar.gz
fwupdate: 0.8-2: add post install instructions and move EFI executable to better path.
-rw-r--r--.SRCINFO5
-rw-r--r--0001-Always-set-a-mode-with-efi_set_variable.patch58
-rw-r--r--0001-libfwup-better-bounds-checking-with-efivar-0.24-APIs.patch31
-rw-r--r--PKGBUILD9
-rw-r--r--fwupdate.install11
5 files changed, 20 insertions, 94 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 8dc20c9f7f4c..0685afaec299 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,10 +1,11 @@
# Generated by mksrcinfo v8
-# Sun Oct 30 18:13:51 UTC 2016
+# Sat Feb 11 14:07:05 UTC 2017
pkgbase = fwupdate
pkgdesc = Tools for using the ESRT and UpdateCapsule() to apply firmware updates
pkgver = 8
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/rhinstaller/fwupdate
+ install = fwupdate.install
arch = i686
arch = x86_64
license = GPL2
diff --git a/0001-Always-set-a-mode-with-efi_set_variable.patch b/0001-Always-set-a-mode-with-efi_set_variable.patch
deleted file mode 100644
index 8d5c26d46d98..000000000000
--- a/0001-Always-set-a-mode-with-efi_set_variable.patch
+++ /dev/null
@@ -1,58 +0,0 @@
-From 84f2ea96f88751fe01228dcd9fc130cfa0893dfc Mon Sep 17 00:00:00 2001
-From: Peter Jones <pjones@redhat.com>
-Date: Wed, 2 Mar 2016 10:05:19 -0500
-Subject: [PATCH] Always set a mode with efi_set_variable()
-
-Apparently the code in efivar to handle whether mode is there or not
-does not always work, so it's going to go away soon.
-
-Signed-off-by: Peter Jones <pjones@redhat.com>
----
- linux/libfwup.c | 10 ++++++----
- 1 file changed, 6 insertions(+), 4 deletions(-)
-
-diff --git a/linux/libfwup.c b/linux/libfwup.c
-index 6f2f896..d50e4d5 100644
---- a/linux/libfwup.c
-+++ b/linux/libfwup.c
-@@ -331,7 +331,7 @@ err:
- | EFI_VARIABLE_BOOTSERVICE_ACCESS
- | EFI_VARIABLE_RUNTIME_ACCESS;
- rc = efi_set_variable(varguid, varname, (uint8_t *)info2,
-- is, attributes, 0644);
-+ is, attributes, 0600);
- error = errno;
- free(info2);
- errno = error;
-@@ -797,7 +797,7 @@ do_next:
- if (found) {
- efi_loadopt_attr_set(loadopt, LOAD_OPTION_ACTIVE);
- rc = efi_set_variable(*guid, name, var_data,
-- var_data_size, attr);
-+ var_data_size, attr, 0600);
- free(var_data);
- if (rc < 0)
- goto out;
-@@ -822,7 +822,8 @@ do_next:
- opt_size,
- EFI_VARIABLE_NON_VOLATILE |
- EFI_VARIABLE_BOOTSERVICE_ACCESS |
-- EFI_VARIABLE_RUNTIME_ACCESS);
-+ EFI_VARIABLE_RUNTIME_ACCESS,
-+ 0600);
- if (rc < 0)
- goto out;
-
-@@ -833,7 +834,8 @@ do_next:
- (uint8_t *)&real_boot_next, 2,
- EFI_VARIABLE_NON_VOLATILE |
- EFI_VARIABLE_BOOTSERVICE_ACCESS |
-- EFI_VARIABLE_RUNTIME_ACCESS);
-+ EFI_VARIABLE_RUNTIME_ACCESS,
-+ 0600);
- ret = rc;
-
- out:
---
-2.9.0
-
diff --git a/0001-libfwup-better-bounds-checking-with-efivar-0.24-APIs.patch b/0001-libfwup-better-bounds-checking-with-efivar-0.24-APIs.patch
deleted file mode 100644
index f1aa1f22b1fc..000000000000
--- a/0001-libfwup-better-bounds-checking-with-efivar-0.24-APIs.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 9b0258e62c3d5272bb8431f1067042945197b2c8 Mon Sep 17 00:00:00 2001
-From: Peter Jones <pjones@redhat.com>
-Date: Thu, 25 Feb 2016 14:59:28 -0500
-Subject: [PATCH] libfwup: better bounds checking with efivar 0.24 APIs
-
-Signed-off-by: Peter Jones <pjones@redhat.com>
----
- linux/libfwup.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/linux/libfwup.c b/linux/libfwup.c
-index 5de9d4c..4154480 100644
---- a/linux/libfwup.c
-+++ b/linux/libfwup.c
-@@ -695,11 +695,11 @@ do_next:
- continue;
- }
-
-- sz = efi_loadopt_pathlen(loadopt);
-+ sz = efi_loadopt_pathlen(loadopt, var_data_size);
- if (sz != efidp_size((efidp)dp_buf))
- goto do_next;
-
-- efidp found_dp = efi_loadopt_path(loadopt);
-+ efidp found_dp = efi_loadopt_path(loadopt, var_data_size);
- if (memcmp(found_dp, dp_buf, sz))
- goto do_next;
-
---
-2.9.0
-
diff --git a/PKGBUILD b/PKGBUILD
index 078ef961cbe4..2fafc0b037a1 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=fwupdate
pkgver=8
-pkgrel=1
+pkgrel=2
pkgdesc='Tools for using the ESRT and UpdateCapsule() to apply firmware updates'
arch=('i686' 'x86_64')
url='https://github.com/rhinstaller/fwupdate'
@@ -11,17 +11,20 @@ depends=('efivar' 'libsmbios' 'bash')
makedepends=('pesign' 'gnu-efi-libs')
source=("${url}/releases/download/${pkgver}/${pkgname}-${pkgver}.tar.bz2")
sha256sums=('c8120f6ff0378d0f070373b6d46bfcaee18deeaf5a50c65d596c6df866980883')
+install=fwupdate.install
+
+_efidir=arch
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
- make EFIDIR=/usr/lib GNUEFIDIR=/usr/lib
+ make EFIDIR="${_efidir}" GNUEFIDIR=/usr/lib
}
package() {
cd "${srcdir}/${pkgname}-${pkgver}"
- make LIBDIR=/usr/lib EFIDIR=/usr/lib DESTDIR="${pkgdir}" libexecdir=/usr/lib/ install
+ make LIBDIR=/usr/lib EFIDIR="${_efidir}" DESTDIR="${pkgdir}" libexecdir=/usr/lib/ install
#don't install into /boot. copy files to /usr/lib/fwupdate for manual installation
install -d ${pkgdir}/usr/lib/fwupdate
diff --git a/fwupdate.install b/fwupdate.install
new file mode 100644
index 000000000000..5171ff82ef50
--- /dev/null
+++ b/fwupdate.install
@@ -0,0 +1,11 @@
+post_install() {
+ echo
+ echo "To use the efi fimware update executable, copy the"
+ echo "content of /usr/lib/fwupdate/EFI/ to your EFI partition,"
+ echo "usually /boot/EFI."
+ echo
+}
+
+post_upgrade() {
+ post_install
+}