Package Details: android-sdk-build-tools r33-1

Git Clone URL: (read-only, click to copy)
Package Base: android-sdk-build-tools
Description: Build-Tools for Google Android SDK (aapt, aidl, dexdump, dx, llvm-rs-cc)
Upstream URL:
Keywords: android
Licenses: custom
Submitter: xgdgsc
Maintainer: mynacol
Last Packager: mynacol
Votes: 474
Popularity: 1.18
First Submitted: 2013-05-16 03:44 (UTC)
Last Updated: 2022-06-11 23:35 (UTC)

Latest Comments

oneup commented on 2022-04-25 17:18 (UTC)

Package doesn't provide dx - description should be updated and broken /usr/bin/dx link should be removed

mynacol commented on 2022-04-23 13:43 (UTC)

@acer189 That's expected. I included the package.xml in the package, so you don't have to accept the license in Android Studio.

acer189 commented on 2022-04-17 10:16 (UTC) (edited on 2022-04-17 10:17 (UTC) by acer189)

Unfortunately an update to the current version did not work for me. The error message:

Error: The operation could not be performed (Conflicting files) android-sdk-build-tools: /opt/android-sdk/build-tools/32.0.0/package.xml exists in the >file system Errors occurred, no packages were updated.

mynacol commented on 2022-04-09 17:40 (UTC)

@OJFord: I updated the package, it now contains the package.xml file. This should be enough to accept the licence.

OJFord commented on 2022-03-10 15:31 (UTC)

Can the licence agreements be accepted without having to install aur/android-studio as well?

mynacol commented on 2021-09-06 12:06 (UTC)

Sorry for the error, didn't notice the error locally (dirty build, yay). Should now be fixed with the r31-2 release

malte commented on 2021-09-06 11:53 (UTC)

Did the last updates break stuff? Now I get this:

Cloning into 'android-sdk-build-tools'...
~/android-sdk-build-tools ~
==> Making package: android-sdk-build-tools r31-1 (Mon 06 Sep 2021 01:30:45 PM CEST)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
  -> Downloading
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 52.3M  100 52.3M    0     0  83.8M      0 --:--:-- --:--:-- --:--:-- 83.8M
==> Validating source files with sha512sums... ... Passed
==> Extracting sources...
  -> Extracting with bsdtar
==> Entering fakeroot environment...
==> Starting package()...
install: cannot stat '/home/notroot/android-sdk-build-tools/src/android-11/NOTICE.txt': No such file or directory
==> ERROR: A failure occurred in package().
The command '/bin/bash -c git clone &&     pushd android-sdk-build-tools &&     makepkg --noconfirm --syncdeps --rmdeps --install --clean &&     popd' returned a non-zero code: 4

Insider a docker container built on archlinux:base-devel

nimaipatel commented on 2021-09-06 11:50 (UTC) (edited on 2021-09-06 11:51 (UTC) by nimaipatel)

Please update _android=android-11 to _android=android-12 in the PKGBUILD.

JcNils commented on 2021-01-07 20:46 (UTC)

Thanks! It updated fine, and it seems to be working properly.

mynacol commented on 2021-01-04 21:03 (UTC)

Thanks @lace and @JcNils for the reports. I have removed the symlink for lld. No other symlinks are conflicting with the packages in the official repo.

Moving the symlink to /usr/local/bin is no option, no package should use this directory.

JcNils commented on 2021-01-04 17:39 (UTC) (edited on 2021-01-04 17:39 (UTC) by JcNils)

Trying to update or remove. I got the same error as @1ace

txtsd commented on 2021-01-03 09:42 (UTC) (edited on 2021-01-04 16:56 (UTC) by txtsd)

Maybe put the binaries/symlinks in /usr/local/bin/

1ace commented on 2021-01-03 08:39 (UTC)

528650baac4e broke the package:

error: failed to commit transaction (conflicting files)
android-sdk-build-tools: /usr/bin/lld exists in filesystem (owned by lld)

txtsd commented on 2020-12-30 14:06 (UTC) (edited on 2020-12-30 14:46 (UTC) by txtsd)

@mynacol Am I manually supposed to source /etc/profile in my zshenv or equivalent? Because the binaries are not in my path.

Nevermind. Reinstalling did the trick. Not sure why it wasn't working before.

mynacol commented on 2020-12-30 14:04 (UTC)

If anyone has warnings regarding the permissions of files, I apologize. The easiest method to fix this is to uninstall and reinstall the latest version of this package.

