237 lines
6.6 KiB
Plaintext
237 lines
6.6 KiB
Plaintext
// *** THIS PACKAGE HAS SPECIAL LICENSING CONDITIONS. PLEASE
|
|
// CONSULT THE OWNERS AND opensource-licensing@google.com BEFORE
|
|
// DEPENDING ON IT IN YOUR PROJECT. ***
|
|
package {
|
|
default_applicable_licenses: ["external_dng_sdk_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 included anything that looked like it might be a license
|
|
// text as a license_text. e.g. LICENSE, NOTICE, COPYING etc.
|
|
//
|
|
// Please consider removing redundant or irrelevant files from 'license_text:'.
|
|
// See: http://go/android-license-faq
|
|
license {
|
|
name: "external_dng_sdk_license",
|
|
visibility: [":__subpackages__"],
|
|
license_kinds: [
|
|
"SPDX-license-identifier-Apache-2.0",
|
|
"SPDX-license-identifier-MIT",
|
|
"legacy_by_exception_only", // by exception only
|
|
],
|
|
license_text: [
|
|
"LICENSE",
|
|
"LICENSE.source_code",
|
|
"LICENSE.technology",
|
|
"NOTICE",
|
|
"PATENTS",
|
|
],
|
|
}
|
|
|
|
cc_defaults {
|
|
name: "libdng_sdk-defaults",
|
|
srcs: [
|
|
"source/dng_1d_function.cpp",
|
|
"source/dng_1d_table.cpp",
|
|
"source/dng_abort_sniffer.cpp",
|
|
"source/dng_area_task.cpp",
|
|
"source/dng_bad_pixels.cpp",
|
|
"source/dng_bottlenecks.cpp",
|
|
"source/dng_camera_profile.cpp",
|
|
"source/dng_color_space.cpp",
|
|
"source/dng_color_spec.cpp",
|
|
"source/dng_date_time.cpp",
|
|
"source/dng_exceptions.cpp",
|
|
"source/dng_exif.cpp",
|
|
"source/dng_file_stream.cpp",
|
|
"source/dng_filter_task.cpp",
|
|
"source/dng_fingerprint.cpp",
|
|
"source/dng_gain_map.cpp",
|
|
"source/dng_globals.cpp",
|
|
"source/dng_host.cpp",
|
|
"source/dng_hue_sat_map.cpp",
|
|
"source/dng_ifd.cpp",
|
|
"source/dng_image.cpp",
|
|
"source/dng_image_writer.cpp",
|
|
"source/dng_info.cpp",
|
|
"source/dng_iptc.cpp",
|
|
"source/dng_jpeg_image.cpp",
|
|
"source/dng_jpeg_memory_source.cpp",
|
|
"source/dng_lens_correction.cpp",
|
|
"source/dng_linearization_info.cpp",
|
|
"source/dng_lossless_jpeg.cpp",
|
|
"source/dng_matrix.cpp",
|
|
"source/dng_memory.cpp",
|
|
"source/dng_memory_stream.cpp",
|
|
"source/dng_misc_opcodes.cpp",
|
|
"source/dng_mosaic_info.cpp",
|
|
"source/dng_mutex.cpp",
|
|
"source/dng_negative.cpp",
|
|
"source/dng_opcode_list.cpp",
|
|
"source/dng_opcodes.cpp",
|
|
"source/dng_orientation.cpp",
|
|
"source/dng_parse_utils.cpp",
|
|
"source/dng_pixel_buffer.cpp",
|
|
"source/dng_point.cpp",
|
|
"source/dng_preview.cpp",
|
|
"source/dng_pthread.cpp",
|
|
"source/dng_rational.cpp",
|
|
"source/dng_read_image.cpp",
|
|
"source/dng_rect.cpp",
|
|
"source/dng_ref_counted_block.cpp",
|
|
"source/dng_reference.cpp",
|
|
"source/dng_render.cpp",
|
|
"source/dng_resample.cpp",
|
|
"source/dng_safe_arithmetic.cpp",
|
|
"source/dng_shared.cpp",
|
|
"source/dng_simple_image.cpp",
|
|
"source/dng_spline.cpp",
|
|
"source/dng_stream.cpp",
|
|
"source/dng_string.cpp",
|
|
"source/dng_string_list.cpp",
|
|
"source/dng_tag_types.cpp",
|
|
"source/dng_temperature.cpp",
|
|
"source/dng_tile_iterator.cpp",
|
|
"source/dng_tone_curve.cpp",
|
|
"source/dng_utils.cpp",
|
|
"source/dng_xy_coord.cpp",
|
|
"source/dng_xmp.cpp",
|
|
],
|
|
cflags: [
|
|
"-DUNIX_ENV=1",
|
|
"-DqDNGBigEndian=0",
|
|
"-DqDNGThreadSafe=1",
|
|
"-DqDNGUseLibJPEG=1",
|
|
"-DqDNGUseXMP=0",
|
|
"-DqDNGValidateTarget=1",
|
|
"-DqAndroid=1",
|
|
"-Werror",
|
|
"-Wsign-compare",
|
|
"-Wno-reorder",
|
|
"-Wframe-larger-than=20000",
|
|
|
|
// Ignore unused parameters.
|
|
"-Wno-unused-parameter",
|
|
|
|
// Some integral return types are annotated with "const."
|
|
"-Wno-ignored-qualifiers",
|
|
],
|
|
|
|
rtti: true,
|
|
cppflags: ["-fexceptions"],
|
|
|
|
clang: true,
|
|
sanitize: {
|
|
misc_undefined: [
|
|
"unsigned-integer-overflow",
|
|
"signed-integer-overflow",
|
|
],
|
|
},
|
|
}
|
|
|
|
cc_library{
|
|
name: "libdng_sdk",
|
|
host_supported: true,
|
|
vendor_available: true,
|
|
defaults: ["libdng_sdk-defaults"],
|
|
|
|
cflags: ["-DqDNGValidate=0"],
|
|
|
|
shared_libs: [
|
|
"libz",
|
|
"libjpeg",
|
|
],
|
|
|
|
target: {
|
|
linux_glibc: {
|
|
static_libs: ["libcompiler_rt-extras"],
|
|
},
|
|
darwin: {
|
|
host_ldlibs: [
|
|
"-framework AppKit",
|
|
],
|
|
},
|
|
windows: {
|
|
enabled: true,
|
|
cflags: [
|
|
"-D_LIBCPP_ENABLE_CXX17_REMOVED_AUTO_PTR",
|
|
"-Wno-null-arithmetic",
|
|
"-Wno-sign-compare",
|
|
"-Wno-tautological-pointer-compare",
|
|
"-Wno-unknown-pragmas",
|
|
],
|
|
static_libs: ["libcompiler_rt-extras"],
|
|
},
|
|
},
|
|
|
|
export_include_dirs: ["source"],
|
|
}
|
|
|
|
// dng sdk validating version static library
|
|
// This version will print out validation warnings/errors to stderr
|
|
// and is built against the NDK for use with CTS
|
|
// ========================================================
|
|
|
|
cc_library_static {
|
|
name: "libdng_sdk_validate",
|
|
defaults: ["libdng_sdk-defaults"],
|
|
|
|
cflags: ["-DqDNGValidate=1"],
|
|
|
|
static_libs: ["libjpeg_static_ndk"],
|
|
shared_libs: ["libz"],
|
|
|
|
export_include_dirs: ["source"],
|
|
|
|
sdk_version: "24",
|
|
stl: "c++_static",
|
|
}
|
|
|
|
// dng sdk unittests for target
|
|
// ========================================================
|
|
|
|
cc_binary {
|
|
name: "dng_validate",
|
|
defaults: ["libdng_sdk-defaults"],
|
|
srcs: ["source/dng_validate.cpp"],
|
|
|
|
cflags: ["-DqDNGValidate=1"],
|
|
|
|
shared_libs: [
|
|
"libz",
|
|
"libjpeg",
|
|
],
|
|
}
|
|
|
|
cc_binary_host {
|
|
name: "dng_validate_host",
|
|
defaults: ["libdng_sdk-defaults"],
|
|
srcs: ["source/dng_validate.cpp"],
|
|
|
|
cflags: ["-DqDNGValidate=1"],
|
|
|
|
shared_libs: [
|
|
"libz",
|
|
"libjpeg",
|
|
],
|
|
|
|
target: {
|
|
darwin: {
|
|
enabled: false, // b/67474260
|
|
},
|
|
},
|
|
}
|