| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
One of the output files in the incremental apk
(stub_application_data.txt) was using CRLF on
Windows, so the mobile-install'ed app was
crashing on startup.
Fix is to open the output file in binary mode so
line endings are not converted to the
host-platform-native one.
See https://github.com/bazelbuild/bazel/issues/3264
Change-Id: Id7d4b5aa4362a21e699517b97dd24858c396eaa7
PiperOrigin-RevId: 164722314
|
|
|
|
|
|
|
|
|
|
|
| |
The Adb command needs the SYSTEMROOT environment
variable (as does Bazel), otherwise it produces
weird errors. So add that to Adb's environment.
See https://github.com/bazelbuild/bazel/issues/3264
Change-Id: Ia393f32ef00e21c90e4fc6d4a3188b7987aa89b0
PiperOrigin-RevId: 164454924
|
|
|
|
| |
PiperOrigin-RevId: 163538636
|
|
|
|
|
|
|
| |
Fixes TODO in AndroidRuleClasses.java.
RELNOTES: None
PiperOrigin-RevId: 162955052
|
|
|
|
|
|
|
|
|
|
|
|
| |
Apparently `rlocation` is not defined in the
environment of regular sh_binary rules, only in
tests. So this commit adds an implementation for
it.
See https://github.com/bazelbuild/bazel/issues/3264
Change-Id: I70ecb91cef5e1b66679e6ba04823831183da5cd9
PiperOrigin-RevId: 161775438
|
|
|
|
|
| |
Change-Id: Ib061c85900e577f3548d47e8fa86086dfec9654a
PiperOrigin-RevId: 161360338
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add extra debugging info to
zip_manifest_creator.sh in case ZIPPER is not
found. This'll help diagnosing
https://github.com/bazelbuild/bazel/issues/3326
RELNOTES: none
Change-Id: I60884b43c1aa10a9f67843628f1fadc74959059d
PiperOrigin-RevId: 161208218
|
|
|
|
|
|
|
|
|
| |
And so does its test.
See https://github.com/bazelbuild/bazel/issues/3264
Change-Id: I32dd906b94747d601254ab55e7962bf6cda058f4
PiperOrigin-RevId: 160953063
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Introduce host and target path separation in the
Android incremental_install.py. This will allow
running this script (and use bazel mobile-install)
on platforms with non-POSIX path semantics
(e.g. Windows).
See https://github.com/bazelbuild/bazel/issues/3264
Change-Id: If6ec09f100dd2e0be3389dce25cb1a13305226e9
PiperOrigin-RevId: 160531950
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The android_sdk_repository now uses the native
Android build tools (e.g. aapt.exe, aidl.exe) when
--host_cpu is one of x64_windows{,_msys,_msvc}.
On Linux/MacOS we create a wrapper script for
these tools and data-depend on
SDK/build-tools/VERSION/lib/*, but on Windows we
have no runfiles support and Bazel just creates a
junction to SDK/build-tools, so all the actual
tools are there where the binaries expect them.
Also change the ":fail" target to select srcs on
the host platform and use a .cmd file on Windows.
See https://github.com/bazelbuild/bazel/issues/3264
Change-Id: Ica586fa1fd4914f4795b4387b449f1c5562164e0
PiperOrigin-RevId: 160383278
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
Use Java implementation of singlejar on FreeBSD, and roll forward change 157473007.
*** Original change description ***
Automated g4 rollback of commit d894345ed88f8adce600b66a310b5210d0bcb59c.
*** Reason for rollback ***
Breaks Bazel on FreeBSD: http://ci.bazel.io/view/Dashboard/job/Bazel/JAVA_VERSION=1.8,PLATFORM_NAME=freebsd-11/1542/console
*** Original change description ***
Use cc implementation of singlejar except on Windows.
Change-Id: Ie4a2db2a6fa1ea86f4bdd42cd806f6804a0c56d4
PiperOrigin-RevId: 157729503
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This will be used to add some tests and targets to the Bazel codebase that build and run successfully when android_sdk_repository is in the WORKSPACE and silently skip if it is not.
Example deps of a library that links against dx.jar:
```
deps = select({
"//external:has_androidsdk": ["//external:android/dx_jar_import"],
"//conditions:default": [],
}),
```
Also adds tests that config_setting works as expected when propagated through an alias or bind rule.
RELNOTES: None
PiperOrigin-RevId: 157627472
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
Breaks Bazel on FreeBSD: http://ci.bazel.io/view/Dashboard/job/Bazel/JAVA_VERSION=1.8,PLATFORM_NAME=freebsd-11/1542/console
*** Original change description ***
Use cc implementation of singlejar except on Windows.
Change-Id: Ie4a2db2a6fa1ea86f4bdd42cd806f6804a0c56d4
PiperOrigin-RevId: 157567871
|
|
|
|
|
| |
Change-Id: Ie4a2db2a6fa1ea86f4bdd42cd806f6804a0c56d4
PiperOrigin-RevId: 157473007
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This will make it easier to build the desugarer tool from the Bazel source tree as an executable (deploy) jar and then use it for something else.
For example, with this CL, you can do the following steps to get a standalone
desugarer binary:
1. git clone https://github.com/bazelbuild/bazel
2. bazel build //src/tools/android/java/com/google/devtools/build/android/desugar:desugar_bin_deploy.jar
3. cp bazel-bin/src/tools/android/java/com/google/devtools/build/android/desugar/desugar_bin_deploy.jar ~/bin/desugar.jar
And then you can invoke desugar without bazel with `java -jar ~/bin/desugar.jar`.
https://github.com/bazelbuild/bazel/issues/2975
RELNOTES: None
PiperOrigin-RevId: 155629711
|
|
|
|
| |
PiperOrigin-RevId: 155287620
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add compile_jars Skylark accessor to JavaProvider. This outputs the
non-recursive set of jars needed to build with this target. Allows
Skylark tools to get the same set of compile_jars that JavaLibrary is
getting.
Added test that verifies Skylark was getting lists from both
compile_jars and transitive_runtime_jars of the expected length. Then,
verified (via test code) those nested sets were identical to the ones
provided by the java_library.
To reviewers:
First, would like to add documentation flags to these fields in
JavaProvider. Is it possible, instead of adding them to this map to
follow use the @SkylarkCallable annotation to expose methods on
JavaProvider instead? It would then also be nice to mark these as
experimental since won't really know the final API until
java_skylark_library sandwich is done.
I also tested this locally via bazel build //src:bazel and then doing
~/bazelsandbox/bazel/bazel-bin/src/bazel test SomeTarget in a different
repo that had a .bzl file trying to use compile_jars.
Change-Id: I1779c1b6303f36e50076c3479bfcb15a25aa95d8
PiperOrigin-RevId: 155191816
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes https://github.com/bazelbuild/bazel/issues/509.
Example output:
```
$ bazel build //:all
INFO: Found 1 target...
ERROR: /usr/local/google/home/ajmichael/.cache/bazel/_bazel_ajmichael/7fcc7480abc634522e5c0cfe6b85b583/external/bazel_tools/tools/android/BUILD:236:1: Executing genrule @bazel_tools//tools/android:no_android_sdk_repository_error failed: Process exited with status 1 [sandboxed].
This build requires an Android SDK. Please add the android_sdk_repository rule to your WORKSPACE.
Use --strategy=Genrule=standalone to disable sandboxing for the failing actions.
Target //:lib failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 0.327s, Critical Path: 0.10s
```
RELNOTES: Attempting to build an Android target without setting up android_sdk_repository will now produce a helpful error message.
PiperOrigin-RevId: 155158667
|
|
|
|
|
|
|
| |
Also, open source two more tests.
RELNOTES: None
PiperOrigin-RevId: 155129416
|
|
|
|
|
|
|
|
|
|
|
|
| |
The logic is already in Bazel but wasn't available to build rules.
This change makes it available, but still requires data binding's
{build|run}time libraries to be checked into appropriate depot
spots for everything to work.
Followup changes will make those libraries easily available.
Issue: #2694
PiperOrigin-RevId: 153359861
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
files for all android system images installed in the SDK. For system images that are not installed, create genrule "poison pills" that print a helpful error message if you attempt to build them.
These filegroups are intended to be used as the system_image attribute of the android_device rule.
Example:
$ bazel build @android_test_support//tools/android/emulated_devices/pixel:android_25_x86
Extracting Bazel installation...
.
INFO: Found 1 target...
ERROR: /usr/local/google/home/ajmichael/.cache/bazel/_bazel_ajmichael/efa32264346ef1fc4fec492202b88b31/external/androidsdk/BUILD.bazel:56:1: Executing genrule @androidsdk//:emulator_images_android_25_x86 failed: Process exited with status 1 [sandboxed].
This rule requires that the Android SDK used by Bazel has the following system image installed: emulator_images_android_25_x86. Please install this system image through the Android SDK Manager and try again.
RELNOTES: None
PiperOrigin-RevId: 152889824
|
|
|
|
|
|
| |
RELNOTES: None
PiperOrigin-RevId: 152292294
|
|
|
|
|
|
|
|
| |
#1391
RELNOTES: None
PiperOrigin-RevId: 152179305
|
|
|
|
|
|
| |
--
PiperOrigin-RevId: 150372383
MOS_MIGRATED_REVID=150372383
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
this flag isn't needed with unknown commit
*** Original change description ***
Add --activity_name_file flag and modify --start flag in incremental_install. This is a first step
to add the ability for mobile-install to wait for the debugger before starting the app.
--
PiperOrigin-RevId: 150340712
MOS_MIGRATED_REVID=150340712
|
|
|
|
|
|
| |
--
PiperOrigin-RevId: 150194430
MOS_MIGRATED_REVID=150194430
|
|
|
|
|
|
|
|
| |
A previous change added this filegroup with the name %s_files. Recent discussions have suggested changing the naming convention to be a prefix instead before it is too late.
--
PiperOrigin-RevId: 150117207
MOS_MIGRATED_REVID=150117207
|
|
|
|
|
|
|
|
|
|
| |
incremental_install. This is a first step
to add the ability for mobile-install to wait for the debugger before starting the app.
--
PiperOrigin-RevId: 149897848
MOS_MIGRATED_REVID=149897848
|
|
|
|
|
|
|
|
|
|
| |
Also, remove some tests from android_integration_test.sh that are now covered by AndroidSdkRepositoryTest. This should hopefully reduce breakages of android_integration_test.sh that are not caught until the change makes its way to Jenkins.
I haven't yet figured out how to move the environment variable settings tests into AndroidSdkRepositoryTest.
--
PiperOrigin-RevId: 147864723
MOS_MIGRATED_REVID=147864723
|
|
|
|
|
|
|
|
| |
Creates filegroup containing sdk path in Bazel embedded Android SDK repository.
--
PiperOrigin-RevId: 147426838
MOS_MIGRATED_REVID=147426838
|
|
|
|
|
|
|
|
|
|
| |
This caused a failure in http://ci.bazel.io/job/Gerrit-bazel-tests/368/BAZEL_VERSION=latest,PLATFORM_NAME=ubuntu_15.10-x86_64/console
where the genrule used java from a jdk7 instead of a jdk8.
--
PiperOrigin-RevId: 147198518
MOS_MIGRATED_REVID=147198518
|
|
|
|
|
|
|
|
|
|
| |
Fixes https://github.com/bazelbuild/bazel/issues/2222.
RELNOTES: Support for Java 8 lambdas, method references, type annotations and repeated annotations in Android builds with --experimental_desugar_for_android.
--
PiperOrigin-RevId: 147109786
MOS_MIGRATED_REVID=147109786
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
Rolling forward with fixes for the incremental tool.
*** Original change description ***
Automated [] rollback of commit d11d510c571b10787856395709f9ad945ca70bb2.
*** Reason for rollback ***
--
PiperOrigin-RevId: 146940409
MOS_MIGRATED_REVID=146940409
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
--
PiperOrigin-RevId: 146820790
MOS_MIGRATED_REVID=146820790
|
|
|
|
|
|
|
|
|
| |
This makes the code simpler as well as reducing the number of targets to build.
It also makes testing and profiling different action strategies vastly easier.
--
PiperOrigin-RevId: 146812659
MOS_MIGRATED_REVID=146812659
|
|
|
|
|
|
| |
--
PiperOrigin-RevId: 146300001
MOS_MIGRATED_REVID=146300001
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
Rollforward with fixes and a test. Previously AndroidSdkRepository required that system-images/ directory exist in the Android SDK. However, it does not exist until you download the first system image.
*** Original change description ***
Automated [] rollback of commit 06072c557290b97cb2d2e4fd255b647a9208cb5c.
*** Reason for rollback ***
Broke andriod_sdk_repository on ci.bazel.io
See https://github.com/bazelbuild/bazel/issues/2465
*** Original change description ***
Make android_sdk_repository discover all system-images directories in the sdk.
This will be used by the upcoming android_device rule that launches emulators.
--
PiperOrigin-RevId: 146258003
MOS_MIGRATED_REVID=146258003
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
Broke andriod_sdk_repository on ci.bazel.io
See https://github.com/bazelbuild/bazel/issues/2465
*** Original change description ***
Make android_sdk_repository discover all system-images directories in the sdk.
This will be used by the upcoming android_device rule that launches emulators.
--
PiperOrigin-RevId: 146235800
MOS_MIGRATED_REVID=146235800
|
|
|
|
|
|
|
|
| |
This will be used by the upcoming android_device rule that launches emulators.
--
PiperOrigin-RevId: 146183077
MOS_MIGRATED_REVID=146183077
|
|
|
|
|
|
| |
--
PiperOrigin-RevId: 146142811
MOS_MIGRATED_REVID=146142811
|
|
|
|
|
|
|
|
| |
Note that these aliases are intentionally not yet functional. Nothing should be trying to build them.
--
PiperOrigin-RevId: 145746166
MOS_MIGRATED_REVID=145746166
|
|
|
|
|
|
|
|
| |
attributes if they aren't present in the original manifest. Before, it would make them None, and aapt would fail.
--
PiperOrigin-RevId: 145726642
MOS_MIGRATED_REVID=145726642
|
|
|
|
|
|
|
|
| |
Saves 12kB! :)
--
PiperOrigin-RevId: 144997917
MOS_MIGRATED_REVID=144997917
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
api_level is no longer required. It now sets the default android_sdk that is used if the --android_sdk flag is not passed. If it is not set, the highest api_level will be used as the default.
The new behavior is demonstrated by the following example:
$ ls $ANDROID_HOME/platforms
android-21 android-22 android-23
$ cat WORKSPACE
android_sdk_repository(
name = "foo",
)
$ bazel build //java/my/app # uses api level 23
$ bazel build --android_sdk=@foo//:sdk-22 //java/my/app # uses api level 22
$ cat > WORKSPACE <<EOF
android_sdk_repository(
name = "foo",
api_level = 21,
)
EOF
$ bazel build //java/my/app # uses api level 21
$ bazel build --android_sdk=@foo//:sdk-23 //java/my/app # uses api level 23
See https://github.com/bazelbuild/bazel/issues/2284 for the master plan for android_sdk_repository.
RELNOTES: android_sdk_repository no longer requires api_level. If one is not specified, the highest android platform installed will be used. Furthermore, android_sdk's are created for all android platforms installed and can be specified with the --android_sdk flag.
--
PiperOrigin-RevId: 144258881
MOS_MIGRATED_REVID=144258881
|
|
|
|
|
|
| |
--
PiperOrigin-RevId: 143825037
MOS_MIGRATED_REVID=143825037
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This should help clear up the confusion that caused https://github.com/bazelbuild/bazel/issues/2283.
Now all of the following work:
bazel build //tools/android/...
bazel test //tools/android/...
bazel build @bazel_tools//tools/android/...
--
PiperOrigin-RevId: 143666995
MOS_MIGRATED_REVID=143666995
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
breaks bazel:
https://github.com/bazelbuild/bazel/issues/2283
http://ci.bazel.io/job/bazel-tests/432/BAZEL_VERSION=HEAD,PLATFORM_NAME=linux-x86_64/console
*** Original change description ***
Remove broken and unused Android tools aliases.
--
PiperOrigin-RevId: 142768488
MOS_MIGRATED_REVID=142768488
|
|
|
|
|
|
| |
--
PiperOrigin-RevId: 142702623
MOS_MIGRATED_REVID=142702623
|
|
|
|
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
Rolling forward, intentionally breaking loading phase (and therefore `bazel fetch`) for android_binary in Bazel if no android_sdk_repository is set up.
Will not submit until Tensorflow's use case is cleaned up in https://github.com/tensorflow/tensorflow/pull/6225.
--
PiperOrigin-RevId: 142068703
MOS_MIGRATED_REVID=142068703
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
*** Reason for rollback ***
Rollforward with fixes to android_integration_test.sh. The test now uses the new syntax for the Support Library AARs.
All CIs that have been created since last December should have this library installed due to https://github.com/bazelbuild/continuous-integration/blob/master/mac/mac-android.sh#L36.
*** Original change description ***
Automated [] rollback of commit f699b502ef6a57dc68570486191ad1c318e8fd1b.
*** Reason for rollback ***
Breaks android_integration_test.sh which relies on the old targets.
I don't have time to update the test to use the new targets at the moment, so rolling the change back for now.
https://github.com/bazelbuild/bazel/issues/2159
RELNOTES:
--
PiperOrigin-RevId: 141233182
MOS_MIGRATED_REVID=141233182
|