blob: 1cd52304afe0951b74d512749ca5442376950763 [file] [log] [blame]
Jesse Hall081806e2017-02-11 22:50:02 -08001ndk_headers {
2 name: "libsync_headers",
3 from: "include/ndk",
4 to: "android",
5 srcs: ["include/ndk/sync.h"],
6 license: "NOTICE",
7}
8
9ndk_library {
Steven Morelanddb9b2602017-04-10 12:58:03 -070010 name: "libsync",
Jesse Hall081806e2017-02-11 22:50:02 -080011 symbol_file: "libsync.map.txt",
12 first_version: "26",
13}
14
Dan Willemsen194edf72016-08-26 15:01:36 -070015cc_defaults {
16 name: "libsync_defaults",
17 srcs: ["sync.c"],
18 local_include_dirs: ["include"],
19 export_include_dirs: ["include"],
20 cflags: ["-Werror"],
21}
22
23cc_library_shared {
24 name: "libsync",
Steven Morelandd0b26ed2017-04-13 23:27:20 -070025 vendor_available: true,
Justin Yun48647f62017-07-26 13:25:27 +090026 vndk: {
27 enabled: true,
28 },
Dan Willemsen194edf72016-08-26 15:01:36 -070029 defaults: ["libsync_defaults"],
30}
31
32// libsync_recovery is only intended for the recovery binary.
33// Future versions of the kernel WILL require an updated libsync, and will break
34// anything statically linked against the current libsync.
35cc_library_static {
36 name: "libsync_recovery",
37 defaults: ["libsync_defaults"],
38}
39
40cc_test {
41 name: "sync_test",
42 defaults: ["libsync_defaults"],
43 gtest: false,
44 srcs: ["sync_test.c"],
45}
46
47cc_test {
48 name: "sync-unit-tests",
49 shared_libs: ["libsync"],
50 srcs: ["tests/sync_test.cpp"],
51 cflags: [
52 "-g",
53 "-Wall",
54 "-Werror",
Dan Willemsen194edf72016-08-26 15:01:36 -070055 "-Wno-missing-field-initializers",
56 "-Wno-sign-compare",
57 ],
58 clang: true,
59}