Commit graph

9383 commits

Author SHA1 Message Date
Jiyong Park
ce16f3bac8 Merge "Stubs variant is used when building for APEX" 2018-12-04 14:07:56 +00:00
Yi Kong
3a33fe535e Merge "Revert "Revert "Remove unnecessary warning suppression""" 2018-12-04 09:30:54 +00:00
Jiyong Park
25fc6a9cc9 Stubs variant is used when building for APEX
When a native module is built for an APEX and is depending on a native
library having stubs (i.e. stubs.versions property is set), the stubs
variant is used unless the dependent lib is directly included in the
same APEX with the depending module.

Example:

apex {
    name: "myapex",
    native_shared_libs: ["libX", "libY"],
}

cc_library {
    name: "libX",
    shared_libs: ["libY", "libZ"],
}

cc_library {
    name: "libY",
    stubs: { versions: ["1", "2"], },
}

cc_library {
    name: "libZ",
    stubs: { versions: ["1", "2"], },
}

In this case, libX is linking to the impl variant of libY (that provides
private APIs) while libY is linking to the version 2 stubs of libZ. This is
because libY is directly included in the same apex via
native_shared_libs property, but libZ isn't.

Bug: 112672359
Test: apex_test added
Change-Id: If9871b70dc74a06bd828dd4cd1aeebd2e68b837c
2018-12-04 17:46:22 +09:00
Treehugger Robot
2098eb8c2a Merge "VNDK lib must not have product_specific: true" 2018-12-04 08:39:35 +00:00
Treehugger Robot
990b4b6e7e Merge changes from topic "python_entry_point"
* changes:
  python par: trim and convert the entry point at build time
  Fix par file zip offsets
2018-12-04 07:11:23 +00:00
Dan Willemsen
6f3e24ab55 Merge "Apply system_shared_libs to static libraries" 2018-12-04 06:19:08 +00:00
Justin Yun
9357f4aeda VNDK lib must not have product_specific: true
VNDK libs are system defined libraries. They must not be product
specific. Adding sanity check and a test to prevent setting
`product_specific: true` on VNDK libs.

Bug: 119575107
Test: building a vndk lib with 'product_specific: true,'
      must return error.

Change-Id: Ie0326540a692573f076ee08baf5d2e2f09d1007e
2018-12-04 14:10:59 +09:00
Yi Kong
734a07c66d Revert "Revert "Remove unnecessary warning suppression""
This reverts commit afedf3bdc9.

Build failure fixed.

Change-Id: I46e7e222c2b5bfa5b1846f3fe87444afb70f1b31
2018-12-04 00:42:27 +00:00
Dan Willemsen
54c5b61f0a python par: trim and convert the entry point at build time
Instead of doing these string operations in the C++ code at every
startup of an embedded par, trim and convert the entry point file to a
python module path at build time.

Test: m
Change-Id: I04a6459a80c84a704b8a25a144ab1e19622d6cc3
2018-12-03 15:58:45 -08:00
Dan Willemsen
263dde779e Fix par file zip offsets
The zip file format does support scripts/programs prefixed to the
archive, though many of the offsets are supposed to start from the
beginning of the file. Some tools (python and zipinfo) are able to
read zip files with arbitrary prefixes, but others (libziparchive and
zipdetails) fail.

So pass the file to prefix onto the zip file into merge_zips so that we
can set the offsets from the real start of the file.

Test: m sepolicy_tests  (runs the embedded python interpreter)
Test: zipinfo out/host/linux-x86/bin/sepolicy_tests
Test: zipdetails out/host/linux-x86/bin/sepolicy_tests
Change-Id: If73d4c2465581f7de5aa47959284ecf2059df091
2018-12-03 15:55:15 -08:00
Dan Willemsen
3a26eefdbe Apply system_shared_libs to static libraries
Even though we aren't doing any linking for static libraries, the
default libraries (libc, libm, libdl) are now exporting headers, so we
should be using those for both static and shared libraries (especially
when re-using objects between the two). Without this we've been in a
state where a cc_library will compile differently than a
cc_library_shared, as we'd re-use the compilation units from the static
variant in the shared library.

This does require marking many of libc's dependencies as not using libc
with system_shared_libs, otherwise we run into dependency loops.

Test: treehugger
Change-Id: Ie42edc5184f315f998db953594e425214b810e0e
2018-12-03 15:38:39 -08:00
Treehugger Robot
314d8c142c Merge "Move setsid(1) to toybox." 2018-12-03 21:49:53 +00:00
Treehugger Robot
5b46a085d7 Merge "Add sanitizer runtime library to recovery when needed." 2018-12-03 20:42:37 +00:00
Treehugger Robot
89df00c216 Merge "Do not generate SHT_RELR relocations before API 28" 2018-12-03 18:40:59 +00:00
Elliott Hughes
5728fb536f Move setsid(1) to toybox.
Test: treehugger
Change-Id: I8caf9dbbb671218379c309e698f23e7c964f1a18
2018-12-03 10:14:52 -08:00
Treehugger Robot
ddefe27f12 Merge "Move tee(1) to toybox." 2018-12-03 18:08:32 +00:00
Pirama Arumuga Nainar
7ef2700761 Merge "Use libucrt instead of libmsvcr110" 2018-12-03 17:53:43 +00:00
Yi Kong
cf492adb34 Merge "Revert "Remove unnecessary warning suppression"" 2018-11-30 23:20:11 +00:00
Jaewoong Jung
acb51e1015 Merge "Use debug mode when running R8 for eng builds." 2018-11-30 22:40:29 +00:00
Zhizhou Yang
9100b1d83d Do not generate SHT_RELR relocations before API 28
This patch fixes an issue that SHR_RELR relocation is not supported by
SDK version earlier than API 28. We only turn it on when SDK is not
used, or SDK version is newer than or equal to API 28.

Test: m -j48 for aosp_taimen-userdebug
Bug: http://b/119086751
Change-Id: I33124ae4f35fb8c00ae9103e8c04e2d4ccd5fec3
2018-11-30 22:07:35 +00:00
Elliott Hughes
3633e8641e Merge "C++17: switch the default." 2018-11-30 22:03:45 +00:00
Pirama Arumuga Nainar
087bba7356 Use libucrt instead of libmsvcr110
Bug: http://b/117796718

ucrt is either preinstalled in newer Windows or can be installed in
older Windows, whereas a dependence on msvcr110 doesn't work on Windows
without additional dependencies.

Test: Run generated binaries on Windows VM (7, 8, and 10) without
installing any extra dependencies.

Change-Id: Ibfaea5d78ac85ff4eeed35c97ad8cae4b44dadbc
2018-11-30 21:42:33 +00:00
Vishnu Nair
afedf3bdc9 Revert "Remove unnecessary warning suppression"
This reverts commit ee53a98e31.

Reason for revert: build break

Change-Id: I065b702d6eaa2e72d47a2b7a404fdd7fe51661c3
2018-11-30 21:01:30 +00:00
Elliott Hughes
1ff2b5d34c Move tee(1) to toybox.
Test: treehugger
Change-Id: Idf7fc37d6e84c295410f71dfc1ad9e460d7f7461
2018-11-30 12:36:44 -08:00
Treehugger Robot
3b67794d7f Merge "Move xxd(1) to toybox." 2018-11-30 20:14:35 +00:00
Yi Kong
da5cf6a7f3 Merge "Remove unnecessary warning suppression" 2018-11-30 19:24:35 +00:00
Elliott Hughes
34e4e416e7 C++17: switch the default.
Bug: http://b/111067277
Change-Id: I07af7cd9e65a6e238d7d256c65927fe128a0f052
Test: builds
2018-11-30 16:03:06 +00:00
Jaewoong Jung
1d6eb68731 Use debug mode when running R8 for eng builds.
Bug: 119601874
Test: Built for different variants.
Change-Id: I2250587eb3e457ca15265eb9f8359872e9b08363
2018-11-30 15:23:16 +00:00
Nikita Iashchenko
a9e5a40bb8 Merge "Revert "C++17: switch the default."" 2018-11-30 14:27:16 +00:00
Jerome Gaillard
ba0653cdb4 Merge "Add flags for Windows assembly builds" 2018-11-30 12:30:06 +00:00
Nikita Iashchenko
7a782203b9 Revert "C++17: switch the default."
This reverts commit c35fc0e130.

Reason for revert: fix broken targets in the internal master.

