Commit graph

1162 commits

Author SHA1 Message Date
Jihoon Kang
98aa8fa840 Remove exportable modules when generating snapshots targeting older platform
This change modifies the contents of the generated Android.bp files so
that when generating a snapshot on a older platform, the "exportable"
modules are removed from the bp files, as the "exportable" modules are
first introduced in V and do not exist in older platforms.

Bug: 345162614
Test: ABTD
Change-Id: I2dba51b98deec7805bd796647a66981f237c55a9
2024-06-10 18:12:35 +00:00
Priyanka Advani
c6a321e4de Revert "Change test_module_config from copying files to symlink ..."
Revert submission 3060229-ron-tmc-symlinks

Reason for revert: Droidmonitor created revert due to b/344045516

Reverted changes: /q/submissionid:3060229-ron-tmc-symlinks

Change-Id: If5045366677163560cdae95c0ab74256b4b49b9a
2024-05-31 23:31:13 +00:00
Ronald Braunstein
f216af5653 Change test_module_config from copying files to symlink files.
Now the derived modules will have symlink's to base's testcase dir
rather than copyfile files from base's intermediates dir.

I also removed storing the "base" module as dependency and only use
data from the provider in GenerateAndroidBuildActions and
AndroidMkEntries.
I did have to add two fields to the provider for this.

To ensure the symlinks always resolve to a physical file, I also added
goals such that building `derived-target` will also build `build-target`

Create new Make variable: LOCAL_SOONG_INSTALLED_COMPATIBILITY_SUPPORT_FILES
for tasks/general-tests.mk,device-tests.mk to read.
This allows "support" files that are installed with soong rules rather
than make rules to still end up in the zips.

Sample dir structure:
% tree -ls testcases                                                                                                                                                                                                                                                   aosp_cf_x86_64_phone[4:31:54]/0
[       4096]  testcases
├── [       4096]  FrameworksServicesTests
│   ├── [       4096]  data
│   │   └── [        851]  broken_shortcut.xml
│   ├── [       2800]  FrameworksServicesTests.config
│   ├── [      12695]  JobTestApp.apk
│   ├── [       8599]  MediaButtonReceiverHolderTestHelperApp.apk
│   ├── [      16791]  SimpleServiceTestApp1.apk
│   ├── [      16791]  SimpleServiceTestApp2.apk
│   ├── [      16791]  SimpleServiceTestApp3.apk
│   ├── [    1017763]  SuspendTestApp.apk
│   └── [       4096]  x86_64
│       └── [   79827767]  FrameworksServicesTests.apk
└── [       4096]  FrameworksServicesTests_contentprotection
    ├── [       4096]  data
    │   └── [         54]  broken_shortcut.xml -> ../../FrameworksServicesTests/data/broken_shortcut.xml
    ├── [       3005]  FrameworksServicesTests_contentprotection.config
    ├── [         41]  JobTestApp.apk -> ../FrameworksServicesTests/JobTestApp.apk
    ├── [         69]  MediaButtonReceiverHolderTestHelperApp.apk -> ../FrameworksServicesTests/MediaButtonReceiverHolderTestHelperApp.apk
    ├── [         52]  SimpleServiceTestApp1.apk -> ../FrameworksServicesTests/SimpleServiceTestApp1.apk
    ├── [         52]  SimpleServiceTestApp2.apk -> ../FrameworksServicesTests/SimpleServiceTestApp2.apk
    ├── [         52]  SimpleServiceTestApp3.apk -> ../FrameworksServicesTests/SimpleServiceTestApp3.apk
    ├── [         45]  SuspendTestApp.apk -> ../FrameworksServicesTests/SuspendTestApp.apk
    ├── [         36]  test_module_config.manifest
    └── [       4096]  x86_64
        ├── [         64]  FrameworksServicesTests.apk -> ../../FrameworksServicesTests/x86_64/FrameworksServicesTests.apk
        └── [         36]  UNUSED-FrameworksServicesTests.apk

Test: m clean && atest FrameworksServicesTests_contentprotection
Test: m clean && atest CtsDevicePolicyManagerTestCases_ParentProfileApiDisabled

