[git] GPGME - branch, master, updated. gpgme-1.12.0-123-g66bcb8a

by NIIBE Yutaka cvs at cvs.gnupg.org
Wed Jan 16 03:02:40 CET 2019


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GnuPG Made Easy".

The branch, master has been updated
       via  66bcb8acb2452cf19318023ed0ff1ea7d7bb8439 (commit)
      from  ce327f994a2888b807b63cf202ddcecc3fb9c685 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 66bcb8acb2452cf19318023ed0ff1ea7d7bb8439
Author: NIIBE Yutaka <gniibe at fsij.org>
Date:   Wed Jan 16 10:59:25 2019 +0900

    build: With LD_LIBRARY_PATH defined, use --disable-new-dtags.
    
    * configure.ac (LDADD_FOR_TESTS_KLUDGE): New for --disable-new-dtags.
    * tests/Makefile.am (LDADD): Use LDADD_FOR_TESTS_KLUDGE.
    * lang/cpp/tests/Makefile.am, lang/qt/tests/Makefile.am: Likewise.
    * tests/gpg/Makefile.am, tests/gpgsm/Makefile.am: Likewise.
    * tests/json/Makefile.am, tests/opassuan/Makefile.am: Likewise.
    
    --
    
    GnuPG-bug-id: 4298
    Signed-off-by: NIIBE Yutaka <gniibe at fsij.org>

diff --git a/configure.ac b/configure.ac
index ff37794..e59a2f8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -105,6 +105,41 @@ AC_ARG_VAR(SYSROOT,[locate config scripts also below that directory])
 # Enable GNU extensions on systems that have them.
 AC_GNU_SOURCE
 
