From 843e3e4ecc42cac1094d6d835f3baf5d2b852aa0 Mon Sep 17 00:00:00 2001 From: David P Date: Thu, 10 May 2018 22:56:52 -0300 Subject: nonsystemd-multilib/lib32-polkit: add package --- nonsystemd-multilib/lib32-polkit/PKGBUILD | 75 ++++++++++++++++++++++ .../lib32-polkit/elogind-configure-fix.patch | 28 ++++++++ 2 files changed, 103 insertions(+) create mode 100644 nonsystemd-multilib/lib32-polkit/PKGBUILD create mode 100644 nonsystemd-multilib/lib32-polkit/elogind-configure-fix.patch (limited to 'nonsystemd-multilib') diff --git a/nonsystemd-multilib/lib32-polkit/PKGBUILD b/nonsystemd-multilib/lib32-polkit/PKGBUILD new file mode 100644 index 000000000..be662d63b --- /dev/null +++ b/nonsystemd-multilib/lib32-polkit/PKGBUILD @@ -0,0 +1,75 @@ +# $Id$ +# Maintainer (Arch): Maxime Gauduin +# Contributor (Arch): Jan de Groot +# Contributor (Arch): jtts +# Contributor (Arch): GordonGR +# Maintainer: David P. + +pkgname=lib32-polkit +pkgver=0.114 +pkgrel=1 +pkgrel+=.nonsystemd1 +pkgdesc='Application development toolkit for controlling system-wide privileges' +arch=('x86_64') +license=('LGPL') +url='https://www.freedesktop.org/wiki/Software/polkit/' +depends=('lib32-expat' 'lib32-glib2' 'lib32-pam' 'polkit') +makedepends=('autoconf-archive' 'gcc-multilib' 'git' 'gobject-introspection' + 'gtk-doc' 'intltool') +_commit='ed06baed179166389d536420a6fc532781d48178' # tags/0.114^0 +source=("git+https://anongit.freedesktop.org/git/polkit#commit=$_commit" + 'elogind-configure-fix.patch') +sha256sums=('SKIP' + 'd90b2a95aa3e9e1ebf9369c038c144e04900e095c5405bc4ba4901c31bf3f59b') + +pkgver() { + cd polkit + + git describe --tags | sed 's/-/+/g' +} + +prepare() { + cd polkit + + git cherry-pick -n 373705b35e7f6c7dc83de5e0a3ce11ecd15d0409 + patch -Np 1 -i ${srcdir}/elogind-configure-fix.patch + NOCONFIGURE=1 ./autogen.sh +} + +build() { + cd polkit + + export CC='gcc -m32' + export CXX='g++ -m32' + export PKG_CONFIG_PATH='/usr/lib32/pkgconfig' + #export CFLAGS="-lelogind" + + ./configure \ + --prefix='/usr' \ + --sysconfdir='/etc' \ + --libdir='/usr/lib32' \ + --localstatedir='/var' \ + --libexecdir='/usr/lib32' \ + --disable-static \ + --enable-libsystemd-login='no' \ + --with-os-type=redhat \ + --enable-libelogind='no' \ + --with-systemdsystemunitdir='no' + +# sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool + + make -C src/polkit polkitenumtypes.h + make -C src/polkit libpolkit-gobject-1.la + make -C src/polkitagent polkitagentenumtypes.h marshal.stamp + make -C src/polkitagent libpolkit-agent-1.la +} + +package() { + cd polkit + + make -C src/polkit DESTDIR="${pkgdir}" lib_LTLIBRARIES='libpolkit-gobject-1.la' install-libLTLIBRARIES + make -C src/polkitagent DESTDIR="${pkgdir}" lib_LTLIBRARIES='libpolkit-agent-1.la' install-libLTLIBRARIES + make -C data DESTDIR="${pkgdir}" install-pkgconfigDATA +} + +# vim: ts=2 sw=2 et: diff --git a/nonsystemd-multilib/lib32-polkit/elogind-configure-fix.patch b/nonsystemd-multilib/lib32-polkit/elogind-configure-fix.patch new file mode 100644 index 000000000..81db3becc --- /dev/null +++ b/nonsystemd-multilib/lib32-polkit/elogind-configure-fix.patch @@ -0,0 +1,28 @@ +From 08bb656496cd3d6213bbe9473f63f2d4a110da6e Mon Sep 17 00:00:00 2001 +From: Rasmus Thomsen +Date: Wed, 11 Apr 2018 13:14:14 +0200 +Subject: [PATCH] configure: fix elogind support + +HAVE_LIBSYSTEMD is used to determine which source files to use. +We have to check if either have_libsystemd or have_libelogind is +true, as both of these need the source files which are used when +HAVE_LIBSYSTEMD is true. +--- + configure.ac | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/configure.ac b/configure.ac +index 36df239..da47ecb 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -221,7 +221,7 @@ AS_IF([test "x$cross_compiling" != "xyes" ], [ + + AC_SUBST(LIBSYSTEMD_CFLAGS) + AC_SUBST(LIBSYSTEMD_LIBS) +-AM_CONDITIONAL(HAVE_LIBSYSTEMD, [test "$have_libsystemd" = "yes"], [Using libsystemd]) ++AM_CONDITIONAL(HAVE_LIBSYSTEMD, [test "$have_libsystemd" = "yes" || test "$have_libelogind" = "yes" ], [Using libsystemd]) + + dnl --------------------------------------------------------------------------- + dnl - systemd unit / service files +-- +2.17.0 -- cgit v1.2.3