summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPF4Public <PF4Public@users.noreply.github.com>2023-07-17 00:47:23 +0300
committerViorel Munteanu <ceamac@gentoo.org>2023-07-21 10:35:15 +0300
commit2718ed746bbe74f17e8b8522d310800831459aa4 (patch)
treec8f56255adeb39dd17fe1998d70449f1264ab49c /dev-embedded
parentdev-python/jupyter-server: add 2.7.0 (diff)
downloadgentoo-2718ed746bbe74f17e8b8522d310800831459aa4.tar.gz
gentoo-2718ed746bbe74f17e8b8522d310800831459aa4.tar.bz2
gentoo-2718ed746bbe74f17e8b8522d310800831459aa4.zip
dev-embedded/sunxi-tools: add 1.4.2 and live
Signed-off-by: PF4Public <PF4Public@users.noreply.github.com> Closes: https://github.com/gentoo/gentoo/pull/31913 Signed-off-by: Viorel Munteanu <ceamac@gentoo.org>
Diffstat (limited to 'dev-embedded')
-rw-r--r--dev-embedded/sunxi-tools/Manifest2
-rw-r--r--dev-embedded/sunxi-tools/sunxi-tools-1.4.2.ebuild68
-rw-r--r--dev-embedded/sunxi-tools/sunxi-tools-9999.ebuild52
3 files changed, 122 insertions, 0 deletions
diff --git a/dev-embedded/sunxi-tools/Manifest b/dev-embedded/sunxi-tools/Manifest
index db2220b9c0ad..a5a930f9841f 100644
--- a/dev-embedded/sunxi-tools/Manifest
+++ b/dev-embedded/sunxi-tools/Manifest
@@ -1,2 +1,4 @@
DIST sunxi-tools-1.3.tar.gz 52608 BLAKE2B e8c3ed7276f705273598e38a0cc469225de1ee4eb8177b78be63b78ebc584c4fdf2362e21b895f61b4c5e84df98bfd5ccf6d3965ffa9338c98027c9ce4635626 SHA512 954c95963013aee8a38b3583ba1b7ec7e7049c7e09c5fa9ec564dfc33f304d3669fdf68c2fa5e4b5a6265640a3d1ee8bc13bcd71d804c714884b6a780d193615
DIST sunxi-tools-1.4.1.tar.gz 78878 BLAKE2B f50b14e79d4880a076f8b25869eea44e34cfc50c91ce7f9e4adc831bb2ac2238c930623677bacb399e52faadba20c9ba21ea212915c50941af825d0579804153 SHA512 b66f5caaabec016a0d2f1ccc88ee7f37cd26a511ac81c270e2de6bf0b967e8dfda2b510d5306daffb33ec8855c3c6be99a29bfd1efd5bd0cf3431494b092a52b
+DIST sunxi-tools-1.4.2-test.zip 890565 BLAKE2B c24bafde5f049eca61962faf71d9928eb6340c48d619484f6dad1a6d7c1b9dc6f23d0f3f9b3e7847efd68004e70b44b9637d27bec8a97e6e3772b4003f3d25db SHA512 7763d60094f990e42bf57ae3e72f19dfb52cc6573777bf8c9a01bc5c1598505b067645f88b04955ae2b0f9456140e6bcb8eab31526e6e94fa28e826a80da7172
+DIST sunxi-tools-1.4.2.tar.gz 84090 BLAKE2B b3261855eb9a18025c19829e343e3e2e7097dc4e267a60fdcf39cd2e9bfa57580267a77846a576ea5fc04a07fd6ba90b1223a8c644c933879dc7aa766ba36210 SHA512 633bc1752ae11799ce0bae347b52296792d28265a2260e173727847e1f457b767e88d02ae547bb55a2bb05e1eb552ba4406985ae105a1712a9fa30852ae293e8
diff --git a/dev-embedded/sunxi-tools/sunxi-tools-1.4.2.ebuild b/dev-embedded/sunxi-tools/sunxi-tools-1.4.2.ebuild
new file mode 100644
index 000000000000..b5be36370bd2
--- /dev/null
+++ b/dev-embedded/sunxi-tools/sunxi-tools-1.4.2.ebuild
@@ -0,0 +1,68 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="8"
+
+inherit toolchain-funcs
+
+if [[ ${PV} = *9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/linux-sunxi/sunxi-tools"
+else
+ KEYWORDS="~amd64"
+ SRC_URI="https://github.com/linux-sunxi/sunxi-tools/archive/v${PV}.tar.gz -> ${P}.tar.gz
+ test? ( https://github.com/linux-sunxi/sunxi-boards/archive/bc7410fed9e5d9b31cd1d6ae90462d06b513660e.zip -> ${P}-test.zip )"
+fi
+
+DESCRIPTION="A collection of command line tools for ARM devices with Allwinner SoCs"
+HOMEPAGE="https://linux-sunxi.org/Main_Page"
+
+LICENSE="GPL-2"
+SLOT="0"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="acct-group/plugdev
+ virtual/libusb:1
+ virtual/udev"
+
+DEPEND="${RDEPEND}
+"
+
+BDEPEND="virtual/pkgconfig
+test? ( app-arch/unzip )"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-1.4.1-fix-strncpy-compiler-warning.patch"
+)
+
+src_unpack() {
+ unpack ${P}.tar.gz
+ # No need to unpack testdata twice
+}
+
+src_prepare() {
+ default
+
+ if use test; then
+ cp "${DISTDIR}/${P}-test.zip" "${S}/tests/sunxi-boards.zip"
+ sed -i 's$sunxi-boards-master$sunxi-boards-bc7410fed9e5d9b31cd1d6ae90462d06b513660e$' tests/Makefile || die
+ sed -i 's|^coverage:.*|coverage: $(BOARDS_DIR)/README|' tests/Makefile || die
+ fi
+}
+
+src_compile() {
+ tc-export PKG_CONFIG
+
+ emake LIBUSB_CFLAGS="$(${PKG_CONFIG} --cflags libusb-1.0)" \
+ LIBUSB_LIBS="$(${PKG_CONFIG} --libs libusb-1.0)" \
+ CC="$(tc-getCC)" tools misc
+}
+
+src_install() {
+ dobin bin2fex fex2bin phoenix_info sunxi-nand-image-builder
+ newbin sunxi-bootinfo bootinfo
+ newbin sunxi-fel fel
+ newbin sunxi-fexc fexc
+ newbin sunxi-nand-part nand-part
+}
diff --git a/dev-embedded/sunxi-tools/sunxi-tools-9999.ebuild b/dev-embedded/sunxi-tools/sunxi-tools-9999.ebuild
new file mode 100644
index 000000000000..7b9cbffdec12
--- /dev/null
+++ b/dev-embedded/sunxi-tools/sunxi-tools-9999.ebuild
@@ -0,0 +1,52 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="8"
+
+inherit toolchain-funcs
+
+if [[ ${PV} = *9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/linux-sunxi/sunxi-tools"
+ PROPERTIES="test_network"
+ RESTRICT="test"
+else
+ KEYWORDS="~amd64"
+ SRC_URI="https://github.com/linux-sunxi/sunxi-tools/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+ RESTRICT="!test? ( test )"
+fi
+
+DESCRIPTION="A collection of command line tools for ARM devices with Allwinner SoCs"
+HOMEPAGE="https://linux-sunxi.org/Main_Page"
+
+LICENSE="GPL-2"
+SLOT="0"
+IUSE="test"
+
+RDEPEND="acct-group/plugdev
+ virtual/libusb:1
+ virtual/udev"
+
+DEPEND="${RDEPEND}
+"
+
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+)
+
+src_compile() {
+ tc-export PKG_CONFIG
+
+ emake LIBUSB_CFLAGS="$(${PKG_CONFIG} --cflags libusb-1.0)" \
+ LIBUSB_LIBS="$(${PKG_CONFIG} --libs libusb-1.0)" \
+ CC="$(tc-getCC)" tools misc
+}
+
+src_install() {
+ dobin bin2fex fex2bin phoenix_info sunxi-nand-image-builder
+ newbin sunxi-bootinfo bootinfo
+ newbin sunxi-fel fel
+ newbin sunxi-fexc fexc
+ newbin sunxi-nand-part nand-part
+}