Bug 224649 - cad/opencascade: upgrade to 7.2.0
Summary: cad/opencascade: upgrade to 7.2.0
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Thierry Thomas
URL: https://reviews.freebsd.org/D13665
Keywords:
Depends on:
Blocks:
 
Reported: 2017-12-28 16:40 UTC by Thierry Thomas
Modified: 2018-02-17 19:48 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Thierry Thomas freebsd_committer 2017-12-28 16:40:31 UTC
This is the latest stable release.
See https://www.opencascade.com/content/latest-release

The patch is available in Phabricator D13665, see
https://reviews.freebsd.org/D13665
Comment 1 devel 2017-12-29 05:38:08 UTC
Fail to build on FreeBSD 10.3/amd64:

[1/3] : && /usr/bin/c++  -std=c++0x -O2 -pipe -I/usr/local/include -fstack-protector -fno-strict-aliasing -fexceptions -fPIC -Wall -Wextra  -O2 -pipe -I/usr/local/include -fstack-protector -fno-strict-aliasing -DNo_Exception  -fstack-protector src/DRAWEXE/CMakeFiles/DRAWEXE.dir/DRAWEXE.cxx.o  -o bsd64/clang/bin/DRAWEXE-7.2.0 -L/usr/local/lib  -L/usr/local/lib/vtk-6.2 -Wl,-rpath,/usr/local/lib:/usr/local/lib/vtk-6.2:/usr/ports/cad/opencascade/work/.build/bsd64/clang/lib: bsd64/clang/lib/libTKDraw.so.7.2.0 bsd64/clang/lib/libTKMesh.so.7.2.0 bsd64/clang/lib/libTKHLR.so.7.2.0 bsd64/clang/lib/libTKService.so.7.2.0 bsd64/clang/lib/libTKShHealing.so.7.2.0 bsd64/clang/lib/libTKTopAlgo.so.7.2.0 bsd64/clang/lib/libTKGeomAlgo.so.7.2.0 bsd64/clang/lib/libTKBRep.so.7.2.0 bsd64/clang/lib/libTKGeomBase.so.7.2.0 bsd64/clang/lib/libTKG3d.so.7.2.0 bsd64/clang/lib/libTKG2d.so.7.2.0 bsd64/clang/lib/libTKMath.so.7.2.0 bsd64/clang/lib/libTKernel.so.7.2.0 -lpthread -lrt -lstdc++ -lGL /usr/local/lib/libfreetype.so /usr/local/lib/libavcodec.so /usr/local/lib/libavformat.so /usr/local/lib/libswscale.so /usr/local/lib/libavutil.so /usr/local/lib/libtcl86.so -ltk86 -lX11 -lXext -lXmu -lXi -ltbb -ltbbmalloc && :
FAILED: bsd64/clang/bin/DRAWEXE-7.2.0 
: && /usr/bin/c++  -std=c++0x -O2 -pipe -I/usr/local/include -fstack-protector -fno-strict-aliasing -fexceptions -fPIC -Wall -Wextra  -O2 -pipe -I/usr/local/include -fstack-protector -fno-strict-aliasing -DNo_Exception  -fstack-protector src/DRAWEXE/CMakeFiles/DRAWEXE.dir/DRAWEXE.cxx.o  -o bsd64/clang/bin/DRAWEXE-7.2.0 -L/usr/local/lib  -L/usr/local/lib/vtk-6.2 -Wl,-rpath,/usr/local/lib:/usr/local/lib/vtk-6.2:/usr/ports/cad/opencascade/work/.build/bsd64/clang/lib: bsd64/clang/lib/libTKDraw.so.7.2.0 bsd64/clang/lib/libTKMesh.so.7.2.0 bsd64/clang/lib/libTKHLR.so.7.2.0 bsd64/clang/lib/libTKService.so.7.2.0 bsd64/clang/lib/libTKShHealing.so.7.2.0 bsd64/clang/lib/libTKTopAlgo.so.7.2.0 bsd64/clang/lib/libTKGeomAlgo.so.7.2.0 bsd64/clang/lib/libTKBRep.so.7.2.0 bsd64/clang/lib/libTKGeomBase.so.7.2.0 bsd64/clang/lib/libTKG3d.so.7.2.0 bsd64/clang/lib/libTKG2d.so.7.2.0 bsd64/clang/lib/libTKMath.so.7.2.0 bsd64/clang/lib/libTKernel.so.7.2.0 -lpthread -lrt -lstdc++ -lGL /usr/local/lib/libfreetype.so /usr/local/lib/libavcodec.so /usr/local/lib/libavformat.so /usr/local/lib/libswscale.so /usr/local/lib/libavutil.so /usr/local/lib/libtcl86.so -ltk86 -lX11 -lXext -lXmu -lXi -ltbb -ltbbmalloc && :
bsd64/clang/lib/libTKernel.so.7.2.0: undefined reference to `__cxa_thread_atexit'
c++: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.
Comment 2 Thierry Thomas freebsd_committer 2018-01-01 13:08:15 UTC
(In reply to devel from comment #1)
Thanks! A more recent compiler is required on FreeBSD 10:

-USES=		alias:10 cmake:outsource compiler:c++11-lib dos2unix \
+USES=		alias:10 cmake:outsource compiler:c++14-lang dos2unix \

I have updated https://reviews.freebsd.org/D13665
Comment 3 devel 2018-01-03 08:06:16 UTC
   Hello !

  On 12/current from April 2016 build is ok.
But cad/salome-gui 8.3.0 get next error messages about this Opencascade while configure:

-- Looking for Open CASCADE Technology ...
CMake Error at /usr/local/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
  Could NOT find CAS (missing: CAS_FWOSPlugin CAS_TKNIS CAS_PTKernel
  CAS_TKPCAF CAS_TKPLCAF CAS_TKPShape CAS_TKShapeSchema CAS_TKStdLSchema
  CAS_TKStdSchema CAS_TKXCAFSchema)
Call Stack (most recent call first):
  /usr/local/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:377 (_FPHSA_FAILURE_MESSAGE)
  /usr/ports/BUILD/usr/ports/cad/salome-gui/work/CONFIGURATION_8.3.0/cmake/FindCAS.cmake:248 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  /usr/ports/BUILD/usr/ports/cad/salome-gui/work/CONFIGURATION_8.3.0/cmake/SalomeMacros.cmake:426 (FIND_PACKAGE)
  /usr/ports/BUILD/usr/ports/cad/salome-gui/work/CONFIGURATION_8.3.0/cmake/SalomeMacros.cmake:525 (SALOME_FIND_PACKAGE)
  /usr/ports/BUILD/usr/ports/cad/salome-gui/work/CONFIGURATION_8.3.0/cmake/FindSalomeCAS.cmake:27 (SALOME_FIND_PACKAGE_AND_DETECT_CONFLICTS)
  CMakeLists.txt:155 (FIND_PACKAGE)


It looks like some additional files are required for integration with Salome:

cat /usr/ports/BUILD/usr/ports/cad/salome-gui/work/GUI_SRC_8.3.0/GUI_build/CMakeCache.txt | grep -i ^CAS | grep NOTFOUND
CAS_CONFIG_H:FILEPATH=CAS_CONFIG_H-NOTFOUND
CAS_DIR:PATH=CAS_DIR-NOTFOUND
CAS_FWOSPlugin:FILEPATH=CAS_FWOSPlugin-NOTFOUND
CAS_PTKernel:FILEPATH=CAS_PTKernel-NOTFOUND
CAS_TKNIS:FILEPATH=CAS_TKNIS-NOTFOUND
CAS_TKPCAF:FILEPATH=CAS_TKPCAF-NOTFOUND
CAS_TKPLCAF:FILEPATH=CAS_TKPLCAF-NOTFOUND
CAS_TKPShape:FILEPATH=CAS_TKPShape-NOTFOUND
CAS_TKShapeSchema:FILEPATH=CAS_TKShapeSchema-NOTFOUND
CAS_TKStdLSchema:FILEPATH=CAS_TKStdLSchema-NOTFOUND
CAS_TKStdSchema:FILEPATH=CAS_TKStdSchema-NOTFOUND
CAS_TKXCAFSchema:FILEPATH=CAS_TKXCAFSchema-NOTFOUND
CAS_VERSION_FILE:FILEPATH=CAS_VERSION_FILE-NOTFOUND
Comment 4 devel 2018-01-03 15:40:56 UTC
I have the same error with "compiler:c++14-lang" on 10.3/BSD:

1/3] : && /usr/local/bin/clang++40  -std=c++0x -O2 -pipe -I/usr/local/include -fstack-protector -fno-strict-aliasing -fexceptions -fPIC -Wall -Wextra  -O2 -pipe -I/usr/local/include -fstack-protector -fno-strict-aliasing -DNo_Exception  -fstack-protector src/DRAWEXE/CMakeFiles/DRAWEXE.dir/DRAWEXE.cxx.o  -o bsd64/clang/bin/DRAWEXE-7.2.0 -L/usr/local/lib  -L/usr/local/lib/vtk-6.2 -Wl,-rpath,/usr/local/lib:/usr/local/lib/vtk-6.2:/usr/ports/cad/opencascade/work/.build/bsd64/clang/lib: bsd64/clang/lib/libTKDraw.so.7.2.0 bsd64/clang/lib/libTKMesh.so.7.2.0 bsd64/clang/lib/libTKHLR.so.7.2.0 bsd64/clang/lib/libTKService.so.7.2.0 bsd64/clang/lib/libTKShHealing.so.7.2.0 bsd64/clang/lib/libTKTopAlgo.so.7.2.0 bsd64/clang/lib/libTKGeomAlgo.so.7.2.0 bsd64/clang/lib/libTKBRep.so.7.2.0 bsd64/clang/lib/libTKGeomBase.so.7.2.0 bsd64/clang/lib/libTKG3d.so.7.2.0 bsd64/clang/lib/libTKG2d.so.7.2.0 bsd64/clang/lib/libTKMath.so.7.2.0 bsd64/clang/lib/libTKernel.so.7.2.0 -lpthread -lrt -lstdc++ -lGL /usr/local/lib/libfreetype.so /usr/local/lib/libavcodec.so /usr/local/lib/libavformat.so /usr/local/lib/libswscale.so /usr/local/lib/libavutil.so /usr/local/lib/libtcl86.so /usr/local/lib/libtk86.so -lX11 -lXext -lXmu -lXi -ltbb -ltbbmalloc && :
FAILED: bsd64/clang/bin/DRAWEXE-7.2.0 
: && /usr/local/bin/clang++40  -std=c++0x -O2 -pipe -I/usr/local/include -fstack-protector -fno-strict-aliasing -fexceptions -fPIC -Wall -Wextra  -O2 -pipe -I/usr/local/include -fstack-protector -fno-strict-aliasing -DNo_Exception  -fstack-protector src/DRAWEXE/CMakeFiles/DRAWEXE.dir/DRAWEXE.cxx.o  -o bsd64/clang/bin/DRAWEXE-7.2.0 -L/usr/local/lib  -L/usr/local/lib/vtk-6.2 -Wl,-rpath,/usr/local/lib:/usr/local/lib/vtk-6.2:/usr/ports/cad/opencascade/work/.build/bsd64/clang/lib: bsd64/clang/lib/libTKDraw.so.7.2.0 bsd64/clang/lib/libTKMesh.so.7.2.0 bsd64/clang/lib/libTKHLR.so.7.2.0 bsd64/clang/lib/libTKService.so.7.2.0 bsd64/clang/lib/libTKShHealing.so.7.2.0 bsd64/clang/lib/libTKTopAlgo.so.7.2.0 bsd64/clang/lib/libTKGeomAlgo.so.7.2.0 bsd64/clang/lib/libTKBRep.so.7.2.0 bsd64/clang/lib/libTKGeomBase.so.7.2.0 bsd64/clang/lib/libTKG3d.so.7.2.0 bsd64/clang/lib/libTKG2d.so.7.2.0 bsd64/clang/lib/libTKMath.so.7.2.0 bsd64/clang/lib/libTKernel.so.7.2.0 -lpthread -lrt -lstdc++ -lGL /usr/local/lib/libfreetype.so /usr/local/lib/libavcodec.so /usr/local/lib/libavformat.so /usr/local/lib/libswscale.so /usr/local/lib/libavutil.so /usr/local/lib/libtcl86.so /usr/local/lib/libtk86.so -lX11 -lXext -lXmu -lXi -ltbb -ltbbmalloc && :
bsd64/clang/lib/libTKernel.so.7.2.0: undefined reference to `__cxa_thread_atexit'
clang-4.0: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.
Comment 5 Thierry Thomas freebsd_committer 2018-01-03 20:45:42 UTC
(In reply to devel from comment #4)
Thanks for your tests. I have no more 10.3, and I have tested it in a poudriere jail on 10.4 (it's OK), and I do not see a difference between 10.3 and 10.4. Do you know which version of the compiler is being used?

(and I'm investigating the problem with cad/salome-gui)
Comment 6 devel 2018-01-04 05:07:11 UTC
Compiler /usr/local/bin/clang++40 taken from llvm40-4.0.1.r1_4.
Comment 7 Thierry Thomas freebsd_committer 2018-01-08 17:57:11 UTC
(In reply to devel from comment #6)
I guess that this is the problem: Clang 5.0 should be brought (See PR 224591).
Comment 8 devel 2018-01-09 16:37:58 UTC
Same problem after updating ports tree and getting clang50 via dependency:

===>  Building for opencascade-7.2.0
[1/3] : && /usr/local/bin/clang++50  -std=c++0x -O2 -pipe -I/usr/local/include -fstack-protector -fno-strict-aliasing -fexceptions -fPIC -Wall -Wextra  -O2 -pipe -I/usr/local/include -fstack-protector -fno-strict-aliasing -DNo_Exception  -fstack-protector src/DRAWEXE/CMakeFiles/DRAWEXE.dir/DRAWEXE.cxx.o  -o bsd64/clang/bin/DRAWEXE-7.2.0 -L/usr/local/lib  -L/usr/local/lib/vtk-6.2 -Wl,-rpath,/usr/local/lib:/usr/local/lib/vtk-6.2:/usr/ports/cad/opencascade/work/.build/bsd64/clang/lib: bsd64/clang/lib/libTKDraw.so.7.2.0 bsd64/clang/lib/libTKMesh.so.7.2.0 bsd64/clang/lib/libTKHLR.so.7.2.0 bsd64/clang/lib/libTKService.so.7.2.0 bsd64/clang/lib/libTKShHealing.so.7.2.0 bsd64/clang/lib/libTKTopAlgo.so.7.2.0 bsd64/clang/lib/libTKGeomAlgo.so.7.2.0 bsd64/clang/lib/libTKBRep.so.7.2.0 bsd64/clang/lib/libTKGeomBase.so.7.2.0 bsd64/clang/lib/libTKG3d.so.7.2.0 bsd64/clang/lib/libTKG2d.so.7.2.0 bsd64/clang/lib/libTKMath.so.7.2.0 bsd64/clang/lib/libTKernel.so.7.2.0 -lpthread -lrt -lstdc++ -lGL /usr/local/lib/libfreetype.so /usr/local/lib/libavcodec.so /usr/local/lib/libavformat.so /usr/local/lib/libswscale.so /usr/local/lib/libavutil.so /usr/local/lib/libtcl86.so /usr/local/lib/libtk86.so -lX11 -lXext -lXmu -lXi -ltbb -ltbbmalloc && :
FAILED: bsd64/clang/bin/DRAWEXE-7.2.0 
: && /usr/local/bin/clang++50  -std=c++0x -O2 -pipe -I/usr/local/include -fstack-protector -fno-strict-aliasing -fexceptions -fPIC -Wall -Wextra  -O2 -pipe -I/usr/local/include -fstack-protector -fno-strict-aliasing -DNo_Exception  -fstack-protector src/DRAWEXE/CMakeFiles/DRAWEXE.dir/DRAWEXE.cxx.o  -o bsd64/clang/bin/DRAWEXE-7.2.0 -L/usr/local/lib  -L/usr/local/lib/vtk-6.2 -Wl,-rpath,/usr/local/lib:/usr/local/lib/vtk-6.2:/usr/ports/cad/opencascade/work/.build/bsd64/clang/lib: bsd64/clang/lib/libTKDraw.so.7.2.0 bsd64/clang/lib/libTKMesh.so.7.2.0 bsd64/clang/lib/libTKHLR.so.7.2.0 bsd64/clang/lib/libTKService.so.7.2.0 bsd64/clang/lib/libTKShHealing.so.7.2.0 bsd64/clang/lib/libTKTopAlgo.so.7.2.0 bsd64/clang/lib/libTKGeomAlgo.so.7.2.0 bsd64/clang/lib/libTKBRep.so.7.2.0 bsd64/clang/lib/libTKGeomBase.so.7.2.0 bsd64/clang/lib/libTKG3d.so.7.2.0 bsd64/clang/lib/libTKG2d.so.7.2.0 bsd64/clang/lib/libTKMath.so.7.2.0 bsd64/clang/lib/libTKernel.so.7.2.0 -lpthread -lrt -lstdc++ -lGL /usr/local/lib/libfreetype.so /usr/local/lib/libavcodec.so /usr/local/lib/libavformat.so /usr/local/lib/libswscale.so /usr/local/lib/libavutil.so /usr/local/lib/libtcl86.so /usr/local/lib/libtk86.so -lX11 -lXext -lXmu -lXi -ltbb -ltbbmalloc && :
bsd64/clang/lib/libTKernel.so.7.2.0: undefined reference to `__cxa_thread_atexit'
clang-5.0: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.
Comment 9 Thierry Thomas freebsd_committer 2018-01-09 17:55:45 UTC
(In reply to devel from comment #8)
__cxa_thread_atexit is part of libsupc++, but I don't want to link explicitly with it.

Would it be possible for you to upgrade your system from 10.3 to 10.4?
Comment 10 devel 2018-02-06 13:03:20 UTC
(In reply to Thierry Thomas from comment #9)
Hello ! 
Sorry for delay.
There is no problem with build after upgrade to 10.4.
Comment 11 Thierry Thomas freebsd_committer 2018-02-17 19:48:41 UTC
Committed! Thanks to the reviewers.
Comment 12 commit-hook freebsd_committer 2018-02-17 19:48:57 UTC
A commit references this bug:

Author: thierry
Date: Sat Feb 17 19:48:35 UTC 2018
New revision: 462190
URL: https://svnweb.freebsd.org/changeset/ports/462190

Log:
  Upgrade to 7.2.0.

  Release notes in
  https://www.opencascade.com/sites/default/files/documents/release_notes_7.2.0.pdf

  PR:		224649
  Differential Revision:	https://reviews.freebsd.org/D13665

Changes:
  head/cad/opencascade/Makefile
  head/cad/opencascade/distinfo
  head/cad/opencascade/files/patch-CMakeLists.txt
  head/cad/opencascade/files/patch-adm_cmake_occt__csf.cmake
  head/cad/opencascade/files/patch-adm_cmake_occt__macros.cmake
  head/cad/opencascade/files/patch-adm_templates_OpenCASCADEConfig.cmake.in
  head/cad/opencascade/files/patch-adm_templates_custom.install.sh.in
  head/cad/opencascade/files/patch-inc_Standard__Time.hxx
  head/cad/opencascade/files/patch-src_DrawResources_CheckCommands.tcl
  head/cad/opencascade/files/patch-src_RWStl_RWStl__Reader.cxx
  head/cad/opencascade/files/patch-src_STEPConstruct_STEPConstruct__AP203Context.cxx
  head/cad/opencascade/files/patch-src_Standard_Standard__CLocaleSentry.hxx
  head/cad/opencascade/files/patch-src_Standard_Standard__CString.cxx
  head/cad/opencascade/files/patch-src_Standard_Standard__MMgrTBBalloc.cxx
  head/cad/opencascade/files/patch-src_Standard_Standard__Time.hxx
  head/cad/opencascade/files/patch-src_StepFile_recfile.pc
  head/cad/opencascade/pkg-plist