Anonymous | Login | 2021-01-15 21:44 MSK | ![]() |
My View | View Issues | Change Log | Roadmap |
View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||||||
0030568 | Open CASCADE | [OCCT] OCCT:Configuration | public | 2019-03-13 14:54 | 2020-09-11 15:40 | ||||||||
Reporter | oan | ||||||||||||
Assigned To | inv | ||||||||||||
Priority | normal | Severity | minor | ||||||||||
Status | new | Resolution | open | ||||||||||
Platform | OS | OS Version | |||||||||||
Product Version | |||||||||||||
Target Version | [OCCT] 7.6.0* | Fixed in Version | |||||||||||
Summary | 0030568: CMake: unified functionality to collect prerequisites | ||||||||||||
Description | In OCCT-based projects and OCCT itself it is common to install all 3rdparty libraries along with target project to avoid usage of bat files, setting necessary environment (like INSTALL_FREEIMAGE option). In OCCT-related projects it is needed to specify libraries and their locations explicitly. At the same time, CMake supports cross-platform tools aimed to collect dependensies of target binary file (either library or executable). It is suggested to create common procedure distributable with OCCT and located in cmake folder, e.g. cmake_prerequisites.cmake, that could be used from successor projects to collect its dependencies and simplify usage of OCCT as an SDK. CMake reference: https://cmake.org/cmake/help/v3.0/module/GetPrerequisites.html [^] Example of usage is given in "Steps to Reproduce". Note that this functionality requires target projects be compiled as soon as it works with binaries only. Thus, this stage can be implemented as a custom target procedure: add_custom_target( prerequisites ALL COMMAND call "${CMAKE_BINARY_DIR}/env.bat" ${VCVER} ${ARCH} $(ConfigurationName) COMMAND ${CMAKE_COMMAND} -DBUILD_TYPE=$(Configuration) -P cmake_prerequisites.cmake COMMENT "Collecting prerequisites" VERBATIM ) | ||||||||||||
Steps To Reproduce | include (GetPrerequisites) set (DIRS "${OCCT_BIN_DIR}") get_prerequisites(${CMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG}/${PROJECT_NAME}.dll DEPENDENCIES 1 1 "" "") foreach(DEPENDENCY_FILE ${DEPENDENCIES}) gp_resolve_item(${CMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG}/${PROJECT_NAME}.dll "${DEPENDENCY_FILE}" "" ${DIRS} resolved_file) get_prerequisites("${resolved_file}" DEPENDENCIES_1 1 1 "" "") foreach(DEPENDENCY_FILE_1 ${DEPENDENCIES_1}) message("${DEPENDENCY_FILE_1}") endforeach() endforeach() .... <install all prerequisites> | ||||||||||||
Tags | No tags attached. | ||||||||||||
Test case number | |||||||||||||
Attached Files | |||||||||||||
![]() |
|||
Date Modified | Username | Field | Change |
2019-03-13 14:54 | oan | New Issue | |
2019-03-13 14:54 | oan | Assigned To | => bugmaster |
2019-03-13 14:54 | oan | Relationship added | related to 0027560 |
2019-03-20 12:51 | bugmaster | Assigned To | bugmaster => apn |
2019-07-19 16:35 | apn | Target Version | 7.4.0 => 7.5.0 |
2020-09-11 15:37 | utverdov | Assigned To | apn => inv |
2020-09-11 15:40 | utverdov | Target Version | 7.5.0 => 7.6.0* |
Copyright © 2000 - 2021 MantisBT Team |