libquic icon indicating copy to clipboard operation
libquic copied to clipboard

cmake got "Could not found Go" error

Open psionic12 opened this issue 8 years ago • 5 comments

here's the log:

~/source/libquic/build$ cmake .. -- The C compiler identification is GNU 5.4.0 -- The CXX compiler identification is GNU 5.4.0 -- Check for working C compiler: /usr/bin/cc -- Check for working C compiler: /usr/bin/cc -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Detecting C compile features -- Detecting C compile features - done -- Check for working CXX compiler: /usr/bin/c++ -- Check for working CXX compiler: /usr/bin/c++ -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done -- Setting build type to 'Debug' as none was specified. -- Looking for pthread.h -- Looking for pthread.h - found -- Looking for pthread_create -- Looking for pthread_create - not found -- Looking for pthread_create in pthreads -- Looking for pthread_create in pthreads - not found -- Looking for pthread_create in pthread -- Looking for pthread_create in pthread - found -- Found Threads: TRUE
-- Found Protobuf: /usr/local/lib/libprotobuf.so (Required is at least version "3") -- Found Perl: /usr/bin/perl (found version "5.22.1") CMake Error at boringssl/CMakeLists.txt:26 (message): Could not find Go

-- Configuring incomplete, errors occurred! See also "/home/liuyafei/source/libquic/build/CMakeFiles/CMakeOutput.log". See also "/home/liuyafei/source/libquic/build/CMakeFiles/CMakeError.log".

psionic12 avatar Aug 08 '17 14:08 psionic12

I'v found the solution in https://github.com/devsisters/libquic/issues/8, sorry for creating this issue

psionic12 avatar Aug 08 '17 14:08 psionic12

I've met the same error. The solution works. But I'd like to know why we should have a Golang executable. Thank you for your response!

Inokinoki avatar Nov 09 '18 17:11 Inokinoki

I've met the same error. The solution works. But I'd like to know why we should have a Golang executable. Thank you for your response!

with the same question, I try

# cd into libquic
$find . -name '*.go'

and find out that lots of test file belongs libquic/boringssl use golang.

./boringssl/crypto/cipher/test/make_legacy_aead_tests.go
./boringssl/crypto/err/err_data_generate.go
./boringssl/ssl/test/runner/alert.go
./boringssl/ssl/test/runner/chacha20_poly1305.go
./boringssl/ssl/test/runner/chacha20_poly1305_test.go
...
...

and look inside libquic/boringssl/CMakeLists.txt, it will run these test file which written by golang.

q191201771 avatar Mar 29 '19 04:03 q191201771

So can we disable the tests to build without go?

TomMD avatar Aug 17 '20 19:08 TomMD

@TomMD Yeah this seems wrong...

There is a "hard" dependency on go but there is no reason for it actually, after you generate the err_data.c you can skip test compilation for boringssl and there's zero dep after that on go. Really those files should be committed, or better yet convert the go script to a c program, then there's no weird dependency.

The usage of go is google fan-boy-ism at best, excessive pandering at worst.

smaudet avatar Oct 19 '20 14:10 smaudet