summaryrefslogtreecommitdiff
blob: 427682fdae4df798b42d32f5711f80bbb26e0ec6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

inherit toolchain-funcs

DESCRIPTION="Tool for flashing Rockchip devices"
HOMEPAGE="https://sourceforge.net/projects/rkflashtool/"
SRC_URI="mirror://sourceforge/project/${PN}/${P}/${P}-src.tar.xz"
S="${WORKDIR}/${P}-src"

LICENSE="BSD-2"
SLOT="0"
KEYWORDS="~amd64"

RDEPEND="virtual/libusb:1"
DEPEND="${RDEPEND}"

src_prepare() {
	default
	cp "${FILESDIR}"/${P}-missing-version.h version.h || die
	sed -i -e "s/CC	=/CC ?=/"\
		-e "s/CFLAGS	=/CFLAGS ?=/"\
		-e "s/LDFLAGS	=/LDFLAGS ?=/" Makefile || die
	tc-export CC
}

src_install() {
	dodoc README
	dobin rkcrc  rkflashtool rkmisc  rkpad  rkparameters  rkparametersblock  rkunpack  rkunsign
}