pidgin/purple-plugin-pack

Parents eeda864ecb1b
Children d550a70c5fb1
Add --with-purple-ver configure param and build for purple2 by default
--- a/configure.ac Thu Apr 06 02:06:29 2017 -0300
+++ b/configure.ac Thu Apr 06 02:07:49 2017 -0300
@@ -68,10 +68,20 @@
fi
AC_SUBST(CFLAGS)
+AC_ARG_WITH(purple-ver,
+ AC_HELP_STRING([--with-purple-ver], [set to 3 to compile against libpurple3]),
+ ,with_purple_ver=2)
+
+if test "x$with_purple_ver" = "x3" ; then
+ # this is used as the suffix below (for purple-3, pidgin-3, etc)
+ # and also as the -3 param to plugin_pack.py
+ PURPLE_VER="-3"
+fi
+
dnl #######################################################################
dnl # Check for purple
dnl #######################################################################
-PKG_CHECK_MODULES(PURPLE, purple-3,
+PKG_CHECK_MODULES(PURPLE, purple${PURPLE_VER},
[
AC_DEFINE(HAVE_PURPLE, 1, [Define if we've found libpurple.])
])
@@ -115,7 +125,7 @@
dnl #######################################################################
dnl # Check for pidgin
dnl #######################################################################
-PKG_CHECK_MODULES(PIDGIN, pidgin-3,
+PKG_CHECK_MODULES(PIDGIN, pidgin${PURPLE_VER},
[
AC_DEFINE(HAVE_PIDGIN, 1, [Define if we've found pidgin.])
HAVE_PIDGIN="yes"
@@ -155,7 +165,7 @@
dnl #######################################################################
dnl # Check for finch
dnl #######################################################################
-PKG_CHECK_MODULES(FINCH, finch,
+PKG_CHECK_MODULES(FINCH, finch${PURPLE_VER},
[
AC_DEFINE(HAVE_FINCH, 1, [Define if we've found finch.])
HAVE_FINCH="yes"
--- a/plugin_pack.py Thu Apr 06 02:06:29 2017 -0300
+++ b/plugin_pack.py Thu Apr 06 02:07:49 2017 -0300
@@ -400,12 +400,12 @@
# setup a second call to determine the plugins to be built
print('{}\n\n{}\n{}\n\n{}\n{}\n{}'.format(
- 'PP_BUILD=`$PYTHON $srcdir/plugin_pack.py build_dirs $DEPENDENCIES $with_plugins`',
+ 'PP_BUILD=`$PYTHON $srcdir/plugin_pack.py $PURPLE_VER build_dirs $DEPENDENCIES $with_plugins`',
'PP_BUILD_DIRS=`echo $PP_BUILD | sed \'s/,/\ /g\'`',
'AC_SUBST(PP_BUILD_DIRS)',
- 'PP_PURPLE_BUILD="$PYTHON $srcdir/plugin_pack.py -p show_names $PP_BUILD"',
- 'PP_PIDGIN_BUILD="$PYTHON $srcdir/plugin_pack.py -P show_names $PP_BUILD"',
- 'PP_FINCH_BUILD="$PYTHON $srcdir/plugin_pack.py -f show_names $PP_BUILD"'))
+ 'PP_PURPLE_BUILD="$PYTHON $srcdir/plugin_pack.py -p $PURPLE_VER show_names $PP_BUILD"',
+ 'PP_PIDGIN_BUILD="$PYTHON $srcdir/plugin_pack.py -P $PURPLE_VER show_names $PP_BUILD"',
+ 'PP_FINCH_BUILD="$PYTHON $srcdir/plugin_pack.py -f $PURPLE_VER show_names $PP_BUILD"'))
commands['config_file'] = config_file
def dependency_graph(self, args):
@@ -561,7 +561,7 @@
types = []
depends = []
- purple_ver = 3
+ purple_ver = 2
try:
shortopts = 'adfiPp23'