Skip to content
instance method

MakeMakefile#pkg_config

pkg_config(pkg, *options)

Returns compile/link information about an installed library in a tuple of [cflags, ldflags, libs], by using the command found first in the following commands:

  1. If --with-{pkg}-config={command} is given via command line option: {command} {options}

  2. {pkg}-config {options}

  3. pkg-config {options} {pkg}

Where options is the option name without dashes, for instance "cflags" for the --cflags flag.

The values obtained are appended to $INCFLAGS, $CFLAGS, $LDFLAGS and $libs.

If one or more options argument is given, the config command is invoked with the options and a stripped output string is returned without modifying any of the global values mentioned above.

See also #modified? #rm_f #log_src #rm_rf also in 4.1 · 3.4 · 3.3 · 3.2 · 3.1 · 3.0