Bug: b/332320956
Change-Id: I8466f253fa559bc74cef4533edf263650e96bbfb
2024-05-31 08:24:11 -07:00
Spandan Das
3dbda18e80 Use r8/d8 optimized profile for dexpreopt
Currently, dexpreopt supports profile guided optimization. This does not
work well with r8/d8 optimization, since the checked-in profile will not
match the dex signatures after r8/d8 has optimized the dex code.

This CL introduces a new property `dex_preopt.enable_profile_rewrting`.
If set, the checked-in profile will passed as `input` to r8 via
`--art-profile <input> <output>`. The <output> from the previous command
will be used as the profile for dexpreopt.

Test: m nothing --no-skip-soong-tests
Test: m CredentialManager with https://ag.corp.google.com/27448930
and obfuscation turned on
Test: nm -U symbol.odex # contains obfuscated methods

Bug: 335418838

Change-Id: I53beed9ed76f013262f1c503de0f2b74997c2a7f
2024-05-29 01:05:05 +00:00
Treehugger Robot
bc44eb03db Merge "Allow experimental Java target 21 by default" into main 2024-05-23 16:37:21 +00:00
Sorin Basca
253f8c045a Allow experimental Java target 21 by default
Bug: 342332820
Test: EXPERIMENTAL_TARGET_JAVA_VERSION_21=true m
Change-Id: I6cc21bf191385df91c2446b7cd6291a0e3532bea
2024-05-23 10:28:24 +01:00
Treehugger Robot
652824c8d6 Merge changes from topic "revert-3094658-revert-3088867-QEHDREAABY-IOPVAUIKWL" into main
* changes:
  Revert^2 "Refactor how jni_libs dependencies are added"
  Revert^2 "Add make java.dependencyTag installable or not"
  Revert "Revert "APK-in-APEX should set use_embedded_native_libs:..."
  Revert^2 "Install jni symlinks in Soong"
2024-05-20 23:00:05 +00:00
Jiyong Park
c1e5b1848a Revert^2 "Add make java.dependencyTag installable or not"
f14b5ba863

Change-Id: I0638d4997cb8e5178f869ea0f469a1a5c141611e
2024-05-21 06:41:36 +09:00
Jiyong Park
25b9222a43 Revert^2 "Install jni symlinks in Soong"
b7646e4d4f

This is a relanding of I0930cb1ebb8ca8a6efd64b1ce2cdfd1c47fe19ef plus
some forward fix described below:

Export non-embedded JNI lib names via LOCAL_REQUIRED_MODULES

The non-embedded JNI libs are installed as the dependencies of the APK.
However, that dependency is not revealed to the Make world and as a
result, the JNI libs are dropped from the file_list.txt file which Make
uses to filter files to include in the image file.

Adding the lib names to LOCAL_REQUIRED_MODULES fixes it.

Bug: 341335305
Bug: 330276359
Test: m out/target/product/vsoc_x86_64_only/obj/PACKAGING/system_intermediates/file_list.txt
and check if libcarservicejni.so is there
Test: go test ./... under soong/java

Change-Id: If915a05909129c92fab7a6cbbd0c4c55f5ced598
2024-05-21 06:40:14 +09:00
Treehugger Robot
8298134503 Merge changes Ifbe123d1,Ie2e738a6 into main
* changes:
  Support min_sdk_version overrides in apexes
  Support min_sdk_version overrides in apps
2024-05-20 17:38:11 +00:00
Spandan Das
b9c58350ca Support min_sdk_version overrides in apps
This replaces the global override of min_sdk_version (via
`APEX_GLOBAL_MIN_SDK_VERSION_OVERRIDE`) with an min_sdk_version override
that can be set by each individual soong override_app.

The use case for this are go apps which are only installed in T and
above, even though the base AOSP apexes might be installable on < T
devices.

Test: added a unit test

Bug: 295311875
Change-Id: Ie2e738a6786bb24417c675617f7c78358017c96c
2024-05-17 21:15:04 +00:00
Yu Shan
b7646e4d4f Revert "Install jni symlinks in Soong"
Revert submission 3088867

Reason for revert: On cf_auto build, we are seeing a symlink of jni lib pointing to lib64/libcarservicejni.so, which does not exist on the device.

