Can't seem to update linux-xanmod

I am trying to update linux-xanmod via this command yay -S --sudoloop linux-xanmod.

After a few prompts I get an error message.

: Checking for conflicts...
:: Checking for inner conflicts...
[Aur:1]  linux-xanmod-5.8.5-1

  1 linux-xanmod                     (Installed) (Build Files Exist)
==> Packages to cleanBuild?
==> [N]one [A]ll [Ab]ort [I]nstalled [No]tInstalled or (1 2 3, 1-3, ^4)
==> 
:: Downloaded PKGBUILD (1/1): linux-xanmod
  1 linux-xanmod                     (Installed) (Build Files Exist)
==> Diffs to show?
==> [N]one [A]ll [Ab]ort [I]nstalled [No]tInstalled or (1 2 3, 1-3, ^4)
==> 
error merging linux-xanmod: error: The following untracked working tree files would be overwritten by merge:
        0001-ZEN-Add-sysctl-and-CONFIG-to-disallow-unprivileged-CLONE_NEWUSER.patch
Please move or remove them before you merge.
Aborting

I am not too sure how to solve this or why this is happening?

You’ve got an existing srcdir, a file has changed, and the new one won’t merge, probably because you didn’t clean build? Try a clean build instead.

2 Likes

Should I remove srcdir? I am not too sure what you mean by clean build?

If you read the output from your post above, you can see where yay is asking you if you want to cleanbuild your packages. Instead of just hitting enter, select a or 1 at that prompt.

In general, whenever you have an issue building a package you should first try a clean build.

2 Likes

Ok I did that but now I have an issue with importing keys.

:: (1/1) Parsing SRCINFO: linux-xanmod

:: PGP keys need importing:
 -> ABAF11C65A2970B130ABE3C479BE3E4300411886, required by: linux-xanmod
 -> 647F28654894E3BD457199BE38DBBDC86092693E, required by: linux-xanmod
==> Import? [Y/n] 
:: Importing keys with gpg...
gpg: keyserver receive failed: No name
problem importing keys

You may need to import manually if you’re using a broken keyserver, or just switch your default to a working keyserver hkps://keyserver.ubuntu.com in $HOME/.gnupg/gpg.conf for AUR package keys and /etc/pacman.d/gnupg/gpg.conf for repo package keys.

https://wiki.archlinux.org/index.php/Arch_User_Repository#Acquire_a_PGP_public_key_if_needed

It’s also possible your DNS resolver is broken.

I could try that.

It only seems to happen to this package though? Not any other package when I use yay.

Do other packages ask you to import a PGP key?

Nah they haven’t asked this