Bug #5559
closedSaxonc library failure on Macos M1 chips
100%
Description
Reported by user on stackoverflow see: https://stackoverflow.com/questions/72569354/saxonc-python-extension-issue-with-macos
The SaxonC dylib library which is generated by Excelsior Jet fails on an M1 chip architecture.
The following error message occurs when I run the C++ samples:
Unable to load /Users/ond1/libsaxon-HEC-11.3/libsaxonhec.dylib
Error: : Undefined error: 0
Updated by O'Neil Delpratt almost 2 years ago
- Category changed from Mac Os X to Documentation
The Saxon/C library (i.e. libsaxonhec.dylib) is built using Excelsior Jet for a x86_64 MacOS machine. Users of SaxonC on these machines will encounter execution problems for the samples, command and Python/PHP extensions because they are building the executable for an arm64 machine.
The workaround is to run the build scripts with the arch -x86_64
command as prefix. See example below for SaxonC commands:
arch -x86_64 ./build64-mac.sh
When building the SaxonC python extension the following should work:
arch -x86_64 python3 saxon-setup.py build_ext -if
Unfortunately python3 needs to be run as x86_64:
arch -x86_64 python3 saxon_example3.py
It is unlikely that that this problem will be fixed on the SaxonC 11 branch. We will add a note in the documentation.
Updated by O'Neil Delpratt over 1 year ago
- Status changed from New to Closed
- % Done changed from 0 to 100
- Fixed in version set to 12.0
Bug issue fixed in SaxonC 12.0 as we have now moved to using Graalvm native-image.
Please register to edit this issue