-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Build gRPC for Firestore C++ #652
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
Merged
Merged
Changes from 8 commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
5e48b19
Clean up quoting and other minor issues
wilhuff 40f4730
Actually parse arguments in the xcodebuild function
wilhuff ee57ee5
Reorganize CMake build output
wilhuff b6e5e80
Use a consistent ordering of ExternalProject arguments
wilhuff a3c68b0
Prevent the top-level build from running in parallel
wilhuff 9178c25
Avoid installing ExternalProjects
wilhuff 9e24e68
Only build the parts of leveldb we need
wilhuff 8327a64
Use ExternalProject features when available
wilhuff 48e7c78
Define an external build for grpc
wilhuff d351703
Add a FindGRPC CMake module
wilhuff 7e4412e
Test that grpc can link successfully.
wilhuff 97b1f09
Actually comment ExternalProjext_GitSource
wilhuff File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
# Copyright 2018 Google | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
include(CMakeParseArguments) | ||
|
||
# Assemble the git-related arguments to an external project in a way that | ||
function(ExternalProject_GitSource RESULT_VAR) | ||
# Parse arguments | ||
set(options "") | ||
set(single_value GIT_REPOSITORY GIT_TAG GIT_PROGRESS GIT_SHALLOW) | ||
set(multi_value GIT_SUBMODULES) | ||
cmake_parse_arguments(EP "${options}" "${single_value}" "${multi_value}" ${ARGN}) | ||
|
||
set( | ||
result | ||
GIT_REPOSITORY ${EP_GIT_REPOSITORY} | ||
GIT_TAG ${EP_GIT_TAG} | ||
${EP_UNPARSED_ARGUMENTS} | ||
) | ||
|
||
# CMake 3.0 added support for constraining the set of submodules to clone | ||
if(NOT (CMAKE_VERSION VERSION_LESS "3.0") AND EP_GIT_SUBMODULES) | ||
list(APPEND result GIT_SUBMODULES ${EP_GIT_SUBMODULES}) | ||
endif() | ||
|
||
# CMake 3.6 added support for shallow git clones. Use a shallow clone if | ||
# available | ||
if(NOT (CMAKE_VERSION VERSION_LESS "3.6")) | ||
if(NOT EP_GIT_SHALLOW) | ||
set(EP_GIT_SHALLOW ON) | ||
endif() | ||
|
||
list(APPEND result GIT_SHALLOW ${EP_GIT_SHALLOW}) | ||
endif() | ||
|
||
# CMake 3.8 added support for showing progress for large downloads | ||
if(NOT (CMAKE_VERSION VERSION_LESS "3.8")) | ||
if(NOT EP_GIT_PROGRESS) | ||
set(EP_GIT_PROGRESS ON) | ||
endif() | ||
|
||
list(APPEND result GIT_PROGRESS ${EP_GIT_PROGRESS}) | ||
endif() | ||
|
||
set(${RESULT_VAR} ${result} PARENT_SCOPE) | ||
|
||
endfunction() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: complete the sentence?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apologies. Now fully commented.