mynacol commented on 2020-12-30 14:00 (UTC)

@txtsd append_path is a function that /etc/profile provides for scripts in /etc/profile.d/. Any login shell will source /etc/profile, which will source all /etc/profile.d/ scripts. You should do this, else e.g. perl executables under /usr/bin/vendor_perl/ are not in your PATH.

Nonetheless, I did introduce the symlinks, primarily, because in the directory with the executables are other files. Anyone who wants to use other exectables with the same name should prepend the PATH.

txtsd commented on 2020-12-27 13:56 (UTC)

Also why not just make symlinks to the executables in /usr/bin/ since this package is not tied to any version?

txtsd commented on 2020-12-27 12:41 (UTC) (edited on 2020-12-27 12:41 (UTC) by txtsd)

/etc/profile.d/ line 1: append_path: command not found

What package is this command a part of?

OJFord commented on 2020-12-16 17:12 (UTC)

@mynacol Ah yes, that would be good please - I have a better reason now too, since upgrading meant my (it happened to be a symlink, but, equivalently, PATH) solution broke, due to the directory name change.

I don't think I source from /etc/profile.d/* currently, but it seems like I probably should be, so that's fine, thanks.

mynacol commented on 2020-11-29 17:57 (UTC)

@OJFord Up to now, no one has complained. If you want it, I can set it up. In the PKGBUILD is a relevant section, but commented out.

OJFord commented on 2020-11-29 17:08 (UTC)

Is it intended that aapt et al. end up in /opt/android-sdk/build-tools/30.0.2/; likely not on PATH?

mynacol commented on 2020-08-28 10:13 (UTC)

Thanks @somekool for your prior work!

somekool commented on 2020-08-27 23:08 (UTC)

I don't know how I ended up becoming the maintainer of this project. but I am definitely not the right person. please take it from me.

mynacol commented on 2020-06-22 08:58 (UTC)

@Kppqju77 You are right, Android Studio serves r30.0.0, so I updated the package accordingly

Kppqju77 commented on 2020-06-22 06:17 (UTC) (edited on 2020-06-22 06:29 (UTC) by Kppqju77)

The #Pkg.Revision with rc4 might refer to the fact that the 30.0.0 has the same content as rc4... But in android studio & sdkmanager it is listed without the "rc4", so I think it's out of RC...

mynacol commented on 2020-06-16 10:45 (UTC)

For me it is not clear, if version 30 is a release candidate or not. lists version 30.0.0 as release candidate 4.

The zip at lists in android-11/

#Pkg.Revision=30.0.0 rc4

If nobody clarifies, I rather wait to be sure it is a stable version.

Kppqju77 commented on 2020-06-16 10:33 (UTC) (edited on 2020-06-16 10:36 (UTC) by Kppqju77)

For the profile.d addin in version 30 we need to be careful as DL address use "30", but profile.d addin needs "30.0.0". I had to declare a


echo 'export PATH=$PATH:/opt/android-sdk/build-tools/'"$_longver/" > etc/profile.d/${pkgname}.sh
echo 'setenv PATH ${PATH}:/opt/android-sdk/build-tools/'"$_longver/" > etc/profile.d/${pkgname}.csh

This will change with 30.0.1 release anyway (usually DL link use the same format then)

BubuIIC commented on 2020-05-25 00:18 (UTC)

Debian has bash completion and a man page for aapt, would it be possible to add this to this package?

BubuIIC commented on 2020-05-19 15:36 (UTC)

Any particular reason why the profile.d addin is disabled by default?

kyak commented on 2020-03-05 18:55 (UTC)

My previous comment was actually wrong: fdroid needs aapt. I thought it doesn't because repo was already up to date.

So this needs to be packaged somehow. So far it works manually.

kyak commented on 2020-02-22 09:13 (UTC)

@mynacol, thanks for the hints!

I was able to manually download and extract debian's aapt package and all the dependencies. For testing, I've used combination of ANDROID_HOME and LD_LIBRARY_PATH to make sure that aapt tool works and fdroid can update repo without any problem.

Just when I started thinking about the best way to package all this mess (debian, did you really have to split each and every android library?), I realized that fdroid only uses aapt when ANDROID_HOME is set. After I've unset this env variable, fdroid switched to using python-pyaxmlparser, which is fine t me.

So it turned out that I don't need aapt after all.

If someone does actually need it, here is the list of needed debian packages:

