Conversation
CMakeLists.txt
Outdated
| endif() | ||
| message(STATUS "Build type: ${CMAKE_BUILD_TYPE}") | ||
|
|
||
| project(IFCPP) |
There was a problem hiding this comment.
I've merged this with previous project. There's no reason to do this twice with different names.
| project(IfcPlusPlus LANGUAGES CXX) | ||
|
|
||
| ADD_DEFINITIONS(-DIFCQUERY_STATIC_LIB) | ||
| ADD_DEFINITIONS(-DIFCQUERY_LIB) |
There was a problem hiding this comment.
-DIFCQUERY_LIB is required for dynamic builds.
| endif() | ||
|
|
||
| add_library(IfcPlusPlus STATIC ${IFCPP_SOURCE_FILES}) | ||
| add_library(IfcPlusPlus ${IFCPP_SOURCE_FILES}) |
There was a problem hiding this comment.
Default is STATIC unless BUILD_SHARED_LIBS is ON - no change of behavior here.
| endif() | ||
|
|
||
| TARGET_INCLUDE_DIRECTORIES(IfcPlusPlus | ||
| PUBLIC "$<INSTALL_INTERFACE:include;include/ifcpp/IFC4X3/include;include/ifcpp/external>" |
There was a problem hiding this comment.
This is required for proper INTERFACE_INCLUDE_DIRECTORIES in exported cmake config.
IfcPlusPlus/CMakeLists.txt
Outdated
| EXPORT IfcPlusPlus | ||
| EXPORT IFCPP-targets | ||
| RUNTIME DESTINATION bin | ||
| LIBRARY DESTINATION bin |
There was a problem hiding this comment.
LIBRARY and ARCHIVE target should really be in lib.
|
@ifcquery any feedback? |
|
Why not keep project(IfcPlusPlus) in the cmake file? I don't see why IFCPP is better... About the lib and bin directory. I have everything in "bin", so everything is in just one place, easy to keep clean or copy stuff to a zip file etc.. And a library file is binary too, so not wrong ;) |
There's no real difference between them except that the exported cmake config name has always been
I find it hard to remember any other project with this installation layout. Pretty much every other library uses |
No description provided.