Bug #5860


Self built python extension failure to link library

Added by O'Neil Delpratt over 1 year ago. Updated 23 days ago.

Python Build
Start date:
Due date:
% Done:


Estimated time:
Applies to branch:
Fix Committed on Branch:
Fixed in Maintenance Release:
Found in version:
Fixed in version:
SaxonC Languages:
SaxonC Platforms:
SaxonC Architecture:


Reported by userL

There is a problem to self build the python library from the pypi directory.

Currently if we build the wheel with the command:

python3 bdist_wheel

or building the extension locallly:

python3 build_ext -if

It builds successfully (although user reported that they had to make changes in the setup file to locate the library). When we run a sample python script we get the following error:

Traceback (most recent call last):
  File "/Users/ond1/work/saxondev/build/temp/libsaxon-EEC-mac-x86_64-v12.0/pypi/samples/", line 1, in <module>
    import saxoncee
ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/, 0x0002): symbol not found in flat namespace (_addProcessorDataPair)
Actions #1

Updated by O'Neil Delpratt 2 months ago

  • Assignee changed from O'Neil Delpratt to Matt Patterson
Actions #2

Updated by Matt Patterson about 1 month ago

  • Status changed from New to Resolved
  • Fixed in version set to 12.5

This has been addressed with improved build scripts in the saxon12 branch.

The hec_python_build_wheel task (or pec_... or eec_...) builds a wheel that does not have libsaxon bundled.

The hec_python_repair_wheel task takes the wheel from the previous task and runs the platform-appropriate utility on it to bundle libsaxon correctly.

(There's also an hec_python_install_wheel which takes the repaired wheel and installs it into the Venv for the current branch, but that seems less relevant here.)

Actions #3

Updated by O'Neil Delpratt 23 days ago

  • Status changed from Resolved to Closed

Bug fix applied in the Saxon 12.5 Maintenance release.

Please register to edit this issue

Also available in: Atom PDF