Reverted changes: /q/submissionid:3088867
Bug: b/341335305

Change-Id: Ie4ff26fe47e1a0ab5e97b185c61cb94473cc5fb8
2024-05-17 13:37:37 -07:00
Yu Shan
f14b5ba863 Revert "Add make java.dependencyTag installable or not"
Revert submission 3088867

Reason for revert: On cf_auto build, we are seeing a symlink of jni lib pointing to lib64/libcarservicejni.so, which does not exist on the device.

Reverted changes: /q/submissionid:3088867
Bug: b/341335305

Change-Id: I60052dbb004df58fdfaf93be6089769ab2a670fc
2024-05-17 13:37:20 -07:00
Jiyong Park
4384d294c3 Add make java.dependencyTag installable or not
java.dependencyTag now has a new field installable which contols whether
the dependency should be added as the install dep of the app or not.

This allows us to model all the dependency tags for Java using the same
struct.

Bug: N/A
Test: m
Change-Id: I9b1c7809a0bde3f15579aefd9bb34d828764b84b
2024-05-16 19:40:01 +09:00
Jiyong Park
4f487c5b56 Install jni symlinks in Soong
The installation of the symlink
(<partition>/app/MyApp/lib/<arch>/libfoo.so) and its target
(/system/lib64/libfoo.so) are now done int Soong.

I gave up the idea of always embedding jni libs to apps, due to a
hard-to-fix regression in storage usage. Specifically, consider this
case.

app --(jni_lib)--> libfoo
    --(jni_lib)--> libbar

libfoo --(shared_lib)--> libbar

Ideally, with the embedding idea, both libfoo and libbar should be
embedded into the app and there should be no libfoo or libbar outside of
the apk, unless there's no dependency to any of them from outside of the
apk.

However, the previous implementation installed libbar to /system/lib64,
leading two copies of the lib; one in /system/lib64, the other in the
apk.

This was happening because libbar was also considered as a transitive
dep of libfoo, and therefore a dependency to its installation path is
added to the apk. The problem here is that the app doesn't know that
libfoo depends on libbar. We in theory can write a very delicate
dependency traverse routine which filters libbar out of the transitive
deps, but that looked too complicated.

Bug: 339923078
Bug: 330276359
Test: Build and watch any bloatbuster warning
Test: m aosp_cf_system_x86_64
The following three files are found
* system/lib64/libnfc_nci_jni.so
* system/etc/libnfc-nci.conf
* system/priv-app/NfcNci/lib/arm64/libnfc_nci_jni.so

Change-Id: I0930cb1ebb8ca8a6efd64b1ce2cdfd1c47fe19ef
2024-05-16 19:40:00 +09:00
Jiyong Park
cd9dca20a0 Revert "Install transitive deps of jni libs, but not the jni libs themselves"
This reverts commit e716807083.

Change-Id: If3b63706114cb534af359fdac2d80d8a5d02ea6d
2024-05-15 03:32:22 +09:00
Jiyong Park
e716807083 Install transitive deps of jni libs, but not the jni libs themselves
Consider this case:

app --(jni_libs)--> libfoo --(shared_libs)--> libprivate

Only libfoo is embedded into the app. libprivate is not embedded because
libprivate is very likely to be depended on by other components in the
platform, in which case it will anyway be installed to /system/lib.
Embedding libprivate into the app will increase the storage usage as a
whole. Furthermore, if libprivate is not a shared lib but a config file
(of type prebuilt_etc), it can't be embedded and therefore must be
installed outside of the app.

However, a problem occurs when libprivate is not depended on by anyone
else. Then libprivate is not installed to the system partition, causing
an error at runtime.

This CL fixes that by making the jni_libs dependency to implement the
new SKipToTransitiveDepsTag interface. Now, jni_libs themselves are not
installed, but their transitive deps are depended on by the app
containing the jni libs.

Bug: 330276359
Test: m NfcNci and check if libnfc-nci.config is installed.
Test: m CarService and check android.hardware.automotive.evs-V2-ndk.so
is installed as well.
Test: go test ./... under soong/java

