Skip to content

[Bug]: Environment variables upset testing #255

Description

What happened?

When building with MPI disabled and vernier loaded from the software stack, the build fails with a cryptic error:

[ 30%] Built target vernier
[ 32%] Linking CXX executable test_profiler
$PWD/build/tests/unit_tests/c++/test_profiler: symbol lookup error: $PWD/build/tests/unit_tests/c++/test_profiler: undefined symbol: _Z8MPI_InitPiPPPc
CMake Error at /data/apps/spack/releases/2025.11.19/install/linux-rhel9-zen2/gcc-12.2.0/cmake-3.30.5-ktdsgm4ll462blorzs6imncxit2ddt5k/share/cmake-3.30/Modules/GoogleTestAddTests.cmake:112 (message):
  Error running test executable.

    Path: '$PWD/build/tests/unit_tests/c++/test_profiler'
    Working directory: '$PWD/build/tests/unit_tests/c++'
    Result: 127
    Output:

This happens because $LDFLAGS also contains a reference to vernier and the build system is picking this up rather than the version that should be being tested. This should probably trigger an error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions