[geany/geany-plugins] e4276e: Autotools: Do not make a positive decision from GP_CHECK_PLUGIN_DEPS()
Colomban Wendling
git-noreply at xxxxx
Mon Jun 17 20:10:18 UTC 2013
Branch: refs/heads/master
Author: Colomban Wendling <ban at herbesfolles.org>
Committer: Colomban Wendling <ban at herbesfolles.org>
Date: Mon, 17 Jun 2013 20:10:18 UTC
Commit: e4276ee12e7c98d904d1e704d4560c5b750098ac
https://github.com/geany/geany-plugins/commit/e4276ee12e7c98d904d1e704d4560c5b750098ac
Log Message:
-----------
Autotools: Do not make a positive decision from GP_CHECK_PLUGIN_DEPS()
GP_CHECK_PLUGIN_DEPS() must never force-enable a plugin by setting
enable_$plugin=yes, even if the plugin was in auto mode and the
dependencies are met; otherwise a further check would assume the
user forcefully enabled the plugin, and then would abort if it failed.
So, only disable the plugin or error out, but never enable it. This
allows e.g. successive calls with one failing:
GP_CHECK_PLUGIN_DEPS(myplugin, A, existing-package)
GP_CHECK_PLUGIN_DEPS(myplugin, B, missing-package)
This should disable plugin "myplugin" by default; but it would have
had aborted on the second check because the first one would have set
"enable_myplugin" to "yes" instead of "auto".
Modified Paths:
--------------
build/common.m4
Modified: build/common.m4
6 files changed, 3 insertions(+), 3 deletions(-)
===================================================================
@@ -14,8 +14,8 @@ AC_DEFUN([GP_ARG_DISABLE],
])
dnl GP_CHECK_PLUGIN_DEPS(PluginName, VARIABLE-PREFIX, modules...)
-dnl Checks whether modules exist using PKG_CHECK_MODULES, and enables/disables
-dnl plugins appropriately if enable_$plugin=auto
+dnl Checks whether modules exist using PKG_CHECK_MODULES, and error
+dnl out/disables plugins appropriately depending on enable_$plugin
AC_DEFUN([GP_CHECK_PLUGIN_DEPS],
[
AC_REQUIRE([GP_CHECK_GTK_VERSION])
@@ -29,7 +29,7 @@ AC_DEFUN([GP_CHECK_PLUGIN_DEPS],
PKG_CHECK_MODULES([$2], [$3])
elif test "$m4_tolower(AS_TR_SH(enable_$1))" = "auto"; then
PKG_CHECK_MODULES([$2], [$3],
- [m4_tolower(AS_TR_SH(enable_$1))=yes],
+ [],
[m4_tolower(AS_TR_SH(enable_$1))=no])
fi
])
--------------
This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).
More information about the Plugins-Commits
mailing list