|
1 | | -# Copyright 2024 The Bazel Authors. All rights reserved. |
2 | | -# |
3 | | -# Licensed under the Apache License, Version 2.0 (the "License"); |
4 | | -# you may not use this file except in compliance with the License. |
5 | | -# You may obtain a copy of the License at |
6 | | -# |
7 | | -# http://www.apache.org/licenses/LICENSE-2.0 |
8 | | -# |
9 | | -# Unless required by applicable law or agreed to in writing, software |
10 | | -# distributed under the License is distributed on an "AS IS" BASIS, |
11 | | -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
12 | | -# See the License for the specific language governing permissions and |
13 | | -# limitations under the License. |
14 | | - |
15 | | -# This file contains everything that is needed when using bzlmod |
16 | | -workspace(name = "rules_python") |
17 | | - |
18 | | -load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive", "http_file") |
19 | | - |
20 | | -# Used for Bazel CI |
21 | | -http_archive( |
22 | | - name = "bazelci_rules", |
23 | | - sha256 = "eca21884e6f66a88c358e580fd67a6b148d30ab57b1680f62a96c00f9bc6a07e", |
24 | | - strip_prefix = "bazelci_rules-1.0.0", |
25 | | - url = "https://github.com/bazelbuild/continuous-integration/releases/download/rules-1.0.0/bazelci_rules-1.0.0.tar.gz", |
26 | | -) |
27 | | - |
28 | | -load("@bazelci_rules//:rbe_repo.bzl", "rbe_preconfig") |
29 | | - |
30 | | -# Creates a default toolchain config for RBE. |
31 | | -# Use this as is if you are using the rbe_ubuntu16_04 container, |
32 | | -# otherwise refer to RBE docs. |
33 | | -rbe_preconfig( |
34 | | - name = "buildkite_config", |
35 | | - toolchain = "ubuntu1804-bazel-java11", |
36 | | -) |
37 | | - |
38 | | -# Add gazelle plugin so that we can run the gazelle example as an e2e integration |
39 | | -# test and include the distribution files. |
40 | | -local_repository( |
41 | | - name = "rules_python_gazelle_plugin", |
42 | | - path = "gazelle", |
43 | | -) |
44 | | - |
45 | | -##################### |
46 | | - |
47 | | -# This wheel is purely here to validate the wheel extraction code. It's not |
48 | | -# intended for anything else. |
49 | | -http_file( |
50 | | - name = "wheel_for_testing", |
51 | | - downloaded_file_path = "numpy-1.25.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", |
52 | | - sha256 = "0d60fbae8e0019865fc4784745814cff1c421df5afee233db6d88ab4f14655a2", |
53 | | - urls = [ |
54 | | - "https://files.pythonhosted.org/packages/50/67/3e966d99a07d60a21a21d7ec016e9e4c2642a86fea251ec68677daf71d4d/numpy-1.25.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", |
55 | | - ], |
56 | | -) |
57 | | - |
58 | | -# rules_proto expects //external:python_headers to point at the python headers. |
59 | | -bind( |
60 | | - name = "python_headers", |
61 | | - actual = "//python/cc:current_py_cc_headers", |
62 | | -) |
0 commit comments