+# Taken from mpfr-4.0.1, then modified for LDADD_FOR_TESTS_KLUDGE
+dnl Under Linux, make sure that the old dtags are used if LD_LIBRARY_PATH
+dnl is defined. The issue is that with the new dtags, LD_LIBRARY_PATH has
+dnl the precedence over the run path, so that if a compatible MPFR library
+dnl is installed in some directory from $LD_LIBRARY_PATH, then the tested
+dnl MPFR library will be this library instead of the MPFR library from the
+dnl build tree. Other OS with the same issue might be added later.
+dnl
+dnl References:
+dnl   https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=859732
+dnl   http://lists.gnu.org/archive/html/libtool/2017-05/msg00000.html
+dnl
+dnl We need to check whether --disable-new-dtags is supported as alternate
+dnl linkers may be used (e.g., with tcc: CC=tcc LD=tcc).
+dnl
+case $host in
+  *-*-linux*)
+    if test -n "$LD_LIBRARY_PATH"; then
+      saved_LDFLAGS="$LDFLAGS"
+      LDADD_FOR_TESTS_KLUDGE="-Wl,--disable-new-dtags"
+      LDFLAGS="$LDFLAGS $LDADD_FOR_TESTS_KLUDGE"
+      AC_MSG_CHECKING(whether --disable-new-dtags is supported by the linker)
+      AC_LINK_IFELSE([AC_LANG_SOURCE([[
+int main (void) { return 0; }
+      ]])],
+      [AC_MSG_RESULT(yes (use it since LD_LIBRARY_PATH is set))],
+      [AC_MSG_RESULT(no)
+       LDADD_FOR_TESTS_KLUDGE=""
+      ])
+      LDFLAGS="$saved_LDFLAGS"
+    fi
+    ;;
+esac
+AC_SUBST([LDADD_FOR_TESTS_KLUDGE])
+
 AH_VERBATIM([_REENTRANT],
 [/* To allow the use of GPGME in multithreaded programs we have to use
   special features from the library.
diff --git a/lang/cpp/tests/Makefile.am b/lang/cpp/tests/Makefile.am
index 67dd3d3..0b27595 100644
--- a/lang/cpp/tests/Makefile.am
+++ b/lang/cpp/tests/Makefile.am
@@ -22,7 +22,7 @@ AM_LDFLAGS = -no-install
 
 LDADD = ../../cpp/src/libgpgmepp.la \
         ../../../src/libgpgme.la @GPG_ERROR_LIBS@ \
-        -lstdc++
+        @LDADD_FOR_TESTS_KLUDGE@ -lstdc++
 
 AM_CPPFLAGS = -I$(top_srcdir)/lang/cpp/src -I$(top_builddir)/src \
               @GPG_ERROR_CFLAGS@ @GPG_ERROR_CFLAGS@ \
diff --git a/lang/qt/tests/Makefile.am b/lang/qt/tests/Makefile.am
index 6d54340..f75d64c 100644
--- a/lang/qt/tests/Makefile.am
+++ b/lang/qt/tests/Makefile.am
@@ -37,7 +37,7 @@ AM_LDFLAGS = -no-install
 
 LDADD = ../../cpp/src/libgpgmepp.la ../src/libqgpgme.la \
         ../../../src/libgpgme.la @GPGME_QT_LIBS@ @GPG_ERROR_LIBS@ \
-        @GPGME_QTTEST_LIBS@ -lstdc++
+        @GPGME_QTTEST_LIBS@ @LDADD_FOR_TESTS_KLUDGE@ -lstdc++
 
 AM_CPPFLAGS = -I$(top_srcdir)/lang/cpp/src -I$(top_builddir)/src \
               @GPG_ERROR_CFLAGS@ @GPGME_QT_CFLAGS@ @GPG_ERROR_CFLAGS@ \
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 8faa05a..8950e96 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -29,7 +29,7 @@ EXTRA_DIST = start-stop-agent t-data-1.txt t-data-2.txt ChangeLog-2011
 
 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@
 AM_LDFLAGS = -no-install
-LDADD = ../src/libgpgme.la @GPG_ERROR_LIBS@
+LDADD = ../src/libgpgme.la @GPG_ERROR_LIBS@ @LDADD_FOR_TESTS_KLUDGE@
 
 noinst_HEADERS = run-support.h
 
@@ -37,7 +37,8 @@ noinst_PROGRAMS = $(TESTS) run-keylist run-export run-import run-sign \
 		  run-verify run-encrypt run-identify run-decrypt run-genkey \
 		  run-keysign run-tofu run-swdb run-threaded
 
-run_threaded_LDADD = ../src/libgpgme.la -lpthread @GPG_ERROR_LIBS@
+run_threaded_LDADD = ../src/libgpgme.la -lpthread @GPG_ERROR_LIBS@ \
+		     @LDADD_FOR_TESTS_KLUDGE@
 
 if RUN_GPG_TESTS
 gpgtests = gpg json
diff --git a/tests/gpg/Makefile.am b/tests/gpg/Makefile.am
index b8d1516..be84290 100644
--- a/tests/gpg/Makefile.am
+++ b/tests/gpg/Makefile.am
@@ -65,11 +65,11 @@ BUILT_SOURCES = gpg.conf gpg-agent.conf pubring-stamp \
            gpg-sample.stamp
 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@
 AM_LDFLAGS = -no-install
-LDADD = ../../src/libgpgme.la
-t_thread1_LDADD = ../../src/libgpgme.la -lpthread
-t_thread_keylist_LDADD = ../../src/libgpgme.la -lpthread
-t_thread_keylist_verify_LDADD = ../../src/libgpgme.la -lpthread
-t_cancel_LDADD = ../../src/libgpgme.la -lpthread
+LDADD = ../../src/libgpgme.la @LDADD_FOR_TESTS_KLUDGE@
+t_thread1_LDADD = ../../src/libgpgme.la -lpthread @LDADD_FOR_TESTS_KLUDGE@
+t_thread_keylist_LDADD = ../../src/libgpgme.la -lpthread @LDADD_FOR_TESTS_KLUDGE@
+t_thread_keylist_verify_LDADD = ../../src/libgpgme.la -lpthread @LDADD_FOR_TESTS_KLUDGE@
+t_cancel_LDADD = ../../src/libgpgme.la -lpthread @LDADD_FOR_TESTS_KLUDGE@
 
 # We don't run t-genkey and t-cancel in the test suite, because it
 # takes too long
diff --git a/tests/gpgsm/Makefile.am b/tests/gpgsm/Makefile.am
index 3706840..63de747 100644
--- a/tests/gpgsm/Makefile.am
+++ b/tests/gpgsm/Makefile.am
@@ -38,7 +38,7 @@ EXTRA_DIST = cert_dfn_pca01.der cert_dfn_pca15.der cert_g10code_test1.der \
 
 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@
 AM_LDFLAGS = -no-install
-LDADD = ../../src/libgpgme.la
+LDADD = ../../src/libgpgme.la @LDADD_FOR_TESTS_KLUDGE@
 
 # We don't run t-genkey in the test suite, because it takes too long
 # and needs a working pinentry.
diff --git a/tests/json/Makefile.am b/tests/json/Makefile.am
index f4db840..9b2cf71 100644
--- a/tests/json/Makefile.am
+++ b/tests/json/Makefile.am
@@ -67,8 +67,9 @@ BUILT_SOURCES = gpg.conf gpg-agent.conf pubring-stamp \
            gpg-sample.stamp
 t_json_SOURCES = t-json.c
 AM_LDFLAGS = -no-install
-LDADD = ../../src/libgpgme.la
-t_json_LDADD = ../../src/cJSON.o -lm ../../src/libgpgme.la @GPG_ERROR_LIBS@
+LDADD = ../../src/libgpgme.la @LDADD_FOR_TESTS_KLUDGE@
+t_json_LDADD = ../../src/cJSON.o -lm ../../src/libgpgme.la @GPG_ERROR_LIBS@ \
+	       @LDADD_FOR_TESTS_KLUDGE@
 
 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@
 
diff --git a/tests/opassuan/Makefile.am b/tests/opassuan/Makefile.am
index 47686eb..b62751d 100644
--- a/tests/opassuan/Makefile.am
+++ b/tests/opassuan/Makefile.am
@@ -27,7 +27,7 @@ TESTS =
 EXTRA_DIST =
 
 AM_CPPFLAGS = -I$(top_builddir)/src @GPG_ERROR_CFLAGS@
-LDADD = ../../src/libgpgme.la
+LDADD = ../../src/libgpgme.la @LDADD_FOR_TESTS_KLUDGE@
 
 noinst_PROGRAMS = $(TESTS) t-command
 

-----------------------------------------------------------------------

Summary of changes:
 configure.ac               | 35 +++++++++++++++++++++++++++++++++++
 lang/cpp/tests/Makefile.am |  2 +-
 lang/qt/tests/Makefile.am  |  2 +-
 tests/Makefile.am          |  5 +++--
 tests/gpg/Makefile.am      | 10 +++++-----
 tests/gpgsm/Makefile.am    |  2 +-
 tests/json/Makefile.am     |  5 +++--
 tests/opassuan/Makefile.am |  2 +-
 8 files changed, 50 insertions(+), 13 deletions(-)


hooks/post-receive
-- 
GnuPG Made Easy
http://git.gnupg.org




More information about the Gnupg-commits mailing list