From 6cfae0f7454977a2a1171b25e82cef512c14e156 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 7 Apr 2024 16:54:38 +0200 Subject: Adding debian version 1:4.13+dfsg1-1. Signed-off-by: Daniel Baumann --- debian/patches/901_testsuite_gcov | 76 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 debian/patches/901_testsuite_gcov (limited to 'debian/patches/901_testsuite_gcov') diff --git a/debian/patches/901_testsuite_gcov b/debian/patches/901_testsuite_gcov new file mode 100644 index 0000000..717ccca --- /dev/null +++ b/debian/patches/901_testsuite_gcov @@ -0,0 +1,76 @@ +--- a/lib/Makefile.am ++++ b/lib/Makefile.am +@@ -1,6 +1,8 @@ + + AUTOMAKE_OPTIONS = 1.0 foreign + ++CFLAGS += -fprofile-arcs -ftest-coverage ++ + DEFS = + + noinst_LTLIBRARIES = libshadow.la +--- a/libmisc/Makefile.am ++++ b/libmisc/Makefile.am +@@ -1,6 +1,8 @@ + + EXTRA_DIST = .indent.pro xgetXXbyYY.c + ++CFLAGS += -fprofile-arcs -ftest-coverage ++ + INCLUDES = -I$(top_srcdir)/lib + + noinst_LIBRARIES = libmisc.a +--- a/src/Makefile.am ++++ b/src/Makefile.am +@@ -7,6 +7,8 @@ + suidperms = 4755 + sgidperms = 2755 + ++CFLAGS += -fprofile-arcs -ftest-coverage ++ + INCLUDES = \ + -I${top_srcdir}/lib \ + -I$(top_srcdir)/libmisc +--- a/debian/rules ++++ b/debian/rules +@@ -40,6 +40,12 @@ + endif + export CFLAGS + ++clean:: clean_gcov ++ ++clean_gcov: ++ find . -name "*.gcda" -delete ++ find . -name "*.gcno" -delete ++ + # Add extras to the install process: + binary-install/login:: + dh_installpam -p login +--- a/lib/defines.h ++++ b/lib/defines.h +@@ -174,23 +174,9 @@ + trust the formatted time received from the unix domain (or worse, + UDP) socket. -MM */ + /* Avoid translated PAM error messages: Set LC_ALL to "C". ++ * This is disabled for coverage testing + * --Nekral */ +-#define SYSLOG(x) \ +- do { \ +- char *old_locale = setlocale (LC_ALL, NULL); \ +- char *saved_locale = NULL; \ +- if (NULL != old_locale) { \ +- saved_locale = strdup (old_locale); \ +- } \ +- if (NULL != saved_locale) { \ +- (void) setlocale (LC_ALL, "C"); \ +- } \ +- syslog x ; \ +- if (NULL != saved_locale) { \ +- (void) setlocale (LC_ALL, saved_locale); \ +- free (saved_locale); \ +- } \ +- } while (false) ++#define SYSLOG(x) syslog x + #else /* !ENABLE_NLS */ + #define SYSLOG(x) syslog x + #endif /* !ENABLE_NLS */ -- cgit v1.2.3