aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorandroid-build-team Robot <android-build-team-robot@google.com>2021-06-21 14:48:34 +0000
committerandroid-build-team Robot <android-build-team-robot@google.com>2021-06-21 14:48:34 +0000
commitcf77c399e3a87af9eb56806597e724e7b283c5d3 (patch)
tree6e1c1fca27986c75003dd1339570b8aa13498b64
parenta947022e8ddbc709f0bbcd79d419030a276f9adc (diff)
parent36689e89eda61863980b986a02afa85bbb3a2c8b (diff)
downloadlibpng-android12-mainline-extservices-release.tar.gz
Change-Id: Ib22adff2dc6f994050beae82f70f5e0ef21953e5
-rw-r--r--Android.bp74
-rw-r--r--METADATA9
l---------NOTICE1
-rw-r--r--TEST_MAPPING7
4 files changed, 85 insertions, 6 deletions
diff --git a/Android.bp b/Android.bp
index 72cd34066..07c96994e 100644
--- a/Android.bp
+++ b/Android.bp
@@ -1,6 +1,47 @@
// We need to build this for both the device (as a shared library)
// and the host (as a static library for tools to use).
+package {
+ default_applicable_licenses: ["external_libpng_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.
+//
+// large-scale-change filtered out the below license kinds as false-positives:
+// SPDX-license-identifier-GPL
+// SPDX-license-identifier-GPL-2.0
+// SPDX-license-identifier-LGPL
+// See: http://go/android-license-faq
+license {
+ name: "external_libpng_license",
+ visibility: [":__subpackages__"],
+ license_kinds: [
+ "SPDX-license-identifier-Apache-2.0",
+ "SPDX-license-identifier-BSD",
+ "SPDX-license-identifier-CC0-1.0",
+ "SPDX-license-identifier-MIT",
+ "SPDX-license-identifier-W3C",
+ "SPDX-license-identifier-Zlib",
+ "legacy_notice",
+ "legacy_unencumbered",
+ ],
+ license_text: [
+ "LICENSE",
+ ],
+}
+
cc_defaults {
name: "libpng-defaults",
exclude_srcs: [
@@ -17,9 +58,14 @@ cc_defaults {
arch: {
arm: {
srcs: ["arm/*"],
+ cflags: ["-O3"],
},
arm64: {
srcs: ["arm/*",],
+ cflags: ["-O3"],
+ exclude_srcs: [
+ "arm/filter_neon.S"
+ ],
},
x86: {
srcs: ["intel/*"],
@@ -50,6 +96,7 @@ cc_defaults {
cc_library {
name: "libpng",
vendor_available: true,
+ product_available: true,
// TODO(b/153609531): remove when no longer needed.
native_bridge_supported: true,
recovery_available: true,
@@ -75,7 +122,7 @@ cc_library_static {
cflags: ["-ftrapv"],
shared_libs: ["libz"],
- sdk_version: "14",
+ sdk_version: "minimum",
}
// For testing
@@ -92,3 +139,28 @@ cc_test {
"libz",
],
}
+
+cc_fuzz {
+ name: "libpng_read_fuzzer",
+ host_supported:true,
+
+ static_libs: [
+ "libpng",
+ "libz",
+ ],
+
+ srcs: [
+ "contrib/oss-fuzz/libpng_read_fuzzer.cc",
+ ],
+
+ dictionary: "contrib/oss-fuzz/png.dict",
+
+ corpus: ["contrib/testpngs/*.png"],
+
+ fuzz_config: {
+ cc: [
+ "scroggo@google.com",
+ ],
+ componentid: 87896,
+ },
+}
diff --git a/METADATA b/METADATA
index cf383c0f6..812f45a43 100644
--- a/METADATA
+++ b/METADATA
@@ -5,10 +5,11 @@ third_party {
type: GIT
value: "https://github.com/glennrp/libpng.git"
}
- version: "v1.6.34"
+ version: "v1.6.37"
+ license_type: NOTICE
last_upgrade_date {
- year: 2017
- month: 10
- day: 6
+ year: 2019
+ month: 6
+ day: 10
}
}
diff --git a/NOTICE b/NOTICE
deleted file mode 120000
index 7a694c969..000000000
--- a/NOTICE
+++ /dev/null
@@ -1 +0,0 @@
-LICENSE \ No newline at end of file
diff --git a/TEST_MAPPING b/TEST_MAPPING
new file mode 100644
index 000000000..10bd0ee90
--- /dev/null
+++ b/TEST_MAPPING
@@ -0,0 +1,7 @@
+{
+ "presubmit": [
+ {
+ "name": "CtsGraphicsTestCases"
+ }
+ ]
+}