aapt android-libaapt android-libandroidfw android-libbacktrace android-libbase android-libcutils android-liblog android-libunwind android-libutils android-libziparchive

mynacol commented on 2020-02-21 14:58 (UTC)

Hey @kyak, I haven't tried this. It seems Google doesn't provide downloadable executables for ARM, so this projcet cannot easily add support for ARM.

But a web search reveals that it is possible, e.g. by building it from source. [1] is years old, but may help you; Debian seems to build it too, maybe you can work with their packages [2].

In any case, if you have a working strategy to have the build-tools for ARM, you can post it here and we may be able to include it.

Good luck!

[1] [2]

kyak commented on 2020-02-21 14:21 (UTC)

Hey guys! Have any of you had success using android-sdk-build-tools on ARM? It trying to make fdroid server work on ARM here...

mynacol commented on 2020-02-04 19:56 (UTC)

I just bumped the version to 29.0.3, thanks @kidonng for the notice.

At the same time, I switched to sha512 as checksum, as it is indeed faster than sha256 on modern computers. See for more information.

somekool commented on 2019-10-21 02:34 (UTC)

lib32-* should be optional now, I bump the version to 0.29 as offered by @mynacol

should anyone else wants to maintain this package, please step up

mynacol commented on 2019-10-15 14:17 (UTC) (edited on 2020-06-22 09:01 (UTC) by mynacol)

I updated the build tools to version 29.0.2 by applying the following diff:

From 311a5db6ffddfc6b6884ec5e6f7fa4c63498f524 Mon Sep 17 00:00:00 2001

 PKGBUILD | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/PKGBUILD b/PKGBUILD
index 2ec5ba6..99f8530 100644
@@ -1,7 +1,7 @@
 # Maintainer: xgdgsc <xgdgsc @t gmail dot com>

 pkgdesc='Build-Tools for Google Android SDK (aapt, aidl, dexdump, dx, llvm-rs-cc)'
