jobextra/udisks2/PKGBUILD

92 lines
3.2 KiB
Bash

#!/usr/bin/bash
# JOBoRun : Jwm OpenBox Obarun RUNit
# Maintainer : Joe Bo Run <joborun@disroot.org>
# PkgSource : url="https://gittea.disroot.org/joborun-pkg/jobextra/$pkgname"
# Website : https://pozol.eu
#-----------------------------------------| DESCRIPTION |---------------------------------------
pkgname=udisks2
pkgver=2.10.1
pkgrel=01
pkgdesc="Disk Management Service, version 2 w/o systemd zram systemd-swap"
# piece of junk software coming from none other than the source of trouble
# they have added systemd-swap functionality to disk management just to exclude
# its use from non-systemd systems, zram is the victim
# since we are based on Arch we must issue junky solutions for junky software
url="https://www.freedesktop.org/wiki/Software/udisks/"
depends=('acl' 'polkit' 'glib2' 'gcc-libs' 'glibc' 'libatasmart' 'libgudev' 'libblockdev' 'util-linux-libs')
makedepends=('gobject-introspection' 'gtk-doc')
optdepends=('gptfdisk: GUID partition table support'
'parted: partition management'
'gptfdisk: GUID partition table support'
'ntfs-3g: NTFS filesystem management support'
'dosfstools: VFAT filesystem management support')
provides=("udisks2=${pkgver}")
conflicts=('udisks2-nosystemd' 'udisks2-eudev')
replaces=('udisks2-nosystemd' 'udisks2-eudev')
options=(!libtool)
backup=('etc/udisks2/udisks2.conf')
source=("https://github.com/storaged-project/udisks/releases/download/udisks-$pkgver/udisks-$pkgver.tar.bz2"
disable_logind_support.patch)
# remove_check.patch
prepare() {
cd "udisks-$pkgver"
# It should fix an issue when udisks is asking to enter an user password on
# every (un)mount operation if installed together with systemd package and any
# initsystem which supports tmpfiles.d configs.
patch -p1 -i "$srcdir"/disable_logind_support.patch
# Allow to build with ZRAM support but without systemd installed
# patch -p1 -i "$srcdir"/remove_check.patch
# NOCONFIGURE=1 ./autogen.sh
}
build() {
# since systemd expanded to systemd-swap used by zram zram support must be dropped
cd "udisks-$pkgver"
./configure \
--prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var \
--disable-static \
--enable-zram=no \
--sbindir=/usr/bin \
--libexecdir=/usr/lib \
--with-systemdsystemunitdir=no \
--enable-gtk-doc
#enable_available_modules=yes
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
make
}
check() {
cd udisks-$pkgver
make check
}
package() {
cd udisks-$pkgver
make DESTDIR="$pkgdir" install
# interface declaration
install -vDm 644 data/org.freedesktop.UDisks2.xml -t "$pkgdir/usr/share/dbus-1/interfaces/"
}
#---- arch license gpg-key & sha256sums ----
arch=(x86_64)
license=(GPL-2.0-or-later
LGPL-2.0-or-later)
sha256sums=(b75734ccf602540dedb4068bec206adcb508a4c003725e117ae8f994d92d8ece # udisks-2.10.1.tar.bz2
# 5917ad67f33648935748cb98f71668431ab07ce4dc4cfd5403e0c0a2af48696a # udisks-2.9.4.tar.gz
53eb9e7f350d76cee03b1e4ad406eaf8bbf239b8d27be696a07d39fd121916ba) # disable_logind_support.patch
# b10d969d29bf2bc39c66241bac32b3bd83267f9e57273cc8781dff6e9b773c43 # remove_check.patch
## debd3661392b68f4c4ee447514c79ce4d325486c0e9a1ae0d823200c3065d091 udisks2-2.10.1-01-x86_64.pkg.tar.lz