Coming back to this thread after a while:

The issue you ran into is actually that you tried to install grpc 
dependencies from submodules (
https://github.com/grpc/grpc/blob/364461aab0a352c43ed93f77a18907f95be709dc/templates/CMakeLists.txt.template#L172
)
and build you ran actually printed a warning that said your cmake version 
is too old for what you're trying to do: 
https://github.com/grpc/grpc/blob/3e2513c31a4417630f2b3519b4125c7e15152dc4/cmake/ssl.cmake#L58

Installing dependencies in "module" mode is documented here: 
https://github.com/grpc/grpc/blob/master/BUILDING.md#install-after-build

I'll look at the C++ quickstart instructions 
https://grpc.io/docs/languages/cpp/quickstart/ and see if they can be 
improved.

On Monday, May 4, 2020 at 7:12:43 PM UTC+2 Patrice Chalin wrote:

> On Mon, May 4, 2020 at 8:53 AM John Leidel <[email protected]> wrote:
>
>> ... That being said, it would be preferred to have the gRPC build throw 
>> an error for incompatible CMake versions.
>>
>
> I agree.
>  
>
>>
>> On Mon, May 4, 2020 at 7:46 AM Jan Tattermusch <[email protected]> 
>> wrote:
>>
>>> The problem with that is that cmake 3.13 is not available by default in 
>>> many popular linux distributions.
>>>
>>> e.g.
>>> - debian stable has https://packages.debian.org/buster/cmake 3.13
>>> - ubuntu18.04 only has cmake 3.10
>>> - ubuntu16.04 only has cmake 3.5.1
>>>
>>> On linux it's pretty painful to use a cmake version that's not 
>>> installable by the package manager.
>>>
>>>
>>> On Mon, Apr 27, 2020 at 8:55 PM Patrice Chalin <[email protected]> wrote:
>>>
>>>> +Jan Tattermusch, Eric and I discussed the following during our Docs 
>>>> WG meeting: to avoid users facing this problem again, how about if we 
>>>> changed the min version of cmake from the current 3.5.1 to, say, 3.13
>>>>
>>>> cmake_minimum_required(VERSION 3.13)
>>>>
>>>>
>>>> in either the C++ hello world cmake config:
>>>>
>>>>    - 
>>>>    
>>>> https://github.com/grpc/grpc/blob/master/examples/cpp/helloworld/CMakeLists.txt#L20
>>>>    
>>>> and/or to the (top-level) grpc cmake config?
>>>>
>>>>    - https://github.com/grpc/grpc/blob/master/CMakeLists.txt#L25
>>>>    
>>>> (and maybe the other C++ examples too?)
>>>>
>>>> cc +Eric Anderson 
>>>>
>>>>
>>>> On Wed, Apr 22, 2020 at 11:38 AM John Leidel <[email protected]> 
>>>> wrote:
>>>>
>>>>> Patrice, I updated CMake to something newer within range and the
>>>>> build+install appears to work.  I have some other issues to get ironed
>>>>> out in order to sync our external packages with the updated Cmake
>>>>> scripts, but I suspect this was the major issue.  Thanks for the help!
>>>>>
>>>>> best
>>>>> john
>>>>>
>>>>> On Wed, Apr 22, 2020 at 10:22 AM John Leidel <[email protected]> 
>>>>> wrote:
>>>>> >
>>>>> > Patrice, thanks for the quick response.  I was, in fact, using the
>>>>> > updated C++ Quick Start directions.  However, I did find that my 
>>>>> CMake
>>>>> > version was slightly out of date (3.10.X).  I'm updating CMake and
>>>>> > will report back as soon as I can get a clean build.
>>>>> >
>>>>> > On Wed, Apr 22, 2020 at 10:08 AM Patrice Chalin <[email protected]> 
>>>>> wrote:
>>>>> > >
>>>>> > > Hi John,
>>>>> > >
>>>>> > > I recently updated the C++ Quick Start, which now describes how to 
>>>>> "build and locally install gRPC before building and running this quick 
>>>>> start’s Hello World example." I've tested the instructions on Ubuntu 
>>>>> 18.04 
>>>>> LTS and haven't had any issues. Maybe you can give those instructions a 
>>>>> try? (Which version of cmake are you using? You'll need 3.13+.)
>>>>> > >
>>>>> > > Best,
>>>>> > > Patrice
>>>>> > >
>>>>> > > On Wednesday, April 22, 2020 at 11:00:01 AM UTC-4, John Leidel 
>>>>> wrote:
>>>>> > >>
>>>>> > >> All, its been quite some time since I last built+installed gRPC 
>>>>> from source.  I'm attempting to build+install on Ubuntu 18.04 LTS from 
>>>>> source and I can't seem to get the libgrpc++* libraries to install.  I'm 
>>>>> following the directions on the gRPC building guide, but regardless of 
>>>>> the 
>>>>> version/options I choose, the build refuses to install the necessary 
>>>>> libraries.  So far, I've tried the current master branch (HEAD), v1.28.1, 
>>>>> v.1.27.2, v.1.25.0 and they all fail.
>>>>> > >>
>>>>> > >> Build method:
>>>>> > >> $> git clone --recurse-submodules -b v1.28.1 
>>>>> https://github.com/grpc/grpc
>>>>> > >> $> cd grpc
>>>>> > >> $> mkdir -p cmake/build
>>>>> > >> $> cd cmake/build
>>>>> > >> $> cmake -DCMAKE_INSTALL_PREFIX=/home/user/grpc -DgRPC_INSTALL=ON 
>>>>> ../../
>>>>> > >> $> make -j
>>>>> > >> $> make install
>>>>> > >>
>>>>> > >> ....where `/home/user/grpc` is a directory within my home 
>>>>> directory.   I see the following libs installed:
>>>>> > >> libcares.a  libprotobuf.a  libprotobuf-lite.a  libprotoc.a  
>>>>> libz.a  libz.so
>>>>> > >>
>>>>> > >> libgrpc++.a (and its other variants) are built via cmake, but 
>>>>> they're not installed.  As an aside, I also tried manually enabling the 
>>>>> CPP 
>>>>> plugin in the cmake build, but it delivers the same results.
>>>>> > >>
>>>>> > >> I've also tried building the helloworld test from within the 
>>>>> source tree as directed by the instructions on Github.  It fails to find 
>>>>> a 
>>>>> cmake dependency from the install:
>>>>> > >> CMake Error at /home/user/grpc/lib/cmake/grpc/gRPCConfig.cmake:12 
>>>>> (include):
>>>>> > >>   include could not find load file:
>>>>> > >>
>>>>> > >>     /home/user/grpc/lib/cmake/grpc/gRPCTargets.cmake
>>>>> > >> Call Stack (most recent call first):
>>>>> > >>   CMakeLists.txt:116 (find_package)
>>>>> > >>
>>>>> > >>
>>>>> > >> Any thoughts?
>>>>> > >
>>>>> > > --
>>>>> > > You received this message because you are subscribed to the Google 
>>>>> Groups "grpc.io" group.
>>>>> > > To unsubscribe from this group and stop receiving emails from it, 
>>>>> send an email to [email protected].
>>>>> > > To view this discussion on the web visit 
>>>>> https://groups.google.com/d/msgid/grpc-io/c002f687-423f-4e03-83ad-c6b11f806647%40googlegroups.com
>>>>> .
>>>>>
>>>>
>>>
>>> -- 
>>>
>>> Jan Tattermusch
>>>
>>> Software Engineer
>>>
>>>
>>> Google Germany GmbH
>>>
>>> Erika-Mann-Straße 33
>>>
>>> 80636 München
>>>
>>> Geschäftsführer: Paul Manicle, Halimah DeLaine Prado
>>>
>>> Registergericht und -nummer: Hamburg, HRB 86891
>>>
>>> Sitz der Gesellschaft: Hamburg
>>>
>>> Diese E-Mail ist vertraulich. Falls sie diese fälschlicherweise erhalten 
>>> haben sollten, leiten Sie diese bitte nicht an jemand anderes weiter, 
>>> löschen Sie alle Kopien und Anhänge davon und lassen Sie mich bitte wissen, 
>>> dass die E-Mail an die falsche Person gesendet wurde. 
>>>
>>>     
>>>
>>> This e-mail is confidential. If you received this communication by 
>>> mistake, please don't forward it to anyone else, please erase all copies 
>>> and attachments, and please let me know that it has gone to the wrong 
>>> person.
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"grpc.io" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/grpc-io/580de5a7-5463-4cad-9c30-66234a66c7b3n%40googlegroups.com.

Reply via email to