1
0
mirror of https://github.com/moparisthebest/arch-ppa synced 2024-08-13 15:43:47 -04:00
arch-ppa/src/evdi-git/PKGBUILD

43 lines
1.2 KiB
Bash
Raw Normal View History

2018-06-19 01:34:16 -04:00
# Maintainer: ajs124
2017-08-27 13:02:19 -04:00
2018-06-19 01:34:16 -04:00
pkgname=evdi-git
2018-08-30 22:56:29 -04:00
pkgver=1.5.0.r2.r7.g8eeb07a
2017-08-27 13:02:19 -04:00
pkgrel=1
2018-06-19 01:34:16 -04:00
pkgdesc="A Linux® kernel module that enables management of multiple screens. Git version."
2017-08-27 13:02:19 -04:00
arch=('i686' 'x86_64')
2018-06-19 01:34:16 -04:00
url="https://github.com/DisplayLink/evdi"
2017-08-27 13:02:19 -04:00
license=('GPL')
2018-06-19 01:34:16 -04:00
depends=(dkms)
makedepends=(git libdrm)
install=$pkgname.install
changelog=$pkgname.Changelog
source=(git+https://github.com/DisplayLink/evdi/)
md5sums=(SKIP)
conflicts=(evdi)
provides=(evdi=$pkgver)
2017-08-27 13:02:19 -04:00
pkgver() {
2018-06-19 01:34:16 -04:00
cd ${pkgname/-git/}
git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
2017-08-27 13:02:19 -04:00
}
build() {
2018-06-19 01:34:16 -04:00
# We only need to build the library in this step, dmks will build the module
cd ${pkgname/-git/}/library
# hotfix mentioned at https://github.com/DisplayLink/evdi/issues/117
sed -i -e 's/#if KERNEL_VERSION(4, 16, 0) <= LINUX_VERSION_CODE/#if KERNEL_VERSION(4, 15, 0) <= LINUX_VERSION_CODE/' ../module/evdi_connector.c
make
2017-08-27 13:02:19 -04:00
}
package() {
2018-06-19 01:34:16 -04:00
# Predfine some target folders
SRCDIR="$pkgdir/usr/src/${pkgname/-git/}-$pkgver" # This one is needed for dkms
LIBNAME=lib${pkgname/-git/}
2017-08-27 13:02:19 -04:00
2018-06-19 01:34:16 -04:00
cd ${pkgname/-git/}
install -D -m 755 library/$LIBNAME.so $pkgdir/usr/lib/$LIBNAME.so
install -d $SRCDIR
install -D -m 755 module/* $SRCDIR
}