As of Wheel 0.24.0, this is support using extra_require
. For instance
setup(
...,
extras_require={':python_version=="2.6"':: ['ipaddr']},
...
)
This is documented in the "Defining Conditional Dependencies" of the Wheel documentation and follows PEP 426.