Change-Id: I04cc92b7fad768a20ec60a02b3e7534641b1e74d
2024-05-10 14:03:07 +09:00
Treehugger Robot
7eaf503cfd Merge "Revert^2 "Remove compilation actions from java sdk library"" into main 2024-05-08 22:28:05 +00:00
Jihoon Kang
a3a05460b4 Revert^2 "Remove compilation actions from java sdk library"
This change modifies the build actions of java_sdk_library module type
so that it does not perform any compilation actions (i.e. does not
create the top level java_sdk_library jar file). Instead, it delegates
the build actions the top level jar file was performing to the
dynamically created ".impl"-suffixed java library module. The build
actions that are delegated to the impl library module include hiddenapi
processing, dexing, and dexpreopt.

This change relands https://r.android.com/3035972. Implementation
changes from the original change:
- "all_apex_contributions" is added as a dependecy to the implementation
  library modules where the parent sdk_library module has a prebuilt
  equivalent. This allows the source apex variant to be hidden from make
  when the prebuilt is active.

Test: patch in internal main, lunch barbet-ap2a-userdebug && m nothing
Test: m nothing --no-skip-soong-tests
Bug: 332785297
Change-Id: I017938e5567aef82e428e7ceb557d9c9090e0257
2024-05-08 17:46:31 +00:00
Jihoon Kang
5284ad3b33 Merge "Revert "Remove compilation actions from java sdk library"" into main 2024-05-07 00:03:05 +00:00
Jihoon Kang
8f25d296b5 Revert "Remove compilation actions from java sdk library"
Revert submission 3070882-sdk_lib_remove_compilation

Reason for revert: Potential culprit for build breakage of barbet-ap2a-userdebug in git_main

Reverted changes: /q/submissionid:3070882-sdk_lib_remove_compilation

Change-Id: I5135760e13e0152480c68fe91a3c88564e9bc7cb
2024-05-06 22:40:22 +00:00
Treehugger Robot
f91daab1ab Merge "Remove compilation actions from java sdk library" into main 2024-05-06 21:06:54 +00:00
Jihoon Kang
d831af4267 Remove compilation actions from java sdk library
This change modifies the build actions of java_sdk_library module type
so that it does not perform any compilation actions (i.e. does not
create the top level java_sdk_library jar file). Instead, it delegates
the build actions the top level jar file was performing to the
dynamically created ".impl"-suffixed java library module. The build
actions that are delegated to the impl library module include hiddenapi
processing, dexing, and dexpreopt.

Test: m nothing --no-skip-soong-tests
Bug: 332785297
Change-Id: I7534f9eaacf6d9f72fbf8d540b1e26af84106c20
2024-05-03 20:51:11 +00:00
Inseob Kim
37e0bb0db4 Merge logtags from cc modules too
Merged logtags files will be used for Soong built filesystem images.

Bug: 336189540
Test: m out/soong/.intermediates/all-event-log-tags.txt
Test: m out/target/common/obj/all-event-log-tags.txt
Change-Id: Ib590c2bc8073e9acee6b45ef08092768237cf9d3
2024-04-29 17:40:40 +09:00
Sorin Basca
db70a80cc7 Merge "Add Java 21 as a known version" into main 2024-04-22 07:08:02 +00:00
Sorin Basca
1fe2cc883f Add Java 21 as a known version
Bug: 335612268
Test: Set java_version to 21 in core-all && m
Change-Id: Ie2093187cec75949ae3bb4903edfb6f62aa31f6e
2024-04-19 10:45:55 +01:00
Treehugger Robot
17b9a5b8b4 Merge "Allow dexpreopt of source sdklib in prebuilt apex builds" into main 2024-04-18 01:25:15 +00:00
Spandan Das
5ae65ee6e0 Allow dexpreopt of source sdklib in prebuilt apex builds
aosp/2984037 disabled dexperopt of the source apex system server jars
when prebuilts are selected. This was done to prevent duplicate
installation and dex2oat deps.

AOSP art has some additional variants like com.android.art.debug. In
source builds, this apex should contain service-art.jar and
service-art.jar.prof (a dexpeopt artifact). We have a test to check this
(`art_apex_test.py`). If we disable dexpreopt of source sdlib when
prebuilts are selected, this test needs to be disabled. This is the
behavior at ToT.

