summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Deymo2017-01-11 16:37:50 -0600
committerAlex Deymo2017-01-11 21:15:11 -0600
commitb0c395955df706c4c453c0dddc13a4f5f7ca44bf (patch)
treeea2e84033641e0b12a59d0d47a6dcef35e37ec44 /libsparse
parent705353ae277e408e70169c0811c5d104a3b733f6 (diff)
downloadplatform-system-core-b0c395955df706c4c453c0dddc13a4f5f7ca44bf.tar.gz
platform-system-core-b0c395955df706c4c453c0dddc13a4f5f7ca44bf.tar.xz
platform-system-core-b0c395955df706c4c453c0dddc13a4f5f7ca44bf.zip
Remove "_host" and "_static" suffix from libsparse definition.
This now combines all the "libsparse" libraries into the same soong target. A minor side-effect of this change is that the libsparse static library depends on the libz shared library instead of the libz static library. This minor change has no effect since targets using the static libsparse library need to explicitly include either the static libz or the shared one. Bug: 34220783 Change-Id: I8f41586cf4c3336791cfa57ab4f5ae59a76d7ffa
Diffstat (limited to 'libsparse')
-rw-r--r--libsparse/Android.bp37
1 files changed, 13 insertions, 24 deletions
diff --git a/libsparse/Android.bp b/libsparse/Android.bp
index 7a6ae8a54..dd8b5fd1d 100644
--- a/libsparse/Android.bp
+++ b/libsparse/Android.bp
@@ -1,7 +1,9 @@
1// Copyright 2010 The Android Open Source Project 1// Copyright 2010 The Android Open Source Project
2 2
3cc_defaults { 3cc_library {
4 name: "libsparse_defaults", 4 name: "libsparse",
5 host_supported: true,
6 unique_host_soname: true,
5 srcs: [ 7 srcs: [
6 "backed_block.c", 8 "backed_block.c",
7 "output_file.c", 9 "output_file.c",
@@ -13,32 +15,19 @@ cc_defaults {
13 cflags: ["-Werror"], 15 cflags: ["-Werror"],
14 local_include_dirs: ["include"], 16 local_include_dirs: ["include"],
15 export_include_dirs: ["include"], 17 export_include_dirs: ["include"],
16}
17
18cc_library_host_static {
19 name: "libsparse_host",
20 defaults: ["libsparse_defaults"],
21 static_libs: ["libz"],
22 target: { 18 target: {
19 host: {
20 shared_libs: ["libz-host"],
21 },
22 android: {
23 shared_libs: ["libz"],
24 },
23 windows: { 25 windows: {
24 enabled: true, 26 enabled: true,
25 }, 27 },
26 }, 28 },
27} 29}
28 30
29cc_library_shared {
30 name: "libsparse",
31 defaults: ["libsparse_defaults"],
32 shared_libs: ["libz"],
33}
34
35cc_library_static {
36 name: "libsparse_static",
37 host_supported: true,
38 defaults: ["libsparse_defaults"],
39 static_libs: ["libz"],
40}
41
42cc_binary { 31cc_binary {
43 name: "simg2img", 32 name: "simg2img",
44 host_supported: true, 33 host_supported: true,
@@ -47,7 +36,7 @@ cc_binary {
47 "sparse_crc32.c", 36 "sparse_crc32.c",
48 ], 37 ],
49 static_libs: [ 38 static_libs: [
50 "libsparse_static", 39 "libsparse",
51 "libz", 40 "libz",
52 ], 41 ],
53 42
@@ -59,7 +48,7 @@ cc_binary {
59 host_supported: true, 48 host_supported: true,
60 srcs: ["img2simg.c"], 49 srcs: ["img2simg.c"],
61 static_libs: [ 50 static_libs: [
62 "libsparse_static", 51 "libsparse",
63 "libz", 52 "libz",
64 ], 53 ],
65 54
@@ -70,7 +59,7 @@ cc_binary_host {
70 name: "append2simg", 59 name: "append2simg",
71 srcs: ["append2simg.c"], 60 srcs: ["append2simg.c"],
72 static_libs: [ 61 static_libs: [
73 "libsparse_static", 62 "libsparse",
74 "libz", 63 "libz",
75 ], 64 ],
76 65