Package Details: nvidia-470xx-utils 470.256.02-7

Git Clone URL: https://aur.archlinux.org/nvidia-470xx-utils.git (read-only, click to copy)
Package Base: nvidia-470xx-utils
Description: NVIDIA drivers utilities
Upstream URL: http://www.nvidia.com/
Keywords: driver nvidia video
Licenses: custom
Conflicts: nvidia-libgl, nvidia-utils
Provides: nvidia-libgl, nvidia-utils, opengl-driver, vulkan-driver
Submitter: jonathon
Maintainer: Sinyria (cysp74, SoftExpert)
Last Packager: SoftExpert
Votes: 99
Popularity: 0.80
First Submitted: 2021-10-31 00:50 (UTC)
Last Updated: 2024-11-10 08:39 (UTC)

Dependencies (6)

Required by (299)

Sources (11)

Latest Comments

« First ‹ Previous 1 .. 3 4 5 6 7 8 9 10 11 12 13 .. 40 Next › Last »

benjarobin commented on 2024-05-12 17:55 (UTC) (edited on 2024-05-12 17:56 (UTC) by benjarobin)

I improved the second patch to properly fix warning during conftest related to EFI (instead of hiding it).

To build a package with a proper fix, do the following:

git clone https://aur.archlinux.org/nvidia-470xx-utils.git
cd nvidia-470xx-utils
curl https://0x0.st/XKB6.patch -o 0001-Fix-GCC-14-build.patch
patch -p1 -i 0001-Fix-GCC-14-build.patch
makepkg

See fixes provided by: https://0x0.st/XKB6.patch

benjarobin commented on 2024-05-12 16:26 (UTC) (edited on 2024-05-12 16:32 (UTC) by benjarobin)

Using -fpermissive is wrong, and introduces a major bug: The call to vmap is done with the wrong function call (missing one argument), as explained in [2].

I did create various patches in order to fix it properly, see [1] and the Nvidia fix that was back-ported [3].

To build a package with a proper fix, do the following:

git clone https://aur.archlinux.org/nvidia-470xx-utils.git
cd nvidia-470xx-utils
curl https://0x0.st/XKmG.patch -o 0001-Fix-GCC-14-build.patch
patch -p1 -i 0001-Fix-GCC-14-build.patch
makepkg

[1] https://0x0.st/XKmG.patch

[2] https://forums.developer.nvidia.com/t/nvidia-modules-build-failure-with-upcoming-gcc-14-and-recent-kernels-due-to-misfiring-conftest-sh-test-heads-up/279072

[3] https://github.com/NVIDIA/open-gpu-kernel-modules/commit/811073c51e1f098834e90e67a074f1746b6e2831#diff-32da369dcd8cd223fa47c8b86028f1a7572ed699c33f2057f4702e4b36f13dd5

unixv commented on 2024-05-12 15:20 (UTC)

@a821, @Mechanicus: actually i tried easiest workaround which is downgrade ['gcc-libs', 'gcc'] from 14.1.1+r1+g43b730b9134-1 to 13.2.1-6 and has been compiled and worked again as previously. Thanks you folks for your efforts to find a workarounds.

loading packages...
warning: downgrading package gcc (14.1.1+r1+g43b730b9134-1 => 13.2.1-6)
warning: downgrading package gcc-libs (14.1.1+r1+g43b730b9134-1 => 13.2.1-6)
resolving dependencies...
looking for conflicting packages...

Package (2)  Old Version               New Version  Net Change

gcc          14.1.1+r1+g43b730b9134-1  13.2.1-6     -17.55 MiB
gcc-libs     14.1.1+r1+g43b730b9134-1  13.2.1-6      -3.81 MiB

==> dkms install --no-depmod nvidia/470.239.06 -k 6.6.30-2-lts
==> depmod 6.6.30-2-lts
(6/6) Updating linux initcpios...
==> Building image from preset: /etc/mkinitcpio.d/linux-lts.preset: 'default'
==> Using default configuration file: '/etc/mkinitcpio.conf'
  -> -k /boot/vmlinuz-linux-lts -g /boot/initramfs-linux-lts.img
==> Starting build: '6.6.30-2-lts'
  -> Running build hook: [base]
  -> Running build hook: [udev]
  -> Running build hook: [microcode]
  -> Running build hook: [keyboard]

Mechanicus commented on 2024-05-12 13:08 (UTC)

@unixv: Try -fpermissive patch. Copy the context to a file, for example workaround.patch, and then apply to the repo: git apply workaround.patch

