# Contributor: Stuart Cardall # Maintainer: Stuart Cardall pkgname=modemmanager pkgver=1.10.4 pkgrel=0 pkgdesc="ModemManager library" url="http://www.freedesktop.org/wiki/Software/ModemManager" arch="all" license="GPL-2.0-or-later AND LGPL-2.1-or-later" depends_dev="libmm-glib" makedepends="$depends_dev gobject-introspection-dev gtk-doc vala libgudev-dev polkit-dev libmbim-dev libqmi-dev linux-headers" checkdepends="glib-dev" options="!check" # https://bugs.freedesktop.org/show_bug.cgi?id=101197 subpackages="$pkgname-lang $pkgname-doc libmm-glib:libmm $pkgname-dev" source="https://www.freedesktop.org/software/ModemManager/ModemManager-$pkgver.tar.xz $pkgname.rules " builddir="$srcdir"/ModemManager-$pkgver build() { export CFLAGS="$CFLAGS -Wno-error" ./configure --prefix=/usr \ --sysconfdir=/etc \ --mandir=/usr/share/man \ --infodir=/usr/share/info \ --localstatedir=/var \ --with-polkit=permissive \ --enable-gtk-doc \ --disable-static \ --enable-more-warnings \ --with-newest-qmi-commands \ --with-dbus-sys-dir=/etc/dbus-1 \ --enable-vala=yes make } libmm() { cd "$builddir" mkdir -p "$subpkgdir" make DESTDIR="$subpkgdir" -C libmm-glib install # move dev files to modemmnager-dev mv -f "$subpkgdir/usr/include/libmm-glib" "$pkgdir/usr/include/" mv -f "$subpkgdir/usr/share/gir-1.0" "$pkgdir/usr/share/" rmdir "$subpkgdir/usr/include" "$subpkgdir/usr/share" } package() { make DESTDIR="$pkgdir" install make DESTDIR="$pkgdir" -C libmm-glib uninstall rmdir "$pkgdir"/usr/lib/girepository-1.0 # in libmm-glib rm -rf "$pkgdir"/usr/share/dbus-1/system-services #systemd-service mkdir -p "$pkgdir/usr/share/polkit-1/rules.d" install -m644 -D "$srcdir/$pkgname.rules" \ "$pkgdir/usr/share/polkit-1/rules.d/01-org.freedesktop.ModemManager.rules" # post-install message mkdir -p "$pkgdir/usr/share/doc/$pkgname" cat > $pkgdir/usr/share/doc/$pkgname/README.alpine <