This CL changes the behavior to enable running this test even when
com.google.android.art prebuilt is active in a specific release
configuraiton. To prevent collisions that prompted aosp/2984037, this CL
special-cases the installation and dex2oat rules instead of disabling
dexpreopt of the source sdklib altogether.

b/331665856 tracks the principled solution to prevent duplicate
dexpreopt rules.

Implementation:
Add a new copyApexSystemServerJarDex arg to GenerateDexpreoptRule API.
If true, the dexjar file will be copied to
out/soong/system_server_jars/. For soong modules, the value of this will
be the inverse of disableSourceApexVariant. Since none of the apex
system server jars are in make, this will be a noop in dexpreopt_gen

Bug: 331665856
Test: modified trunk_staging.scl locally to select
art.google.contributions.prebuilt; mmma art; (with the sibling CL in
topic)

Change-Id: Idb59e424f83d126cdc8b1671dde358745979bd8d
2024-04-17 23:15:20 +00:00
Treehugger Robot
9a8255f48e Merge changes from topic "cherrypicker-L27000030003160683:N90900030051335582" into main
* changes:
  Propagate transitive missing optional_uses_libs.
  Refactor the contruction of the manifest check inputs.
2024-04-16 13:35:54 +00:00
Jiakai Zhang
369370818f Propagate transitive missing optional_uses_libs.
Bug: 331528424
Test: m --no-skip-soong-tests
Ignore-AOSP-First: Depends on internal changes. Will cherry-pick once merged.
Merged-In: Ied2821f11b6a5056ecf577e1e25765bc6dd212c0
Change-Id: Ied2821f11b6a5056ecf577e1e25765bc6dd212c0
2024-04-15 12:16:21 +00:00
Jiakai Zhang
f98da19a07 Refactor the contruction of the manifest check inputs.
This is a no-op change for a majority of cases.

Before this change, the contruction of the manifest check inputs is
confusing. It mutates uses_libs properties in place just for the
manifest check, by replacing module names with library names for
direct dependencies and merging library names from CLC for both direct
denpendencies and transitive denpendencies, and then constructs manifest
check inputs from those mutated uses_libs properties. This is
error-prone and leads to insistency: the goal is to check that the CLC
matches the manifest, but the inputs to the check don't reflect the CLC.

After this change, we no longer mutate uses_libs properties in place.
Instead, we maintain a separate list of missing denpendencies, and then
construct manifest check inputs directly from the CLC for all existing
libraries, no matter they are direct or transtive, and from the separate
list of missing libraries. This change makes the logic more
consistent and straightforward, and it also allows us to easily do the
next change, which is to propagate transtive missing denpendencies.

In fact, this change revealed several bugs around library optionality
and order in CLC construction, and fixed them.

Bug: 331528424
Test: m --no-skip-soong-tests
Ignore-AOSP-First: Depends on internal changes. Will cherry-pick once merged.
Merged-In: I0de82e76c47995b54aba9efd41538d950256a95f
Change-Id: I0de82e76c47995b54aba9efd41538d950256a95f
2024-04-15 11:15:41 +00:00
Ronald Braunstein
cdc66f4268 Add "test-only" flag for java modules
As part of aosp/3022586 where we added the idea of "test-only" modules
and top_level_test_targets, this CL implements that for java modules.

We let users set "test-only" on java_library, but not on other modules
where the module kind is implicitly test-only, like java_test.
The implementation, not the user decides it is test-only.
We also exclude it from java_defaults.

	% gqui from  "flatten(~/aosp-main-with-phones/out/soong/ownership/all_teams.pb, teams)" proto team.proto:AllTeams 'select teams.kind, count(*) where teams.test_only = true and teams.kind not like "%cc_%" group by teams.kind'
	+--------------------------+----------+
	|        teams.kind        | count(*) |
	+--------------------------+----------+
	| android_test             |     1382 |
	| android_test_helper_app  |     1680 |
	| java_fuzz                |        5 |
	| java_test                |      774 |
	| java_test_helper_library |       29 |
	+--------------------------+----------+

	 % gqui from  "flatten(~/aosp-main-with-phones/out/soong/ownership/all_teams.pb, teams)" proto team.proto:AllTeams 'select teams.kind, count(*) where teams.top_level_target = true and teams.kind not like "%cc_%" group by teams.kind'
	+--------------+----------+
	|  teams.kind  | count(*) |
	+--------------+----------+
	| android_test |     1382 |
	| java_fuzz    |        5 |
	| java_test    |      774 |
	+--------------+----------+

