Path Workbench not loading in macOS arm build

This subforum is specifically to discuss packaging issues on different platforms (windows, mac, linux), and using different packaging systems (conda, etc...)
Post Reply
steve123
Posts: 149
Joined: Fri Sep 04, 2015 8:58 pm

Path Workbench not loading in macOS arm build

Post by steve123 »

Downloaded the macOS arm build a couple days ago and cannot load the Path Workbench. It appears the libgcc library is missing from the package and numpy fails to load. I tried to import numpy separately using the console and this is the error message:

Code: Select all

Python 3.10.5 | packaged by conda-forge | (main, Jun 14 2022, 07:09:13) [Clang 13.0.1 ] on darwin
Type 'help', 'copyright', 'credits' or 'license' for more information.
>>> Gui.runCommand('Std_Workbench',10)
>>> Gui.runCommand('Std_ViewStatusBar',1)
>>> import numpy
Traceback (most recent call last):
  File "/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/numpy/core/__init__.py", line 23, in <module>
    from . import multiarray
  File "/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/shiboken2/files.dir/shibokensupport/feature.py", line 139, in _import
    return original_import(name, *args, **kwargs)
  File "/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/numpy/core/multiarray.py", line 10, in <module>
    from . import overrides
  File "/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/shiboken2/files.dir/shibokensupport/feature.py", line 139, in _import
    return original_import(name, *args, **kwargs)
  File "/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/numpy/core/overrides.py", line 6, in <module>
    from numpy.core._multiarray_umath import (
  File "/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/shiboken2/files.dir/shibokensupport/feature.py", line 139, in _import
    return original_import(name, *args, **kwargs)
ImportError: dlopen(/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/numpy/core/_multiarray_umath.cpython-310-darwin.so, 0x0002): Library not loaded: '@rpath/libgcc_s.1.1.dylib'
  Referenced from: '/Applications/FreeCAD.app/Contents/Resources/lib/libgfortran.5.dylib'
  Reason: tried: '/Applications/FreeCAD.app/Contents/Resources/lib/libgcc_s.1.1.dylib' (no such file), '/Applications/FreeCAD.app/Contents/Resources/lib/libgcc_s.1.1.dylib' (no such file), '/Applications/FreeCAD.app/Contents/Resources/lib/libgcc_s.1.1.dylib' (no such file), '/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/numpy/core/../../../../libgcc_s.1.1.dylib' (no such file), '/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/numpy/core/../../../../libgcc_s.1.1.dylib' (no such file), '/Applications/FreeCAD.app/Contents/Resources/lib/libgcc_s.1.1.dylib' (no such file), '/Applications/FreeCAD.app/Contents/Resources/bin/../lib/libgcc_s.1.1.dylib' (no such file), '/usr/local/lib/libgcc_s.1.1.dylib' (no such file), '/usr/lib/libgcc_s.1.1.dylib' (no such file)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<input>", line 1, in <module>
  File "/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/shiboken2/files.dir/shibokensupport/feature.py", line 139, in _import
    return original_import(name, *args, **kwargs)
  File "/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/numpy/__init__.py", line 140, in <module>
    from . import core
  File "/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/shiboken2/files.dir/shibokensupport/feature.py", line 139, in _import
    return original_import(name, *args, **kwargs)
  File "/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/numpy/core/__init__.py", line 49, in <module>
    raise ImportError(msg)
ImportError: 

IMPORTANT: PLEASE READ THIS FOR ADVICE ON HOW TO SOLVE THIS ISSUE!

Importing the numpy C-extensions failed. This error can happen for
many reasons, often due to issues with your setup or how NumPy was
installed.

We have compiled some common reasons and troubleshooting tips at:

    https://numpy.org/devdocs/user/troubleshooting-importerror.html

Please note and check the following:

  * The Python version is: Python3.10 from "/Applications/FreeCAD.app/Contents/Resources/bin/freecad"
  * The NumPy version is: "1.23.2"

and make sure that they are the versions you expect.
Please carefully study the documentation linked above for further help.

Original error was: dlopen(/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/numpy/core/_multiarray_umath.cpython-310-darwin.so, 0x0002): Library not loaded: '@rpath/libgcc_s.1.1.dylib'
  Referenced from: '/Applications/FreeCAD.app/Contents/Resources/lib/libgfortran.5.dylib'
  Reason: tried: '/Applications/FreeCAD.app/Contents/Resources/lib/libgcc_s.1.1.dylib' (no such file), '/Applications/FreeCAD.app/Contents/Resources/lib/libgcc_s.1.1.dylib' (no such file), '/Applications/FreeCAD.app/Contents/Resources/lib/libgcc_s.1.1.dylib' (no such file), '/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/numpy/core/../../../../libgcc_s.1.1.dylib' (no such file), '/Applications/FreeCAD.app/Contents/Resources/lib/python3.10/site-packages/numpy/core/../../../../libgcc_s.1.1.dylib' (no such file), '/Applications/FreeCAD.app/Contents/Resources/lib/libgcc_s.1.1.dylib' (no such file), '/Applications/FreeCAD.app/Contents/Resources/bin/../lib/libgcc_s.1.1.dylib' (no such file), '/usr/local/lib/libgcc_s.1.1.dylib' (no such file), '/usr/lib/libgcc_s.1.1.dylib' (no such file)

>>> 

Code: Select all

OS: macOS 12.5
Word size of FreeCAD: 64-bit
Version: 0.21.30138 (Git)
Build type: Release
Branch: master
Hash: f5c5eec3bbe6cf1499d34d292d154d48e6285c0f
Python 3.10.5, Qt 5.15.4, Coin 4.0.0, Vtk 9.1.0, OCC 7.6.2
Locale: C/Default (C)
Installed mods: 
  * ThreadProfile 1.81.0
  * kicadStepUpMod 10.12.4
  * Curves 0.4.4
steve123
Posts: 149
Joined: Fri Sep 04, 2015 8:58 pm

Re: Path Workbench not loading in macOS arm build

Post by steve123 »

Build 30193 seems to have fixed the issue:

Code: Select all

OS: macOS 12.5
Word size of FreeCAD: 64-bit
Version: 0.21.30193 (Git)
Build type: Release
Branch: master
Hash: a8cb4e744483ce2c4b0770b948105a766330a4b2
Python 3.10.6, Qt 5.15.4, Coin 4.0.0, Vtk 9.1.0, OCC 7.6.2
Locale: C/Default (C)
Installed mods: 
  * ThreadProfile 1.81.0
  * kicadStepUpMod 10.12.4
  * Curves 0.4.4
Minor cosmetic issue ... the app icon is just a white box.
Post Reply