configure.ac

changeset 57
a76dc0db592c
parent 51
a03b6dac5398
child 75
4b976601737d
--- a/configure.ac	Tue May 27 23:20:37 2014 +0200
+++ b/configure.ac	Sat May 31 11:39:13 2014 +0200
@@ -39,7 +39,6 @@
   AC_MSG_ERROR(libmosquitto not found)
 fi
 
-
 WIRINGPI=No
 AC_CHECK_LIB(wiringPi,wiringPiSetup,result=yes,result=no)
 if test "$result" = "yes"; then
@@ -63,6 +62,17 @@
   CFLAGS="-g -O2 -fomit-frame-pointer -fno-strict-aliasing -Wall -Wshadow -Wwrite-strings -Wstrict-prototypes -Winline"
 fi
 
+
+LIBXML2=No
+AC_CHECK_LIB(xml2,xmlParseFile,result=yes,result=no)
+if test "$result" = "yes"; then
+  LIBS="$LIBS -lxml2"
+  CFLAGS="$CFLAGS $(xml2-config --cflags)"
+  AC_CHECK_HEADERS(libxml/xmlmemory.h,LIBXML2=Yes,LIBXML2=No)
+fi
+
+
+
 dnl Checks for header files.
 AC_HEADER_STDC
 
@@ -81,6 +91,7 @@
     Version : ............ ${VERSION}
     Main directory : ..... ${prefix}
     WiringPi : ........... ${WIRINGPI}
+    XML2: ................ ${LIBXML2}
 
   Now type 'make' and 'sudo make install'
 ])

mercurial