Commit graph

18778 commits

Author SHA1 Message Date
Jooyung Han
7556839772 Enforce apex.min_sdk_version for bundled builds
Previously, when Q-targeting apexes are bundled-built, they are built
against the latest stubs.

It was because unwinder is linked dynamically in R and APIs are provided
by libc while Q apexes should run on Q where libc doesn't provide those
APIs. To make Q apexes run on Q device, libc++ should be linked with
static unwinder. But, because libc++ with static unwinder may cause problem
on HWASAN build, Q apexes were built against the latest stubs for bundled
build.

However, Q apexes should be built against Q stubs.

Now, only for HWASAN builds, Q apexes are built against the latest stubs
(and native modules are not linked with static unwinder).

Bug: 151912436
Test: TARGET_SANITIZE=hwaddress m
      => Q apexes(media, resolv, ..) are linked with the latest stubs
      m
      => Q apexes are linked with Q stubs,
         and Q apexes' libc++ is linked with static unwinder
Merged-In: If32f1b547e6d93e3955c7521eec8aef5851f908c
Change-Id: If32f1b547e6d93e3955c7521eec8aef5851f908c
(cherry picked from commit 7406660685)

Exempt-From-Owner-Approval: cp from internal
Change-Id: If32f1b547e6d93e3955c7521eec8aef5851f908c
2020-04-02 03:34:30 +00:00
Paul Duffin
4ac530d4c7 Merge "Allow walkPayloadDeps visitor to control walk flow" 2020-04-01 17:54:04 +00:00
David Srbecky
20d854948b Merge "Adjust embedded dex locations in host boot image." 2020-04-01 15:42:29 +00:00
Jiyong Park
1cda30e211 Merge "Remove some apex_available whitelist" 2020-04-01 13:03:10 +00:00
David Srbecky
ab99498ea1 Adjust embedded dex locations in host boot image.
ART tests require that "out/host/linux-x86" is included.

This requires making the dexLocations per-variant specific.

Test: m test-art-host-gtest
Bug: 147817558
Bug: 147819342
Change-Id: I7839ee15cb6dfc62508bdd3fa0f306336af17055
2020-04-01 12:06:56 +01:00
Paul Duffin
be5a5be549 Allow walkPayloadDeps visitor to control walk flow
Delegate the responsibility for determining whether the
walkPayloadDeps() should visit a child dependency to its do function.
This is needed to allow the visitor in checkApexAvailability() to avoid
checking the apex_available setting after crossing the APEX boundary.

Bug: 152878661
Test: m droid
Change-Id: If46a2f74b6eca670befc3aeae430650e85542346
2020-04-01 09:30:31 +01:00
Dan Shi
7182c45fe7 Merge "Rename VTS to VTS10" 2020-03-31 17:32:34 +00:00
Bill Peckham
0ad0e940c0 Merge "Include partition tag in apexkeys.txt." 2020-03-31 13:42:30 +00:00
satayev
b7f5c22ee4 Merge "Use modular removed-dex.txt files for greylisting." 2020-03-31 12:24:10 +00:00
Nicolas Geoffray
32e89ddb60 Merge "Update owners of build-aml-prebuilts.sh." 2020-03-31 09:08:35 +00:00
Paul Duffin
545d958508 Merge "Add apex_available to sysprop_library" 2020-03-31 09:06:58 +00:00
Paul Duffin
4db3298d34 Merge "Improve missing apex_available message" 2020-03-31 09:06:42 +00:00
Paul Duffin
33050c13c0 Merge "Split TestApexAvailable into separate tests" 2020-03-31 09:06:31 +00:00
Hsin-Yi Chen
74b2c7cb38 Merge "Fix the logic for selecting ABI dump paths" 2020-03-31 02:30:55 +00:00
Bill Peckham
fff3f8a3f8 Include partition tag in apexkeys.txt.
The partition tag helps merge_target_files.py determine
which apexkeys.txt to select from the framework partial
target files and which to select from the vendor partial
target files. The partition tag is the pysical partition
name, for example, a system_ext module on a device where
system_ext is at system/system_ext has a system
partition tag.

Bug: 138942268
Change-Id: Ia07887b34f1aa77dae94ef23610dfef83c1a5849
2020-03-30 22:33:50 +00:00
Paul Duffin
7b3de8f85b Add apex_available to sysprop_library
Added apex_available support to sysprop_library and copied it onto the
underlying cc_library.

Bug: 152762638
Test: m nothing
Change-Id: I8f4c539532b48f3a45c1fbf0f7287db11df69d2f
2020-03-30 18:43:39 +01:00
Paul Duffin
df915ff3db Improve missing apex_available message
The apex available check can traverse quite a long path (5+ steps) to
get from the apex to a module that is missing the apex from its
apex_available property. Understanding where that dependency came from
can often require examining the dependency path which can be difficult.
This change adds the path to the error to simplify that process.

Test: m nothing
Bug: 152762638
Change-Id: Ic4eb169dc2026cd8339d49e23b25d6d1c3879750
2020-03-30 18:43:39 +01:00
Paul Duffin
e52e66fba0 Split TestApexAvailable into separate tests
Having multiple tests within one method makes debugging specific
failures more difficult so this change split the TestApexAvailable
test into multiple separate tests.

Test: m nothing
Bug: 152762638
Change-Id: I2b2408ef515fd79c078686ef29a6ee8fb0407e7e
2020-03-30 18:43:39 +01:00
Artur Satayev
c7fb5c9964 Use modular removed-dex.txt files for greylisting.
Use droidstubs for public and system stubs to provide a list of @removed APIs. As these APIs are not present in the stubs, they are not whitelisted / greylised automatically. Keep them on greylist manually.

Bug: 143864733
Test: diff out/soong/hiddenapi/hiddenapi-flags.csv
Change-Id: I4c8e6899fadfdfd1da82f6f453cc92e71aa9b78c
2020-03-30 17:25:13 +01:00
Nicolas Geoffray
90934f7177 Update owners of build-aml-prebuilts.sh.
Test: N/A
Change-Id: Ie5be75f90be00db5adeaa40662e26a92c66d1b05
2020-03-30 14:23:13 +01:00
Dan Shi
984c129c84 Rename VTS to VTS10
Bug: 151896491
Test: m -j vts10
Change-Id: I7b70b13401678d70e4b46f9e7eb9d844bcfa315e
2020-03-28 16:42:17 -07:00
Jiyong Park
58d1090032 Don't run apex_available check for coverage builds
Coverage build adds extra dependencies for the runtime libs. Marking
them and their transitive dependenciese with apex_available doesn't make
any value; it instead adds noise.

Bug: 150999716
Test: m
Change-Id: I08e51cec1de6ded624ef9d4c41c1e5b2e611ff38
2020-03-28 14:43:19 +09:00
Evgenii Stepanov
995bccfad2 Merge "Revert "Reenable the new pass manager in hwasan builds."" 2020-03-27 20:17:33 +00:00
Evgenii Stepanov
96fa3dd0af Revert "Reenable the new pass manager in hwasan builds."
This reverts commit 259eaab3b3.

Reason for revert: breaks hwasan + gcov

Bug: 135298400
Change-Id: Ie8574753f9237a55ad1618783bd5150ffb646015
2020-03-27 19:42:01 +00:00
David Srbecky
2d557ced02 Merge "Fix dump-oat-boot build target." 2020-03-27 16:12:22 +00:00
Jaewoong Jung
87a33e72bc Add code coverage support to android_app JNI libs.
Test: Built mainline module coverage data
Bug: 152117890
Change-Id: I47bf3e5d6e78c4518729bdb52616e248156d3cec
2020-03-27 01:39:54 +00:00
Yi Kong
365d107dd3 Merge "Add platform-wide sampling PGO option" 2020-03-27 01:17:26 +00:00
Evgenii Stepanov
910dc607b1 Merge "Reenable the new pass manager in hwasan builds." 2020-03-26 21:52:06 +00:00
Treehugger Robot
ac66c74a58 Merge "Implement sysprop type checker" 2020-03-26 21:22:26 +00:00
Treehugger Robot
49bd9cc371 Merge "[cc_fuzz] Export DSO symbols to /symbols/data/" 2020-03-26 20:54:33 +00:00
Treehugger Robot
730181c909 Merge "Add no-canonical-prefixes to make sure paths in .d file are relative paths" 2020-03-26 20:08:13 +00:00
Martin Stjernholm
ca703b6c7a Merge "Don't run new test on Darwin that lacks snapshot support." 2020-03-26 17:49:37 +00:00
Martin Stjernholm
66a06945aa Don't run new test on Darwin that lacks snapshot support.
Test: m nothing
Bug: 152514829
Bug: 152255951
Change-Id: Ib14af7caa408e252242e6933f7281aab3888789c
2020-03-26 17:39:30 +00:00
David Srbecky
1aacc6c3df Fix dump-oat-boot build target.
Implement support of dumping host boot.art.

That was not possible before because imageLocation is different on host.

This CL makes imageLocation per-variant so can access for the host variant.

Test: m dump-oat-boot
Change-Id: Id82161e4901a6b77f220238aec460b8609fd765f
2020-03-26 15:28:27 +00:00
Hsin-Yi Chen
27d235f918 Fix the logic for selecting ABI dump paths
A library may have both VNDK variant and stubs. getRefAbiDumpFile should
differentiate its vendor and core variants.

Bug: 152277104
Test: Add dumps to platform/ and vndk/ ; make libselinux.vendor libselinux
Change-Id: Iad038cf4cd3eccc3dfbef13fab67da044498ce77
2020-03-26 18:09:30 +08:00
Treehugger Robot
d9578f563e Merge "Propagate empty vs unspecified system_shared_libs correctly." 2020-03-26 09:40:15 +00:00
Anton Hansson
282dc32fb6 Merge "Default droiddoc to disting the api txt if there is one" 2020-03-26 08:40:46 +00:00
Kousik Kumar
fb0e251f30 Add no-canonical-prefixes to make sure paths in .d file are relative paths
Test: Ran "m out/soong/.intermediates/system/netd/bpf_progs/clatd.o/android_common/obj/system/netd/bpf_progs/clatd.o"
and verified that the output .d file did NOT contain absolute paths.

Change-Id: I2d187638eb7a6db8de057b83312cba3116985ac8
2020-03-25 16:44:13 -07:00
Martin Stjernholm
10566a035f Propagate empty vs unspecified system_shared_libs correctly.
Necessary to get correct prebuilts for many Bionic libs.

Cleaned up numerious "system_shared_libs: []" from test fixtures, since
they otherwise would need correction in the expected results, and it is
better to have a single test focused on testing system_shared_libs
propagation.

Test: m nothing
Bug: 152255951
Change-Id: If2e8a5296223e6281d833312660e8e9e4cd184c0
2020-03-25 23:19:37 +00:00
Treehugger Robot
38a2e3cb92 Merge "Add a major incremental build scenario to cuj metrics." 2020-03-25 16:59:16 +00:00
Patrice Arruda
f326139678 Add a major incremental build scenario to cuj metrics.
The mentioned scenario in b/152046247 would help to detect if there
is an incremental build issue.

Bug: b/145688720
Test: * m cuj_tests
      * Ran the cuj_tests and verified that the Intent.java file was
         touched. Unmarshalled the cuj_metrics.pb file and check if
	 the added scenario existed.
Change-Id: Ic6c335f005568dd77c99e4e1762383ec76d57ecb
2020-03-25 08:03:00 -07:00
Anton Hansson
f6aead085c Merge "Make system_server stubs consistent with other stubs" 2020-03-25 14:18:32 +00:00
Anton Hansson
ba6ab2e791 Make system_server stubs consistent with other stubs
Include the module_api stubs in system_server one instead of
putting both of these jars on the classpath. Also rename it
to be in line with the other stubs.

Bug: 149293194
Test: m
Exempt-From-Owner-Approval: approved internally
Change-Id: Iead5af4152a49cd59a4fd7afc0312c2f0c872c1e
Merged-In: Iead5af4152a49cd59a4fd7afc0312c2f0c872c1e
(cherry picked from commit bbd78556da)
2020-03-25 14:18:02 +00:00
Treehugger Robot
5e9cf02ab5 Merge "add aidl.export_include_dirs to java_import module type" 2020-03-25 09:55:12 +00:00
Inseob Kim
628d7ef0c7 Implement sysprop type checker
sysprop type checker compares a sysprop_library API file and
property_contexts files, and detects if there are any mismatches of
property types. For example, the following snippets are detected.

// foo.sysprop
prop {
prop_name: "ro.foo.bar"
type: Integer
...
}

// property_contexts
ro.foo.bar u:object_r:foo_prop:s0 exact string

"ro.foo.bar" is an Integer in .sysprop file, but it's a string in
property_contexts file.

Bug: 151879375
Test: sysprop_test
Test: run "m PlatformProperties" and see existing mismatches.
Change-Id: Iad86d0770011e13a6d8f3e9596e730200942e3fd
2020-03-25 11:10:49 +09:00
Jooyung Han
eb4d9f2d68 Merge changes from topic "reland-llndk-sdk-enforcement"
* changes:
  Pass min_sdk_version to cc __ANDROID_SDK_VERSION__
  Revert "Revert "Enforce min_sdk_version of apex(use_vendor:true)""
2020-03-25 00:52:40 +00:00
Treehugger Robot
5f1d031679 Merge "More fix for -e" 2020-03-24 23:16:32 +00:00
Bob Badour
0d3d8e40c1 More fix for -e
Not sure whether sort, tr or xargs returning non-zero status, but
one of them sometimes does.

Test: manually

Change-Id: I8f2b862de9d6e22dd90068252e393533ec992dfd
2020-03-24 13:42:43 -07:00
Ulya Trafimovich
55285bab77 Don't append build directory to the output path twice.
Soong already uses build directory as a part of the generated output
path. Besides, trying to append it second time breaks if the build
directory is an absolute path.

Test: frameworks/rs/build_rs.py  (uses absolute build directory path)
Test: walleye-userdebug boots

Bug: 152235239
Change-Id: Ie03c9e688013b9a3e6bc859c936d89c538ded76a
Merged-In: Ie03c9e688013b9a3e6bc859c936d89c538ded76a
(cherry picked from commit f798c3ec32)
2020-03-24 17:02:19 +00:00
Yi Kong
ceb5b76c91 Add platform-wide sampling PGO option
This causes the compiler to emit some additional debug infomation that
will be used for sampling PGO. These debug infomation will get stripped
so it only affects intermediate files.

Test: build
Bug: 79161490
Change-Id: Ie4d1d5ffbd311ba6e268cb94a618f5272be246ef
2020-03-24 07:04:54 -07:00