This undoes most of the Xerces related part of the commits listed below.
The issue resolved here is that the Xerces include dir *is* set in the
CMakeLists.txt of src/Base, but it got removed from various App and Gui
dirs in src/Mod. If those now include a header from src/Base, which
itself includes xercesc, the build fails using Apple clang version 11.0.0
(clang-1100.0.33.17) on Mojave, configured using cmake 3.22.1, with
errors like the following:
In file included from .../src/Mod/Part/App/FeaturePartBoolean.cpp:34:
In file included from .../src/App/Application.h:33:
.../src/Base/Parameter.h:54:10: fatal error: 'xercesc/util/XercesDefs.hpp' file not found
#include <xercesc/util/XercesDefs.hpp>
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
Finally, a full list of the commits that introduced this spurious include
dir optimization for reference:
- Drawing: commit f4411478d106ba9f4827754a50efa53bd7767a66
- Image: commit e3476815c04c571199779bd1e444b950e6398025
- Import: commit b7b264e52c8fd97e83987c4ce42ce563170c8918
- Inspection: commit 1f64d8b1b8fcabe983c6e5e624d65766b4429ea0
- Mesh: commit 5a8fed0720d681cdbb9fedc840d2532c4f2f6042
- Part: commit 26bb65f11f4b51e5e47b65b2d6049ece10705a83
- PartDesign: commit f4e49f2aecf08f2337e84510ed019b7fa4b685a3
- Path: commit e3d9cc98577d2073297d55ffd8de28dd50f8444c
- Points: commit 09f3e867cdccd31294cced4e3c73015d3add3f4a
- Raytracing: commit 7b92dedc53f09e2ce8365408f3003e5700aebfc8
- ReverseEnginering: commit eeacc51ad0cd82e5f17d63207f78f79eb20bf9a9
- Robot: commit 4d06684cbd0328e4f43c78b5dab7e7fcebab148d
- Sketcher: commit 079125665495a08a7e2e2a4f01da406128dca625
- Spreadsheet: commit 514097954e95c04a7ec9d7e8ec1afc3aac3dd8d
- Start: commit 2ea2bb0dc393d7b8b41e9137c6d4ae40ce29719d
- Surface: commit 272268dd6c0b460ae9aeecdf371495ea26aa044d
- TechDraw: commit c70fdc3e0aa6b409626a6fa6b7266d05f3338c6d
- Test: commit 49a07b121e08e9bf3fef0f414a8da5602533592e
- Web: commit a93a23d7e4da13b2d5c37ac087b2dcf41aae197d
85 lines
2.1 KiB
CMake
85 lines
2.1 KiB
CMake
if(MSVC)
|
|
add_definitions(-DHAVE_ACOSH -DHAVE_ATANH -DHAVE_ASINH)
|
|
else(MSVC)
|
|
add_definitions(-DHAVE_LIMITS_H -DHAVE_CONFIG_H)
|
|
endif(MSVC)
|
|
|
|
include_directories(
|
|
${CMAKE_BINARY_DIR}
|
|
${CMAKE_SOURCE_DIR}/src
|
|
${CMAKE_CURRENT_BINARY_DIR}
|
|
${Boost_INCLUDE_DIRS}
|
|
${OCC_INCLUDE_DIR}
|
|
${COIN3D_INCLUDE_DIRS}
|
|
${PYTHON_INCLUDE_DIRS}
|
|
${ZLIB_INCLUDE_DIR}
|
|
${XercesC_INCLUDE_DIRS}
|
|
)
|
|
link_directories(${OCC_LIBRARY_DIR})
|
|
|
|
set(ReenGui_LIBS
|
|
ReverseEngineering
|
|
MeshGui
|
|
)
|
|
|
|
if(BUILD_QT5)
|
|
qt5_add_resources(ReenGui_QRC_SRCS Resources/ReverseEngineering.qrc)
|
|
else()
|
|
qt4_add_resources(ReenGui_QRC_SRCS Resources/ReverseEngineering.qrc)
|
|
endif()
|
|
|
|
set(Dialogs_UIC_SRCS
|
|
FitBSplineSurface.ui
|
|
Poisson.ui
|
|
Segmentation.ui
|
|
SegmentationManual.ui
|
|
)
|
|
|
|
if(BUILD_QT5)
|
|
qt5_wrap_ui(Dialogs_UIC_HDRS ${Dialogs_UIC_SRCS})
|
|
else()
|
|
qt4_wrap_ui(Dialogs_UIC_HDRS ${Dialogs_UIC_SRCS})
|
|
endif()
|
|
|
|
SET(Dialogs_SRCS
|
|
${Dialogs_UIC_HDRS}
|
|
${Dialogs_UIC_SRCS}
|
|
FitBSplineSurface.cpp
|
|
FitBSplineSurface.h
|
|
Poisson.cpp
|
|
Poisson.h
|
|
Segmentation.cpp
|
|
Segmentation.h
|
|
SegmentationManual.cpp
|
|
SegmentationManual.h
|
|
)
|
|
SOURCE_GROUP("Dialogs" FILES ${Dialogs_SRCS})
|
|
|
|
SET(ReenGui_SRCS
|
|
${ReenGui_QRC_SRCS}
|
|
${Dialogs_SRCS}
|
|
AppReverseEngineeringGui.cpp
|
|
Command.cpp
|
|
Resources/ReverseEngineering.qrc
|
|
PreCompiled.cpp
|
|
PreCompiled.h
|
|
Workbench.cpp
|
|
Workbench.h
|
|
)
|
|
|
|
SET(ReverseEngineeringGuiIcon_SVG
|
|
Resources/icons/ReverseEngineeringWorkbench.svg
|
|
)
|
|
|
|
add_library(ReverseEngineeringGui SHARED ${ReenGui_SRCS} ${ReverseEngineeringGuiIcon_SVG})
|
|
target_link_libraries(ReverseEngineeringGui ${ReenGui_LIBS})
|
|
|
|
|
|
SET_BIN_DIR(ReverseEngineeringGui ReverseEngineeringGui /Mod/ReverseEngineering)
|
|
SET_PYTHON_PREFIX_SUFFIX(ReverseEngineeringGui)
|
|
|
|
fc_copy_sources(ReverseEngineeringGui "${CMAKE_BINARY_DIR}/${CMAKE_INSTALL_DATADIR}/Mod/ReverseEngineering" ${ReverseEngineeringGuiIcon_SVG})
|
|
|
|
install(TARGETS ReverseEngineeringGui DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
|
install(FILES ${ReverseEngineeringGuiIcon_SVG} DESTINATION "${CMAKE_INSTALL_DATADIR}/Mod/ReverseEngineering/Resources/icons")
|