[mate-indicator-applet] 02/07: debian/patches: Improve 2001_AyatanaIndicators-support.patch. Add AC_ARG_WITHs for choosing a build against Ayatana Indicators or Ubuntu Indicators.
Mike Gabriel
sunweaver at debian.org
Tue Jan 9 11:44:58 UTC 2018
This is an automated email from the git hooks/post-receive script.
sunweaver pushed a commit to branch master
in repository mate-indicator-applet.
commit e3def9c2c7442104e63b6473fe298b3e3047e9c3
Author: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
Date: Tue Jan 9 00:49:14 2018 +0100
debian/patches: Improve 2001_AyatanaIndicators-support.patch. Add AC_ARG_WITHs for choosing a build against Ayatana Indicators or Ubuntu Indicators.
---
.../patches/2001_AyatanaIndicators-support.patch | 108 +++++++++++++++------
1 file changed, 78 insertions(+), 30 deletions(-)
diff --git a/debian/patches/2001_AyatanaIndicators-support.patch b/debian/patches/2001_AyatanaIndicators-support.patch
index f174fe0..d4b85f7 100644
--- a/debian/patches/2001_AyatanaIndicators-support.patch
+++ b/debian/patches/2001_AyatanaIndicators-support.patch
@@ -15,7 +15,7 @@
PKG_CHECK_MODULES(APPLET, gtk+-3.0 >= $GTK_REQUIRED_VERSION
x11
-@@ -37,16 +41,56 @@
+@@ -37,16 +41,104 @@
AC_SUBST(APPLET_CFLAGS)
AC_SUBST(APPLET_LIBS)
@@ -23,9 +23,25 @@
- [have_indicator_ng="yes"],
- [have_indicator_ng="no"])
+# Which Indicator implementation shall we use?
+
+-if test "x$have_indicator_ng" = "xyes"; then
+- PKG_CHECK_MODULES(INDICATOR, indicator3-0.4 >= $INDICATOR_NG_VERSION
++AC_ARG_WITH([ayatana-indicators],
++ [AS_HELP_STRING([--with-ayatana-indicators],
++ [build against Ayatana Indicators])],
++ [with_ayatana_indicators='yes']
++ [with_ayatana_indicators='no']
++)
++
++AC_ARG_WITH([ubuntu-indicators],
++ [AS_HELP_STRING([--with-ubuntu-indicators],
++ [build against Ubuntu Indicators])],
++ [with_ubuntu_indicators='yes']
++ [with_ubuntu_indicators='no']
++)
+
+###
-+### Look for Ubuntu Indicators first
++### Look for Ubuntu Indicators
+###
+
+PKG_CHECK_EXISTS(indicator3-0.4,
@@ -35,50 +51,82 @@
+PKG_CHECK_EXISTS(indicator3-0.4 >= $UBUNTU_INDICATOR_NG_VERSION,
+ [have_ubuntuindicator_ng="yes"],
+ [have_ubuntuindicator_ng="no"])
-
--if test "x$have_indicator_ng" = "xyes"; then
-- PKG_CHECK_MODULES(INDICATOR, indicator3-0.4 >= $INDICATOR_NG_VERSION
++
+if test "x$have_ubuntuindicator_ng" = "xyes"; then
+ PKG_CHECK_MODULES(INDICATOR, indicator3-0.4 >= $UBUNTU_INDICATOR_NG_VERSION
libido3-0.1 >= 13.10,
[AC_DEFINE(HAVE_INDICATOR_NG, 1, "New style indicators support")])
+elif test "x$have_ubuntuindicator" = "xyes"; then
+ PKG_CHECK_MODULES(INDICATOR, indicator3-0.4 >= $UBUNTU_INDICATOR_REQUIRED_VERSION)
++fi
+
- else
-- PKG_CHECK_MODULES(INDICATOR, indicator3-0.4 >= $INDICATOR_REQUIRED_VERSION)
++###
++### Look for Ayatana Indicators
++###
++
++PKG_CHECK_EXISTS(ayatana-indicator3-0.4,
++ [have_ayatanaindicator="yes"],
++ [have_ayatanaindicator="no"])
+
-+ ###
-+ ### If we lack Ubuntu Indicators, look for Ayatana Indicators, alternatively.
-+ ###
-+
-+ PKG_CHECK_EXISTS(ayatana-indicator3-0.4,
-+ [have_ayatanaindicator="yes"],
-+ [have_ayatanaindicator="no"])
-+
-+ PKG_CHECK_EXISTS(ayatana-indicator3-0.4 >= $AYATANA_INDICATOR_NG_VERSION,
-+ [have_ayatanaindicator_ng="yes"],
-+ [have_ayatanaindicator_ng="no"])
-+
-+ if test "x$have_ayatanaindicator_ng" = "xyes"; then
-+ PKG_CHECK_MODULES(INDICATOR, ayatana-indicator3-0.4 >= $AYATANA_INDICATOR_NG_VERSION
-+ libayatana-ido3-0.4 >= 0.4.0,
-+ [AC_DEFINE(HAVE_INDICATOR_NG, 1, "New style indicators support")])
-+ elif test "x$have_ayatanaindicator" = "xyes"; then
-+ PKG_CHECK_MODULES(INDICATOR, ayatana-indicator3-0.4 >= $AYATANA_INDICATOR_REQUIRED_VERSION)
-+ fi
++PKG_CHECK_EXISTS(ayatana-indicator3-0.4 >= $AYATANA_INDICATOR_NG_VERSION,
++ [have_ayatanaindicator_ng="yes"],
++ [have_ayatanaindicator_ng="no"])
++
++if test "x$have_ayatanaindicator_ng" = "xyes"; then
++ PKG_CHECK_MODULES(INDICATOR, ayatana-indicator3-0.4 >= $AYATANA_INDICATOR_NG_VERSION
++ libayatana-ido3-0.4 >= 0.4.0,
++ [AC_DEFINE(HAVE_INDICATOR_NG, 1, "New style indicators support")])
++elif test "x$have_ayatanaindicator" = "xyes"; then
++ PKG_CHECK_MODULES(INDICATOR, ayatana-indicator3-0.4 >= $AYATANA_INDICATOR_REQUIRED_VERSION)
+fi
+
-+if test "x$have_ayatanaindicator" == "xyes"; then
++if test "x$have_ayatanaindicator" == "xyes" &&
++ test "x$with_ubuntu_indicators" == "xno"; then
++
++ # use Ayatana Indicators (because they are present, and noone is enforcing Ubuntu Indicators)
+ AC_DEFINE(HAVE_AYATANA_INDICATORS, 1, "Ayatana Indicators Support")
-+elif test "x$have_ubuntuindicator" == "xyes"; then
++
++elif test "x$have_ubuntuindicator" == "xyes" &&
++ test "x$with_ayatana_indicators" == "xno"; then
++
++ # use Ubuntu Indicators (because they are present, and noone is enforcing Ayatana Indicators)
+ AC_DEFINE(HAVE_UBUNTU_INDICATORS, 1, "Ubuntu Indicators Support")
-+else
++
++elif test "x$have_ubuntuindicator" == "xyes" &&
++ test "x$have_ayatanaindicator" == "xyes" &&
++ test "x$with_ayatana_indicators" == "xyes" &&
++
++ # both Indicator implementations are present, and we are asked to use Ayatana Indicators
++ AC_DEFINE(HAVE_AYATANA_INDICATORS, 1, "Ayatana Indicators Support (enforced)")
++
++elif test "x$have_ubuntuindicator" == "xyes" &&
++ test "x$have_ayatanaindicator" == "xyes" &&
++ test "x$with_ubuntu_indicators" == "xyes" &&
++
++ # both Indicator implementations are present, and we are asked to use Ubuntu Indicators
++ AC_DEFINE(HAVE_UBUNTU_INDICATORS, 1, "Ubuntu Indicators Support (enforced)")
++
++elif test "x$have_ubuntuindicator" == "xyes" &&
++ test "x$have_ayatanaindicator" == "xno" &&
++ test "x$with_ayatana_indicators" == "xyes" &&
++
++ AC_MSG_ERROR([Ubuntu Indicators are present, but you want to build mate-indicator-applet against Ayatana Indicators. This does not match.])
++
++elif test "x$have_ubuntuindicator" == "xno" &&
++ test "x$have_ayatanaindicator" == "xyes" &&
++ test "x$with_ubuntu_indicators" == "xyes" &&
++
++ AC_MSG_ERROR([Ayatana Indicators are present, but you want to build mate-indicator-applet against Ubuntu Indicators. This does not match.])
++
+ else
+- PKG_CHECK_MODULES(INDICATOR, indicator3-0.4 >= $INDICATOR_REQUIRED_VERSION)
++
+ AC_MSG_ERROR([Either Ayatana Indicators or Ubuntu Indicators are required to build mate-indicator-applet.])
++
fi
AC_SUBST(INDICATOR_CFLAGS)
-@@ -63,12 +107,24 @@
+@@ -63,12 +155,24 @@
# Indicator Info
###########################
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mate/mate-indicator-applet.git
More information about the pkg-mate-commits
mailing list