Vendored GTest Compile Error (-Werror=undef)
envgap__bpftrace__bpftrace-2951
01 / FAILURE SIGNATURE
As reported upstream
_deps/gtest-src/googletest/src/gtest_main.cc:33:5: error: "GTEST_OS_ESP8266" is not defined, evaluates to 0 [-Werror=undef]
Not a benchmark task.
- In a clean container the reported failure did not reproduce, or the known fix did not make the project run.
02 / ENVIRONMENT RECIPE
- Base commit
4bc94a15025f6c60b8cff20daea3d47e7891a18a- Manifest
CMakeLists.txt- Reproduce
Awaiting issue-specific recipe- Run under trace
Awaiting a meaningful runtime command
03 / ORIGINAL ISSUE TEXT
bpftrace/bpftrace #2951 · read the original issue
#2950 added `-Werror=undef` which causes GTest's compilation to fail.
https://github.com/iovisor/bpftrace/blob/f0c8f3fcd033a6ee2952b55ad272604f30146764/tests/CMakeLists.txt#L1
We need to decide if we want to keep support for vendoring GTest. Most major distros seem to provide gtest-1.11+ at this point, with exceptions being openSUSE and MX Linux: https://repology.org/project/gtest/versions.
Unless there are any strong opinions, let's leave this issue open for a while and see if anyone complains.
Example errors:
```
_deps/gtest-src/googletest/src/gtest_main.cc:33:5: error: "GTEST_OS_ESP8266" is not defined, evaluates to 0 [-Werror=undef]
33 | #if GTEST_OS_ESP8266 || GTEST_OS_ESP32
| ^~~~~~~~~~~~~~~~
_deps/gtest-src/googletest/src/gtest_main.cc:33:25: error: "GTEST_OS_ESP32" is not defined, evaluates to 0 [-Werror=undef]
33 | #if GTEST_OS_ESP8266 || GTEST_OS_ESP32
| ^~~~~~~~~~~~~~
```04 / LABELS
Labels from the report text only; not yet run
No supported category has been assigned.
Label rules and the text that matched
[]