Import bazelbuild/platforms from GitHub.

- e51978ee25 initial checkin by Tony Aiuto <aiuto@google.com>
  - d91995f1a9 Add CONTRIBUTING.md by Tony Aiuto <aiuto@google.com>

GIT_ORIGIN_REV_ID=d91995f1a9497602a02d11db41a7ffa5551147be

RELNOTES: None.
PiperOrigin-RevId: 251811887
Change-Id: Iadfdbbc9d013343e495067ebf51b1e0ea59e0fe6
This commit is contained in:
Googler 2019-06-06 11:18:26 +02:00 committed by Marcel Hlopko
parent 55fc545818
commit cab94988cf
5 changed files with 99 additions and 13 deletions

1
CODEOWNERS Normal file
View File

@ -0,0 +1 @@
@aiuto @aragos @gregestren @katre

View File

@ -1,12 +1,9 @@
# How to Contribute
We'd love to accept your patches and contributions to this project. There are
just a few small guidelines you need to follow.
# Contributing to Bazel
## Contributor License Agreement
Contributions to this project must be accompanied by a Contributor License
Agreement. You (or your employer) retain the copyright to your contribution;
Agreement. You (or your employer) retain the copyright to your contribution,
this simply gives us permission to use and redistribute your contributions as
part of the project. Head over to <https://cla.developers.google.com/> to see
your current agreements on file or to sign a new one.
@ -15,14 +12,13 @@ You generally only need to submit a CLA once, so if you've already submitted one
(even if it was for a different project), you probably don't need to do it
again.
## Code reviews
## Patch Acceptance Process
All submissions, including submissions by project members, require review. We
use GitHub pull requests for this purpose. Consult
[GitHub Help](https://help.github.com/articles/about-pull-requests/) for more
information on using pull requests.
The process is described in the [README for this repository](README.md). For
background, you should also understand how to
[contribute to Bazel](https://bazel.build/contributing.html).
## Community Guidelines
## Setting up your development environment
This project follows
[Google's Open Source Community Guidelines](https://opensource.google.com/conduct/).
Read how to
[set up your development environment](https://bazel.build/contributing.html).

1
WORKSPACE Normal file
View File

@ -0,0 +1 @@
workspace(name = "platforms")

44
cpu/BUILD Normal file
View File

@ -0,0 +1,44 @@
# Standard cpu name constraint_setting and constraint_values
licenses(["notice"])
package(
default_visibility = ["//visibility:public"],
)
filegroup(
name = "srcs",
srcs = glob(["**"]),
)
# These match values in https://github.com/bazelbuild/bazel/blob/master/src/main/java/com/google/devtools/build/lib/util/CPU.java
constraint_setting(name = "cpu")
constraint_value(
name = "x86_32",
constraint_setting = ":cpu",
)
constraint_value(
name = "x86_64",
constraint_setting = ":cpu",
)
constraint_value(
name = "ppc",
constraint_setting = ":cpu",
)
constraint_value(
name = "arm",
constraint_setting = ":cpu",
)
constraint_value(
name = "aarch64",
constraint_setting = ":cpu",
)
constraint_value(
name = "s390x",
constraint_setting = ":cpu",
)

44
os/BUILD Normal file
View File

@ -0,0 +1,44 @@
# Standard constraint_setting and constraint_values to be used in platforms.
licenses(["notice"])
package(
default_visibility = ["//visibility:public"],
)
filegroup(
name = "srcs",
srcs = glob(["**"]),
)
# These match values in https://github.com/bazelbuild/bazel/blob/master/src/main/java/com/google/devtools/build/lib/util/OS.java
constraint_setting(name = "os")
constraint_value(
name = "osx",
constraint_setting = ":os",
)
constraint_value(
name = "ios",
constraint_setting = ":os",
)
constraint_value(
name = "freebsd",
constraint_setting = ":os",
)
constraint_value(
name = "android",
constraint_setting = ":os",
)
constraint_value(
name = "linux",
constraint_setting = ":os",
)
constraint_value(
name = "windows",
constraint_setting = ":os",
)