-
Notifications
You must be signed in to change notification settings - Fork 8
Description
Hi @dholth,
first of all many thanks for this project. I'm currently searching for alternatives for our current setup.py based python packaging (due to the deprecation of setuptools command line usage and a lot of frustration in the past)... As an old scons user, I very much like the idea to use SCons for python packaging :)
One of the reasons for the migration is that we currently use pip's deprecated --build-option / --global-option which broke with the latest pip 23.x releases. They suggest to use --config-settings instead.
Unfortunately enscons seem to ignore these settings passed from pip.
It would be cool if we could pass the settings into the ARGUMENTS from SCons.
For example, in enscons.api.build_wheel:
def build_wheel(wheel_directory, settings, metadata_directory=None):
sys.argv[1:] = ["--wheel-dir=" + wheel_directory, "bdist_wheel"]
for k in settings:
sys.argv.append(f"{k}=settings{k}")
return _run("bdist_wheel")Then we could say pip wheel --config-settings 'an_option=a_value' and in the SConstruct we can access that option by ARGUMENTS["an_option"].
What do you think about this?