bazel: Update rules_
This commit is contained in:
11
WORKSPACE
11
WORKSPACE
@@ -33,6 +33,12 @@ git_repository(
|
||||
remote = "https://github.com/bazelbuild/platforms.git",
|
||||
)
|
||||
|
||||
git_repository(
|
||||
name = "rules_proto",
|
||||
tag = "5.3.0-21.7",
|
||||
remote = "https://github.com/bazelbuild/rules_proto.git",
|
||||
)
|
||||
|
||||
# ZLIB
|
||||
new_git_repository(
|
||||
name = "zlib",
|
||||
@@ -135,10 +141,13 @@ new_git_repository(
|
||||
## Bazel Python rules.
|
||||
git_repository(
|
||||
name = "rules_python",
|
||||
tag = "0.16.2",
|
||||
tag = "0.20.0",
|
||||
remote = "https://github.com/bazelbuild/rules_python.git",
|
||||
)
|
||||
|
||||
load("@rules_python//python:repositories.bzl", "py_repositories")
|
||||
py_repositories()
|
||||
|
||||
# Create a central external repo, @ortools_deps, that contains Bazel targets for all the
|
||||
# third-party packages specified in the python_deps.txt file.
|
||||
load("@rules_python//python:pip.bzl", "pip_parse")
|
||||
|
||||
@@ -11,9 +11,10 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
load("@rules_cc//cc:defs.bzl", "cc_proto_library")
|
||||
load("@rules_cc//cc:defs.bzl", "cc_library", "cc_proto_library")
|
||||
load("@rules_proto//proto:defs.bzl", "proto_library")
|
||||
load("@rules_python//python:proto.bzl", "py_proto_library")
|
||||
load("@bazel_skylib//rules:copy_file.bzl", "copy_file")
|
||||
load("@com_google_protobuf//:protobuf.bzl", "py_proto_library")
|
||||
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
@@ -57,9 +58,8 @@ cc_proto_library(
|
||||
|
||||
py_proto_library(
|
||||
name = "linear_solver_py_pb2",
|
||||
srcs = ["linear_solver.proto"],
|
||||
deps = [":linear_solver_proto"],
|
||||
visibility = ["//visibility:public"],
|
||||
deps = ["//ortools/util:optional_boolean_py_pb2"],
|
||||
)
|
||||
|
||||
# You can include the interfaces to different solvers by invoking '--define'
|
||||
@@ -153,7 +153,7 @@ cc_library(
|
||||
"//ortools/util:fp_utils",
|
||||
"//ortools/util:lazy_mutable_copy",
|
||||
] + select({
|
||||
":with_glpk": ["@glpk//:glpk",
|
||||
":with_glpk": ["@glpk//:glpk",
|
||||
"//ortools/glpk:glpk_env_deleter"],
|
||||
"//conditions:default": [],
|
||||
}),
|
||||
|
||||
@@ -14,8 +14,9 @@
|
||||
# Home of CP/SAT solver (which includes SAT, max-SAT and PB problems).
|
||||
#
|
||||
|
||||
load("@rules_cc//cc:defs.bzl", "cc_proto_library")
|
||||
load("@com_google_protobuf//:protobuf.bzl", "py_proto_library")
|
||||
load("@rules_cc//cc:defs.bzl", "cc_library", "cc_proto_library")
|
||||
load("@rules_proto//proto:defs.bzl", "proto_library")
|
||||
load("@rules_python//python:proto.bzl", "py_proto_library")
|
||||
load("@rules_java//java:defs.bzl", "java_proto_library")
|
||||
|
||||
package(
|
||||
@@ -34,8 +35,8 @@ cc_proto_library(
|
||||
|
||||
py_proto_library(
|
||||
name = "sat_parameters_py_pb2",
|
||||
srcs = ["sat_parameters.proto"],
|
||||
visibility = ["//visibility:public"],
|
||||
deps = [":sat_parameters_proto"],
|
||||
)
|
||||
|
||||
java_proto_library(
|
||||
@@ -66,8 +67,8 @@ cc_proto_library(
|
||||
|
||||
py_proto_library(
|
||||
name = "cp_model_py_pb2",
|
||||
srcs = ["cp_model.proto"],
|
||||
visibility = ["//visibility:public"],
|
||||
deps = [":cp_model_proto"],
|
||||
)
|
||||
|
||||
java_proto_library(
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
# limitations under the License.
|
||||
|
||||
load("@rules_cc//cc:defs.bzl", "cc_proto_library")
|
||||
load("@com_google_protobuf//:protobuf.bzl", "py_proto_library")
|
||||
load("@rules_python//python:proto.bzl", "py_proto_library")
|
||||
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
@@ -339,8 +339,8 @@ cc_proto_library(
|
||||
|
||||
py_proto_library(
|
||||
name = "optional_boolean_py_pb2",
|
||||
srcs = ["optional_boolean.proto"],
|
||||
visibility = ["//visibility:public"],
|
||||
deps = [":optional_boolean_proto"],
|
||||
)
|
||||
|
||||
cc_library(
|
||||
|
||||
Reference in New Issue
Block a user