Test: m nothing --no-skip-soong-tests
Test: go test ./java
Test: m all_teams

Bug: b/327280661
Change-Id: I9c3ad947dc3d68d6427abada27449526d69daa6b
2024-04-12 11:42:10 -07:00
Treehugger Robot
80214e550e Merge "Strip relative paths from java_import output files" into main 2024-04-12 01:22:10 +00:00
Colin Cross
5e87f349b8 Strip relative paths from java_import output files
androidx.annotation_annotation is used as a test data file, and
converting it from a java_library to a java_library_import causes
the relative path used in the test data path to change. Clear the
relative path in java_import the same way that other java based
modules do.

Bug: 288358614
Test: TestJavaLibraryOutputFileRel
Change-Id: I1f494110da32e916043ca94ac6ebeeafccc06f9a
2024-04-11 16:51:21 -07:00
Nikolay Elenkov
f28b5697b8 Merge "Add secretkeeper-v1-java to platform APIs" into main 2024-04-09 01:59:35 +00:00
Ronald Braunstein
c654ad162c Merge "Add test_module_config_host" into main 2024-03-29 22:15:08 +00:00
Ronald Braunstein
1a6e7c032a Add test_module_config_host
This pairs with `test_module_config` but also works on the base is a
`java_test_host` module.
e.g.

	test_module_config_host {
	     name: "CtsOsHostTestCases_DERIVED_2566",
	     base: "CtsOsHostTestCases",
	     test_suites: ["general-tests"],
	     include_filters: [ "android.os.cts.StaticSharedLibsHostTests" ],
	     exclude_annotations: [ "androidx.test.filters.FlakyTest","org.junit.Ignore" ],
	}

The new module is composed of the previous and shares much of the same
code.

With respect to build size,
	Without this change, if you build CtsAppSecurityHostTestCases, there
	will be several copies of the jar (and related apks) :
	 *) 1 in framework
	     out/host/linux-x86/framework/CtsAppSecurityHostTestCases.jar
	 *) 1 in testcases for the test
	     out/host/linux-x86/testcases/CtsAppSecurityHostTestCases/CtsAppSecurityHostTestCases.jar
	 *) 1 per compatibility suite testcases
		out/host/linux-x86/mts-documentsui/android-mts-documentsui/testcases/CtsAppSecurityHostTestCases/CtsAppSecurityHostTestCases.jar
		out/host/linux-x86/mts-mediaprovider/android-mts-mediaprovider/testcases/CtsAppSecurityHostTestCases/CtsAppSecurityHostTestCases.jar
		out/host/linux-x86/mts/android-mts/testcases/CtsAppSecurityHostTestCases/CtsAppSecurityHostTestCases.jar
		out/host/linux-x86/cts/android-cts/testcases/CtsAppSecurityHostTestCases/CtsAppSecurityHostTestCases.jar
		out/host/linux-x86/mts-mainline-infra/android-mts-mainline-infra/testcases/CtsAppSecurityHostTestCases/CtsAppSecurityHostTestCases.jar

	A dervived test using CtsAppSecurityHostTestCases as base adds one more
	to its testcases dir:
	  *) derived testcase.
	     out/host/linux-x86/testcases/CtsAppSecurityHostTestCases_presubmit_ExternalStorageApp/CtsAppSecurityHostTestCases.jar

Fixes: b/327280990
Test: m clean && m  CtsOsHostTestCases_DERIVED_2566# as above
Test: atest CtsOsHostTestCases_DERIVED_2566 --collect-tests-only
Test: migrated the 71 TestMapping instances to Android.bp and build them.
  Ran tests on some of them.
  Ran some original `test_module_config` tests derived from `android_test` as well

