vtk wheel: vendored proj does not work because the database is not included
So VTK's wheels contain libproj
but not in a way that works because its proj.db
is not in the wheel itself. Alas, Python packaging intersecting VTK's build system is a nightmare and I was able to get it into the wheel by abusing Python's duck typing and just path-traversing in package_data
, but not in a way that pip install
liked on install (why does bdist_wheel
not error on the creation side? who knows):
ERROR: For req: vtk==9.2.20221216.dev0. Unknown scheme key used in /home/boeckb/misc/builds/vtk/build-whl/dist/vtk-9.2.20221216.dev0-cp311-cp311-linux_x86_64.whl: share (for file 'vtk-9.2.20221216.data/share/vtk/proj/proj.db'). .data directory contents should be in subdirectories named with a valid scheme key (data, headers, platlib, purelib, scripts)
So the wheel build needs to update how the database is placed into the build tree in ThirdParty/libproj/vtklibproj/data/CMakeLists.txt
and get it into the wheel with whatever setuptools
wants in CMake/setup.py.in
.
Edited by Ben Boeckel