-1

I was installing gcc and gdb in my windows 64bit env but I face a network issue, then when I tried to run "pacman -S mingw-w64-x86_64-gdb" or "pacman -Syu" it shows : screenshot

Any solutions?

I tried removing /var/lib/pacman/db.lck using comand " pacman -R " but it did not work!

user4581301
  • 33,082
  • 7
  • 33
  • 54
Mokh
  • 1
  • 2
    Did you try `rm -f /var/lib/pacman/db.lck` to delete the file? By remove they mean delete the file not use the package manager to remove a package. – drescherjm May 11 '23 at 18:24
  • 1
    I removed the VS code and gcc tags because they're totally unrelated to the question, but left the C++ and gdb tags because they may make this easier to find. That said the same problem could happen with any tool and language. – user4581301 May 11 '23 at 18:33
  • 2
    Stackoverflow usage note: there are almost no good reasons to include an image of text, particularly code and error messages, in a question or answer. Images exclude too many people from participating. – user4581301 May 11 '23 at 18:36

1 Answers1

0

By telling you to remove a lock file /var/lib/pacman/db.lck they want you to delete the file:

Type the following command in the mingw64 terminal to delete the file:

rm -f /var/lib/pacman/db.lck

They do not mean use the remove option of the package manager. The lock file is not a package. Instead its a file that pacman creates to make sure that you don't attempt multiple simultaneous installs which could corrupt the system packages.

drescherjm
  • 10,365
  • 5
  • 44
  • 64