Re: pkg-config output on the Windows platform?



 > >  > Can anyone tell me what system pkg-config uses when some/all of the C
 > >  > Preprocessor paths contain spaces?

 > > How hard would it be to try yourself? ;)

 > Well, quite hard :-). I would have to download and attempt to build all 
 > of GTK and whatever its dependencies are. Not keen for that.

No need to (attempt to) build anything, it would have been enough to
download pkg-config for Windows:
  http://ftp.gnome.org/pub/gnome/binaries/win32/dependencies/pkg-config-0.20.zip

and for instance the GLib developer package for Windows:
  http://ftp.gnome.org/pub/gnome/binaries/win32/glib/2.12/glib-dev-2.12.4.zip

, unzip them somewhere in a patch with spaces, set PKG_CONFIG_PATH if
necessary (if you unzipped the pkg-config zipfile and developer
package into different trees), and just try running 
  pkg-config --cflags glib-2.0 .

Based on Yevgen Muntyan's reply, pkg-config's problem with spaces in
paths is cross-platform, not specific to Windows. I haven't read the
pkg-config source code in a while, and can't say whether it is
possible to fix it.

 > Actually the reason I ask this question here is that you guys have got 
 > the 'pkg-config' tool and although I'm not sure that this 'standard' 
 > started here, that was my best guess.

 > The '*-config' concept is a pretty 
 > good one when it comes to building packages that have dependencies on 
 > other ones,

When you say *-config, do you mean pkg-config, or the older *-config
shell scripts from each package (for instance, gtk-config) that were
succeded by pkg-config and the package-specific .pc files?

 > and that's what I'm trying to pick up on and use on the 
 > Windows platform... but this means that the *-config tool must support 
 > spaces,

Well, I'm not that sure this is a problem. Several people have been
using pkg-config on Windows, and nobody has noticed until now (well,
nobody has complained) that paths with spaces cause a problem. Still,
it would be nice to fix this indeed.

 > My guess is that one should use flags in a form that could be pasted 
 > into the Bash command-line.

Sure. (Or, if the --msvc-syntax flag has been passed to pkg-config,
into a cmd.exe command line.)

--tml




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]