diff --git a/PKGBUILD b/PKGBUILD
index 15fd45f..639ea2c 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -22,7 +22,8 @@ source=('nvidia-drm-outputclass.conf'
         "kernel-6.4.patch"
         "kernel-6.5.patch"
         "kernel-6.6.patch"
-        "kernel-6.1.76_6.6.15_6.7.3.patch")
+        "kernel-6.1.76_6.6.15_6.7.3.patch"
+        "gcc-permissive.patch")

 sha512sums=('de7116c09f282a27920a1382df84aa86f559e537664bb30689605177ce37dc5067748acf9afd66a3269a6e323461356592fdfc624c86523bf105ff8fe47d3770'  #nvidia-drm-outputclass
             '4b3ad73f5076ba90fe0b3a2e712ac9cde76f469cd8070280f960c3ce7dc502d1927f525ae18d008075c8f08ea432f7be0a6c3a7a6b49c361126dcf42f97ec499'  #nvidia-470xx.sysusers
@@ -31,7 +32,8 @@ sha512sums=('de7116c09f282a27920a1382df84aa86f559e537664bb30689605177ce37dc50677
             'd9df8b13d5fbe4f456a31de3679fd11aca7cd88771f8f11a5cc8ab17bab05861823b26d2d467593e5b90967a2902db691ca832f09fe21a5975eb3e4d6275e00c'  #kernel-6.4 patch
             '40ea983c81851b8a20629a943f9692cc0e007c815f46dd3b63cf1d7a44ccbed1ac5f9a3110720de54b017b9f9c7f5cc534ec6e097bc02fa5bd1de6b0a730c803'  #kernel-6.5 patch
             'fa9985b0dd9d7a973019da88a40d7830ea53df83af2d71d498b6b9dde04c0c797570991239dafc30cc2ccabbb8e8a7c3fa1bf89f26d8e8a26e624d7a17e5a84b'  #kernel-6.6 patch
-            'e0756be173930faf6b5104562d8092ccf8967fba7bf1a97d8e0e86e76a5e0e944b41f24aaee98eb8c7b3ad995353f6acb20a0f6173b82ee718664293a6493fea') #kernel-6.1 patch
+            'e0756be173930faf6b5104562d8092ccf8967fba7bf1a97d8e0e86e76a5e0e944b41f24aaee98eb8c7b3ad995353f6acb20a0f6173b82ee718664293a6493fea'  #kernel-6.1 patch
+            '5338c833081300a1857a2ed3e89a9ba67397b68a65a4cb029f69001519fc18d2b0f4af0aad389a2a0c0ecc7fd513cc47030a2f3c53b5b185fad25053b6a1f59c') #gcc-permissive patch

 create_links() {
     # create soname links
@@ -49,6 +51,9 @@ prepare() {
     cd "${_pkg}"
     bsdtar -xf nvidia-persistenced-init.tar.bz2

+    # GCC-14 workaround
+    patch -p1 -i "$srcdir/gcc-permissive.patch"
+
     cd kernel

 #    patch -p1 -i "$srcdir/kernel-6.4.patch"
diff --git a/gcc-permissive.patch b/gcc-permissive.patch
new file mode 100644
index 0000000..7f20dbd
--- /dev/null
+++ b/gcc-permissive.patch
@@ -0,0 +1,11 @@
+diff -Naru a/kernel/Kbuild b/kernel/Kbuild
+--- a/kernel/Kbuild    2024-02-03 08:25:55.000000000 +0200
++++ b/kernel/Kbuild    2024-05-12 15:37:12.620937599 +0300
+@@ -73,6 +73,7 @@
+ EXTRA_CFLAGS += $(call cc-option,-Werror=undef,)
+ EXTRA_CFLAGS += -DNV_SPECTRE_V2=$(NV_SPECTRE_V2)
+ EXTRA_CFLAGS += -DNV_KERNEL_INTERFACE_LAYER
++EXTRA_CFLAGS += -fpermissive
+ 
+ #
+ # Detect SGI UV systems and apply system-specific optimizations.

a821 commented on 2024-05-12 07:22 (UTC)

@unixv: did you read any of the latest comments / workarounds? If so, what did you try?

unixv commented on 2024-05-12 03:34 (UTC) (edited on 2024-05-12 03:36 (UTC) by unixv)

it's failed to compile and I'm no longer able to use my nvidia-470xx card .

(5/6) Install DKMS modules ==> dkms install --no-depmod nvidia/470.239.06 -k 6.6.30-2-lts Error! Bad return status for module build on kernel: 6.6.30-2-lts (x86_64) Consult /var/lib/dkms/nvidia/470.239.06/build/make.log for more information. ==> WARNING:dkms install --no-depmod nvidia/470.239.06 -k 6.6.30-2-lts' exited 10 `

Mechanicus commented on 2024-05-11 15:33 (UTC)

@SoftExpert, older GCC will also work with -fpermissive flag, it is supported since GCC-4 version

SoftExpert commented on 2024-05-11 09:14 (UTC)

@TechXero: We will update as soon as consensus is reached towards the needed patch - I still see that some differences allow to solve edge cases. We also want to avoid breaking currently working configurations. Can someone confirm that the patch will not break the build processus with older GCC ?

dimytch commented on 2024-05-11 09:04 (UTC)

https://bbs.archlinux.org/viewtopic.php?id=295600 Does not compile without hands for current LTS kernel too.