Skip to content

Add scons options for compilation verbosity - #104

Open
clemisch wants to merge 2 commits into
diffpy:mainfrom
clemisch:compile_silent
Open

Add scons options for compilation verbosity#104
clemisch wants to merge 2 commits into
diffpy:mainfrom
clemisch:compile_silent

Conversation

@clemisch

Copy link
Copy Markdown
Contributor

(essentially the same as diffpy/libobjcryst#32)

Currently the manual compilation with scons dev is quite noisy: it prints all compiler commands and all compiler warnings. There is no flag to control it.

For development I found that annoying, mainly because it's hard to spot an error in the wall of warnings.

This PR adds scons flags verbose: true|false = false and warnigns: all|default|none = none. verbose controls if compiler commands are printed. warnings controls compiler warnings. For the latter:

  • all: inherited -W flags (from python-config) + -Wextra
  • default: no explicit warning-control flags
  • none: suppress all warnings (only show errors) [new default]

I think it's more common to show warnings on demand rather than by default, but that's kinda subjective and I'm happy to change the default to warnings=all and verbose=true. That would mimick current behavior.

@github-actions

Copy link
Copy Markdown

Warning! No news item is found for this PR. If this is a user-facing
change/feature/fix,
please add a news item by copying the format from news/TEMPLATE.rst.
For best practices, please visit
https://scikit-package.github.io/scikit-package/snippets/news-file-format.html#how-do-i-create-a-news-file.

@clemisch

Copy link
Copy Markdown
Contributor Author

I'll add the news item after we discussed the rest and came to an agreement ;-)

@vincefn

vincefn commented Aug 24, 2026

Copy link
Copy Markdown
Collaborator

If we move towards nanobind, the proposed branch switched to cmake, so it may supersede this. And it would remove libobjcryst. I guess that needs to be settled first.

@clemisch

Copy link
Copy Markdown
Contributor Author

Yeah but how soon will that be, realistically?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants