-
Notifications
You must be signed in to change notification settings - Fork 10.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cmake compilation issue #7233
Comments
Ping @tberghammer |
I had a similar problem (cannot find gmock directory) while attempting to compile third_party/protobuf https://github.com/grpc/grpc/blob/master/vsprojects/README.md via CMake, on Windows. |
A full build of protobuf depends on gmock even though it is not part of a standrad checkout. This CL explicitly disable the build of the protobuf tests to get rid of this dependency. If somebody want to build the protobuf tests then they have to download gmock to the protobuf directory and specify -Dprotobuf_BUILD_TESTS=ON to the cmake command line. Fixes grpc#7233
I created a pull request for fixing this issue (#7235). Until it is merged there are a few possible workaround (any of them should work):
|
Thanks, I will try it with your workaround OR by manually merging your patch. |
A full build of protobuf depends on gmock even though it is not part of a standrad checkout. This CL explicitly disable the build of the protobuf tests to get rid of this dependency. If somebody want to build the protobuf tests then they have to download gmock to the protobuf directory and specify -Dprotobuf_BUILD_TESTS=ON to the cmake command line. Fixes grpc#7233
Hi,
I tried to build grpc using cmake and got the following error.
Why don't we build gmock from third_party/googletest?
I attached log files, so PTAL.
$ cmake ..
-- The C compiler identification is GNU 4.8.4
-- The CXX compiler identification is GNU 4.8.4
-- 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
-- Found Perl: /usr/bin/perl (found version "5.18.2")
-- The ASM compiler identification is GNU
-- Found assembler: /usr/bin/cc
-- 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 ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.8")
CMake Error at third_party/protobuf/cmake/tests.cmake:2 (message):
Cannot find gmock directory.
Call Stack (most recent call first):
third_party/protobuf/cmake/CMakeLists.txt:150 (include)
-- Configuring incomplete, errors occurred!
See also "/home/seoz/grpc/build/CMakeFiles/CMakeOutput.log".
See also "/home/seoz/grpc/build/CMakeFiles/CMakeError.log".
CMakeError.log.txt
CMakeOutput.log.txt
Thanks,
Daniel
The text was updated successfully, but these errors were encountered: