Ok so I've got my whole Go development environment up under Windows 8, also with MinGW. I'm using the LiteIde.
C:/Go/bin/go.exe build [C:/Users/Alyx/Go/Hi]
pkg-config --cflags sdl
exec: "pkg-config": executable file not found in %PATH%
Error: process exited with code 2.
But then I get an error for "pkg-config" which at first I didn't have installed. (I'm trying to compile the SDL binding with a test that lists the fullscreen modes)
Then I got it all set up in the C:\MinGW\Bin folder (pkg-config.exe and the extra dll's).
But then it still wouldn't work. Went into CMD typed in its name "not recognized as internal..."
So then I figured I must need to put an environment variable into Windows. I tried %PATH% with the "C:\MinGW\bin" value. Nothing. Then I tried PKG_CONFIG_PATH. Nothing.
So I'm not sure what Environment Variable I need, or if there is any sort of variable I can put into LiteIde. Other than that idk what else to do.
On most systems, pkg-config looks in /usr/lib/pkgconfig , /usr/share/pkgconfig , /usr/local/lib/pkgconfig and /usr/local/share/pkgconfig for these files. It will additionally look in the colon-separated (on Windows, semicolon-separated) list of directories specified by the PKG_CONFIG_PATH environment variable.
The primary use of pkg-config is to provide the necessary details for compiling and linking a program to a library. This metadata is stored in pkg-config files. These files have the suffix . pc and reside in specific locations known to the pkg-config tool.
pkg-config exits with a nonzero code if it can't find metadata for one or more of the packages on the command line. This option is identical to "--cflags", only it prints the link flags. As with "--cflags", duplicate flags are merged (maintaining proper ordering), and flags for dependencies are included in the output.
From the error, it sounds like your attempt to add C:\MinGW\bin
to the %PATH%
variable was unsuccessful.
Make sure you're adding it to the System Environment Variables under Control Panel\All Control Panel Items\System
, Click on Advanced System Settings
, Advanced
tab, Environment Variables...
button and edit the Path
entry under System variables
(Add ;C:\MinGW\bin
to the end of the existing value). Then restart your shell or IDE to apply the system settings.
If pkg-config.exe
is in the C:\MinGW\bin
folder it will be found in %PATH%
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With