Skip to content

Wheel package

Ben Boeckel requested to merge ben.boeckel/vtk:wheel-package into master
This topic adds support for building a wheel (`.whl`) for
VTK. This is done by generating a `setup.py` file in VTK's
build tree during its configuration step which then can be
used to complete the build and make a wheel. It does not
support making a valid `sdist` file because the `setup.py`
is not the entry point to this build.

The reason that things are done this way is because VTK's
configuration logic is complicated and reimplementing it in
`setup.py` is not maintainable. Instead, it takes whatever
VTK is built and packages it up.

When this mode is used, the sole purpose of the build tree
is to build a wheel; it is not a general-purpose VTK build
tree. This is because the structure expected by the
`bdist_wheel` command is accomplished by setting output
directories which causes standard things such as  `bin` and
`lib` to not be included.

This will likely be split into a separate MR (!5544 (merged)) to get the "easy" fixes and such in earlier. than this is likely to land.

TODO list:

  • support marking the wheel with "feature" flags for what is actually contained in it
  • Windows support
  • macOS support
  • documentation for building a wheel
  • replace sdist command pointing to aforementioned instructions

Cc: @jcfr @matt-mccormick @thewtex @utkarsh.ayachit @demarle @danlipsa @ken-martin @stephen.aylward

Edited by Ben Boeckel

Merge request reports