jobcore/efivar/PKGBUILD-37-4
2022-03-20 14:19:37 +02:00

58 lines
1.7 KiB
Bash

#!/usr/bin/bash
# JOBoRun : Jwm OpenBox Obarun RUNit
# Maintainer : Joe Bo Run <joborun@disroot.org>
# PkgSource : url="https://gittea.disroot.org/joborun/jobcore/$pkgname"
#-----------------------------------------| DESCRIPTION |---------------------------------------
pkgname=efivar
pkgdesc="Tools and libraries to work with EFI variables"
pkgver=37
pkgrel=04
arch=('x86_64')
url="https://github.com/rhboot/efivar"
makedepends=('git')
depends=('glibc')
provides=('libefiboot.so' 'libefivar.so')
source=("git+https://github.com/rhinstaller/efivar.git#tag=${pkgver}?signed")
prepare() {
mv -v "${pkgname}" "${pkgname}-${pkgver}"
cd "${pkgname}-${pkgver}"
# -Werror, not even once
sed -e 's/-Werror//g' -i gcc.specs
# remove insecure rpath in efivar-tester
sed 's|-rpath,$(TOPDIR)/src|-rpath,$(libdir)|g' -i src/test/Makefile
}
build() {
cd "${pkgname}-${pkgver}"
make libdir="/usr/lib/" \
bindir="/usr/bin/" \
mandir="/usr/share/man/" \
includedir="/usr/include/"
# build efivar-tester
make libdir="/usr/lib/" \
bindir="/usr/bin/" \
mandir="/usr/share/man/" \
includedir="/usr/include/" \
-C src/test
}
package() {
cd "${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}/" \
libdir="/usr/lib/" \
bindir="/usr/bin/" \
mandir="/usr/share/man/" \
includedir="/usr/include/" install -j1 V=1
install -vDm 755 "src/test/tester" "${pkgdir}/usr/bin/efivar-tester"
install -vDm 644 {README.md,TODO} -t "${pkgdir}/usr/share/doc/${pkgname}"
}
#---- license gpg-key sha256sums ----
license=('LGPL2.1')
validpgpkeys=('B00B48BC731AA8840FED9FB0EED266B70F4FEF10') # Peter Jones <pjones@redhat.com>
sha256sums=(SKIP)