blob: ea327d7bd48358a5e7a0eeb38b54d156a15d41cc [file] [log] [blame]
Jon Brandvein522222a2019-07-26 23:35:39 -04001# Copyright 2019 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
Jon Brandvein522222a2019-07-26 23:35:39 -040015load("//python:defs.bzl", "py_library")
Alex Eagle17229882023-01-21 11:16:41 -080016load("//python:packaging.bzl", "py_wheel")
Jon Brandvein522222a2019-07-26 23:35:39 -040017
aiutoe953b0a2019-10-04 16:29:41 -040018filegroup(
19 name = "distribution",
20 srcs = glob(["**"]),
21 visibility = ["//python:__pkg__"],
22)
23
Jon Brandvein522222a2019-07-26 23:35:39 -040024py_library(
25 name = "runfiles",
Alex Eagle17229882023-01-21 11:16:41 -080026 srcs = [
27 "__init__.py",
28 "runfiles.py",
29 ],
Jon Brandvein522222a2019-07-26 23:35:39 -040030 visibility = ["//visibility:public"],
31)
Alex Eagle17229882023-01-21 11:16:41 -080032
33# This can be manually tested by running tests/runfiles/runfiles_wheel_integration_test.sh
34# We ought to have an automated integration test for it, too.
35# see https://github.com/bazelbuild/rules_python/issues/1002
36py_wheel(
37 name = "wheel",
38 # From https://pypi.org/classifiers/
39 classifiers = [
40 "Development Status :: 5 - Production/Stable",
41 "License :: OSI Approved :: Apache Software License",
42 ],
43 description_file = "README.md",
Alex Eagle68b02132023-01-26 15:14:05 -080044 dist_folder = "dist",
Alex Eagle17229882023-01-21 11:16:41 -080045 distribution = "bazel_runfiles",
46 homepage = "https://github.com/bazelbuild/rules_python",
47 strip_path_prefixes = ["python"],
48 version = "{BUILD_EMBED_LABEL}",
49 visibility = ["//visibility:public"],
50 deps = [":runfiles"],
51)