Don't try to install directories as files (some change in recent cmake?)

This commit is contained in:
Thomas Krijnen
2024-10-03 10:28:13 +02:00
parent 3b9c1d88c8
commit 83c40c7fb4
+4 -2
View File
@@ -117,8 +117,10 @@ IF((PYTHONINTERP_FOUND AND NOT "${PYTHON_EXECUTABLE}" STREQUAL "") OR PYTHON_MOD
FOREACH(file ${sourcefiles})
FILE(RELATIVE_PATH relative "${CMAKE_CURRENT_SOURCE_DIR}/../ifcopenshell-python/ifcopenshell/" "${file}")
GET_FILENAME_COMPONENT(dir "${relative}" DIRECTORY)
INSTALL(FILES "${file}"
DESTINATION "${python_package_dir}/ifcopenshell/${dir}")
if(NOT IS_DIRECTORY "${file}")
INSTALL(FILES "${file}"
DESTINATION "${python_package_dir}/ifcopenshell/${dir}")
endif()
ENDFOREACH()
INSTALL(FILES "${CMAKE_BINARY_DIR}/ifcwrap/ifcopenshell_wrapper.py"
DESTINATION "${python_package_dir}/ifcopenshell")