Skip to content

Instantly share code, notes, and snippets.

@meisa233
Created April 12, 2024 01:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save meisa233/ef8cfb1bd663a98e8540c3eb7bf01624 to your computer and use it in GitHub Desktop.
Save meisa233/ef8cfb1bd663a98e8540c3eb7bf01624 to your computer and use it in GitHub Desktop.
dpkg: error processing package nvidia-dkms-525(--configure):
 installed nvidia-dkms-525 package post-installation script subprocess returned error exit status 10

Examining the /var/lib/dkms/nvidia/525.78.01/build/make.log reveals multiple
cc: error: unrecognized command-line option ‘-ftrivial-auto-var-init=zero’

SOLVE:

sudo apt purge *nvidia* && sudo apt autoremove
sudo apt install gcc-12
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-12 12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment