diff --git a/BUILD.bazel b/BUILD.bazel index efd142c..cafd9c2 100644 --- a/BUILD.bazel +++ b/BUILD.bazel @@ -1,22 +1,23 @@ -load("@rules_license//rules:license.bzl", "license") load( "@gz//bazel/skylark:build_defs.bzl", "GZ_FEATURES", + "GZ_ROOT", "GZ_VISIBILITY", "gz_configure_header", "gz_export_header", "gz_include_header", ) +load("@rules_license//rules:license.bzl", "license") package( - default_applicable_licenses = [":license"], + default_applicable_licenses = [GZ_ROOT + "utils:license"], default_visibility = GZ_VISIBILITY, features = GZ_FEATURES, ) license( - name = "license", - package_name = "gz-utils" + name = "license", + package_name = "gz-utils", ) licenses(["notice"]) @@ -46,8 +47,8 @@ gz_include_header( name = "utilshh_genrule", out = "include/gz/utils.hh", hdrs = public_headers_no_gen + [ - "include/gz/utils/config.hh", "include/gz/utils/Export.hh", + "include/gz/utils/config.hh", ], ) @@ -61,6 +62,7 @@ cc_library( name = "utils", srcs = ["src/Environment.cc"], hdrs = public_headers, + copts = ["-fexceptions"], includes = ["include"], ) @@ -101,6 +103,7 @@ cc_test( cc_test( name = "NeverDestroyed_TEST", srcs = ["src/NeverDestroyed_TEST.cc"], + copts = ["-fexceptions"], deps = [ ":utils", "@gtest", diff --git a/cli/BUILD.bazel b/cli/BUILD.bazel index 096f09e..04c7c71 100644 --- a/cli/BUILD.bazel +++ b/cli/BUILD.bazel @@ -1,8 +1,13 @@ load( "@gz//bazel/skylark:build_defs.bzl", + "GZ_ROOT", "GZ_VISIBILITY", ) +package( + default_applicable_licenses = [GZ_ROOT + "utils:license"], +) + public_headers = [ "include/gz/utils/cli/GzFormatter.hpp", ] + glob([ @@ -12,6 +17,7 @@ public_headers = [ cc_library( name = "cli", hdrs = public_headers, + copts = ["-fexceptions"], includes = [ "include", "include/external-cli",