Commit Graph

3749 Commits

Author SHA1 Message Date
Ramy Medhat
8af6b81a91 Merge "Run non-RBE supported actions in the local pool when USE_RBE is set." am: 75c82fb518 am: a64d8aecff
am: 60cac6c7a3

Change-Id: Iae99c1271d90a265e1d34594595c6e92830e8bc7
2019-11-06 11:19:54 -08:00
Ramy Medhat
75c82fb518 Merge "Run non-RBE supported actions in the local pool when USE_RBE is set." 2019-11-06 18:36:18 +00:00
Jiyong Park
3d7b69a657 Rename # vndk tag to # llndk
The APIs that are tagged with # vndk are actually for LLNDK libraries.
Although LLNDK is part of VNDK, calling those APIs 'vndk' has given
users a wrong perception that the APIs don't need to be kept stable
because that's the norm for most of the VNDK libraries that are not
LLNDK.

In order to eliminate the misunderstanding, rename the tag to 'llndk' so
that people introducing new such API will realize what they are signing
themselves up for.

Bug: 143765505
Test: m
Test: python3 test_gen_stub_libs.py
Change-Id: I2853df3b6e245056c21d4ab3d62466954cf26d72
2019-11-06 12:43:47 +09:00
Fabien Sanglard
33ca8080e5 Fix Soong CMakeLists.txt generator
Problem: Soong does not guarantee that the list of parameters will
be in individual strings. This means the CMakeLists generator can
receive as input:

  params = {"-isystem", "path/to/system"}

or it could receive:

  params = {"-isystem path/to/system"}

Solution: Normalize the list of parameters into a flattened list
of parameters where each parameters is in an individual string.

Fixes: 143378093
Test: None
Change-Id: I9bd1a2006a1cf0ba383f467748b6fd4eadef6866
2019-11-05 16:26:37 -08:00
Martin Stjernholm
f4ed8df84d Recognize libdl_android as a Bionic library.
Necessary to create the symlinks from /system/lib{,64} to the Runtime APEX.

Test: build & boot
Bug: 135753770
Change-Id: I231b4ec48869843de233ebb7c2e4fc5a49e7288a
2019-11-06 00:22:37 +00:00
Ramy Medhat
dd0418a4d4 Run non-RBE supported actions in the local pool when USE_RBE is set.
Bug: 143938974
Test: ran CTS build at -j500 successfully.
Change-Id: I55074bd67308cd716972e24fb56a20bc393d5d9d
2019-11-05 22:57:35 +00:00
Inseob Kim
bc27c76b1a Merge "Fix and generate vndk snapshot entirely in Soong" am: fe0c50e0d0 am: 44df62da53
am: b80ee9d09b

Change-Id: I6912b1fcda6ef30ff0119e924e1584371d5516d7
2019-11-05 10:44:10 -08:00
Inseob Kim
242ef0c4de Fix and generate vndk snapshot entirely in Soong
- VNDK snapshot now respects stem and suffix.
- ld.config.txt is removed from snapshot as linkerconfig has become default.
- Soong builds entire snapshot, and make just calls dist-for-goals.

Bug: 142589718
Test: build and install snapshot
Test: development/vndk/snapshot/update.py with past version of snapshot
Change-Id: Id1ed658c22bb2e41c0ee50d1fe2a97924a76d7dc
2019-11-04 17:03:25 +09:00
Inseob Kim
fcbb526076 Merge "Fix vendor variants generation of vndk" am: f68f98eeb6 am: 3af01a3fc9
am: ad18218113

Change-Id: I14eebbeaa066da04d95bb7d68357354ac96d0d74
2019-11-03 18:22:46 -08:00
Treehugger Robot
f68f98eeb6 Merge "Fix vendor variants generation of vndk" 2019-11-04 02:00:41 +00:00
Jooyung Han
7f1ac2c35a Merge "delete redundant code" am: 1f056cd69d am: 4608595e74
am: cd8be8bb61

Change-Id: I95c13e34d2aabb7e77375c94aa01168a74afca9b
2019-11-01 12:00:33 -07:00
Treehugger Robot
1f056cd69d Merge "delete redundant code" 2019-11-01 18:15:33 +00:00
Inseob Kim
bc093672ed Fix vendor variants generation of vndk
Current routine to check whether BOARD_VNDK_VERSION variant is created
or not is not correct, because only non-VNDK modules are installed in
/vendor. Thus, BOARD_VNDK_VERSION variants should only be created with
non-VNDK modules.

Bug: N/A
Test: m nothing
Change-Id: I2ee7821fce407214ac6be4f4b6d62483c907971f
2019-11-01 13:28:59 +09:00
Jooyung Han
21d2bcc106 Merge "Soong generates vndk-related .libraries.txt files" am: 7acbfc033d am: ed3d5d730b
am: 76daab7a04

Change-Id: I85fab7585e3cf73601ffc1dbc133cf42364f3c60
2019-10-31 19:24:52 -07:00
Jiyong Park
5cc4a3433f Merge "native shared libs in an SDK can be snapshotted" am: 40dfbe3a16 am: 2c4966ad65
am: 0d3c428390

Change-Id: I8582547239d687ba5db88fe276a46d85f36dbca9
2019-10-31 18:59:48 -07:00
Jooyung Han
7acbfc033d Merge "Soong generates vndk-related .libraries.txt files" 2019-11-01 01:57:50 +00:00
Treehugger Robot
40dfbe3a16 Merge "native shared libs in an SDK can be snapshotted" 2019-11-01 01:23:35 +00:00
Jooyung Han
a463f720aa delete redundant code
no need to use separate test-only key for config.Once().

Test: m
Change-Id: I9e05d413504114df8f8ea8d9ef521db1d5da5d01
2019-11-01 09:00:11 +09:00
Jooyung Han
0302a84ddc Soong generates vndk-related .libraries.txt files
This is a follow-up CL of I9a24f6975bd4b226a94f61a13d43857dcdce6b88

Generated files are passed to make via MakeVars:
- SOONG_LLNDK_LIBRARIES_FILE
- SOONG_VNDKCORE_LIBRARIES_FILE
- SOONG_VNDKSP_LIBRARIES_FILE
- SOONG_VNDKPRIVATE_LIBRARIES_FILE
- SOONG_VNDKCOREVARIANT_LIBRARIES_FILE
- SOONG_VNDK_LIBRARIES_FILE

Previously filenames were "guessed" from module names. Now VndkMutator
stores filenames as well and generate those files with them.

Bug: 142963962
Bug: 141450808
Test: m && device boots && TH
Change-Id: I0c248b707188f904df60ead50059fefe90bfd17f
2019-11-01 04:35:21 +09:00
Kris Alder
9b7fdbf885 Merge "change output file extension (config.txt -> config.json)" am: 5d0b3b7195 am: edf33a3253
am: 67618b11dc

Change-Id: I6232e336e7812b73ecbde4b76fc78c6ac00d03c0
2019-10-30 22:27:28 -07:00
Kris Alder
5d0b3b7195 Merge "change output file extension (config.txt -> config.json)" 2019-10-31 04:59:55 +00:00
Jooyung Han
57498b64ca Merge "apex: __ANDROID_APEX__ defined with no value" am: bdad6c378f am: 15e234ef49
am: f3061ff6b5

Change-Id: I47a2799c6e619ad052c363c1975fd87392f93107
2019-10-30 17:21:58 -07:00
Jooyung Han
bdad6c378f Merge "apex: __ANDROID_APEX__ defined with no value" 2019-10-30 23:50:58 +00:00
Mitch Phillips
c030bdff24 Merge "Use unstripped binaries in fuzz target packaging." am: 9f221955f4 am: 7be457b958
am: aafc79b830

Change-Id: I67227d392707aa08efff6999933933e4dbe414ec
2019-10-30 15:33:29 -07:00
Kris Alder
db97af4a4b change output file extension (config.txt -> config.json)
This is causing some build errors because the config.json file isn't
associated with a rule (because the rule looks for .txt).

Test: ran locally, checked output directory
Bug: 142551000
Change-Id: Idcdb226fa2d23055a8850b2a0545202921edc3b1
2019-10-30 20:58:54 +00:00
Treehugger Robot
9f221955f4 Merge "Use unstripped binaries in fuzz target packaging." 2019-10-30 20:48:14 +00:00
Chih-hung Hsieh
69987355c6 Merge "Add rust_test and rust_test_host." am: bb3e6c3c35 am: 462e944d4d
am: bcde681e90

Change-Id: I5de4db48515a40fae36bfad48c72cc1ea7211bf6
2019-10-30 00:52:47 -07:00
Chih-hung Hsieh
bb3e6c3c35 Merge "Add rust_test and rust_test_host." 2019-10-30 07:22:53 +00:00
Jooyung Han
09a2e257ec Merge changes from topic "fix-vndk-core-variant" am: 61eb8aaea4 am: d178df9c20
am: b8d3065ff9

