android-ndk-8c.ebuild 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. # Copyright 1999-2015 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=3
  4. MY_P="${PN}-r${PV}"
  5. DESCRIPTION="Open Handset Alliance's Android NDK (Native Dev Kit)"
  6. HOMEPAGE="http://developer.android.com/sdk/ndk/"
  7. SRC_URI="https://dl.google.com/android/ndk/${MY_P}-linux-x86.tar.bz2"
  8. LICENSE="android"
  9. SLOT="0"
  10. KEYWORDS="~amd64 ~x86"
  11. IUSE=""
  12. RESTRICT="mirror strip installsources test"
  13. DEPEND=""
  14. RDEPEND=">=dev-util/android-sdk-update-manager-10
  15. >=sys-devel/make-3.81"
  16. S="${WORKDIR}/${MY_P}"
  17. ANDROID_NDK_DIR="opt/${PN}"
  18. ANDROID_TC_ARM_ANDROID_4_4="${ANDROID_NDK_DIR}/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86"
  19. ANDROID_TC_ARM_ANDROID_4_6="${ANDROID_NDK_DIR}/toolchains/arm-linux-androideabi-4.6/prebuilt/linux-x86"
  20. ANDROID_TC_MIPS_ANDROID_4_4="${ANDROID_NDK_DIR}/toolchains/mipsel-linux-android-4.4.3/prebuilt/linux-x86"
  21. ANDROID_TC_MIPS_ANDROID_4_6="${ANDROID_NDK_DIR}/toolchains/mipsel-linux-android-4.6/prebuilt/linux-x86"
  22. ANDROID_TC_X86_ANDROID_4_4="${ANDROID_NDK_DIR}/toolchains/x86-4.4.3/prebuilt/linux-x86"
  23. ANDROID_TC_X86_ANDROID_4_6="${ANDROID_NDK_DIR}/toolchains/x86-4.6/prebuilt/linux-x86"
  24. QA_PREBUILT="*"
  25. PYTHON_UPDATER_IGNORE="1"
  26. src_configure() {
  27. :
  28. }
  29. src_compile() {
  30. :
  31. }
  32. src_install() {
  33. dodir "/${ANDROID_NDK_DIR}"
  34. cp -pPR * "${ED}/${ANDROID_NDK_DIR}"
  35. fowners -R root:android "/${ANDROID_NDK_DIR}"
  36. fperms 0775 "/${ANDROID_NDK_DIR}/"{,build,docs,platforms,samples}
  37. fperms 0775 "/${ANDROID_NDK_DIR}/"{sources,tests,toolchains}
  38. dodir "/${ANDROID_NDK_DIR}/out"
  39. fowners root:android "/${ANDROID_NDK_DIR}/out"
  40. fperms 3775 "/${ANDROID_NDK_DIR}/out"
  41. printf '%s' \
  42. "PATH=\"${EPREFIX}/${ANDROID_NDK_DIR}:" \
  43. "${EPREFIX}/${ANDROID_TC_ARM_ANDROID_4_4}/bin/:" \
  44. "${EPREFIX}/${ANDROID_TC_ARM_ANDROID_4_6}/bin/:" \
  45. "${EPREFIX}/${ANDROID_TC_MIPS_ANDROID_4_4}/bin/:" \
  46. "${EPREFIX}/${ANDROID_TC_MIPS_ANDROID_4_6}/bin/:" \
  47. "${EPREFIX}/${ANDROID_TC_X86_ANDROID_4_4}/bin/:" \
  48. "${EPREFIX}/${ANDROID_TC_X86_ANDROID_4_6}/bin/\"" \
  49. $'\n' \
  50. > "${T}/80${PN}" || die
  51. doenvd "${T}/80${PN}" || die
  52. echo "SEARCH_DIRS_MASK=\"${EPREFIX}/${ANDROID_NDK_DIR}\"" \
  53. > "${T}/80${PN}" || die
  54. insinto "/etc/revdep-rebuild"
  55. doins "${T}/80${PN}"
  56. }