# Contributor: Francesco Colista # Maintainer: Francesco Colista pkgname=openscap pkgver=1.3.1 pkgrel=6 pkgdesc="NIST Certified SCAP 1.2 toolkit" url="https://www.open-scap.org/tools/openscap-base/" arch="all" license="LGPL-2.1-or-later" makedepends="cmake python3-dev dbus-dev dbus-glib-dev bash libselinux-dev curl-dev openssl-dev libgcrypt-dev acl-dev libblkid libcap-dev libxml2-dev libxslt-dev openldap-dev pcre2-dev perl-xml-parser perl-xml-xpath perl-dev rpm-dev swig bzip2-dev asciidoc fts-dev doxygen procps-dev libbz2 util-linux-dev nss-dev" options="!check" subpackages="$pkgname-dev $pkgname-doc $pkgname-bash-completion:bashcomp:noarch" source="https://github.com/OpenSCAP/openscap/releases/download/$pkgver/openscap-$pkgver.tar.gz fix-ppc64le-path_max.patch path_mounted.patch 0001-Handle-rpmVerifyFile-removal-in-rpm-4.15.patch 0002-Refer-to-the-RPMVERIFY_-constants-instead-of-VERIFY_.patch 0003-Drop-bogus-VERIFY_SIGNATURE-and-VERIFY_DIGEST-checks.patch " prepare() { default_prepare mkdir -p build } build() { cd "$builddir"/build export LIBS=-lfts cmake \ -DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_INSTALL_LIBDIR=lib \ -DENABLE_DOCS=ON \ -DENABLE_PERL=OFF \ -DENABLE_TESTS=OFF\ .. make } package() { cd "$builddir"/build make DESTDIR="$pkgdir" install } bashcomp() { depends="" pkgdesc="Bash completions for $pkgname" install_if="$pkgname=$pkgver-r$pkgrel bash-completion" install -Dm644 "$builddir"/dist/bash_completion.d/oscap \ "$subpkgdir"/usr/share/bash-completion/completions/$pkgname } sha512sums="c42c59a19e3f71a4ef55daa82be7a2b66514dfe4a98b8e897a03d4785b25395a3508ff2457072d3ae123328a104cab054e64dcb52209ae77060542484439d859 openscap-1.3.1.tar.gz 70bcc718e473862ecac22752ad553c5a520e42207688960403e3d7b9caefc7868fc4d81379a07d3c50fdd9373caab5ac91f758f306d1e3d2bbf355618674b611 fix-ppc64le-path_max.patch f2157d6b1d31affe16edb184a287b69d28808123f1cc26a5a4238040d935517b307772b1f2d66271b8ee99b59a4d204930f9147b78478c83c36c7fc8718ec1d9 path_mounted.patch b95065c7bcb808fe85c971b1fc311f800a26a77391e7a652a3659ce0d5cb6bc89ea50d054d47a459078a9e6101ac44fb1fedc1e3cc84e101915b81f9b625cee5 0001-Handle-rpmVerifyFile-removal-in-rpm-4.15.patch dffa0244a20df1f7935ebbbf16f38a1d4e0db5ec770a47cd353d923abee8b9472cb6f380c5d022b27f50b59a9702bfd7ae943f17b9bfdd3634c921a939b7c76d 0002-Refer-to-the-RPMVERIFY_-constants-instead-of-VERIFY_.patch 539d4e6bbed1a16724a103e6d72e9e468ef3babdd55e1aa13e8fdf3202982dd1a3c8e17a41f1656051d826dc125539b6dec89885a44bf90980b500b2f7d1143b 0003-Drop-bogus-VERIFY_SIGNATURE-and-VERIFY_DIGEST-checks.patch"