summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 124af8f862f8f27916c495a3a97412ce0aea6486 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# Maintainer: Fabrizio del Tin <fdt@euniversity.pub>
pkgname=rtl8852cu-dkms-git
_pkgbase=rtl8852cu
_pkgver="1.0.0"
pkgver=1.0.0.3.a246437
pkgrel=1
pkgdesc="Kernel module for USB WiFi Adapters that use the RTL8852CU and RTL8832CU Chipsets"
arch=('x86_64')
url="https://github.com/lwfinger/rtw8852cu"
license=('GPL2')
depends=('dkms' 'linux-headers' 'git')
makedepends=('git' 'make' 'linux-headers')
conflicts=("${_pkgbase}" "${_pkgbase}-git")
source=("git+https://github.com/lwfinger/rtw8852cu.git"
        "dkms.conf")
sha256sums=('SKIP'
            'e22dcac4ccd9b5db371cc7eb0e947e7ce51b3adcfb64224a638244159331f5ca')
procs_num=$(nproc)

pkgver() {
   cd ${srcdir}/rtw8852cu
   printf '%s' ${_pkgver} "." "$(git rev-list --count HEAD)" "." "$(git rev-parse --short HEAD)"
}

package(){
  cd ${srcdir}/rtw8852cu
    mkdir -p ${pkgdir}/usr/src/${_pkgbase}-${pkgver}
    cp -pr * ${pkgdir}/usr/src/${_pkgbase}-${pkgver}
    cp ${srcdir}/dkms.conf ${pkgdir}/usr/src/${_pkgbase}-${pkgver}
    # Set name and version
    sed -e "s/@_PKGBASE@/${_pkgbase}-dkms/" \
        -e "s/@PKGVER@/${pkgver}/" \
        -i "${pkgdir}"/usr/src/${_pkgbase}-${pkgver}/dkms.conf
}