Update rules_foreign_cc
Fixes https://github.com/google/mediapipe/issues/4365 PiperOrigin-RevId: 538301543
This commit is contained in:
parent
d063ed2c1e
commit
4a123445c4
|
@ -45,12 +45,13 @@ http_archive(
|
||||||
)
|
)
|
||||||
|
|
||||||
http_archive(
|
http_archive(
|
||||||
name = "rules_foreign_cc",
|
name = "rules_foreign_cc",
|
||||||
strip_prefix = "rules_foreign_cc-0.1.0",
|
sha256 = "2a4d07cd64b0719b39a7c12218a3e507672b82a97b98c6a89d38565894cf7c51",
|
||||||
url = "https://github.com/bazelbuild/rules_foreign_cc/archive/0.1.0.zip",
|
strip_prefix = "rules_foreign_cc-0.9.0",
|
||||||
|
url = "https://github.com/bazelbuild/rules_foreign_cc/archive/refs/tags/0.9.0.tar.gz",
|
||||||
)
|
)
|
||||||
|
|
||||||
load("@rules_foreign_cc//:workspace_definitions.bzl", "rules_foreign_cc_dependencies")
|
load("@rules_foreign_cc//foreign_cc:repositories.bzl", "rules_foreign_cc_dependencies")
|
||||||
|
|
||||||
rules_foreign_cc_dependencies()
|
rules_foreign_cc_dependencies()
|
||||||
|
|
||||||
|
|
8
third_party/BUILD
vendored
8
third_party/BUILD
vendored
|
@ -13,7 +13,7 @@
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
#
|
#
|
||||||
|
|
||||||
load("@rules_foreign_cc//tools/build_defs:cmake.bzl", "cmake_external")
|
load("@rules_foreign_cc//foreign_cc:cmake.bzl", "cmake")
|
||||||
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
|
load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
|
||||||
|
|
||||||
licenses(["notice"]) # Apache License 2.0
|
licenses(["notice"]) # Apache License 2.0
|
||||||
|
@ -154,7 +154,7 @@ OPENCV_SHARED_LIBS = True
|
||||||
|
|
||||||
OPENCV_SO_VERSION = "3.4"
|
OPENCV_SO_VERSION = "3.4"
|
||||||
|
|
||||||
cmake_external(
|
cmake(
|
||||||
name = "opencv_cmake",
|
name = "opencv_cmake",
|
||||||
# Values to be passed as -Dkey=value on the CMake command line;
|
# Values to be passed as -Dkey=value on the CMake command line;
|
||||||
# here are serving to provide some CMake script configuration options
|
# here are serving to provide some CMake script configuration options
|
||||||
|
@ -230,7 +230,7 @@ cmake_external(
|
||||||
"-lpthread",
|
"-lpthread",
|
||||||
"-lrt",
|
"-lrt",
|
||||||
],
|
],
|
||||||
shared_libraries = select({
|
out_shared_libs = select({
|
||||||
"@bazel_tools//src/conditions:darwin": ["libopencv_%s.%s.dylib" % (module, OPENCV_SO_VERSION) for module in OPENCV_MODULES],
|
"@bazel_tools//src/conditions:darwin": ["libopencv_%s.%s.dylib" % (module, OPENCV_SO_VERSION) for module in OPENCV_MODULES],
|
||||||
# Only the shared objects listed here will be linked in the directory
|
# Only the shared objects listed here will be linked in the directory
|
||||||
# that Bazel adds to the RUNPATH of dependent executables. You cannot
|
# that Bazel adds to the RUNPATH of dependent executables. You cannot
|
||||||
|
@ -238,7 +238,7 @@ cmake_external(
|
||||||
# versioned name is the one that the executables actually reference.
|
# versioned name is the one that the executables actually reference.
|
||||||
"//conditions:default": ["libopencv_%s.so.%s" % (module, OPENCV_SO_VERSION) for module in OPENCV_MODULES],
|
"//conditions:default": ["libopencv_%s.so.%s" % (module, OPENCV_SO_VERSION) for module in OPENCV_MODULES],
|
||||||
}) if OPENCV_SHARED_LIBS else None,
|
}) if OPENCV_SHARED_LIBS else None,
|
||||||
static_libraries = [
|
out_static_libs = [
|
||||||
"libopencv_%s.a" % module
|
"libopencv_%s.a" % module
|
||||||
for module in OPENCV_MODULES
|
for module in OPENCV_MODULES
|
||||||
] if not OPENCV_SHARED_LIBS else None,
|
] if not OPENCV_SHARED_LIBS else None,
|
||||||
|
|
Loading…
Reference in New Issue
Block a user