From: Jan Palus Date: Thu, 4 Jun 2020 08:48:36 +0000 (+0200) Subject: fix build with kernel 5.7 X-Git-Tag: auto/th/xorg-driver-video-nvidia-legacy-390xx-390.132-7~1 X-Git-Url: https://git.pld-linux.org/?p=packages%2Fxorg-driver-video-nvidia-legacy-390xx.git;a=commitdiff_plain;h=bf926a1 fix build with kernel 5.7 --- diff --git a/kernel-5.7.patch b/kernel-5.7.patch new file mode 100644 index 0000000..4f0c422 --- /dev/null +++ b/kernel-5.7.patch @@ -0,0 +1,22 @@ +diff --git a/kernel/conftest.sh b/kernel/conftest.sh +index e0f937d..e2aa328 100755 +--- a/kernel/conftest.sh ++++ b/kernel/conftest.sh +@@ -139,6 +139,7 @@ test_headers() { + # Arch specific headers which need testing + FILES_ARCH="asm/book3s/64/hash-64k.h" + FILES_ARCH="$FILES_ARCH asm/set_memory.h" ++ FILES_ARCH="$FILES_ARCH asm/pgtable.h" + FILES_ARCH="$FILES_ARCH asm/powernv.h" + FILES_ARCH="$FILES_ARCH asm/tlbflush.h" + +@@ -422,6 +423,9 @@ compile_test() { + # Determine if the set_memory_array_uc() function is present. + # + CODE=" ++ #if defined(NV_ASM_PGTABLE_H_PRESENT) ++ #include ++ #endif + #if defined(NV_ASM_SET_MEMORY_H_PRESENT) + #include + #else diff --git a/xorg-driver-video-nvidia-legacy-390xx.spec b/xorg-driver-video-nvidia-legacy-390xx.spec index 055251c..3752161 100644 --- a/xorg-driver-video-nvidia-legacy-390xx.spec +++ b/xorg-driver-video-nvidia-legacy-390xx.spec @@ -58,6 +58,7 @@ Patch1: X11-driver-nvidia-desktop.patch Patch2: kernel-5.5.patch Patch3: kernel-5.6.patch Patch4: kernel-5.6-x8664.patch +Patch5: kernel-5.7.patch URL: http://www.nvidia.com/object/unix.html BuildRequires: rpmbuild(macros) >= 1.701 %{?with_kernel:%{expand:%buildrequires_kernel kernel%%{_alt_kernel}-module-build >= 3:2.6.20.2}} @@ -269,6 +270,7 @@ rm -rf NVIDIA-Linux-x86*-%{version}* %ifarch %{x8664} %patch4 -p1 %endif +%patch5 -p1 echo 'EXTRA_CFLAGS += -Wno-pointer-arith -Wno-sign-compare -Wno-unused' >> kernel/Makefile.kbuild %build