-
Notifications
You must be signed in to change notification settings - Fork 125
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Please consider making the python bindings optional #360
Comments
In the top-level CMakeLists.txt, the
Could the problem be that the |
The Debian imath package explicitly wants to build the python binding. This is desirable (in Debian, we build source packages with all available features enabled) and not what I propose to change. For that reason, the Debian imath package sets https://sources.debian.org/src/imath/3.1.9-3/debian/rules/#L21 But I'm not talking about making the python bindings optional when building imath. I'm talking about making them optional when installing everything and then building a package that uses imath via cmake. This is why this affects all the other packages I listed above. It is about building software that requires imath not about building imath itself. Through the |
Ah, that makes sense, I was thinking only of the build. If you're confident that removing the EXPORT solves the problem and isn't otherwise necessary, please do submit a PR. As you point out, we should also clarify the wording in the README.md to state that the bindings are optional at build time. |
…orting targets for dependent projects Thanks: Jochen Sprickerhof Closes: AcademySoftwareFoundation#360
…orting targets for dependent projects Thanks: Jochen Sprickerhof Closes: AcademySoftwareFoundation#360 Signed-off-by: Johannes Schauer Marin Rodrigues <[email protected]>
…orting targets for dependent projects (#361) Thanks: Jochen Sprickerhof Closes: #360 Signed-off-by: Johannes Schauer Marin Rodrigues <[email protected]>
…orting targets for dependent projects (AcademySoftwareFoundation#361) Thanks: Jochen Sprickerhof Closes: AcademySoftwareFoundation#360 Signed-off-by: Johannes Schauer Marin Rodrigues <[email protected]>
…orting targets for dependent projects (AcademySoftwareFoundation#361) Thanks: Jochen Sprickerhof Closes: AcademySoftwareFoundation#360 Signed-off-by: Johannes Schauer Marin Rodrigues <[email protected]>
…orting targets for dependent projects (#361) Thanks: Jochen Sprickerhof Closes: #360 Signed-off-by: Johannes Schauer Marin Rodrigues <[email protected]>
Hi,
the second paragraph of the
README.md
states:The python bindings though, are in fact (as of the time i'm writing this) not optional. If one tries to build a project that requires imath using cmake one gets the following error output during configuration if the python bindings are not installed:
What makes the python bindings not optional is the
EXPORT
line insrc/python/config/ModuleDefine.cmake
. The following patch fixes the problem and makes the python bindings indeed optional as stated in the readme:To make sure, that this does not break anything, I obtained a list of all source packages in Debian unstable which directly or indirectly use imath. The full list is:
Out of those packages, the following packages fail with above error if the python imath module is not installed:
After removing the
EXPORT
line, these build successfully again. Credit goes to @jspricke for finding theEXPORT
line as the culprit.Would you like me to file a pull request with the change proposed above?
The practical problem that removing the hard python requirement solves is, that otherwise packages that directly or indirectly require imath will pull in the host architecture python which makes the cross-build dependencies unsatisfiable for the long list of packages above.
Thanks!
The text was updated successfully, but these errors were encountered: