Apply licenses with rules_license
This commit is contained in:
12
BUILD.bazel
12
BUILD.bazel
@ -2,11 +2,15 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
load("@hedron_compile_commands//:refresh_compile_commands.bzl", "refresh_compile_commands")
|
load("@rules_license//rules:license.bzl", "license")
|
||||||
|
|
||||||
refresh_compile_commands(
|
license(
|
||||||
name = "refresh_clangd",
|
name = "license",
|
||||||
targets = "//...",
|
license_kinds = [
|
||||||
|
"@rules_license//licenses/spdx:BSD-3-Clause",
|
||||||
|
],
|
||||||
|
license_text = "LICENSE.txt",
|
||||||
|
package_name = "ASL",
|
||||||
)
|
)
|
||||||
|
|
||||||
platform(
|
platform(
|
||||||
|
@ -6,6 +6,7 @@ module(name = "asl")
|
|||||||
|
|
||||||
bazel_dep(name = "platforms", version = "0.0.10")
|
bazel_dep(name = "platforms", version = "0.0.10")
|
||||||
bazel_dep(name = "rules_cc", version = "0.0.17")
|
bazel_dep(name = "rules_cc", version = "0.0.17")
|
||||||
|
bazel_dep(name = "rules_license", version = "1.0.0")
|
||||||
|
|
||||||
bazel_dep(name = "hedron_compile_commands", dev_dependency = True)
|
bazel_dep(name = "hedron_compile_commands", dev_dependency = True)
|
||||||
git_override(
|
git_override(
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "base",
|
name = "base",
|
||||||
hdrs = [
|
hdrs = [
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "buffer",
|
name = "buffer",
|
||||||
hdrs = [
|
hdrs = [
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "formatting",
|
name = "formatting",
|
||||||
hdrs = [
|
hdrs = [
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "hashing",
|
name = "hashing",
|
||||||
hdrs = [
|
hdrs = [
|
||||||
@ -14,6 +18,9 @@ cc_library(
|
|||||||
"//asl/base",
|
"//asl/base",
|
||||||
"//asl/types:span",
|
"//asl/types:span",
|
||||||
],
|
],
|
||||||
|
applicable_licenses = [
|
||||||
|
"//vendor/cityhash:license",
|
||||||
|
],
|
||||||
visibility = ["//visibility:public"],
|
visibility = ["//visibility:public"],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "writer",
|
name = "writer",
|
||||||
hdrs = [
|
hdrs = [
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "logging",
|
name = "logging",
|
||||||
srcs = [
|
srcs = [
|
||||||
|
@ -27,6 +27,6 @@ ASL_TEST(custom_writer)
|
|||||||
ASL_LOG_INFO("Hello");
|
ASL_LOG_INFO("Hello");
|
||||||
auto sv = string_writer.as_string_view();
|
auto sv = string_writer.as_string_view();
|
||||||
|
|
||||||
ASL_TEST_EXPECT(sv == "[ INFO ] asl/logging/logging_tests.cpp:23: Hello\n");
|
ASL_TEST_EXPECT(sv == "[ INFO ] asl/logging/logging_tests.cpp:27: Hello\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "memory",
|
name = "memory",
|
||||||
hdrs = [
|
hdrs = [
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "string_view",
|
name = "string_view",
|
||||||
hdrs = [
|
hdrs = [
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "atomic",
|
name = "atomic",
|
||||||
hdrs = [
|
hdrs = [
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "testing",
|
name = "testing",
|
||||||
hdrs = [
|
hdrs = [
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "utils",
|
name = "utils",
|
||||||
hdrs = [
|
hdrs = [
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "box",
|
name = "box",
|
||||||
hdrs = [
|
hdrs = [
|
||||||
|
@ -1 +1 @@
|
|||||||
bazel run //:refresh_clangd --config=windows -- --config=windows
|
bazel run //tools:refresh_clangd --config=windows -- --config=windows
|
||||||
|
@ -1 +1 @@
|
|||||||
bazel run //:refresh_clangd --config=linux -- --config=linux
|
bazel run //tools:refresh_clangd --config=linux -- --config=linux
|
||||||
|
@ -3,6 +3,11 @@
|
|||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
load("@rules_python//python:py_binary.bzl", "py_binary")
|
load("@rules_python//python:py_binary.bzl", "py_binary")
|
||||||
|
load("@hedron_compile_commands//:refresh_compile_commands.bzl", "refresh_compile_commands")
|
||||||
|
|
||||||
|
package(
|
||||||
|
default_applicable_licenses = ["//:license"],
|
||||||
|
)
|
||||||
|
|
||||||
py_binary(
|
py_binary(
|
||||||
name = "fix_line_endings",
|
name = "fix_line_endings",
|
||||||
@ -11,3 +16,8 @@ py_binary(
|
|||||||
],
|
],
|
||||||
visibility = ["//:__subpackages__"],
|
visibility = ["//:__subpackages__"],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
refresh_compile_commands(
|
||||||
|
name = "refresh_clangd",
|
||||||
|
targets = "//...",
|
||||||
|
)
|
||||||
|
15
vendor/cityhash/BUILD.bazel
vendored
Normal file
15
vendor/cityhash/BUILD.bazel
vendored
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
# Copyright 2025 Steven Le Rouzic
|
||||||
|
#
|
||||||
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
load("@rules_license//rules:license.bzl", "license")
|
||||||
|
|
||||||
|
license(
|
||||||
|
name = "license",
|
||||||
|
license_kinds = [
|
||||||
|
"@rules_license//licenses/spdx:MIT",
|
||||||
|
],
|
||||||
|
license_text = "LICENSE.txt",
|
||||||
|
package_name = "CityHash",
|
||||||
|
package_url = "https://github.com/google/cityhash",
|
||||||
|
)
|
15
vendor/dragonbox/BUILD.bazel
vendored
15
vendor/dragonbox/BUILD.bazel
vendored
@ -2,9 +2,24 @@
|
|||||||
#
|
#
|
||||||
# SPDX-License-Identifier: BSD-3-Clause
|
# SPDX-License-Identifier: BSD-3-Clause
|
||||||
|
|
||||||
|
load("@rules_license//rules:license.bzl", "license")
|
||||||
|
|
||||||
|
license(
|
||||||
|
name = "license",
|
||||||
|
license_kinds = [
|
||||||
|
"@rules_license//licenses/spdx:Apache-2.0",
|
||||||
|
],
|
||||||
|
license_text = "LICENSE.txt",
|
||||||
|
package_name = "Dragonbox",
|
||||||
|
package_url = "https://github.com/jk-jeon/dragonbox",
|
||||||
|
)
|
||||||
|
|
||||||
cc_library(
|
cc_library(
|
||||||
name = "dragonbox",
|
name = "dragonbox",
|
||||||
hdrs = ["dragonbox.h"],
|
hdrs = ["dragonbox.h"],
|
||||||
includes = ["."],
|
includes = ["."],
|
||||||
visibility = ["//:__subpackages__"],
|
visibility = ["//:__subpackages__"],
|
||||||
|
applicable_licenses = [
|
||||||
|
":license",
|
||||||
|
],
|
||||||
)
|
)
|
||||||
|
Reference in New Issue
Block a user