mirror of
https://github.com/google/sandboxed-api.git
synced 2024-03-22 13:11:30 +08:00
Internal change
PiperOrigin-RevId: 251624033 Change-Id: I9b2ab423082be3bfdb6da66ab7a8e77e5673789b
This commit is contained in:
parent
ffd4e1270a
commit
e09bda2628
|
@ -26,6 +26,7 @@ list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
|
||||||
list(APPEND CMAKE_PREFIX_PATH
|
list(APPEND CMAKE_PREFIX_PATH
|
||||||
"${PROJECT_BINARY_DIR}/Dependencies/Build/gflags"
|
"${PROJECT_BINARY_DIR}/Dependencies/Build/gflags"
|
||||||
"${PROJECT_BINARY_DIR}/Dependencies/Build/glog"
|
"${PROJECT_BINARY_DIR}/Dependencies/Build/glog"
|
||||||
|
"${PROJECT_BINARY_DIR}/Dependencies/Build/protobuf"
|
||||||
)
|
)
|
||||||
|
|
||||||
include(SapiCompilerOptions)
|
include(SapiCompilerOptions)
|
||||||
|
@ -85,6 +86,7 @@ add_library(sapi::base ALIAS sapi_base)
|
||||||
target_include_directories(sapi_base INTERFACE
|
target_include_directories(sapi_base INTERFACE
|
||||||
${PROJECT_BINARY_DIR}
|
${PROJECT_BINARY_DIR}
|
||||||
${PROJECT_SOURCE_DIR}
|
${PROJECT_SOURCE_DIR}
|
||||||
|
${Protobuf_INCLUDE_DIR}
|
||||||
# Need to reach into Abseil internal headers from a few targets.
|
# Need to reach into Abseil internal headers from a few targets.
|
||||||
${PROJECT_BINARY_DIR}/Dependencies/Source/absl
|
${PROJECT_BINARY_DIR}/Dependencies/Source/absl
|
||||||
)
|
)
|
||||||
|
|
17
WORKSPACE
17
WORKSPACE
|
@ -17,6 +17,13 @@ workspace(name = "com_google_sandboxed_api")
|
||||||
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
|
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
|
||||||
load("//sandboxed_api/bazel:repositories.bzl", "autotools_repository")
|
load("//sandboxed_api/bazel:repositories.bzl", "autotools_repository")
|
||||||
|
|
||||||
|
# Bazel Skylib, needed by newer Protobuf builds
|
||||||
|
http_archive(
|
||||||
|
name = "bazel_skylib",
|
||||||
|
sha256 = "2ef429f5d7ce7111263289644d233707dba35e39696377ebab8b0bc701f7818e",
|
||||||
|
url = "https://github.com/bazelbuild/bazel-skylib/releases/download/0.8.0/bazel-skylib.0.8.0.tar.gz", # 2019-03-20
|
||||||
|
)
|
||||||
|
|
||||||
# Abseil
|
# Abseil
|
||||||
http_archive(
|
http_archive(
|
||||||
name = "com_google_absl",
|
name = "com_google_absl",
|
||||||
|
@ -106,11 +113,15 @@ http_archive(
|
||||||
# Protobuf
|
# Protobuf
|
||||||
http_archive(
|
http_archive(
|
||||||
name = "com_google_protobuf",
|
name = "com_google_protobuf",
|
||||||
sha256 = "9510dd2afc29e7245e9e884336f848c8a6600a14ae726adb6befdb4f786f0be2",
|
sha256 = "1e622ce4b84b88b6d2cdf1db38d1a634fe2392d74f0b7b74ff98f3a51838ee53",
|
||||||
strip_prefix = "protobuf-3.6.1.3",
|
strip_prefix = "protobuf-3.8.0",
|
||||||
urls = ["https://github.com/protocolbuffers/protobuf/archive/v3.6.1.3.zip"],
|
urls = ["https://github.com/protocolbuffers/protobuf/archive/v3.8.0.zip"],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
load("@com_google_protobuf//:protobuf_deps.bzl", "protobuf_deps")
|
||||||
|
|
||||||
|
protobuf_deps()
|
||||||
|
|
||||||
# libcap
|
# libcap
|
||||||
http_archive(
|
http_archive(
|
||||||
name = "org_kernel_libcap",
|
name = "org_kernel_libcap",
|
||||||
|
|
|
@ -61,6 +61,20 @@ ExternalProject_Add(libunwind
|
||||||
)
|
)
|
||||||
list(APPEND DEPENDENCIES libunwind)
|
list(APPEND DEPENDENCIES libunwind)
|
||||||
|
|
||||||
|
ExternalProject_Add(protobuf
|
||||||
|
GIT_REPOSITORY https://github.com/protocolbuffers/protobuf.git
|
||||||
|
GIT_TAG e08f01ce6a78a6cf2834dfa37281eb366eb0c5c3 # 2019-06-05
|
||||||
|
PREFIX ${CMAKE_CURRENT_BINARY_DIR}/Dependencies/Build/protobuf
|
||||||
|
SOURCE_SUBDIR cmake
|
||||||
|
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
|
||||||
|
-DCMAKE_BUILD_TYPE=@CMAKE_BUILD_TYPE@
|
||||||
|
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
|
||||||
|
-Dprotobuf_BUILD_TESTS=OFF
|
||||||
|
-Dprotobuf_BUILD_SHARED_LIBS=OFF
|
||||||
|
-Dprotobuf_WITH_ZLIB=OFF
|
||||||
|
)
|
||||||
|
list(APPEND DEPENDENCIES protobuf)
|
||||||
|
|
||||||
ExternalProject_Add(sandboxed_api
|
ExternalProject_Add(sandboxed_api
|
||||||
DEPENDS ${DEPENDENCIES}
|
DEPENDS ${DEPENDENCIES}
|
||||||
SOURCE_DIR ${PROJECT_SOURCE_DIR}
|
SOURCE_DIR ${PROJECT_SOURCE_DIR}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user