Opened 5 months ago
Last modified 5 months ago
#70235 new defect
opencascade: wrong handling of symbols on older macOS
Reported by: | barracuda156 | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.9.3 |
Keywords: | snowleopard, powerpc | Cc: | MarcusCalhoun-Lopez (Marcus Calhoun-Lopez) |
Port: | opencascade |
Description
I got weird behavior with opencascade
. First of all, it tries to pull symbols for system frameworks from MacPorts prefix:
36-25% /opt/local/libexec/opencascade/bin/draw.sh Hint: use "pload ALL" command to load standard commands dyld: Symbol not found: __cg_jpeg_resync_to_restart Referenced from: /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/ImageIO Expected in: /opt/local/lib/libJPEG.dylib /opt/local/libexec/opencascade/bin/draw.sh: line 10: 50815 Trace/BPT trap DRAWEXE dyld: Library not loaded: /opt/local/lib/libjpeg.8.dylib Referenced from: /opt/local/lib/libTIFF.dylib Reason: image not found ^C/opt/local/libexec/opencascade/bin/draw.sh: line 10: 50914 Trace/BPT trap DRAWEXE dyld: Symbol not found: _gll_noop Referenced from: /System/Library/Frameworks/OpenGL.framework/Versions/A/OpenGL Expected in: /opt/local/lib/libGL.dylib /opt/local/libexec/opencascade/bin/draw.sh: line 10: 50968 Trace/BPT trap DRAWEXE
This is not linking, it just seems to shade away system libs even for system components.
I have to deactivate libjpeg-turbo
, tiff
, giflib
, mesa
and libGLU
.
Once that is done, no more symbols errors, but the app crashes when I try to do something in it.
36-25% /opt/local/libexec/opencascade/bin/draw.sh Hint: use "pload ALL" command to load standard commands Draw[1]> Draw[2]> bgerror failed to handle background error. Original error: Error in bgerror: XIO: fatal IO error 0 (Unknown error: 0) on X server "/tmp/launch-GEIw2u/org.macports:0" after 1262 requests (1262 known processed) with 4 events remaining. Assertion failed: (ret != inval_id), function _XAllocID, file xcb_io.c, line 626. /opt/local/libexec/opencascade/bin/draw.sh: line 10: 51019 Abort trap
(Initially there is a malloc error too, but that I have fixed via adding a path in the wrapper.)
Crash aside, such behavior with libraries I see for the first time, I think.
Change History (5)
comment:1 Changed 5 months ago by barracuda156
comment:3 Changed 5 months ago by barracuda156
It is a mess starting from configure:
-- Info: TKIVtk and TKIVtkDraw toolkits excluded due to VTK usage is disabled -- Info: The directories of 3rdparty headers: /System/Library/Frameworks/Tcl.framework/Headers /System/Library/Frameworks/Tk.framework/Headers
comment:4 Changed 5 months ago by barracuda156
I give up for now.
Fixed linking to the right tk/tcl, fixed build against X11, but it is still defunct. I was able to get a step further as compared to Cocoa build, but it is broken anyway.
Gives build times, I may not be willing to fix it via trial and error.
comment:5 Changed 5 months ago by ryandesign (Ryan Carsten Schmidt)
Replying to barracuda156:
36-25% /opt/local/libexec/opencascade/bin/draw.sh Hint: use "pload ALL" command to load standard commands dyld: Symbol not found: __cg_jpeg_resync_to_restart Referenced from: /System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/ImageIO.framework/Versions/A/ImageIO Expected in: /opt/local/lib/libJPEG.dylib
This happens if the environment variable DYLD_LIBRARY_PATH
is set to contain /opt/local/lib
and you have a case-insensitive filesystem. I see that draw.sh sources env.sh and that env.sh contains:
if [ "$WOKSTATION" == "mac" ]; then if [ "$DYLD_LIBRARY_PATH" != "" ]; then export DYLD_LIBRARY_PATH="${LD_LIBRARY_PATH}:${DYLD_LIBRARY_PATH}" else export DYLD_LIBRARY_PATH="${LD_LIBRARY_PATH}" fi fi
This is the cause of the problem and has to stop.
Notice, that app itself launches successfully. I get a crash once I try doing something from menus. Trying to run a sample now, I got:
Which seems suggestive. Maybe it assumes Cocoa backend? That should be changed, if so.