From 977b947e2c464a1df18bdccaef261b0c7776406a Mon Sep 17 00:00:00 2001
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
Date: Sun, 8 Jun 2014 21:43:33 +0200
Subject: Fix include dirs for Haiku.


diff --git a/Makefile b/Makefile
index 4ec03f3..f6bfff2 100644
--- a/Makefile
+++ b/Makefile
@@ -47,9 +47,9 @@ ifeq ($(WANT_TEST),yes)
   # We require the presence of libjson -- http://oss.metaparadigm.com/json-c/
   ifneq ($(PKGCONFIG),)
     TESTCFLAGS := $(TESTCFLAGS) \
-		$(shell $(PKGCONFIG) $(PKGCONFIGFLAGS) --cflags json)
+		$(shell $(PKGCONFIG) $(PKGCONFIGFLAGS) --cflags json-c)
     TESTLDFLAGS := $(TESTLDFLAGS) \
-		$(shell $(PKGCONFIG) $(PKGCONFIGFLAGS) --libs json)
+		$(shell $(PKGCONFIG) $(PKGCONFIGFLAGS) --libs json-c)
   else
     TESTCFLAGS := $(TESTCFLAGS) -I$(PREFIX)/include/json
     TESTLDFLAGS := $(TESTLDFLAGS) -ljson
@@ -61,7 +61,7 @@ ifeq ($(WANT_TEST),yes)
 endif
 
 # Extra installation rules
-I := /include/hubbub
+I := /$(INCLUDEDIR)/hubbub
 INSTALL_ITEMS := $(INSTALL_ITEMS) $(I):include/hubbub/errors.h
 INSTALL_ITEMS := $(INSTALL_ITEMS) $(I):include/hubbub/functypes.h
 INSTALL_ITEMS := $(INSTALL_ITEMS) $(I):include/hubbub/hubbub.h
diff --git a/libhubbub.pc.in b/libhubbub.pc.in
index 2f9565e..b20a4a0 100644
--- a/libhubbub.pc.in
+++ b/libhubbub.pc.in
@@ -1,7 +1,7 @@
 prefix=PREFIX
 exec_prefix=${prefix}
 libdir=${exec_prefix}/LIBDIR
-includedir=${prefix}/include
+includedir=${prefix}/INCLUDEDIR
 
 Name: libhubbub
 Description: HTML5 parsing library
-- 
1.8.3.4