Change-Id: I3519ec81f4c3f7133cfafbdb7e02497bc9e694da
2019-10-29 21:50:22 -07:00
Chih-Hung Hsieh
a5f22ed6b0 Add rust_test and rust_test_host.
* Rust tests are like binary files compiled with --test.
  New test.go follows binary.go code patterns and reuses
  some code in binary.go.
* Generate one test per source file as testPerSrc in cc/test.go.
  The "all tests" variation feature of cc/test.go is not copied yet.
  Fix some Stem and SubName settings to make testPerSrc work.
* Move cc.CheckDuplicate to android.CheckDuplicate,
  which is now shared by cc and rust.
* Refactor tests in binary_test.go and add new test_test.go.

Bug: 140938178
Test: mm in rust projects, added rust_test and rust_test_host
Change-Id: Ia6fec8b4cf2572fd352ab1938a1f3c7b5cca2212
2019-10-29 17:19:03 -07:00
Jooyung Han
b01c114d27 Do not install VNDK lib in favor of VNDK APEX
Since VNDK APEX replaces VNDK lib /system/lib/vndk{-sp}, VNDK libs are
not installed.

Bug: 141451661
Test: m && boot device
Change-Id: I14686927a56ded5176839c89f29a2fd7e0fca658
2019-10-30 00:07:25 +00:00
Mitch Phillips
d5bd5773e3 Use unstripped binaries in fuzz target packaging.
Unstripped binaries allow for online symbolization, and offline
symbolization using the debug info in the binary. Debug information
isn't stripped for host binaries, but is for target. Target should also
contain debugging info.

Bug: N/A
Test: m fuzz && # Check that fuzz targets in the fuzz-*.zip package have
debug info.

Change-Id: Ibd3002674d519e927340a50dfdfbf44f2d809d58
2019-10-29 17:04:22 -07:00
Jooyung Han
87a7f3064f Fix apex_vndk with TARGET_VNDK_USE_CORE_VARIANT
When TARGET_VNDK_USE_CORE_VARIANT is set, vndk apex should have only
- vndk sp libraries
- vndk core libraries which are marked as "must use vendor variant"

Previously, vndk sp libs are discarded when TARGET_VNDK_USE_CORE_VARIANT
is set.

Bug: 143374795
Bug: 139772411
Test: TARGET_VNDK_USE_CORE_VARIANT=true m com.android.vndk.current
      see if vndk sp lib(e.g. libunwindstakc) is included.

Change-Id: Iae218fff5c354eb874839a1f71be30633fb8a9ab
2019-10-30 09:04:13 +09:00
Jooyung Han
6b8459be4f apex: __ANDROID_APEX__ defined with no value
__ANDROID_APEX__ was defined with the name of apex module.
-D__ANDROID_APEX__=com.android.foo

