blob: 3a429d57e19a17ba6adc6558c3c70c36a3ae5d5d [file] [log] [blame]
rjw1f884582022-01-06 17:20:42 +08001DESCRIPTION = "Different utilities from Android - based on the corresponding ubuntu \
2package"
3SECTION = "console/utils"
4LICENSE = "Apache-2.0 & GPL-2.0 & BSD-2-Clause & BSD-3-Clause"
5LIC_FILES_CHKSUM = " \
6 file://${COMMON_LICENSE_DIR}/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10 \
7 file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6 \
8 file://${COMMON_LICENSE_DIR}/BSD-2-Clause;md5=8bef8e6712b1be5aa76af1ebde9d6378 \
9 file://${COMMON_LICENSE_DIR}/BSD-3-Clause;md5=550794465ba0ec5312d6919e203a55f9 \
10 file://${WORKDIR}/debian/copyright;md5=141efd1050596168ca05ced04e4f498b \
11"
12
13DEPENDS = "zlib openssl"
14
15# Use same version than ubuntu does here
16BASE_PV = "4.2.2+git20130218"
17PV = "${BASE_PV}-3ubuntu13"
18
19ALLOW_EMPTY_${PN} = "1"
20
21SRC_URI = " \
22 https://launchpad.net/ubuntu/+archive/primary/+files/android-tools_${BASE_PV}.orig.tar.xz;name=source \
23 https://launchpad.net/ubuntu/+archive/primary/+files/android-tools_${PV}.debian.tar.gz;name=debian \
24 file://reboot-syscall.patch \
25 file://disable-selinux-support.patch \
26 file://remove-libselinux.patch;patchdir=.. \
27"
28S = "${WORKDIR}/android-tools"
29
30SRC_URI[source.md5sum] = "0e653b129ab0c95bdffa91410c8b55be"
31SRC_URI[source.sha256sum] = "9bfba987e1351b12aa983787b9ae4424ab752e9e646d8e93771538dc1e5d932f"
32SRC_URI[debian.md5sum] = "5e409d01caf3c33fc60a2100464754ff"
33SRC_URI[debian.sha256sum] = "320757edc8af015f40335c41dc96bf37e2d50c9f3a40a31e64264ff6e2dba5e3"
34
35do_compile() {
36 # Setting both variables below causing our makefiles to not work with implicit make
37 # rules
38 unset CFLAGS
39 unset CPPFLAGS
40
41 sed -i "s%^CPPFLAGS+= -I/usr/include%# we don't want to include headers from host CPPFLAGS+= -I/usr/include%g" ${WORKDIR}/debian/makefiles/ext4_utils.mk
42
43 oe_runmake -f ${WORKDIR}/debian/makefiles/fastboot.mk -C ${S}/core/fastboot clean
44 oe_runmake -f ${WORKDIR}/debian/makefiles/fastboot.mk -C ${S}/core/fastboot
45}
46
47do_install() {
48 install -d ${D}${bindir}
49 install -m 0755 ${S}/core/fastboot/fastboot ${D}${bindir}
50}
51
52inherit deploy
53
54do_deploy () {
55 install -d ${DEPLOYDIR}
56 install -m 0755 ${S}/core/fastboot/fastboot ${DEPLOYDIR}/fastboot-linux-arm
57}
58
59addtask deploy before do_build after do_compile
60