[Bug 254138] devel/cmake: aborts if CMAKE_CXX_STANDARD is set to empty

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Tue Mar 30 14:11:23 BST 2021


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=254138

Adriaan de Groot <adridg at freebsd.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |Not Accepted
             Status|Open                        |Closed

--- Comment #5 from Adriaan de Groot <adridg at freebsd.org> ---
Fixed upstream already with
https://gitlab.kitware.com/cmake/cmake/-/commit/533386ca2961060b81fce2f0532a55ed76b1b53d
. I'm going to close this again with "Don't DO THAT then", the workaround is to
not send an invalid empty value for CMAKE_CXX_STANDARD. I don't think it's
worth the effort to try to backport the fix to current FreeBSD ports when it
will show up in a future CMake release soon-ish.

For the record cmake git does this:

```
[adridg at beastie ~/Catch2/build]$
/usr/home/adridg/src/git/cmake-adridg/bin/cmake -GNinja -DCMAKE_CXX_STANDARD=
..
-- The CXX compiler identification is Clang 11.0.1
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Error at src/CMakeLists.txt:250 (target_compile_features):
  target_compile_features The CXX_STANDARD property on target "Catch2"
  contained an invalid value: "".


-- Configuring incomplete, errors occurred!
```

Which is the right thing to do, compared to

```
Abort trap (core dumped)
```

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the kde-freebsd mailing list