But in this way, conditional compilation is not easy since comparing
macro's string value is not supported in C/C++.
(There's no usages of this value in source tree.)

In most cases, modules can check if __ANDROID_APEX__ is defined to see
if they are compiled for apex.
For modules which should behave differently according to which apex they
are included, they can check __ANDROID_APEX_<NAME>__.

Bug: 142582178
Test: m (soong tests run) && boot device && TH
Change-Id: I0f5e3e9463ccd96cbba333a8bdd648470c5c912d
2019-10-29 23:47:59 +00:00
Ivan Lozano
6ec3e06cf6 Merge changes Ia7deed13,I7378a46f am: 765fe7a501 am: 5e94b2dd4b
am: d446f0b06e

Change-Id: I4affe1644dfa7c34df9ecface7bcd85857e61761
2019-10-29 15:41:03 -07:00
Ivan Lozano
765fe7a501 Merge changes Ia7deed13,I7378a46f
* changes:
  Add support for Rust C libraries.
  Add a common interface for cc linkable libraries.
2019-10-29 21:47:14 +00:00
Ivan Lozano
52767be335 Add support for Rust C libraries.
Adds the ability for rust modules to be compiled as C libraries, and
allows cc modules to depend on these rust-generated modules. This also
means that soong-rust should not have any dependencies on soong-cc aside
from what's required for testing.

There's a couple small fixes included as well:

 - A bug in libNameFromFilePath that caused issues when library's had
 "lib" in their name.
 - VariantName is removed from rust library MutatedProperties since this
 was unused.

Bug: 140726209
Test: Soong tests pass.
Test: Example cc_binary can include a rust shared library as a dep.
Test: m crosvm.experimental
Change-Id: Ia7deed1345d2423001089014cc65ce7934123da4
2019-10-28 22:09:01 -07:00
Jiyong Park
73c54ee7fe native shared libs in an SDK can be snapshotted
The snapshot script can now handle native shared libs in an SDK.

Bug: 138182343
Test: create following sdk module:
sdk {
    name: "mysdk",
    native_shared_libs: ["libc", "libdl"],
}
, then execute `m mysdk` and execute the update_prebuilt-1.sh as
prompted. Following directories are generated under the directory where
mysdk is defined at:

1
├── aidl
├── Android.bp
├── arm64
│   ├── include
│   ├── include_gen
│   └── lib
│       ├── libc.so
│       └── libdl.so
├── include
│   └── bionic
│       └── libc
│           └── include
│               ├── alloca.h
│               ├── android
│               │   ├── api-level.h
<omitted>

Change-Id: Ia1dcc5564c1cd17c6ccf441d06d5995af55db9ee
2019-10-29 12:27:35 +09:00
Kris Alder
b3076cee75 add additional fields to cc_fuzz build types am: f979ee3873 am: 0bb1b218a9 am: b3670d2945
am: bc4710e870

Change-Id: I4f0e6d3d642a116b26321b9db700d681c13faf7a
2019-10-28 17:13:55 -07:00
Kris Alder
f979ee3873 add additional fields to cc_fuzz build types
Specifically, this adds:
* Owner
* Disable (stop fuzzer from running in Haiku)
* Bug Component
* Bug Hotlist

The fields are all inside a new 'options' struct.

The values from these fields (if any) are written into a config file as
json.

Bug: 142551000
Test: ran locally with a modified build file and verified output in .zip
Change-Id: I86edf74c2cebe9912ac0ad203f99028be4062c8b
2019-10-28 16:15:50 -07:00
Ryan Prichard
d818cbe2bd Merge "Stop linking libdl.a into static bins" am: ce6b216c5e am: d258b0fceb am: f26152245c
am: 1d051e0bb5

Change-Id: Ife881f70b97d1f2d432eeed93b1288368efda807
2019-10-28 14:03:32 -07:00
Ivan Lozano
183a3218e2 Add a common interface for cc linkable libraries.
Adds an interface, CcLinkableInterface, for cc linkable dependencies
which come from other toolchains such as Rust.

Bug: 140726209
Test: Soong tests pass, rust modules still compile.
Change-Id: I7378a46fad94fd0b735746aaf4e265fd2c2c04d8
2019-10-28 13:45:12 -07:00
Ryan Prichard
ce6b216c5e Merge "Stop linking libdl.a into static bins" 2019-10-28 20:14:37 +00:00
Greg Kaiser
d9d40ecf47 Merge "Partial reverts of vndk-apex" am: 5bce0931c1 am: 908aa0cf74 am: 4e7313bd3d
am: d6a1e1caa9

Change-Id: I421d7474ad5fc4a48a911a27209424b7b2631a95
2019-10-28 10:37:57 -07:00
Jooyung Han
6db2f177db Partial reverts of vndk-apex
This installs vndk libs under system/lib/vndk
instead of vndk-apex.
(Partial reverts of 31c470b5d5)

Also fixes the bug 097087be53 brought.
This produced incomplete list of vndkcorevariant.libraries.txt.

Bug: 143374795
Test: m && boot
Change-Id: I17864de4770a84431756e0c3765b601d3dc2abb1
2019-10-28 14:12:48 +09:00
Jiyong Park
abcfdc9aea Merge "Change exportedDirs and exportedSystemDirs from []string to android.Paths" am: b480debbd8 am: 229ebeea9b am: c5bb8dc821
am: 774c8ba3b6

Change-Id: I3f6aecc5232759524f04778ef3576fd68f6139b3
2019-10-27 19:53:58 -07:00
Treehugger Robot
b480debbd8 Merge "Change exportedDirs and exportedSystemDirs from []string to android.Paths" 2019-10-28 02:24:41 +00:00
Jooyung Han
382cded017 Merge "Soong generates libraries.txt files for vndk" am: 7d6b21c265 am: 678af96675 am: cdd21aa9e7
am: 63261b8a9e

Change-Id: I564228bbfdf894185d18df47a56e38e5ab933854
2019-10-25 19:34:50 -07:00
Treehugger Robot
7d6b21c265 Merge "Soong generates libraries.txt files for vndk" 2019-10-26 01:52:39 +00:00
Jooyung Han
1c124a9350 Merge changes from topic "add-vndk-again" am: 7289ddbeba am: 6bab6fe3e0 am: 9f50ee32d7
am: 6179be2c32

Change-Id: I57a9626c207be164340a663167069692c1d4cbf5
2019-10-25 02:02:43 -07:00