Skip to content

Commit adea203

Browse files
committed
CMake: allow to specify an XML library.
If we don't then we get some undefined symbols XML-related methods (e.g., _xmlCreatePushParserCtxt).
1 parent b58b14f commit adea203

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

CMakeLists.txt

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -364,6 +364,12 @@ elseif (ZIPPER_LIBRARY)
364364
set(LIBCOMBINE_LIBS ${LIBCOMBINE_LIBS} ${ZIPPER_LIBRARY})
365365
endif()
366366

367+
if (XML_LIBRARY_NAME)
368+
set(LIBCOMBINE_LIBS ${LIBCOMBINE_LIBS} ${XML_LIBRARY_NAME})
369+
elseif (XML_LIBRARY)
370+
set(LIBCOMBINE_LIBS ${LIBCOMBINE_LIBS} ${XML_LIBRARY})
371+
endif()
372+
367373
set(USING_INTEL FALSE)
368374
if (WIN32 AND CMAKE_C_COMPILER AND CMAKE_C_COMPILER MATCHES ".*icl.*$")
369375
message(STATUS "Detected Intel Compiler")
@@ -484,6 +490,7 @@ include_directories(${EXTRA_INCLUDE_DIRS})
484490
endif()
485491

486492
include_directories(${LIBSBML_INCLUDE_DIR})
493+
include_directories(${XML_INCLUDE_DIR})
487494
include_directories(${ZLIB_INCLUDE_DIR})
488495
include_directories(${ZIPPER_INCLUDE_DIR})
489496
include_directories(BEFORE ${CMAKE_CURRENT_SOURCE_DIR}/src/)
@@ -627,6 +634,10 @@ libCombine version ${LIBCOMBINE_VERSION}
627634
SBML include dir = ${LIBSBML_INCLUDE_DIR}
628635
libSBML compression support = ${LIBSBML_HAS_MINIZIP}
629636
637+
XML library configuration:
638+
XML library = ${XML_LIBRARY}
639+
XML include dir = ${XML_INCLUDE_DIR}
640+
630641
Zlib library configuration:
631642
Zlib library = ${ZLIB_LIBRARY}
632643
Zlib include dir = ${ZLIB_INCLUDE_DIR}

0 commit comments

Comments
 (0)