Files
build/tools/zipalign/Android.bp
Elliott Hughes c2039151ba Run zipalign tests in presubmit.
Test: treehugger
Change-Id: I2779c04313976d29c29c50920c0b356309c08439
2020-11-05 16:37:40 -08:00

70 lines
1.3 KiB
Plaintext

//
// Copyright 2008 The Android Open Source Project
//
// Zip alignment tool
//
cc_defaults {
name: "zipalign_defaults",
target: {
windows: {
host_ldlibs: ["-lpthread"],
enabled: true,
},
},
}
cc_library_host_static {
name: "libzipalign",
srcs: [
"ZipAlign.cpp",
"ZipEntry.cpp",
"ZipFile.cpp",
],
export_include_dirs: [
"include",
],
cflags: ["-Wall", "-Werror"],
// NOTE: Do not add any shared_libs dependencies because they will break the
// static_sdk_tools target.
whole_static_libs: [
"libutils",
"libcutils",
"liblog",
"libziparchive",
"libz",
"libbase",
"libzopfli",
],
defaults: ["zipalign_defaults"],
}
cc_binary_host {
name: "zipalign",
srcs: [
"ZipAlignMain.cpp",
],
cflags: ["-Wall", "-Werror"],
static_libs: [
"libzipalign",
],
defaults: ["zipalign_defaults"],
}
cc_test_host {
name: "zipalign_tests",
srcs: [
"tests/src/*_test.cpp",
],
static_libs: [
"libzipalign",
"libgmock",
],
data: [
"tests/data/unaligned.zip",
],
defaults: ["zipalign_defaults"],
test_suites: ["general-tests"],
}