Advertisement
Guest User

Untitled

a guest
Oct 30th, 2019
211
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # Based on the file created for Arch Linux by:
  2. # Massimiliano Torromeo <massimiliano.torromeo@gmail.com>
  3. # Bob Fanger < bfanger(at)gmail >
  4. # Filip <fila pruda com>, Det < nimetonmaili(at)gmail >
  5.  
  6. # Maintainer: Philip Muller <philm@manjaro.org>
  7. # Maintainer: Guinux <guillaume@manjaro.org>
  8. # Maintainer: Rob McCathie <rob@manjaro.org>
  9.  
  10. _linuxprefix=linux-lqx
  11. _extramodules=extramodules-lqx
  12. #kver=50
  13. pkgname=r8168-$_linuxprefix #-$kver
  14. _pkgname=r8168
  15. pkgver=8.047.04
  16. pkgrel=7
  17. pkgdesc="A kernel module for Realtek 8168 network cards"
  18. url="http://www.realtek.com.tw"
  19. license=("GPL")
  20. arch=('i686' 'x86_64')
  21. depends=('glibc' "$_linuxprefix")
  22. makedepends=("$_linuxprefix-headers")
  23. conflicts=("linux-lqx-r8168" "r8168-linux-lqx-${prev_kver}")
  24. provides=("$_pkgname=$pkgver")
  25. groups=("$_linuxprefix-extramodules")
  26. source=("https://github.com/mtorromeo/r8168/archive/$pkgver/$_pkgname-$pkgver.tar.gz" 'linux-4.15.patch')
  27. sha256sums=('4a201c7691b66e47f19172367c70a14b8b38d600f0739719c57dba9c0cf3f17a'
  28. '1c9f5bd2890bc98b552bd1b7acc91885c4ed013a2c188bfab70ddaae058fa241')
  29. install=$_pkgname.install
  30.  
  31. #prepare() {
  32. # cd "$_pkgname-$pkgver"
  33. # patch -p1 -i "$srcdir/linux-4.15.patch"
  34. #}
  35.  
  36. build() {
  37. _kernver="$(cat /usr/lib/modules/$_extramodules/version || true)"
  38.  
  39. cd "$_pkgname-$pkgver"
  40.  
  41. # avoid using the Makefile directly -- it doesn't understand
  42. # any kernel but the current.
  43. make -C /usr/lib/modules/$_kernver/build \
  44. SUBDIRS="$srcdir/$_pkgname-$pkgver/src" \
  45. EXTRA_CFLAGS="-DCONFIG_R8168_NAPI -DCONFIG_R8168_VLAN" \
  46. modules
  47. }
  48.  
  49. package() {
  50. cd "$srcdir/$_pkgname-$pkgver/src"
  51. install -D -m644 $_pkgname.ko "$pkgdir/usr/lib/modules/$_extramodules/$_pkgname.ko"
  52.  
  53. # set the kernel we've built for inside the install script
  54. sed -i -e "s/EXTRAMODULES=.*/EXTRAMODULES=${_extramodules}/g" "${startdir}/${_pkgname}.install"
  55.  
  56. find "$pkgdir" -name '*.ko' -exec gzip -9 {} \;
  57. }
Advertisement
Advertisement
Advertisement
RAW Paste Data Copied
Advertisement