diff options
author | Alfred Wingate <parona@protonmail.com> | 2022-09-29 16:13:55 +0300 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2022-10-02 21:35:46 -0700 |
commit | eb553bf1f5e93a11e880c492df85dff9a579e6e1 (patch) | |
tree | bc6fbb19cfb4d4cccbc395fada04c1b58ac9b2a8 /dev-util | |
parent | dev-util/android-udev-rules: new package, add 20220903 (diff) | |
download | gentoo-eb553bf1f5e93a11e880c492df85dff9a579e6e1.tar.gz gentoo-eb553bf1f5e93a11e880c492df85dff9a579e6e1.tar.bz2 gentoo-eb553bf1f5e93a11e880c492df85dff9a579e6e1.zip |
dev-util/android-tools: revision with dependency to android-udev-rules
* drop x86-linux keyword as prefix and non-prefix keywords arent
differentiated anymore #473598
Closes: https://github.com/gentoo/gentoo/pull/27588
Signed-off-by: Alfred Wingate <parona@protonmail.com>
Signed-off-by: Zac Medico <zmedico@gentoo.org>
Diffstat (limited to 'dev-util')
-rw-r--r-- | dev-util/android-tools/android-tools-33.0.3-r1.ebuild | 85 |
1 files changed, 85 insertions, 0 deletions
diff --git a/dev-util/android-tools/android-tools-33.0.3-r1.ebuild b/dev-util/android-tools/android-tools-33.0.3-r1.ebuild new file mode 100644 index 000000000000..5e81ccbffd54 --- /dev/null +++ b/dev-util/android-tools/android-tools-33.0.3-r1.ebuild @@ -0,0 +1,85 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{8..11} ) + +inherit cmake python-r1 + +DESCRIPTION="Android platform tools (adb, fastboot, and mkbootimg)" +HOMEPAGE="https://github.com/nmeum/android-tools/ https://developer.android.com/" + +MY_PV="${PV//_/}" +SRC_URI="https://github.com/nmeum/android-tools/releases/download/${MY_PV}/${PN}-${MY_PV}.tar.xz + https://dev.gentoo.org/~zmedico/dist/${PN}-31.0.3-no-gtest.patch +" +S="${WORKDIR}/${PN}-${MY_PV}" + +# The entire source code is Apache-2.0, except for fastboot which is BSD-2. +LICENSE="Apache-2.0 BSD-2" +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~x86" +IUSE="python" +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" + +# dev-libs/libpcre only required for e2fsdroid +DEPEND=" + app-arch/brotli:= + app-arch/lz4:= + app-arch/zstd:= + dev-libs/libpcre2:= + >=dev-libs/protobuf-3.0.0:= + sys-libs/zlib:= + virtual/libusb:1= +" +RDEPEND="${DEPEND} + dev-util/android-udev-rules + python? ( ${PYTHON_DEPS} ) +" +BDEPEND=" + dev-lang/go +" + +DOCS=() + +src_prepare() { + eapply "${DISTDIR}/${PN}-31.0.3-no-gtest.patch" + cd "${S}/vendor/core" || die + eapply "${S}/patches/core/0011-Remove-the-useless-dependency-on-gtest.patch" + cd "${S}/vendor/libziparchive" || die + eapply "${S}/patches/libziparchive/0004-Remove-the-useless-dependency-on-gtest.patch" + cd "${S}" + rm -r patches || die + cmake_src_prepare +} + +src_configure() { + local mycmakeargs=( + # Statically link the bundled boringssl + -DBUILD_SHARED_LIBS=OFF + ) + cmake_src_configure +} + +src_compile() { + export GOCACHE="${T}/go-build" + export GOFLAGS="-mod=vendor" + cmake_src_compile +} + +src_install() { + cmake_src_install + rm "${ED}/usr/bin/mkbootimg" || die + rm "${ED}/usr/bin/unpack_bootimg" || die + rm "${ED}/usr/bin/repack_bootimg" || die + if use python; then + python_foreach_impl python_newexe vendor/mkbootimg/mkbootimg.py mkbootimg + python_foreach_impl python_newexe vendor/mkbootimg/unpack_bootimg.py unpack_bootimg + python_foreach_impl python_newexe vendor/mkbootimg/repack_bootimg.py repack_bootimg + fi + docinto adb + dodoc vendor/adb/*.{txt,TXT} + docinto fastboot + dodoc vendor/core/fastboot/README.md +} |