Skip to content
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

ecbuild_print_summary: Inconsistent presentation of feature status #79

Open
reuterbal opened this issue Feb 21, 2025 · 3 comments
Open
Assignees
Labels
bug Something isn't working

Comments

@reuterbal
Copy link

What happened?

The fix for #65 was a more detailed output of the project summary in superbuilds within the boundaries that reporting on the CMake feature level allows (in particular, grouping features with the same name together, irrespective of whether they are enabled or disabled in a specific project).

This project-specific status is reported in parentheses, where the value in the parentheses (ON/OFF) represents the status of this option for the particular project. Or so I thought. It seems that options that are not explicitly enabled or disabled but end up being disabled, e.g., because a CONDITION is not fulfilled, may still show (ON) if that is their default value.

What are the steps to reproduce the bug?

module reset
module load cmake/3.28
git clone https://github.com/ecmwf/ecbuild
cd ecbuild/examples/simple
../../bin/ecbuild -S . -B build

This reports:

-- ---------------------------------------------------------
-- Feature summary
-- ---------------------------------------------------------
-- The following features have been enabled:

 * TESTS, simple(ON): 'Enable the unit tests'
 * PKGCONFIG, simple(ON): 'Enable ecbuild_pkgconfig'

-- The following OPTIONAL packages have been found:

 * Git
 * Threads
 * PkgConfig
 * Perl

-- The following REQUIRED packages have been found:

 * ecbuild

-- The following features have been disabled:

 * MATRIX, simple(ON): 'Use matrix operations'
 * BESSEL, simple(ON): 'Compute Bessel function'

-- The following OPTIONAL packages have not been found:

 * BLAS
 * LAPACK
 * GSL

Note that the MATRIX and BESSEL features are disabled because their conditions (REQUIRED_PACKAGES "NAME LAPACK" or CONDITION HAVE_MATRIX AND GSL_FOUND, respectively) are not fulfilled. I would have expected the parentheses to show (OFF) for both in this situation.

Version

3.9.1

Platform (OS and architecture)

ECMWF Atos HPCF

Relevant log output

Accompanying data

No response

Organisation

No response

@reuterbal reuterbal added the bug Something isn't working label Feb 21, 2025
@marcosbento marcosbento self-assigned this Feb 26, 2025
@marcosbento
Copy link
Collaborator

Hi @reuterbal, thanks for reporting this issue. Let me investigate what might be happening and I'll come back to you.

@marcosbento
Copy link
Collaborator

@reuterbal Sorry for taking so long, but I finally looked into this and indeed the ON/OFF status was being cached too early and didn't take into consideration the required packages or conditions.

I believe the necessary changes, on #82, fix this issue and should now be running on the CI.

@marcosbento
Copy link
Collaborator

Hi @reuterbal, @wdeconinck has merged the PR with changes regarding this issue.
I kindly ask you to check and make sure this has been fixed, in order to close the issue.

marcosbento added a commit that referenced this issue Mar 19, 2025
The new tests prove that issue #73
is fixed by the changes intended to correct #79.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants