From 8546cecf3276a97a45347b6bdc172bdd9ecf4e30 Mon Sep 17 00:00:00 2001 From: Michael Carroll Date: Fri, 8 Mar 2024 20:52:54 +0000 Subject: [PATCH] Lint Signed-off-by: Michael Carroll --- BUILD.bazel | 11 ++++++++++- av/BUILD.bazel | 6 ++++++ events/BUILD.bazel | 3 +++ geospatial/BUILD.bazel | 3 +++ graphics/BUILD.bazel | 6 ++++++ io/BUILD.bazel | 6 ++++++ profiler/BUILD.bazel | 1 + testing/BUILD.bazel | 6 ++++++ 8 files changed, 41 insertions(+), 1 deletion(-) diff --git a/BUILD.bazel b/BUILD.bazel index 33ac2dac..0107b472 100644 --- a/BUILD.bazel +++ b/BUILD.bazel @@ -7,13 +7,20 @@ load( "gz_export_header", "gz_include_header", ) +load("@rules_license//rules:license.bzl", "license") package( + default_applicable_licenses = [GZ_ROOT + "common:license"], default_visibility = GZ_VISIBILITY, features = GZ_FEATURES, ) -licenses(["notice"]) # Apache-2.0 +license( + name = "license", + package_name = "gz-common", +) + +licenses(["notice"]) exports_files(["LICENSE"]) @@ -93,3 +100,5 @@ test_sources = glob( "@gtest//:gtest_main", ], ) for src in test_sources] + +add_lint_tests() diff --git a/av/BUILD.bazel b/av/BUILD.bazel index 93fb8a6a..7ff8967b 100644 --- a/av/BUILD.bazel +++ b/av/BUILD.bazel @@ -1,11 +1,17 @@ load( "@gz//bazel/skylark:build_defs.bzl", + "GZ_FEATURES", "GZ_ROOT", "GZ_VISIBILITY", "gz_export_header", "gz_include_header", ) +package( + default_applicable_licenses = [GZ_ROOT + "common:license"], + features = GZ_FEATURES +) + public_headers_no_gen = glob([ "include/gz/common/*.hh", "include/gz/common/**/*.hh", diff --git a/events/BUILD.bazel b/events/BUILD.bazel index 4d6936b9..f401c4e7 100644 --- a/events/BUILD.bazel +++ b/events/BUILD.bazel @@ -1,11 +1,14 @@ load( "@gz//bazel/skylark:build_defs.bzl", + "GZ_FEATURES", "GZ_ROOT", "GZ_VISIBILITY", "gz_export_header", "gz_include_header", ) +package(features = GZ_FEATURES) + public_headers_no_gen = glob([ "include/gz/common/*.hh", "include/gz/common/**/*.hh", diff --git a/geospatial/BUILD.bazel b/geospatial/BUILD.bazel index b01923fa..898703fd 100644 --- a/geospatial/BUILD.bazel +++ b/geospatial/BUILD.bazel @@ -1,11 +1,14 @@ load( "@gz//bazel/skylark:build_defs.bzl", + "GZ_FEATURES", "GZ_ROOT", "GZ_VISIBILITY", "gz_export_header", "gz_include_header", ) +package(features = GZ_FEATURES) + public_headers_no_gen = glob([ "include/gz/common/*.hh", "include/gz/common/**/*.hh", diff --git a/graphics/BUILD.bazel b/graphics/BUILD.bazel index 6d7b8822..c2fbf61f 100644 --- a/graphics/BUILD.bazel +++ b/graphics/BUILD.bazel @@ -1,11 +1,17 @@ load( "@gz//bazel/skylark:build_defs.bzl", + "GZ_FEATURES", "GZ_ROOT", "GZ_VISIBILITY", "gz_export_header", "gz_include_header", ) +package( + default_applicable_licenses = [GZ_ROOT + "common:license"], + features = GZ_FEATURES +) + public_headers_no_gen = glob([ "include/gz/common/*.hh", "include/gz/common/**/*.hh", diff --git a/io/BUILD.bazel b/io/BUILD.bazel index a3371a45..de642964 100644 --- a/io/BUILD.bazel +++ b/io/BUILD.bazel @@ -1,11 +1,17 @@ load( "@gz//bazel/skylark:build_defs.bzl", + "GZ_FEATURES", "GZ_ROOT", "GZ_VISIBILITY", "gz_export_header", "gz_include_header", ) +package( + default_applicable_licenses = [GZ_ROOT + "common:license"], + features = GZ_FEATURES +) + public_headers_no_gen = glob([ "include/gz/common/*.hh", "include/gz/common/**/*.hh", diff --git a/profiler/BUILD.bazel b/profiler/BUILD.bazel index 8d9a6dd2..442be198 100644 --- a/profiler/BUILD.bazel +++ b/profiler/BUILD.bazel @@ -1,5 +1,6 @@ load( "@gz//bazel/skylark:build_defs.bzl", + "GZ_FEATURES", "GZ_ROOT", "GZ_VISIBILITY", "cmake_configure_file", diff --git a/testing/BUILD.bazel b/testing/BUILD.bazel index ac9111cd..8b5c51a0 100644 --- a/testing/BUILD.bazel +++ b/testing/BUILD.bazel @@ -1,9 +1,15 @@ load( "@gz//bazel/skylark:build_defs.bzl", + "GZ_FEATURES", "GZ_ROOT", "gz_export_header", ) +package( + default_applicable_licenses = [GZ_ROOT + "common:license"], + features = GZ_FEATURES +) + gz_export_header( name = "include/gz/common/testing/Export.hh", export_base = "GZ_COMMON_TESTING",