@@ -14,8 +14,8 @@ depends_x86_64=('lib32-gcc-libs' 'lib32-zlib')


 package() {

rnmhdn commented on 2019-07-17 16:44 (UTC)

@somekool @xgdgsc Thank you so much for maintaining this package. I have a small question. Do you have any specific reason for not removing lib32-* from the dependencies? You have been asked to do that twice in 2017 but you didn't give any response and again twice in 2019(including myself:D)

kyak commented on 2019-05-19 09:45 (UTC)

Please remove the lib32-* dependencies or mark them as optional.

I have to enable the multilib repository just for lib32-zlib dependency of android-sdk-build-tools.

rpodgorny commented on 2018-09-18 23:12 (UTC)

just a cosmetic note -> the PKGBUILD has the executable flag...

xgdgsc commented on 2018-09-18 01:10 (UTC)

Adding to PATH used to cause problems . I don 't know if it still does now. You' d better create yourself for now.

fordprefect commented on 2018-09-17 11:43 (UTC)

could you add a link to the apksigner binary to /usr/bin so it appears in the PATH?

mattsturgeon commented on 2018-05-13 14:10 (UTC) (edited on 2018-05-13 14:15 (UTC) by mattsturgeon)

As hinted at earlier by @einbisschen, this package should create /etc/profile.d/ with the content export PATH=$PATH:/opt/android-sdk/build-tools/27.0.3

Perhaps adding mkdir -p etc/profile.d and echo -e "export PATH=\"\$PATH:/opt/$_sdk/build-tools/$ver\"\n" > $pkgdir/etc/profile.d/$ to PKGBUILD would do the trick?

EDIT: it may also make sense to have a latest symlink... Something like ln -sf /opt/$_sdk/build-tools/$ver opt/$_sdk/build-tools/latest, if so perhaps this should be what is added to the PATH instead. Although it is probably a good idea to check no higher version already exists, which may make a simple feature a bit more complex.

somekool commented on 2017-08-19 16:32 (UTC)

@xgdgsc If I get this thing to work locally, you can give me write access if you are still looking for a co-maintainer

somekool commented on 2017-08-19 16:30 (UTC)

please remove lib32-* from the dependencies

farwayer commented on 2017-08-01 00:53 (UTC)

Look like lib32-gcc-libs can be removed and ncurses5-compat-libs, java-environment, bash should be added for x86_64.

xgdgsc commented on 2017-06-22 02:44 (UTC)

android-sdk-build-tools E: Dependency lib32-zlib detected and not included (libraries ['usr/lib32/'] needed in files ['opt/android-sdk/build-tools/26.0.0/mipsel-linux-android-ld', 'opt/android-sdk/build-tools/26.0.0/i686-linux-android-ld', 'opt/android-sdk/build-tools/26.0.0/aarch64-linux-android-ld', 'opt/android-sdk/build-tools/26.0.0/arm-linux-androideabi-ld']) android-sdk-build-tools E: Dependency clang detected and not included (libraries ['usr/lib/'] needed in files ['opt/android-sdk/build-tools/26.0.0/llvm-rs-cc']) android-sdk-build-tools W: Dependency included and not needed ('ncurses5-compat-libs') This is namcap output.

lonaowna commented on 2017-06-21 14:50 (UTC) (edited on 2017-06-21 16:05 (UTC) by lonaowna)

@dreamingincode, I tested all the binaries in /opt/android-sdk/build-tools/26.0.0, and all of them seem to work fine. All that link to libz link to the 64-bit one. (check with ldd *) While testing I also found that /opt/android-sdk/build-tools/26.0.0/bcc_compat doesn't work without the ncurses5-compat-libs package. So that should probably be added as a dependency.

dreamingincode commented on 2017-06-21 14:39 (UTC) (edited on 2017-06-21 15:20 (UTC) by dreamingincode)

[Removed for being incorrect]

lonaowna commented on 2017-06-21 14:35 (UTC)

The lib32* dependencies are no longer needed. You can just replace depends_i686 and depends_x86_64 with: depends=('gcc-libs' 'zlib') ('gcc-libs' isn't strictly needed either, since it is part of the base group)

dreamingincode commented on 2017-04-27 02:05 (UTC)

25.0.3 is out: db95f3a0ae376534d4d69f4cdb6fad20649f3509

xgdgsc commented on 2016-11-29 01:59 (UTC)

Anyone interested in becoming co-maintainers?

einbisschen commented on 2016-09-28 06:38 (UTC)

I needed to create the file "/etc/profile.d/" with the content "export PATH=$PATH:/opt/android-sdk/build-tools/24.0.2" to make the commands work.

xgdgsc commented on 2016-09-26 13:17 (UTC)

@TamasBarta Why flag? I didn' t find a new version here .

berb commented on 2016-08-24 21:03 (UTC)

Seems like the SHA1 checksum is wrong in the PKGBUILD. The correct one seems to be 84f18c392919a074fcbb9b1d967984e6b2fef8b4 at the moment (as reported in

normalraw commented on 2016-08-24 13:46 (UTC)

There exists a version mismatch wherein the package is installed to `/opt/android-sdk/build-tools/24.0.0` as parsed from `` even though version 24.0.1 has been specified in the PKGBUILD. As a result, uncommenting the lines responsible for setting $PATH do not work. Thoughts?

xgdgsc commented on 2016-08-13 01:58 (UTC)

@kazik117 I don' t have access to an arch machine now. Would you mind me adding you to co-maintainers to change this?

kazik117 commented on 2016-08-12 20:27 (UTC)

There is a bug version string in file. I added sed -i "s@24\.0\.0@24\.0\.1@g" "${srcdir}/$_android/" before copying files to destination.

xgdgsc commented on 2016-08-01 02:00 (UTC)

Looking for co-maintainers.

xgdgsc commented on 2016-07-06 01:49 (UTC)

Thanks. Changed.

sjakub commented on 2016-07-05 20:01 (UTC) (edited on 2016-07-05 20:01 (UTC) by sjakub)

I am getting this warning while building with gradle: Observed package id 'build-tools;24.0.0' in inconsistent location '/opt/android-sdk/build-tools/24' (Expected '/opt/android-sdk/build-tools/24.0.0') It might be a good idea to use standard paths...

xgdgsc commented on 2016-04-04 01:08 (UTC)

Thsnks. Changed.

edh commented on 2016-04-03 09:08 (UTC)

Please use depends_i686 and depends_x86_64 [1] instead of checking the CARCH. [1]

xgdgsc commented on 2015-09-20 12:16 (UTC)

There' s a package for that: May need to change a few lines as I commented there.

zman0900 commented on 2015-09-20 10:27 (UTC)

Some of the libs included in this are still linked to ncurses 5. Not sure if there is anything that can even be done about it since they come pre-built, but it's probably going to cause problems. └──╼ for f in $(find /opt/android-sdk/build-tools -type f -executable); do unset OUT; OUT=$(ldd $f | grep 'ncurses.*\.so\.5'); if [ -n "$OUT" ]; then echo "====> $f"; echo -e $OUT; echo ""; fi; done ====> /opt/android-sdk/build-tools/23.0.1/lib/ => not found => not found ====> /opt/android-sdk/build-tools/23.0.1/lib/ => not found ====> /opt/android-sdk/build-tools/23.0.1/lib/ => not found => not found => not found ====> /opt/android-sdk/build-tools/23.0.1/lib/ => not found => not found ====> /opt/android-sdk/build-tools/23.0.1/llvm-rs-cc => not found => not found => not found ====> /opt/android-sdk/build-tools/23.0.1/bcc_compat => not found => not found => not found => not found

davidbailey00 commented on 2015-09-19 10:00 (UTC)

sorry, thought there was a v24 (as android-sdk is v24) so I flagged, can't seem to unflag now.

xgdgsc commented on 2015-05-07 02:30 (UTC)

@Jesin Why flag out of date? There is no new version.

incomingstick commented on 2015-05-05 16:12 (UTC)

yaourt output when updating: aur/android-sdk-build-tools r19.0.3-1 -> r22.0.1-1

egore911 commented on 2014-11-01 18:27 (UTC)

21.1 was released

felixonmars commented on 2014-10-24 15:45 (UTC)

Looks like a typo in PKGBUILD: _ver=21.02. => _ver=21.0.2

mvdan commented on 2014-07-17 07:06 (UTC)

No idea, sorry. But I suppose sed isn't that bad.

tsp commented on 2014-07-09 01:50 (UTC)

@mvdan: Yeah that should work. I tried that at some point but it didn't work. It's more likely that I botched it though. Is there any way to do that in the pkgbuild that doesn't require some epic sed-fu or something?

mvdan commented on 2014-06-30 15:43 (UTC)

@Teasp00n: What about placing them in the right order, so that the clang package binary takes precedence over the one in this package? I think that we should place the clang path before this one in order for that to work. I suppose we can play with the names of the scripts to make the other one come before this one. This would not normally happen since 'android-' comes before 'clang', I guess. Also, the right package version is 20.0.0. If you want to use the number 20 that's fine, but the install path should still be 20.0.0 as in /opt/android-sdk/build-tools/20.0.0. Changing it is just asking for trouble :)

tsp commented on 2014-06-29 08:29 (UTC)

@mvdan: Sorry for the extremely late reply. I didn't see your comment. The problem is `which clang` returns the one in the android tools directory and not the version of clang explicitly installed on the system. I've had local builds fail because of this. Something about the symbols of libraries not being compatible/ valid. If I remove the android build tools from the path the problem is solved. That said, I also use the tools on the command line. I would prefer that they were still on the path, it's only the bundled clang I have an issue with.

commented on 2014-06-26 20:30 (UTC)

Upgraded PKGBUILD for r20 and switch to https

klusark commented on 2014-06-26 18:00 (UTC)

Version 20 is out

mvdan commented on 2014-05-22 15:10 (UTC)

For what it's worth, I do use the build-tools from the command line, and not having PATH set up automatically is a tad sub-optimal. What problems does Clang have with this, exactly? Are there some binaries that conflict?

xgdgsc commented on 2014-04-18 06:15 (UTC)

Well, if it conflicts, I think removing the adding to PATH should be fine. Most people just use IDEs that can find these things. Is removing it OK for most of you?

tsp commented on 2014-04-18 05:55 (UTC)

/etc/profile.d/ is adding the build-tools to the PATH (I would hazard a guess deliberately ;) ). This does however cause issues when attempting to link with libclang. Are there are accepted solutions to this currently? I can override the PATH for the terminal session I'm using as a workaround but I would prefer something a little more seamless. Thoughts?

a172 commented on 2014-02-28 15:11 (UTC)

I'm getting a trailing '/' on the path for this. I glanced at the PKGBUILD and didn't see why. Not a huge deal as it still works, but I thought you may want to look into it.

B_Lizzard commented on 2014-01-31 15:28 (UTC)

Not outdated, I accidentally clicked while trying to download it. :)

giniu commented on 2013-10-16 13:48 (UTC)

According to android sdk manager, there is already 18.1.1

commented on 2013-09-11 13:38 (UTC)

Sorry, it's not outdated. I clicked accidentally when trying to vote for it.

arielp commented on 2013-08-05 20:49 (UTC)

Possibly add options=('!strip')

xgdgsc commented on 2013-05-16 12:37 (UTC)

Google splitted platform-tools.