aboutsummaryrefslogtreecommitdiffstats
path: root/lang/python/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'lang/python/configure.ac')
-rw-r--r--lang/python/configure.ac22
1 files changed, 20 insertions, 2 deletions
diff --git a/lang/python/configure.ac b/lang/python/configure.ac
index 34033ed3..116d7d0b 100644
--- a/lang/python/configure.ac
+++ b/lang/python/configure.ac
@@ -409,8 +409,26 @@ AM_CONDITIONAL(USE_GPGRT_CONFIG, [test -n "$GPGRT_CONFIG" \
# And for gpgme.
have_gpgme=no
-AM_PATH_GPGME("$NEED_GPGME_VERSION",
- have_gpgme=yes, have_gpgme=no)
+builddir=`pwd`
+# Check if Python bindings are built as nested package of gpgme
+if test "${srcdir%/lang/python}/lang/python" == "$srcdir" -a \
+ "${builddir%/lang/python}/lang/python" == "$builddir"; then
+ AC_MSG_CHECKING(for GpgME - assuming nested build)
+ gpgme_build_dir=${builddir%/lang/python}
+ if test -f "$gpgme_build_dir/src/gpgme.h"; then
+ GPGME_CFLAGS="-I$gpgme_build_dir/src"
+ GPGME_LIBS="-L$gpgme_build_dir/src/.libs -lgpgme"
+ have_gpgme=yes
+ AC_MSG_RESULT(yes)
+ else
+ AC_MSG_RESULT(no)
+ fi
+fi
+
+if test "$have_gpgme" = "no"; then
+ AM_PATH_GPGME("$NEED_GPGME_VERSION",
+ have_gpgme=yes, have_gpgme=no)
+fi
#