TODO: Add actions to validate the given filters are valid for the given
test apks/jars.

Change-Id: I115eedb6ff6ba8e72bb49e71867daf49d25ca0f1
2024-03-28 15:07:17 -07:00
Nikolay Elenkov
7ee98928ea Add secretkeeper-v1-java to platform APIs
Bug: 324321147
Test: Manual -- trigger factory reset, confirm ISecretKeeper.deleteAll()
is being called in Trusty logs.

Change-Id: If793f784bc1a8c621a721d15da9aeb1ef11e7334
2024-03-27 06:51:34 +00:00
Colin Cross
dad2a361ef Revert^2 "Support static_libs for java_import modules"
c6c9c7354b

Change-Id: Id011aca133d7bb45023a63c0f53d84a4d694cc2f
2024-03-23 04:43:41 +00:00
Colin Cross
567b9d707b Merge changes from topic "revert-3008874-OJOKRLYEZJ" into main
* changes:
  Revert "Support transitive dependencies through android_libary_i..."
  Revert "Support static_libs for java_import modules"
2024-03-22 18:25:30 +00:00
Colin Cross
c6c9c7354b Revert "Support static_libs for java_import modules"
Revert submission 3008874

Reason for revert: b/330903911
Reverted changes: /q/submissionid:3008874

Change-Id: I34cca9d021d9c806e28bb6a6a6da78efd61cde27
2024-03-22 18:17:00 +00:00
Colin Cross
77be51bcab Merge changes from topic "no_more_nodeps" into main
* changes:
  Support static_libs for java_import modules
  Support transitive dependencies through android_libary_import modules
2024-03-22 16:55:47 +00:00
Colin Cross
a174d2e987 Support static_libs for java_import modules
Remove the need to wrap java_import modules with a java_library
just to include static dependencies.

Bug: 288358614
Test: TestJavaImport
Change-Id: I888aecc6c0efc696a397fc1dd5d0ef5fd644bebc
2024-03-21 15:36:01 -07:00
Treehugger Robot
b291690bc4 Merge "Export JavaBootLibsSdkMemberType and JavaSystemserverLibsSdkMemberType" into main 2024-03-21 02:47:59 +00:00
Spandan Das
159b264873 Export JavaBootLibsSdkMemberType and JavaSystemserverLibsSdkMemberType
build/soong/sdk will use these tags to differentiate the sdk and non-sdk
contents of bootclasspath and systemserverclasspath fragments.

Test: go build ./java
Bug: 326246905

Change-Id: Ia8352c09fcbbca06988eb57153e5986801eb45a5
2024-03-20 21:41:49 +00:00
Treehugger Robot
064b145365 Merge "Change java stem attribute for both device and host" into main 2024-03-20 01:05:50 +00:00
Jihoon Kang
705e63e362 Propagate intermediateCacheFiles in java modules and filegroup
This change propagates the intermediateCacheFiles generated by the
aconfig_declarations to the static rdeps that are java modules or the
rdeps that are filegroups.

Test: m nothing
Bug: 329284345
Change-Id: I02431336c1aa0378d03248f3bb6edf2f57ec3b7f
2024-03-19 20:54:05 +00:00
yangbill
2af0b6edd7 Change java stem attribute for both device and host
Bug: 329762127
Test: cd build/soong/java ; go test -run TestJavaLibHostWithStem
Test: cd build/soong/java ; go test -run TestAppStem
Test: cd build/soong/java ; go test -run TestAndroidAppImport_ArchVariants
Test: cd build/soong/java ; go test -run TestOverrideAndroidAppStem
Test: cd build/soong/java ; go test -run TestOverrideAndroidApp
Test: cd build/soong/java ; go test -run TestPackageNameOverride

Change-Id: I8fbdc82116f9a0c68121fbbeb1ef4f78f2b6fea3
2024-03-19 09:11:59 +00:00
Yu Liu
f509eba41d Merge "Validate aconfig libs are built with the correct modes." into main 2024-03-14 18:39:12 +00:00
Treehugger Robot
fd3921f6bb Merge "Use uncompressed dex for all preopted system targets" into main 2024-03-12 01:43:32 +00:00