# Maintainer: Lukas Fleischer # Contributor: Geoffrey Teale # Contributor: Mark, Huo Mian # Contributor: Biginoz # Contributor: Mattias Andrée <`base64 -d`(bWFhbmRyZWUK)@member.fsf.org> pkgname=(redshift redshift-gtk) pkgver=1.11 pkgrel=5 pkgdesc='Adjusts the color temperature of your screen according to your surroundings.' arch=('i686' 'x86_64') url='http://jonls.dk/redshift/' license=('GPL3') depends=('geoclue2' 'libdrm' 'libxcb' 'libxxf86vm') optdepends=('python-gobject: for redshift-gtk' 'python-xdg: for redshift-gtk' 'librsvg: for redshift-gtk') makedepends=('intltool' 'python') source=("https://github.com/jonls/${pkgname}/releases/download/v${pkgver}/${pkgname}-${pkgver}.tar.xz") md5sums=('a31d768b0348c5202e58612855a9027e') build() { pkgdesc='Adjusts the color temperature of your screen according to your surroundings.' cd "${srcdir}/${pkgname}-${pkgver}" ./configure --prefix=/usr --enable-drm --enable-randr --enable-vidmode --enable-geoclue2 \ --with-systemduserunitdir=/usr/lib/systemd/user make } package_redshift() { cd "${srcdir}/${pkgbase}-${pkgver}" make DESTDIR="${pkgdir}" install # remove redshift-gtk files rm -r "${pkgdir}/usr/lib/python3.6" rm -r "${pkgdir}/usr/share/icons" rm "${pkgdir}/usr/lib/systemd/user/redshift-gtk.service" rm "${pkgdir}/usr/share/applications/redshift-gtk.desktop" rm "${pkgdir}/usr/share/appdata/redshift-gtk.appdata.xml" rm "${pkgdir}/usr/bin/redshift-gtk" } package_redshift-gtk() { pkgdesc='GTK frontend for Redshift' depends=("${pkgbase}" 'python-gobject' 'python-xdg' 'librsvg' 'python') cd "${srcdir}/${pkgbase}-${pkgver}" make DESTDIR="${pkgdir}" install # remove files provided by redshift rm -r "${pkgdir}/usr/share/locale" rm -r "${pkgdir}/usr/share/man" rm "${pkgdir}/usr/lib/systemd/user/redshift.service" rm "${pkgdir}/usr/share/applications/redshift.desktop" rm "${pkgdir}/usr/bin/redshift" }