Aapt is not working correctly - cannot generate R IDs on fresh project

匿名 (未验证) 提交于 2019-12-03 01:34:02

问题:

I am running headless Ubuntu Server, with Jenkins, for Android builds, mostly for testing, several physical devices are connected all the time.

Week ago it started to behave wierd, it was impossible to have sucesful build on this machine. At first I thought it might be something with code, then pom.xml files.

Maven projects are throwing the same error (132):

[INFO] Illegal instruction (core dumped) [ERROR] Error when generating sources. ... Caused by: com.jayway.maven.plugins.android.ExecutionException: ANDROID-040-001: Could not execute: Command = /bin/sh -c cd /var/lib/jenkins/sks/Wieliczka/app && /opt/android-sdk/build-tools/18.0.1/aapt package -m -J /var/lib/jenkins/sks/Wieliczka/app/target/generated-sources/r -M /var/lib/jenkins/sks/Wieliczka/app/AndroidManifest.xml -S /var/lib/jenkins/sks/Wieliczka/app/res -S /var/lib/jenkins/sks/Wieliczka/app/target/unpack/apklibs/com.actionbarsherlock_actionbarsherlock_apklib_4.4.0/res --auto-add-overlay -A /var/lib/jenkins/sks/Wieliczka/app/assets -I /opt/android-sdk/platforms/android-17/android.jar, Result = 132 

I created fresh project with "android create project" command, then I tried to build it with Ant, same error in result

[aapt] Generating resource IDs...  BUILD FAILED /opt/android-sdk/tools/ant/build.xml:649: The following error occurred while executing this line: /opt/android-sdk/tools/ant/build.xml:690: null returned: 132 

Machine runs on 32bit processor and it is pretty old, I believe ~7 years old

Ubuntu version:

Distributor ID: Ubuntu Description:    Ubuntu 12.04.2 LTS Release:        12.04 Codename:       precise 

Java version

java version "1.7.0_25" Java(TM) SE Runtime Environment (build 1.7.0_25-b15) Java HotSpot(TM) Client VM (build 23.25-b01, mixed mode) 

Android SDK is up to date, actually I already redownloaded and reinstalled it twice :-/

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!