pscoro added a comment.

In D154869#4652224 <https://reviews.llvm.org/D154869#4652224>, @sylvestre.ledru 
wrote:

> With this patch, it started to fail with:
> It would be nice to have a better error message suggesting what to do
>
>   -- Performing Test HAVE_DECL_STRERROR_S
>   -- Performing Test HAVE_DECL_STRERROR_S - Failed
>   CMake Error at /build/source/flang-rt/unittests/CMakeLists.txt:37 (message):
>     Target llvm_gtest not found.
>   
>   
>   -- Configuring incomplete, errors occurred!

Hi, I originally authored this patch but **I am no longer actively involved in 
Flang's development at the moment**, however, I've been getting notifications 
that this patch has been landed yesterday and subsequently, the failing 
buildbots.
I believe all the gtest not found errors originate from a missing build flag, 
as per the documentation page for flang-rt in `flang-rt/docs/GettingStarted.md`:

  # We need to enable GTest if we want to run Flang-rt's testsuites
  -DLLVM_INSTALL_GTEST=On \

I believe I saw that clang buildbots also got inadvertently by this cmake 
change as well.
Wish I had time to investigate this further myself, hopefully @madanial can 
take a closer look. I believe what needs to be done is:

- flang buildbots need their build flags updated to include 
`-DLLVM_INSTALL_GTEST=On`
- The `Target llvm_gtest not found.` should be improved to offer better guidance
- The clang failures should be looked at closer; see if its possible to make a 
change to the cmake to limit the scope of builds needing the 
`-DLLVM_INSTALL_GTEST=On` flag update to just be flang builds. If there is no 
simple way to limit the scope, then updating the build flags for the clang 
builders is another solution
- I noticed at least one flang builder 
(https://lab.llvm.org/buildbot/#/builders/191/builds/24124) is failing build 
with:

  FAILED: bin/external-hello-world 
  : && /usr/local/bin/c++ -fPIC -fno-semantic-interposition 
-fvisibility-inlines-hidden -Werror=date-time 
-Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter 
-Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic 
-Wno-long-long -Wc++98-compat-extra-semi -Wimplicit-fallthrough 
-Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor 
-Wdelete-non-virtual-dtor -Wsuggest-override -Wstring-conversion 
-Wmisleading-indentation -Wctad-maybe-unsupported -fdiagnostics-color 
-ffunction-sections -fdata-sections -Wno-deprecated-copy -Wno-string-conversion 
-Wno-ctad-maybe-unsupported -Wno-unused-command-line-argument 
-Wstring-conversion           -Wcovered-switch-default -Wno-nested-anon-types 
-O3 -DNDEBUG 
-Wl,-rpath-link,/home/tcwg-buildbot/worker/flang-aarch64-rel-assert/build/./lib 
 -Wl,--gc-sections 
tools/flang/examples/ExternalHelloWorld/CMakeFiles/external-hello-world.dir/external-hello.cpp.o
 -o bin/external-hello-world  -Wl,-rpath,"\$ORIGIN/../lib:"  -lpthread  
-lFortranRuntime && :
  /usr/bin/ld: cannot find -lFortranRuntime

This looks to be a usage of the old FortranRuntime configuration that I 
overlooked and so it wasnt updated. This should be linking flang-rt instead of 
FortranRuntime

Hopefully addressing these small issues will get the buildbots green again, 
sorry for the disruptions.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D154869/new/

https://reviews.llvm.org/D154869

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to