question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Passing through setup.py options

See original GitHub issue

Pip has an (ugly) mechanism for passing through arguments. When using SciKit Build, these arguments are used to control the CMake build. So, for example:

setup.py install -- "-DCMAKE_MY_ARGUMENT=ON"

can be handled as

pip install . --install-option "--" --install-option "-DCMAKE_MY_ARGUMENT=ON"

(pip also offers a --global-option, but don’t provide much info on the difference; I assume this also gets applied to dependencies?)

pipenv doesn’t offer a way to pass this through to pip, as far as I can tell. This would make the most sense with . installs, since build arguments are not be stored (AFAIK) in the Pipfile.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:12 (10 by maintainers)

github_iconTop GitHub Comments

7reactions
cLupuscommented, Apr 19, 2018

Is there a way to give these arguments in the Pipfile?

1reaction
uranusjrcommented, Apr 19, 2018

@cLupus No.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to obtain arguments passed to setup.py from pip with
In the run method you can expose the value of the option to setup.py (in my example I use a global variable). from...
Read more >
2. Writing the Setup Script — Python 3.11.1 documentation
The setup script is the centre of all activity in building, distributing, and installing modules using the Distutils. The main purpose of the...
Read more >
A Practical Guide to Using Setup.py - GoDataDriven
The key to setting up your project is the setup.py file. In this blog I'll go into the details of this file. Where...
Read more >
Running setuptools commands - Python Packaging Authority
Historically, setuptools allowed running commands via a setup.py script at the root of a Python project, as indicated in the examples below:.
Read more >
Getting Started With setuptools and setup.py - PythonHosted.org
All the features of what can go into a setup.py file is beyond the scope of this simple tutorial. I'll just focus on...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found