Reputation: 93
I installed MSYS2 and inside the MSYS2 (MINGW64) shell I installed pkg-config and gtk4. When I ran the command
pkg-config --modversion gtk4
inside the MSYS2 shell, everything just worked fine. But as soon as I ran the exact same command inside a Windows shell, I got this error message:
Package gtk4 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gtk4.pc'
to the PKG_CONFIG_PATH environment variable
No package 'gtk4' found
I then tried fiddling around with the PKG_CONFIG_PATH environment variable, but that did nothing. Then, I tried
where pkg-config
and got this:
d:\devkitPro\msys2\usr\bin\pkg-config.exe
D:\msys64\mingw64\bin\pkg-config.exe
Notice anything strange? Windows isn't running the same pkg-config
that I was using with MSYS2 but is instead running devkitPro's installation.
Upvotes: 0
Views: 1907
Reputation: 93
How to solve this
Open up the editor for the PATH environment variable, then select the path that leads to the undesired pkg-config installation (aka the first line of the where-output). Click "Move down" repeatedly until you arrive at the very bottom. Click OK. Restart your terminal. Done.
Upvotes: -1