Update/delete things

This commit is contained in:
moparisthebest
2018-06-19 01:34:16 -04:00
parent 8213027401
commit a650cef370
40 changed files with 50 additions and 1298 deletions

View File

@@ -1,56 +1,43 @@
# Maintainer: Chris Severance aur.severach aATt spamgourmet dott com
# Contributor: ajs124
# Maintainer: ajs124
set -u
pkgname='evdi-git'
pkgver=1.5.0_r2.r0.gdc3c9d6
_pkgver="${pkgver%%.r*}"
pkgname=evdi-git
pkgver=1.5.0.r2.r6.ge08998f
pkgrel=1
pkgdesc="A Linux® kernel module that enables management of multiple screens."
pkgdesc+=' Git version.'
pkgdesc="A Linux® kernel module that enables management of multiple screens. Git version."
arch=('i686' 'x86_64')
url='https://github.com/DisplayLink/evdi'
url="https://github.com/DisplayLink/evdi"
license=('GPL')
depends=('dkms')
makedepends=('git' 'libdrm')
provides=("evdi=${_pkgver}")
conflicts=('evdi')
install=${pkgname}.install
changelog="${pkgname}.Changelog"
_srcdir="${pkgname%-git}"
source=("git+https://github.com/DisplayLink/evdi/")
sha256sums=('SKIP')
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)
pkgver() {
set -u
cd "${_srcdir}"
# extra -r interfers with version management
local _t1="$(git describe --tags)" # v1.5.0-r2
local _t1a="${_t1//-/_}"
local _t2="$(git describe --long --tags)" # v1.5.0-r2-0-gdc3c9d6
local _t2a="${_t2//${_t1}/${_t1a}}"
sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' <<< "${_t2a}"
set +u
cd ${pkgname/-git/}
git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}
build() {
set -u
# We only need to build the library in this step, dmks will build the module
#cd "${_srcdir}/library"
# DKMS builds are hard to debug. We build it here and throw it away.
cd "${_srcdir}"
make
set +u
# 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
}
package() {
set -u
cd "${_srcdir}"
install -Dpm755 "library/lib${pkgname%-git}.so" -t "${pkgdir}/usr/lib/"
# Predfine some target folders
SRCDIR="$pkgdir/usr/src/${pkgname/-git/}-$pkgver" # This one is needed for dkms
LIBNAME=lib${pkgname/-git/}
local _DKMS="${pkgdir}/usr/src/${pkgname%-git}-${_pkgver}"
install -Dpm644 module/* -t "${_DKMS}/"
make -j1 -C "${_DKMS}" clean
set +u
}
set +u
cd ${pkgname/-git/}
install -D -m 755 library/$LIBNAME.so $pkgdir/usr/lib/$LIBNAME.so
install -d $SRCDIR
install -D -m 755 module/* $SRCDIR
}