This is the mail archive of the mailing list for the glibc project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] [BZ 17956] Fix nss tests build failure due to missing definitions from header file nss.h when Mozilla NSS is used

A build failure occurs when glibc is configured with the --enable-nss-crypt
option in order to use Mozilla NSS library for cryptography and the
tests are built and executed by running "make check".

Such failure is due to conflicting "nss.h" header files: one from GNU
glibc and the other from the Mozilla NSS library (usually located at

This patch aims to fix such build failure (BZ 17956) by helping the
preprocessor pick the right (local) "nss.h" header file during compilation
of the tests.

Signed-off-by: Guido Trentalancia <>
 nss/nss_test1.c     |    2 +-
 nss/tst-field.c     |    2 +-
 nss/tst-nss-test1.c |    2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff -pru glibc-30052016-2000-nss-include-fixes/nss/nss_test1.c glibc-30052016-2000-nss-include-fixes-nss-tests/nss/nss_test1.c
--- glibc-30052016-2000-nss-include-fixes/nss/nss_test1.c	2016-05-30 13:25:36.270699791 +0200
+++ glibc-30052016-2000-nss-include-fixes-nss-tests/nss/nss_test1.c	2016-05-30 22:57:07.014001099 +0200
@@ -1,5 +1,5 @@
 #include <errno.h>
-#include <nss.h>
+#include "nss.h"
 #include <pthread.h>
 #include <string.h>
diff -pru glibc-30052016-2000-nss-include-fixes/nss/tst-field.c glibc-30052016-2000-nss-include-fixes-nss-tests/nss/tst-field.c
--- glibc-30052016-2000-nss-include-fixes/nss/tst-field.c	2016-05-30 13:25:36.271699794 +0200
+++ glibc-30052016-2000-nss-include-fixes-nss-tests/nss/tst-field.c	2016-05-30 22:57:35.364966665 +0200
@@ -19,7 +19,7 @@
 /* This test needs to be statically linked because it access hidden
    functions.  */
-#include <nss.h>
+#include "nss.h"
 #include <stdbool.h>
 #include <stdio.h>
 #include <stdlib.h>
diff -pru glibc-30052016-2000-nss-include-fixes/nss/tst-nss-test1.c glibc-30052016-2000-nss-include-fixes-nss-tests/nss/tst-nss-test1.c
--- glibc-30052016-2000-nss-include-fixes/nss/tst-nss-test1.c	2016-05-30 13:25:36.271699794 +0200
+++ glibc-30052016-2000-nss-include-fixes-nss-tests/nss/tst-nss-test1.c	2016-05-30 22:57:51.168947430 +0200
@@ -1,4 +1,4 @@
-#include <nss.h>
+#include "nss.h"
 #include <pwd.h>
 #include <stdio.h>
 #include <stdlib.h>

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]