Date: Tuesday, December 24, 2019 @ 03:27:14
  Author: heftig
Revision: 539691

archrelease: copy trunk to community-testing-x86_64

Added:
  r8168/repos/community-testing-x86_64/
  r8168/repos/community-testing-x86_64/PKGBUILD
    (from rev 539688, r8168/trunk/PKGBUILD)
  r8168/repos/community-testing-x86_64/kernel-5.4.patch
    (from rev 539688, r8168/trunk/kernel-5.4.patch)

------------------+
 PKGBUILD         |   47 +++++++++++++++++++++++++++++++++++++++++++++++
 kernel-5.4.patch |   12 ++++++++++++
 2 files changed, 59 insertions(+)

Copied: r8168/repos/community-testing-x86_64/PKGBUILD (from rev 539688, 
r8168/trunk/PKGBUILD)
===================================================================
--- community-testing-x86_64/PKGBUILD                           (rev 0)
+++ community-testing-x86_64/PKGBUILD   2019-12-24 03:27:14 UTC (rev 539691)
@@ -0,0 +1,47 @@
+# Maintainer: Massimiliano Torromeo <massimiliano.torro...@gmail.com>
+# Contributor: Bob Fanger < bfanger(at)gmail >
+# Contributor: Filip <fila pruda com>, Det < nimetonmaili(at)gmail >
+
+pkgname=r8168
+pkgver=8.047.05
+pkgrel=9
+pkgdesc="A kernel module for Realtek 8168 network cards"
+url="http://www.realtek.com.tw";
+license=("GPL")
+arch=('x86_64')
+makedepends=('linux-headers')
+source=(https://github.com/mtorromeo/r8168/archive/$pkgver/$pkgname-$pkgver.tar.gz
+               kernel-5.4.patch)
+sha256sums=('1344bf3d8a1d01a1be8805b48940be1b946b5e694ca75bd14ed1c76fd4c3d67b'
+            'be79c151c6323bb4d340e31e44fae25a36a93d317812fe5d75c54649ed2508b0')
+
+prepare() {
+       cd "$pkgname-$pkgver"
+       patch -Np1 -i ../kernel-5.4.patch
+}
+
+build() {
+       local KERNEL_VERSION=$(</usr/src/linux/version)
+       msg2 "Kernel = $KERNEL_VERSION"
+
+       cd "$pkgname-$pkgver"
+       # avoid using the Makefile directly -- it doesn't understand
+       # any kernel but the current.
+       make -C /usr/src/linux M="$PWD/src" \
+                       EXTRA_CFLAGS="-DCONFIG_R8168_NAPI -DCONFIG_R8168_VLAN" \
+                       modules
+}
+
+package() {
+       depends=('glibc' 'linux')
+
+       local extradir=/usr/lib/modules/$(</usr/src/linux/version)/extramodules
+       cd "$pkgname-$pkgver"
+       install -Dt "$pkgdir$extradir" -m644 src/*.ko
+       find "$pkgdir" -name '*.ko' -exec xz {} +
+
+       echo "blacklist r8169" | \
+               install -Dm644 /dev/stdin 
"$pkgdir/usr/lib/modprobe.d/$pkgname.conf"
+}
+
+# vim:set sw=0 noet:

Copied: r8168/repos/community-testing-x86_64/kernel-5.4.patch (from rev 539688, 
r8168/trunk/kernel-5.4.patch)
===================================================================
--- community-testing-x86_64/kernel-5.4.patch                           (rev 0)
+++ community-testing-x86_64/kernel-5.4.patch   2019-12-24 03:27:14 UTC (rev 
539691)
@@ -0,0 +1,12 @@
+diff -u -r r8168-8.047.05/src/r8168_n.c r8168-8.047.05-5.4/src/r8168_n.c
+--- r8168-8.047.05/src/r8168_n.c       2019-11-25 18:01:38.000000000 +0000
++++ r8168-8.047.05-5.4/src/r8168_n.c   2019-11-25 23:36:15.427988367 +0000
+@@ -56,7 +56,7 @@
+ #include <linux/rtnetlink.h>
+ #include <linux/completion.h>
+ 
+-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26) && LINUX_VERSION_CODE < 
KERNEL_VERSION(5,4,0)
+ #include <linux/pci-aspm.h>
+ #endif
+ #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,37)

Reply via email to