Package Details: android-ndk r29-3

Git Clone URL: https://aur.archlinux.org/android-ndk.git (read-only, click to copy)
Package Base: android-ndk
Description: Android C/C++ developer kit
Upstream URL: https://developer.android.com/ndk/
Licenses: GPL, custom, LGPL
Replaces: android-ndk64
Submitter: sergej
Maintainer: migrev
Last Packager: migrev
Votes: 279
Popularity: 0.96
First Submitted: 2009-06-26 09:29 (UTC)
Last Updated: 2026-03-30 18:21 (UTC)

Latest Comments

1 2 3 4 5 6 .. 17 Next › Last »

medaminezghal commented on 2026-03-25 15:05 (UTC)

@migrev Android Studio can't find out the NDK, it needs package.xml file.

medaminezghal commented on 2026-02-21 06:43 (UTC) (edited on 2026-02-21 06:52 (UTC) by medaminezghal)

@migrev This is a modified PKGBUILD file to make SDKManager read the NDK:

# Maintainer: Miguel Revilla Rodríguez <yo at miguelrevilla dot com>
# Contributor: Chih-Hsuan Yen <yan12125@gmail.com>
# Contributor: Alexander F Rødseth <xyproto@archlinux.org>
# Contributor: Daniel Micay <danielmicay@gmail.com>
# Contributor: frownlee <florez.brownlee@gmail.com>

pkgname=android-ndk
pkgver=r29
_ndkver=29.0.14206865
pkgrel=2
pkgdesc='Android C/C++ developer kit'
arch=('x86_64')
url='https://developer.android.com/ndk/'
license=('GPL' 'LGPL' 'custom')
options=('!strip' 'staticlibs')
backup=("etc/profile.d/$pkgname.sh")
install="$pkgname.install"
replaces=('android-ndk64')
depends=('bash' 'glibc' 'gcc-libs' 'zlib')
# makedepends are just for making namcap happy. AUR packages are not added to
# avoid unneeded efforts
makedepends=('bzip2' 'libxcrypt-compat' 'python' 'perl' 'libc++')
optdepends=(
  'ncurses5-compat-libs: for curses module in bundled Python'
  'bzip2: for bz2 module in bundled Python'
  'libxcrypt-compat: for crypt module in bundled Python'
  'python: various helper scripts'
  'perl: various helper scripts'
  'libc++: for some LLVM components'
)
source=("$pkgname.sh"
        "package.xml")
source_x86_64=("https://dl.google.com/android/repository/$pkgname-${pkgver/./}-linux.zip")
# SHA1 sums is kept to follow upstream releases https://github.com/android-ndk/ndk/issues/673
sha1sums=('38c46b7b1a1c54a0845d027a8eaf37ed0447d3b2'
          '2d3d15bfd815a48e98fb4e19a4619fc43b02afe4')
sha1sums_x86_64=('87e2bb7e9be5d6a1c6cdf5ec40dd4e0c6d07c30b')
sha256sums=('2050ff500443f6cfa4567c02248cb3ec6ccbc67ce81b32d8dda79383c5103db2'
            '79ac075d543ece2d43784ef88791dc7fb32e9adec5ad0f3d24d62400e547a427')
sha256sums_x86_64=('4abbbcdc842f3d4879206e9695d52709603e52dd68d3c1fff04b3b5e7a308ecf')

package() {
  install -Ddm755 "$pkgdir"/opt
  mv $pkgname-${pkgver/./} "$pkgdir"/opt/$pkgname

  install -Dm644 $pkgname.sh -t "$pkgdir"/etc/profile.d/

  # make sdkmanager and gradle recognize NDK
  install -Ddm755 "$pkgdir"/opt/android-sdk/ndk
  ln -s /opt/$pkgname "$pkgdir"/opt/android-sdk/ndk/$_ndkver
  local _major=${_ndkver%%.*}
  local _minor=${_ndkver#*.}; _minor=${_minor%%.*}
  local _micro=${_ndkver##*.}
  sed -i "s/NDKMAJ/$_major/g;s/NDKMIN/$_minor/g;s/NDKMIC/$_micro/g;s/NDKVER/$_ndkver/g" "$srcdir"/package.xml
  install -Dm644 "${srcdir}"/package.xml "$pkgdir"/opt/$pkgname/package.xml
}

This is package.xml file.

medaminezghal commented on 2025-11-21 18:50 (UTC) (edited on 2025-11-21 20:09 (UTC) by medaminezghal)

@migrev Could you edit the installation location to be /opt/android-sdk/ndk/$ndk_full_version for example /opt/android-sdk/ndk/29.0.14206865 or link it to that location instead of /opt/android-sdk/ndk-bundle.

yan12125 commented on 2024-04-22 17:15 (UTC)

Orphaning - I rarely use NDK nowadays.

yan12125 commented on 2023-10-12 07:11 (UTC)

Is removal of replaces= related to https://github.com/chaotic-aur/toolbox/issues/89#issuecomment-1727820523 ? This replaces= is valid, as android-ndk64 was merged into android-ndk in 2014 [1]. For most users, this replaces= might be useless (only meaningful for binary repositories), unneeded (people may not upgrade a system after nine years without upgrades), but also harmless, so I may not change it.

[1] https://github.com/felixonmars/aur3-mirror/commit/4a6efb65dab3b627bff4672f2d3b848f254a8f88#diff-70c31113defd6d1d7ed8e8f31dcdb4701e1665a1ef899435381324610dbc34bd

yan12125 commented on 2023-09-07 16:03 (UTC)

Thanks, added.

Fell commented on 2023-09-06 07:46 (UTC)

Godot Engine still wouldn't find the NDK after installing. I fixed it by adding export ANDROID_NDK_ROOT=/opt/android-ndk to /etc/profile.d/android-ndk.sh.

Maybe ANDROID_NDK_ROOT should also be set by the package just for good measure.

Martchus commented on 2023-06-10 14:10 (UTC)

Thanks!

yan12125 commented on 2023-06-10 14:09 (UTC)

Okay, I added it along with some other deps detected by namcap. Thanks for the catch!