Permalink
Browse files

Build against the new JSON-C library name.

If json-c is built with the --disable-oldname-compat then bti will not
build.

This fixes it. Obviously it could be more complex but most distros use
the new name now as it's needed for both PHP and PulseAudio.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information...
1 parent 7dc7db4 commit 97903ba5504223b7177cfe23292d49ae577e1665 Colin Guthrie committed with Dec 5, 2013
Showing with 2 additions and 2 deletions.
  1. +1 −1 bti.c
  2. +1 −1 configure.ac
View
2 bti.c
@@ -32,7 +32,7 @@
#include <libxml/xmlmemory.h>
#include <libxml/parser.h>
#include <libxml/tree.h>
-#include <json/json.h>
+#include <json-c/json.h>
#include <pcre.h>
#include <termios.h>
#include <dlfcn.h>
View
@@ -18,7 +18,7 @@ PKG_CHECK_MODULES(LIBOAUTH, oauth)
PKG_CHECK_MODULES(LIBPCRE, libpcre)
PKG_CHECK_MODULES([LIBCURL], [libcurl])
PKG_CHECK_MODULES([XML], [libxml-2.0])
-PKG_CHECK_MODULES([JSON], [json])
+PKG_CHECK_MODULES([JSON], [json-c])
AC_SEARCH_LIBS([dlopen], [dl])

2 comments on commit 97903ba

Why switching to libjson-c instead of libjson?
The first one is not available for arm7v7 like the Cubieboard.
Without these changes it compiles and works fine on armv7l, so maybe fall back on libjson if libjson-c is not found?

Owner

gregkh replied Mar 26, 2014

If you can write a patch to do the "fall-back", I'll gladly accept it.

Please sign in to comment.