From 09adecfa179ec950cb9f7b7801a02c155aad55f8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= Date: Thu, 5 Dec 2019 17:15:44 +0100 Subject: [PATCH] Add NSPR detection to get path to includes directory. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Slávek Banko (cherry picked from commit 09b0af1392cdcdbc470765c33654ea084f112a05) --- configure.in | 6 ++++++ src/Makefile.am | 2 +- src/jni_md.h | 2 +- src/jri_md.h | 2 +- 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/configure.in b/configure.in index 22f26c5..5f9591e 100644 --- a/configure.in +++ b/configure.in @@ -18,5 +18,11 @@ dnl --------------------------------------------- AC_CHECK_HEADER(X11/Xaw/Form.h,, [AC_MSG_ERROR([you need to install libxaw header files (-dev package)])]) +dnl --------------------------------------------- +dnl Check for NSPR include directory +dnl --------------------------------------------- +AC_CHECK_PROG(PKGCONFIGFOUND, pkg-config,[yes]) +PKG_CHECK_MODULES(NSPR, nspr, have_nspr=yes, + [ AC_MSG_ERROR([nspr library not found on your system]) ]) AC_OUTPUT(Makefile src/Makefile) diff --git a/src/Makefile.am b/src/Makefile.am index a0227fa..8a6d324 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,7 +1,7 @@ EXTRA_DIST = npapi.h npunix.c npupp.h plugin.c plugin.h -AM_CFLAGS = @CFLAGS@ $(X_CFLAGS) +AM_CFLAGS = @CFLAGS@ $(X_CFLAGS) $(NSPR_CFLAGS) lib_LTLIBRARIES = kaffeineplugin.la diff --git a/src/jni_md.h b/src/jni_md.h index d6d2d71..5723bc4 100644 --- a/src/jni_md.h +++ b/src/jni_md.h @@ -40,7 +40,7 @@ #ifndef JNI_MD_H #define JNI_MD_H -#include /* needed for _declspec */ +#include /* needed for _declspec */ /******************************************************************************* * WHAT'S UP WITH THIS FILE? diff --git a/src/jri_md.h b/src/jri_md.h index 800b70f..301053c 100644 --- a/src/jri_md.h +++ b/src/jri_md.h @@ -43,7 +43,7 @@ #define JRI_MD_H #include -#include /* Needed for HAS_LONG_LONG ifdefs */ +#include /* Needed for HAS_LONG_LONG ifdefs */ #ifdef __cplusplus extern "C" {