aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-connectivity/dhcp/dhcp/libxml2-configure-argument.patch
blob: 9d2fbfb2927cd8c02391e3236154704072b73907 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
Add configure argument to make the libxml2 dependency explicit and
determinisitic.

Upstream-Status: Pending

Signed-off-by: Christopher Larson <chris_larson@mentor.com>

--- dhcp-4.3.3.orig/configure.ac	2016-03-16 20:25:53.830697637 -0700
+++ dhcp-4.3.3/configure.ac	2016-03-16 20:28:19.415355257 -0700
@@ -631,7 +631,16 @@

 # We need to find libxml2 if bind was built with support enabled
 # otherwise we'll fail to build omapip/test.c
-AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],)
+AC_ARG_WITH(libxml2,
+	AS_HELP_STRING([--with-libxml2], [link against libxml2. this is needed if bind was built with xml2 support enabled]),
+	with_libxml2="$withval", with_libxml2="no")
+
+if test x$with_libxml2 != xno; then
+    AC_SEARCH_LIBS(xmlTextWriterStartElement, [xml2],
+                   [if test x$with_libxml2 != xauto; then
+                        AC_MSG_FAILURE([*** Cannot find xmlTextWriterStartElement with -lxml2 and libxml2 was requested])
+                    fi])
+fi

 # OpenLDAP support.
 AC_ARG_WITH(ldap,