From 7c7ea461b05066901a5dc330b2994c27d523cd34 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20B=C3=A4hr?= Date: Fri, 11 Aug 2023 12:00:09 +0200 Subject: [PATCH] Fix build of "tests" on macOS Building the C++ unit tests failed for tests/src/Mod/Sketcher/App/SketchObject.cpp because some XML headers were not found. This was because the XercesC include dir was not in the search list for headers. Details: > In file included from /Users/jonas/src/FreeCAD/FreeCAD-git/tests/src/Mod/Sketcher/App/SketchObject.cpp:7: > In file included from /Users/jonas/src/FreeCAD/FreeCAD-git/src/App/Application.h:33: > /Users/jonas/src/FreeCAD/FreeCAD-git/src/Base/Parameter.h:55:10: fatal error: 'xercesc/util/XercesDefs.hpp' file not found > #include > ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ This is the same issue as already adresses previously with PR9657 [1] but the test for SketchObject was added later [2]. [1]: https://github.com/FreeCAD/FreeCAD/pull/9657 [2]: https://github.com/FreeCAD/FreeCAD/commit/03bb50328386008f3f3d3dab8835b5aea6203313 --- tests/CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index a7eeba4c00..50a3d3b77e 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -54,6 +54,7 @@ target_include_directories(Sketcher_tests_run PUBLIC ${EIGEN3_INCLUDE_DIR} ${OCC_INCLUDE_DIR} ${Python3_INCLUDE_DIRS} + ${XercesC_INCLUDE_DIRS} ) target_link_libraries(Sketcher_tests_run gtest_main