|
| 1 | +################################################################################ |
| 2 | +# This file is part of OpenELEC - http://www.openelec.tv |
| 3 | +# Copyright (C) 2016 Peter Smorada |
| 4 | +# |
| 5 | +# This Program is free software; you can redistribute it and/or modify |
| 6 | +# it under the terms of the GNU General Public License as published by |
| 7 | +# the Free Software Foundation; either version 2, or (at your option) |
| 8 | +# any later version. |
| 9 | +# |
| 10 | +# This Program is distributed in the hope that it will be useful, |
| 11 | +# but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | +# GNU General Public License for more details. |
| 14 | +# |
| 15 | +# You should have received a copy of the GNU General Public License |
| 16 | +# along with OpenELEC.tv; see the file COPYING. If not, write to |
| 17 | +# the Free Software Foundation, 51 Franklin Street, Suite 500, Boston, MA 02110, USA. |
| 18 | +# http://www.gnu.org/copyleft/gpl.html |
| 19 | +################################################################################ |
| 20 | + |
| 21 | +PKG_NAME="u-boot-tools" |
| 22 | +PKG_VERSION="2016.01" |
| 23 | +PKG_REV="0" |
| 24 | +PKG_ARCH="any" |
| 25 | +PKG_LICENSE="GPL" |
| 26 | +PKG_SITE="http://www.denx.de/wiki/U-Boot/WebHome" |
| 27 | +PKG_URL="ftp://ftp.denx.de/pub/u-boot/u-boot-$PKG_VERSION.tar.bz2" |
| 28 | +PKG_DEPENDS_TARGET="toolchain" |
| 29 | +PKG_PRIORITY="optional" |
| 30 | +PKG_SECTION="tools" |
| 31 | +PKG_SHORTDESC="U-Boot bootloader utility tools" |
| 32 | +PKG_LONGDESC="U-Boot bootloader utility tools. This package includes the mkimage program, which allows generation of U-Boot images in various formats, and the fw_printenv and fw_setenv programs to read and modify U-Boot's environment and other tools." |
| 33 | +PKG_DISCLAIMER="This addon can make your device unusable if improperly configured. Use at your own risk. This is an unofficial addon. Please don't ask for support in openelec forum / irc channel" |
| 34 | + |
| 35 | +PKG_AUTORECONF="no" |
| 36 | + |
| 37 | +PKG_IS_ADDON="yes" |
| 38 | +PKG_ADDON_TYPE="xbmc.python.script" |
| 39 | +PKG_ADDON_PROVIDES="" |
| 40 | +PKG_ADDON_NAME="uboot-tools" |
| 41 | +PKG_ADDON_REPOVERSION="7.0" |
| 42 | + |
| 43 | +PKG_MAINTAINER="Peter Smorada (smoradap at gmail dot com)" |
| 44 | + |
| 45 | +unpack() { |
| 46 | + tar jxf "$SOURCES/$PKG_NAME/u-boot-${PKG_VERSION}.tar.bz2" -C $BUILD |
| 47 | + mv $BUILD/u-boot-$PKG_VERSION $BUILD/u-boot-tools-$PKG_VERSION |
| 48 | +} |
| 49 | + |
| 50 | + |
| 51 | +make_target() { |
| 52 | + make dummy_defconfig |
| 53 | + make CROSS_COMPILE="$TARGET_PREFIX" ARCH="$TARGET_ARCH" env |
| 54 | + make CROSS_COMPILE="$TARGET_PREFIX" cross_tools |
| 55 | +} |
| 56 | + |
| 57 | +makeinstall_target() { |
| 58 | + : # nop |
| 59 | +} |
| 60 | + |
| 61 | +addon() { |
| 62 | + mkdir -p $ADDON_BUILD/$PKG_ADDON_ID/bin |
| 63 | + cp $PKG_BUILD/tools/env/fw_printenv $ADDON_BUILD/$PKG_ADDON_ID/bin/fw_printenv |
| 64 | + cp $PKG_BUILD/tools/env/fw_printenv $ADDON_BUILD/$PKG_ADDON_ID/bin/fw_setenv |
| 65 | + cp $PKG_BUILD/tools/dumpimage $ADDON_BUILD/$PKG_ADDON_ID/bin/dumpimage |
| 66 | + cp $PKG_BUILD/tools/fdtgrep $ADDON_BUILD/$PKG_ADDON_ID/bin/fdtgrep |
| 67 | + cp $PKG_BUILD/tools/gen_eth_addr $ADDON_BUILD/$PKG_ADDON_ID/bin/gen_eth_addr |
| 68 | + cp $PKG_BUILD/tools/img2srec $ADDON_BUILD/$PKG_ADDON_ID/bin/img2srec |
| 69 | + cp $PKG_BUILD/tools/mkenvimage $ADDON_BUILD/$PKG_ADDON_ID/bin/mkenvimage |
| 70 | + cp $PKG_BUILD/tools/mkimage $ADDON_BUILD/$PKG_ADDON_ID/bin/mkimage |
| 71 | + cp $PKG_BUILD/tools/proftool $ADDON_BUILD/$PKG_ADDON_ID/bin/proftool |
| 72 | + cp $PKG_BUILD/tools/relocate-rela $ADDON_BUILD/$PKG_ADDON_ID/bin/relocate-rela |
| 73 | +} |
| 74 | + |
| 75 | + |
0 commit comments