[git] GPG-ERROR - branch, master, updated. libgpg-error-1.23-9-gd57a16c

by Yann E. MORIN cvs at cvs.gnupg.org
Tue Jul 12 10:45:25 CEST 2016


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 "Error codes used by GnuPG et al.".

The branch, master has been updated
       via  d57a16c3779eca84dedcf2423b26e41172cd5a96 (commit)
       via  abcdfa7964da62b92984516608faf8941038b71d (commit)
      from  65e967627b3d60f550c7d302227dcf9f797e437f (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 d57a16c3779eca84dedcf2423b26e41172cd5a96
Author: Yann E. MORIN <yann.morin.1998 at free.fr>
Date:   Sun Jul 10 11:38:47 2016 +0200

    Add an option to disable tests
    
    * configure.ac: add an option to enable/disable building tests
    * Makefile.am: conditionally build tests
    --
    
    On an embeded device, there is no reason to have the tests present in
    a production release build. Add a configure-time option to disable
    them.
    
    Signed-off-by: "Yann E. MORIN" <yann.morin.1998 at free.fr>

diff --git a/Makefile.am b/Makefile.am
index baeba14..5abd97d 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -39,7 +39,13 @@ else
 doc =
 endif
 
-SUBDIRS = m4 src $(doc) tests po $(lang_subdirs)
+if BUILD_TESTS
+tests = tests
+else
+tests =
+endif
+
+SUBDIRS = m4 src $(doc) $(tests) po $(lang_subdirs)
 
 
 dist-hook: gen-ChangeLog
diff --git a/configure.ac b/configure.ac
index 682fd84..d19943d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -533,6 +533,11 @@ AC_ARG_ENABLE([doc], AC_HELP_STRING([--disable-doc],
                      build_doc=$enableval, build_doc=yes)
 AM_CONDITIONAL([BUILD_DOC], [test "x$build_doc" != xno])
 
+build_tests=yes
+AC_ARG_ENABLE([tests], AC_HELP_STRING([--disable-tests],
+                                    [do not build the tests]),
+                     build_tests=$enableval, build_tests=yes)
+AM_CONDITIONAL([BUILD_TESTS], [test "x$build_tests" != xno])
 
 #
 # Substitution

commit abcdfa7964da62b92984516608faf8941038b71d
Author: Yann E. MORIN <yann.morin.1998 at free.fr>
Date:   Sun Jul 10 11:38:46 2016 +0200

    Fix build without threads
    
    * src/gen-posix-lock-obj.c: properly guard inclusioin of pthread.h
    * tests/t-lock.c: likewise
    * tests/t-poll.c: likewise
    --
    
    Although ./configure checks for thread support, gen-posix-lock-obj and
    two tests still include pthread.h unconditionally.
    
    Guard that inclusion using the same condition as all other uses of
    pthread-related code.
    
    Signed-off-by: "Yann E. MORIN" <yann.morin.1998 at free.fr>

diff --git a/src/gen-posix-lock-obj.c b/src/gen-posix-lock-obj.c
index e32a3cd..e6f33ae 100644
--- a/src/gen-posix-lock-obj.c
+++ b/src/gen-posix-lock-obj.c
@@ -29,7 +29,9 @@
 #include <string.h>
 #include <stdio.h>
 #include <errno.h>
-#include <pthread.h>
+#ifdef USE_POSIX_THREADS
+# include <pthread.h>
+#endif
 
 #include "posix-lock-obj.h"
 
diff --git a/tests/t-lock.c b/tests/t-lock.c
index 38c9cec..6add18b 100644
--- a/tests/t-lock.c
+++ b/tests/t-lock.c
@@ -31,7 +31,9 @@
 # include <windows.h>
 # include <time.h>
 #else
-# include <pthread.h>
+# ifdef USE_POSIX_THREADS
+#  include <pthread.h>
+# endif
 #endif
 
 #define PGM "t-lock"
diff --git a/tests/t-poll.c b/tests/t-poll.c
index 811f895..a26cbfa 100644
--- a/tests/t-poll.c
+++ b/tests/t-poll.c
@@ -34,7 +34,9 @@
 # include <windows.h>
 # include <time.h>
 #else
-# include <pthread.h>
+# ifdef USE_POSIX_THREADS
+#  include <pthread.h>
+# endif
 #endif
 
 #define PGM "t-lock"

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

Summary of changes:
 Makefile.am              | 8 +++++++-
 configure.ac             | 5 +++++
 src/gen-posix-lock-obj.c | 4 +++-
 tests/t-lock.c           | 4 +++-
 tests/t-poll.c           | 4 +++-
 5 files changed, 21 insertions(+), 4 deletions(-)


hooks/post-receive
-- 
Error codes used by GnuPG et al.
http://git.gnupg.org




More information about the Gnupg-commits mailing list