diff options
author | Dan Nicholson <dbn.lists@gmail.com> | 2012-08-22 11:26:26 -0700 |
---|---|---|
committer | Dan Nicholson <dbn.lists@gmail.com> | 2012-08-22 11:35:13 -0700 |
commit | 1baefdf7d6ccde47f6e25d9db50b06e96b9212db (patch) | |
tree | 8c611702157625032cff9d292e0c4e4ed8a10c42 | |
parent | 617963c55e128eb182868c8a21782d2b65ea8110 (diff) |
Discourage repeated usage of VARIABLE-PREFIX in PKG_CHECK_MODULES
When the VARIABLE-PREFIX tag is used more than once in PKG_CHECK_MODULES
it can result in later runs reporting success without actually running
pkg-config. This is because PKG_CHECK_MODULES looks for FOO_CFLAGS and
FOO_LIBS from the environment as a way to allow users to override the
test. PKG_CHECK_MODULES also sets these variables, though, and
subsequent calls will simply use these values.
Although there are legitimate ways to use the same VARIABLE-PREFIX
(e.g., they're all under conditionals meaning only one will be used),
document that repeated usage is not recommended.
Freedesktop #3550
-rw-r--r-- | pkg-config.1 | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/pkg-config.1 b/pkg-config.1 index aba3758..e8df5b3 100644 --- a/pkg-config.1 +++ b/pkg-config.1 @@ -323,6 +323,11 @@ use to display what went wrong. Note that if there is a possibility the first call to PKG_CHECK_MODULES might not happen, you should be sure to include an explicit call to PKG_PROG_PKG_CONFIG in your configure.ac. + +Also note that repeated usage of VARIABLE-PREFIX is not recommended. +After the first successful usage, subsequent calls with the same +VARIABLE-PREFIX will simply use the _LIBS and _CFLAGS variables set from +the previous usage without calling \fIpkg-config\fP again. .\" .TP .I "PKG_PROG_PKG_CONFIG([MIN-VERSION])" |