Change-Id: I70447a05ae5b2afa7efc7ab21c0432e651cab1ba
2018-11-30 11:15:16 +00:00
Anton Hansson
6641b97d13 Merge "Remove obsolete flag" 2018-11-30 09:11:28 +00:00
Treehugger Robot
b44bdb2be3 Merge "C++17: switch the default." 2018-11-30 08:06:02 +00:00
Elliott Hughes
f3f3b99bb3 Move xxd(1) to toybox.
Test: treehugger
Change-Id: I906b0c94da5b65dc387ae253492356ca78f93fd2
2018-11-29 22:04:16 -08:00
Treehugger Robot
ca62abc776 Merge "Move paste(1) to toybox." 2018-11-30 01:06:08 +00:00
Evgenii Stepanov
98f5b0642c Add sanitizer runtime library to recovery when needed.
Make sanitized targets in recovery depend on ".recovery" flavor of
sanitizer runtime library. This forces installation of the runtime
library in recovery image as long as at least one target depends on it.

Test: hwasan build can boot into recovery
Bug: 112438058
Bug: 119582521
Change-Id: I1b7f9fa4ff5f29acb03c27074512ea24467a3d37
2018-11-29 23:22:20 +00:00
Treehugger Robot
42f19a7987 Merge "Change srcjarDir/stubsDirs to a different name." 2018-11-29 22:22:15 +00:00
Elliott Hughes
15f2dfe482 Move paste(1) to toybox.
Test: treehugger
Change-Id: Id5e8e841406357d8301198eb433b96d2f1ba02d9
2018-11-29 11:36:51 -08:00
Treehugger Robot
47ff60e136 Merge "Move rmdir(1) to toybox." 2018-11-29 19:13:32 +00:00
Nan Zhang
3ffc352545 Change srcjarDir/stubsDirs to a different name.
Otherwise it might have the chance to clobber each other
if the rules ran at the same time.

Test: m -j docs
Bug: b/119671939
Change-Id: Ia57e62f0899e5c61539516833c6e3db88547932e
2018-11-29 10:42:47 -08:00
Ivan Lozano
a6703fe6b7 Merge "Disable AArch64 XOM when not using lld." 2018-11-29 15:58:39 +00:00
Jerome Gaillard
80fec097b1 Add flags for Windows assembly builds
This is necessary to build libjpeg for Windows.

Test: lunch sdk, make libjpeg
Change-Id: I6ace0e524d1d710b5ce78320e7a06777511d1634
2018-11-29 15:47:31 +00:00
Anton Hansson
7dbfd82346 Remove obsolete flag
Last use removed in Ibefde5feaeaec8fb68cbc6ea1c019bf8b5e608bb

Test: make
Change-Id: Icd4273b2ab472758ce0fbc237c294960ee16685d
2018-11-29 10:08:14 +00:00
Stephen Hines
c027b309f1 Merge "Support Qualcomm Kryo 385 CPU variant." 2018-11-29 07:23:40 +00:00
Elliott Hughes
c35fc0e130 C++17: switch the default.
Bug: http://b/111067277
Test: builds
Change-Id: I5065b03218772bf8cf8173f3d9808b3f0a484dc5
2018-11-28 21:45:23 -08:00
Bill Yi
25ce2ab6bf Merge pi-qpr1-release PQ1A.181105.017.A1 to pi-platform-release
Change-Id: Id26c628ad766809fd69076b6840d684d6fcfb6d4
2018-11-28 18:33:29 -08:00
Elliott Hughes
4afedfadb2 Merge "Bump "experimental" C++ to C++2a." 2018-11-29 01:48:54 +00:00
Treehugger Robot
abe477a33a Merge "Allow NDK APIs to be marked as drafts." 2018-11-28 23:11:06 +00:00
Elliott Hughes
37976122aa Bump "experimental" C++ to C++2a.
C++17 is so last year.

Test: treehugger
Change-Id: Ifd5e6d4a4837fe037837c49c31ee2fe1499e2d79
2018-11-28 14:16:39 -08:00
Elliott Hughes
716fa36dd9 Move rmdir(1) to toybox.
Test: treehugger
Change-Id: Ibb43f09c0cfcda631025ef0fea4730519a3b6fe6
2018-11-28 14:14:35 -08:00