[TIMOB-17872] Android: Update to Android build tools ver.21 breaks the build process
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Critical |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2014-11-05T18:36:32.000+0000 |
Affected Version/s | Release 3.4.0, Release 3.4.1 |
Fix Version/s | Release 3.4.1, Release 3.4.2, Release 3.5.0, Release 4.0.0 |
Components | Android |
Labels | module_android_tooling_smoke, qe-3.4.1, qe-manualtest, qe-testadded |
Reporter | Lokesh Choudhary |
Assignee | Hieu Pham |
Created | 2014-10-17T19:36:48.000+0000 |
Updated | 2014-11-21T18:38:11.000+0000 |
Description
Attachments
File | Date | Size |
---|---|---|
build_errors.png | 2014-10-24T21:26:30.000+0000 | 424059 |
Check out the comments on: https://code.google.com/p/android/issues/detail?id=77629
[~ingo] but that issue is Windows-specific and this ticket is on Mac
Understood. It is suspiciously similar, though.
Yup, I experienced some similarities. I didn't update to V21 tools, but tried to use appcompat V21 in my SDK fork and modules, and that just doesn't work with the V20 tools, as some people reported on that thread.
After update to android build tools 21.0.2 , verified the issue on MAC OSX & Windows 8.1. The issue still exist. The build process is still failing for me.
Does it fail with exactly the same error? Note: https://android.googlesource.com/platform/frameworks/base/+/android-l-preview_r2/tools/aapt/AaptAssets.cpp, line 2864 as the likely line throwing the error.
@ingo- On win 8.1- 64 bit I see errors as below:
Nothing as you mentioned in your comment above. Might be titanium is showing the same error you mentioned but with a different error, not sure here though.
Another set of data: I tried creating a native Android app with the latest Android build tools with ADT + Eclipse and I'm seeing build errors; see build_errors.png. Tested on: OS: Yosemite (10.10) Eclipse: Luna (4.4.1) ADT: 23.0.4.1468518 Android SDK Tools: 23.0.5 Android SDK Platform-tools: 21 Android SDK Build-tools: 21.0.2
I have been trying to figure out a workaround on a Mac with no success. Here's what I have tried: 1. Put titanium.jar and aps-analytics.jar in a path without spaces 2. Extract titanium.jar and aps-analytics.jar and reference their directories 3. Rezip titanium.jar and aps-analytics.jar without compression 4. Run from android folder with relative paths 5. Generating bad zip files I've been analyzing the source at https://android.googlesource.com/platform/frameworks/base/+/android-l-preview_r2/tools/aapt/AaptAssets.cpp and I'm not convinced that it's the same code used in the final version. For example, after enabling verbose output, I see "Including resources from package: /Users/chris/titanium.jar", but then in the event of a bad zip file it will say "W/zipro (41322): Error opening archive /Users/chris/titanium.jar: Invalid file" and I don't see a clear code path where the zip file is being opened. A possible next step is to compile a custom aapt with more debug code.
The latest comment on https://code.google.com/p/android/issues/detail?id=77629#c112 indicates that there is NO issue with the OS X apps version. Either we're missing something, or they are.
Here's another source link: https://github.com/android/platform_frameworks_base/blob/master/tools/aapt/AaptAssets.cpp
We've filed a bug with Google. Please see here: https://code.google.com/p/android/issues/detail?id=78354
Today we got new android build tools update to ver 21.1 & I still see the build failure.
Environment: Appc Studio : 3.4.1.201410281743 Ti SDK : 3.4.1.v20141028145715 CLI : 3.4.1-dev Alloy : 1.5.1 GA Code Processor : 1.1.1 MAC Yosemite : 10.10 Android Build Tools : 21.1 SDK Platform Tools : 21
master PR: https://github.com/appcelerator/titanium_mobile/pull/6308 3.4.1 PR: https://github.com/appcelerator/titanium_mobile/pull/6310 3.4.X PR: https://github.com/appcelerator/titanium_mobile/pull/6311
Works as expected. Tested using Android tools 21, building to both Genymotion (4.4.2) and device (GNex 4.2.2)
Verified the fix. Build succeeds when android build tools 21.1 are installed. Closing. Environment: Appc Studio : 3.4.1.201410281743 Ti SDK : 3.4.1.v20141105104918, 3.4.2.v20141105104917, 3.5.0.v20141105133558 CLI : 3.4.1-alpha Alloy : 1.5.1 GA Code Processor : 1.1.1 MAC Yosemite : 10.10 Nexus 5 - Android 5.0 Android build tools : 21.1.0