From f2a2bd35ec436cc7ec0c72a9d93b511e91484cf9 Mon Sep 17 00:00:00 2001 From: Bob Badour Date: Mon, 15 Mar 2021 09:33:50 -0700 Subject: [PATCH] [LSC] Add LOCAL_LICENSE_KINDS to device/google/sunfish Added SPDX-license-identifier-Apache-2.0 to: bootctrl/Android.bp dumpstate/Android.mk health/Android.bp keymaster/Android.bp overlay_packages/SettingsOverlayG025J/Android.bp overlay_packages/SettingsOverlayG025M/Android.bp overlay_packages/SettingsOverlayG025N/Android.bp pixelstats/Android.bp powerstats/Android.bp rro_overlays/WifiOverlay/Android.bp self-extractors/qcom/staging/Android.mk usb/Android.bp vibrator/Android.bp vibrator/apex/Android.bp vibrator/common/Android.bp vibrator/common/bench/Android.bp vibrator/drv2624/Android.bp vibrator/drv2624/bench/Android.bp vibrator/drv2624/tests/Android.bp voice_processing/Android.bp Added SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD SPDX-license-identifier-MIT legacy_not_a_contribution legacy_unencumbered to: Android.bp Added SPDX-license-identifier-BSD to: gpt-utils/Android.bp Added SPDX-license-identifier-MIT legacy_unencumbered to: json-c/Android.mk Bug: 68860345 Bug: 151177513 Bug: 151953481 Test: m all Exempt-From-Owner-Approval: janitorial work Change-Id: Ie80d0d60f0f11e319f786604d4a548543ab07ce9 Merged-in: I1fb52042e21be78a79d59c4d8c33c34b6a2957aa --- Android.bp | 31 +++++++++++++++++++ bootctrl/Android.bp | 4 +++ dumpstate/Android.mk | 2 ++ gpt-utils/Android.bp | 9 ++++++ health/Android.bp | 4 +++ json-c/Android.mk | 3 ++ keymaster/Android.bp | 4 +++ .../SettingsOverlayG025J/Android.bp | 6 +++- .../SettingsOverlayG025M/Android.bp | 6 +++- .../SettingsOverlayG025N/Android.bp | 6 +++- pixelstats/Android.bp | 5 ++- powerstats/Android.bp | 4 +++ rro_overlays/WifiOverlay/Android.bp | 4 +++ self-extractors/qcom/staging/Android.mk | 9 ++++++ usb/Android.bp | 4 +++ vibrator/Android.bp | 4 +++ vibrator/apex/Android.bp | 6 +++- vibrator/common/Android.bp | 4 +++ vibrator/common/bench/Android.bp | 4 +++ vibrator/drv2624/Android.bp | 6 +++- vibrator/drv2624/bench/Android.bp | 4 +++ vibrator/drv2624/tests/Android.bp | 4 +++ voice_processing/Android.bp | 4 +++ 23 files changed, 131 insertions(+), 6 deletions(-) diff --git a/Android.bp b/Android.bp index 913278a7..2726a0a6 100644 --- a/Android.bp +++ b/Android.bp @@ -5,3 +5,34 @@ soong_namespace { "hardware/qcom/bootctrl", ], } + +package { + default_applicable_licenses: ["device_google_sunfish_license"], +} + +// Added automatically by a large-scale-change that took the approach of +// 'apply every license found to every target'. While this makes sure we respect +// every license restriction, it may not be entirely correct. +// +// e.g. GPL in an MIT project might only apply to the contrib/ directory. +// +// Please consider splitting the single license below into multiple licenses, +// taking care not to lose any license_kind information, and overriding the +// default license using the 'licenses: [...]' property on targets as needed. +// +// For unused files, consider creating a 'fileGroup' with "//visibility:private" +// to attach the license to, and including a comment whether the files may be +// used in the current project. +// See: http://go/android-license-faq +license { + name: "device_google_sunfish_license", + visibility: [":__subpackages__"], + license_kinds: [ + "SPDX-license-identifier-Apache-2.0", + "SPDX-license-identifier-BSD", + "SPDX-license-identifier-MIT", + "legacy_not_a_contribution", + "legacy_unencumbered", + ], + // large-scale-change unable to identify any license_text files +} diff --git a/bootctrl/Android.bp b/bootctrl/Android.bp index 1c149201..3ed93158 100644 --- a/bootctrl/Android.bp +++ b/bootctrl/Android.bp @@ -14,6 +14,10 @@ // limitations under the License. // +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_library { name: "bootctrl.sm6150", defaults: ["bootctrl_hal_defaults"], diff --git a/dumpstate/Android.mk b/dumpstate/Android.mk index 6e7a91c4..8771d26f 100644 --- a/dumpstate/Android.mk +++ b/dumpstate/Android.mk @@ -17,6 +17,8 @@ LOCAL_PATH:= $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE := android.hardware.dumpstate@1.1-service.sunfish +LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0 +LOCAL_LICENSE_CONDITIONS := notice LOCAL_INIT_RC := android.hardware.dumpstate@1.1-service.sunfish.rc LOCAL_MODULE_RELATIVE_PATH := hw diff --git a/gpt-utils/Android.bp b/gpt-utils/Android.bp index 4215181d..08fad2eb 100644 --- a/gpt-utils/Android.bp +++ b/gpt-utils/Android.bp @@ -14,6 +14,15 @@ // limitations under the License. // +package { + // See: http://go/android-license-faq + // A large-scale-change added 'default_applicable_licenses' to import + // all of the 'license_kinds' from "device_google_sunfish_license" + // to get the below license kinds: + // SPDX-license-identifier-BSD + default_applicable_licenses: ["device_google_sunfish_license"], +} + cc_library { name: "libgptutils.sunfish", vendor: true, diff --git a/health/Android.bp b/health/Android.bp index 057c63d9..f3de7d28 100644 --- a/health/Android.bp +++ b/health/Android.bp @@ -14,6 +14,10 @@ * limitations under the License. */ +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_library_shared { name: "android.hardware.health@2.1-impl-sunfish", stem: "android.hardware.health@2.0-impl-2.1-sunfish", diff --git a/json-c/Android.mk b/json-c/Android.mk index 139a10c3..6202a538 100644 --- a/json-c/Android.mk +++ b/json-c/Android.mk @@ -1,7 +1,10 @@ LIBJSON_ROOT := $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE := libjson +LOCAL_LICENSE_KINDS := SPDX-license-identifier-MIT legacy_unencumbered +LOCAL_LICENSE_CONDITIONS := notice unencumbered LOCAL_PATH := $(LIBJSON_ROOT) +LOCAL_NOTICE_FILE := $(LOCAL_PATH)/COPYING LOCAL_C_INCLUDES += $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr/include LOCAL_ADDITIONAL_DEPENDENCIES += $(TARGET_OUT_INTERMEDIATES)/KERNEL_OBJ/usr LOCAL_COPY_HEADERS_TO := libjson/inc diff --git a/keymaster/Android.bp b/keymaster/Android.bp index 30952a6e..87f73988 100644 --- a/keymaster/Android.bp +++ b/keymaster/Android.bp @@ -13,6 +13,10 @@ // See the License for the specific language governing permissions and // limitations under the License. +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_binary { name: "wait_for_strongbox", relative_install_path: "hw", diff --git a/overlay_packages/SettingsOverlayG025J/Android.bp b/overlay_packages/SettingsOverlayG025J/Android.bp index 813a9826..0586fa4e 100644 --- a/overlay_packages/SettingsOverlayG025J/Android.bp +++ b/overlay_packages/SettingsOverlayG025J/Android.bp @@ -1,4 +1,8 @@ +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + runtime_resource_overlay { name: "SettingsOverlayG025J", product_specific: true, -} \ No newline at end of file +} diff --git a/overlay_packages/SettingsOverlayG025M/Android.bp b/overlay_packages/SettingsOverlayG025M/Android.bp index 050ff76c..d89d2d57 100644 --- a/overlay_packages/SettingsOverlayG025M/Android.bp +++ b/overlay_packages/SettingsOverlayG025M/Android.bp @@ -1,4 +1,8 @@ +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + runtime_resource_overlay { name: "SettingsOverlayG025M", product_specific: true, -} \ No newline at end of file +} diff --git a/overlay_packages/SettingsOverlayG025N/Android.bp b/overlay_packages/SettingsOverlayG025N/Android.bp index 61c51d5a..985145f0 100644 --- a/overlay_packages/SettingsOverlayG025N/Android.bp +++ b/overlay_packages/SettingsOverlayG025N/Android.bp @@ -1,4 +1,8 @@ +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + runtime_resource_overlay { name: "SettingsOverlayG025N", product_specific: true, -} \ No newline at end of file +} diff --git a/pixelstats/Android.bp b/pixelstats/Android.bp index 8c33fc81..0d43f107 100644 --- a/pixelstats/Android.bp +++ b/pixelstats/Android.bp @@ -13,6 +13,10 @@ // See the License for the specific language governing permissions and // limitations under the License. +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_binary { name: "pixelstats-vendor", init_rc: ["pixelstats-vendor.sunfish.rc"], @@ -32,4 +36,3 @@ cc_binary { static_libs: ["chre_client"], header_libs: ["chre_api"], } - diff --git a/powerstats/Android.bp b/powerstats/Android.bp index 688e5a57..02cd3c31 100644 --- a/powerstats/Android.bp +++ b/powerstats/Android.bp @@ -12,6 +12,10 @@ // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_binary { name: "android.hardware.power.stats@1.0-service.pixel", relative_install_path: "hw", diff --git a/rro_overlays/WifiOverlay/Android.bp b/rro_overlays/WifiOverlay/Android.bp index c2089a10..3929ea91 100644 --- a/rro_overlays/WifiOverlay/Android.bp +++ b/rro_overlays/WifiOverlay/Android.bp @@ -1,3 +1,7 @@ +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + runtime_resource_overlay { name: "WifiOverlay", theme: "WifiOverlay", diff --git a/self-extractors/qcom/staging/Android.mk b/self-extractors/qcom/staging/Android.mk index 7891cabf..2f308ea5 100644 --- a/self-extractors/qcom/staging/Android.mk +++ b/self-extractors/qcom/staging/Android.mk @@ -4,6 +4,9 @@ ifneq ($(filter sunfish, $(TARGET_DEVICE)),) include $(CLEAR_VARS) LOCAL_MODULE_SUFFIX := $(COMMON_ANDROID_PACKAGE_SUFFIX) LOCAL_MODULE := ims +LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0 +LOCAL_LICENSE_CONDITIONS := notice +LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../COPYRIGHT $(LOCAL_PATH)/../LICENSE LOCAL_MODULE_TAGS := optional LOCAL_BUILT_MODULE_STEM := package.apk LOCAL_SYSTEM_EXT_MODULE := true @@ -17,6 +20,9 @@ include $(BUILD_PREBUILT) include $(CLEAR_VARS) LOCAL_MODULE_SUFFIX := $(COMMON_ANDROID_PACKAGE_SUFFIX) LOCAL_MODULE := qcrilmsgtunnel +LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0 +LOCAL_LICENSE_CONDITIONS := notice +LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../COPYRIGHT $(LOCAL_PATH)/../LICENSE LOCAL_MODULE_TAGS := optional LOCAL_BUILT_MODULE_STEM := package.apk LOCAL_SYSTEM_EXT_MODULE := true @@ -30,6 +36,9 @@ include $(BUILD_PREBUILT) include $(CLEAR_VARS) LOCAL_MODULE_SUFFIX := $(COMMON_ANDROID_PACKAGE_SUFFIX) LOCAL_MODULE := QtiTelephonyService +LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0 +LOCAL_LICENSE_CONDITIONS := notice +LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../COPYRIGHT $(LOCAL_PATH)/../LICENSE LOCAL_MODULE_TAGS := optional LOCAL_BUILT_MODULE_STEM := package.apk LOCAL_SYSTEM_EXT_MODULE := true diff --git a/usb/Android.bp b/usb/Android.bp index 5f12eecd..6abbf9d2 100644 --- a/usb/Android.bp +++ b/usb/Android.bp @@ -13,6 +13,10 @@ // See the License for the specific language governing permissions and // limitations under the License. +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_binary { name: "android.hardware.usb@1.2-service.sunfish", relative_install_path: "hw", diff --git a/vibrator/Android.bp b/vibrator/Android.bp index cd89f0c1..5e0d601c 100644 --- a/vibrator/Android.bp +++ b/vibrator/Android.bp @@ -13,6 +13,10 @@ // See the License for the specific language governing permissions and // limitations under the License. +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_defaults { name: "PixelVibratorDefaultsSunfish", defaults: ["hidl_defaults"], diff --git a/vibrator/apex/Android.bp b/vibrator/apex/Android.bp index a3f0b2f1..3babe5e8 100644 --- a/vibrator/apex/Android.bp +++ b/vibrator/apex/Android.bp @@ -1,3 +1,7 @@ +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + apex { name: "com.android.vibrator.sunfish", manifest: "apex_manifest.json", @@ -47,4 +51,4 @@ prebuilt_etc { name: "android.hardware.vibrator@1.3-service.sunfish.rc", src: "android.hardware.vibrator@1.3-service.sunfish.rc", installable: false, -} \ No newline at end of file +} diff --git a/vibrator/common/Android.bp b/vibrator/common/Android.bp index a62d43b3..712312c7 100644 --- a/vibrator/common/Android.bp +++ b/vibrator/common/Android.bp @@ -13,6 +13,10 @@ // See the License for the specific language governing permissions and // limitations under the License. +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_library { name: "PixelVibratorCommonSunfish", srcs: [ diff --git a/vibrator/common/bench/Android.bp b/vibrator/common/bench/Android.bp index aa582ef8..7cda2ddb 100644 --- a/vibrator/common/bench/Android.bp +++ b/vibrator/common/bench/Android.bp @@ -13,6 +13,10 @@ // See the License for the specific language governing permissions and // limitations under the License. +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_benchmark { name: "VibratorHalIntegrationBenchmarkSunfish", defaults: ["hidl_defaults"], diff --git a/vibrator/drv2624/Android.bp b/vibrator/drv2624/Android.bp index 045e1d0b..08c18bbc 100644 --- a/vibrator/drv2624/Android.bp +++ b/vibrator/drv2624/Android.bp @@ -13,6 +13,10 @@ // See the License for the specific language governing permissions and // limitations under the License. +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_defaults { name: "android.hardware.vibrator@1.3-defaults.sunfish", defaults: ["PixelVibratorDefaultsSunfish"], @@ -57,4 +61,4 @@ prebuilt_firmware { src: "drv2624.bin", filename_from_src: true, proprietary: true, -} \ No newline at end of file +} diff --git a/vibrator/drv2624/bench/Android.bp b/vibrator/drv2624/bench/Android.bp index f79d0393..dec9f3e5 100644 --- a/vibrator/drv2624/bench/Android.bp +++ b/vibrator/drv2624/bench/Android.bp @@ -13,6 +13,10 @@ // See the License for the specific language governing permissions and // limitations under the License. +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_benchmark { name: "VibratorHalDrv2624BenchmarkSunfish", defaults: ["VibratorHalDrv2624TestDefaultsSunfish"], diff --git a/vibrator/drv2624/tests/Android.bp b/vibrator/drv2624/tests/Android.bp index d000c10c..00fbf7d8 100644 --- a/vibrator/drv2624/tests/Android.bp +++ b/vibrator/drv2624/tests/Android.bp @@ -13,6 +13,10 @@ // See the License for the specific language governing permissions and // limitations under the License. +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_test { name: "VibratorHalDrv2624TestSuiteSunfish", defaults: ["VibratorHalDrv2624TestDefaultsSunfish"], diff --git a/voice_processing/Android.bp b/voice_processing/Android.bp index 48d21dd8..2fe366e7 100644 --- a/voice_processing/Android.bp +++ b/voice_processing/Android.bp @@ -12,6 +12,10 @@ // See the License for the specific language governing permissions and // limitations under the License. +package { + default_applicable_licenses: ["Android-Apache-2.0"], +} + cc_library_shared { name: "libqcomvoiceprocessingdescriptors", srcs: ["voice_processing_descriptors.c"],