This repository has been archived by the owner on Jul 19, 2021. It is now read-only.
forked from stackb/rules_proto
-
Notifications
You must be signed in to change notification settings - Fork 0
/
deps.bzl
103 lines (93 loc) · 3.06 KB
/
deps.bzl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
load(
"//:deps.bzl",
"io_bazel_rules_dart",
"io_bazel_rules_go",
)
load(
"//protobuf:deps.bzl",
"protobuf",
)
# Special dart_sdk_repository
load("//dart:sdk.bzl", "dart_sdk_repository")
load("//dart:dart_pub_deps.bzl", "dart_pub_deps")
def dart_sdk(**kwargs):
"""The dart sdk
"""
name = "dart_sdk"
if name not in native.existing_rules():
dart_sdk_repository(
name = name,
)
def dart_pub_deps_protoc_plugin(**kwargs):
"""Dart pub dependencies for the dart protoc plugin
"""
name = "dart_pub_deps_protoc_plugin"
if name not in native.existing_rules():
dart_pub_deps(
name = name,
spec = str(Label("//dart:pubspec.yaml")),
# these overrides were determined by manually browsing
# pub.dartlang.org, starting at protoc_plugin and going through all
# transitive dependencies, pinning them to the version specified
override = {
"dart_style": "1.2.7",
"analyzer": "0.36.1",
"args": "1.5.1",
"charcode": "1.1.2",
"collection": "1.14.11",
"convert": "2.1.1",
"typed_data": "1.1.6",
"crypto": "2.0.6",
"front_end": "0.1.16",
"kernel": "0.3.16",
"package_config": "1.0.5",
"path": "1.6.2",
"yaml": "2.1.15",
"source_span": "1.5.5",
"term_glyph": "1.1.0",
"string_scanner": "1.0.4",
"meta": "1.1.7",
"glob": "1.1.7",
"async": "2.2.0",
"html": "0.14.0+1",
"csslib": "0.15.0",
"pub_semver": "1.4.2",
"watcher": "0.9.7+10",
"fixnum": "0.10.9",
"protobuf": "0.13.11",
},
)
def dart_pub_deps_grpc(**kwargs):
"""Dart pub dependencies for grpc
"""
name = "dart_pub_deps_grpc"
if name not in native.existing_rules():
dart_pub_deps(
name = name,
spec = str(Label("//dart:pubspec-grpc.yaml")),
# these overrides were determined by manually browsing
# pub.dartlang.org, starting at grpc and going through all
# transitive dependencies, pinning them to the version specified
# there
override = {
"async": "2.2.0",
"googlapis_auth": "0.2.7",
"http": "0.12.0+2",
"http_parser": "3.1.3",
"pedantic": "1.5.0",
},
)
def dart_proto_compile(**kwargs):
protobuf(**kwargs)
io_bazel_rules_go(**kwargs)
io_bazel_rules_dart(**kwargs)
dart_sdk(**kwargs)
dart_pub_deps_protoc_plugin(**kwargs)
def dart_grpc_compile(**kwargs):
dart_proto_compile(**kwargs)
def dart_proto_library(**kwargs):
dart_proto_compile(**kwargs)
def dart_grpc_library(**kwargs):
dart_grpc_compile(**kwargs)
dart_proto_library(**kwargs)
dart_pub_deps_grpc(**kwargs)