Summary: | cad/opencascade: cmake fails to discover opencascade | ||
---|---|---|---|
Product: | Ports & Packages | Reporter: | Yuri Victorovich <yuri> |
Component: | Individual Port(s) | Assignee: | Thierry Thomas <thierry> |
Status: | Closed FIXED | ||
Severity: | Affects Only Me | Flags: | thierry:
merge-quarterly?
|
Priority: | --- | ||
Version: | Latest | ||
Hardware: | Any | ||
OS: | Any |
Description
Yuri Victorovich
![]() ![]() Could you please give more details on the failing port? cad/freecad and cad/gmsh also use cmake, and they find OpenCASCADE: I'd like to compare their CMakeLists.txt with yours. The example above is how they find OpenCASCADE: > cmake_minimum_required(VERSION 3.12) > find_package(OpenCASCADE REQUIRED) The same in the context of the f3d project: https://github.com/f3d-app/f3d/blob/master/CMakeLists.txt#L77 Thanks, I have just located the issue: - OpenCASCADE uses a variable OCCT_INSTALL_BIN_LETTER which can be used to install several versions of its libraries (e.g. under lib64 or libd for debug); - in the various OpenCASCADE*Targets-release.cmake (installed under /usr/local/lib/cmake/), the dollar sign of this variable is escaped! E.g. we have "/usr/local/lib\${OCCT_INSTALL_BIN_LETTER}/libTKernel.so.7.6.0" where it should be "/usr/local/lib${OCCT_INSTALL_BIN_LETTER}/libTKernel.so.7.6.0" Note: in our case OCCT_INSTALL_BIN_LETTER is empty. I shall try to fix it ASAP. A fix has just been committed, please let me know if this is OK for your ports. A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=31735a5b1aae9a7967e8cc5f12ffab7779acc53c commit 31735a5b1aae9a7967e8cc5f12ffab7779acc53c Author: Thierry Thomas <thierry@FreeBSD.org> AuthorDate: 2022-09-10 11:05:31 +0000 Commit: Thierry Thomas <thierry@FreeBSD.org> CommitDate: 2022-09-10 11:12:13 +0000 cad/opencascade: fix cmake files A cmake macro, which should have configured $OCCT_INSTALL_BIN_LETTER was not applied correctly. Thus some cmake files where badly configured, and some consumers could not use them. PR: 266280 Reported by: yuri MFH: 2022Q3 cad/opencascade/Makefile | 8 +++++++- .../files/patch-adm_cmake_occt__macros.cmake | 17 ++++++++++++++++- .../files/patch-src_Standard_Standard__CString.cxx | 4 ++-- 3 files changed, 25 insertions(+), 4 deletions(-) A commit in branch 2022Q3 references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=3f4f4b240990348b8b261be32e797811f5ee09b4 commit 3f4f4b240990348b8b261be32e797811f5ee09b4 Author: Thierry Thomas <thierry@FreeBSD.org> AuthorDate: 2022-09-10 11:05:31 +0000 Commit: Thierry Thomas <thierry@FreeBSD.org> CommitDate: 2022-09-17 12:38:38 +0000 cad/opencascade: fix cmake files A cmake macro, which should have configured $OCCT_INSTALL_BIN_LETTER was not applied correctly. Thus some cmake files where badly configured, and some consumers could not use them. PR: 266280 Reported by: yuri MFH: 2022Q3 (cherry picked from commit 31735a5b1aae9a7967e8cc5f12ffab7779acc53c) cad/opencascade/Makefile | 8 +++++++- .../files/patch-adm_cmake_occt__macros.cmake | 17 ++++++++++++++++- .../files/patch-src_Standard_Standard__CString.cxx | 4 ++-- 3 files changed, 25 insertions(+), 4 deletions(-) (In reply to Thierry Thomas from comment #4) Thanks Thierry, My port graphics/f3d now builds fine with OpenCascade. Yuri (In reply to Yuri Victorovich from comment #7) You’re welcome! |