Some platforms don't even have libxml++ version defines.
[libcxml.git] / src / cxml.cc
index d4eb1388499a284f6333faec165def73e7b977b6..c6ab5cce1a41f009796fa17eeb0da50b773d88a9 100644 (file)
@@ -478,7 +478,7 @@ cxml::raw_convert (string v)
 xmlpp::Element*
 cxml::add_child(xmlpp::Element* parent, string const& name, string const& ns_prefix)
 {
-#if LIBXMLXX_MAJOR_VERSION == 2
+#if !defined(LIBXMLXX_MAJOR_VERSION) || LIBXMLXX_MAJOR_VERSION == 2
        return parent->add_child(name, ns_prefix);
 #else
        return parent->add_child_element(name, ns_prefix);