diff options
author | yjun | 2023-09-06 22:30:45 +0800 |
---|---|---|
committer | yjun | 2023-09-06 22:30:45 +0800 |
commit | 6ae592d5752cfb0a7faf15c927be030b4a64adb8 (patch) | |
tree | 750e0eca080463e94240d29f41e48629d09841e5 | |
parent | 14484958135f5319eb9eada23db3b3454b1f69ab (diff) | |
download | aur-6ae592d5752cfb0a7faf15c927be030b4a64adb8.tar.gz |
wrap update with script aml-update
-rw-r--r-- | ' | 64 | ||||
-rw-r--r-- | .SRCINFO | 4 | ||||
-rw-r--r-- | PKGBUILD | 7 | ||||
-rw-r--r-- | aml-update.sh | 3 |
4 files changed, 76 insertions, 2 deletions
@@ -0,0 +1,64 @@ +# Maintainer: yjun <jerrysteve1101@gmail.com> + +pkgname=aml-flash-tool +pkgver=4.9 +pkgrel=2 +pkgdesc="Linux version of Amlogic USB Burning Tool." +arch=('x86_64') +url="https://github.com/khadas/utils/tree/master/aml-flash-tool" +license=('unknown') +depends=('libusb' + 'libusb-compat') +source=("${pkgname}-${pkgver}::git+https://github.com/khadas/utils#" + "${pkgname}.sh" + "aml-update.sh" + "0001-BTW_I-use-Arch.patch") +provides=('aml-flash') +options=('!strip') +sha256sums=('SKIP' + 'a31b6e5633e81eeb3e447a0077ca5abc2bd7bb22e38910693681776a315151fc' + 'd9a1e81742452298b4181470a3791910c781fdbfaba55c301cb9578a165c61f6') + +prepare() { + cd "$pkgname-$pkgver" + patch --forward --strip=1 --input="${srcdir}/0001-BTW_I-use-Arch.patch" +} + +package() { + cd ${pkgname}-${pkgver}/${pkgname} + + _executable=flash-tool + # executable + install -Dm755 ${_executable} -t ${pkgdir}/usr/lib/${pkgname}/ + + # tools + _not_executable_files=(decompressPara_4M.dump + usbbl2runpara_ddrinit.bin + usbbl2runpara_runfipimg.bin) + + for _ne in "${_not_executable_files[@]}"; + do + install -Dm644 tools/datas/${_ne} -t ${pkgdir}/usr/lib/${pkgname}/tools/datas + done + + _executable_files=(update + aml_image_v2_packer + aml_update.app) + + for _e in "${_executable_files[@]}"; + do + install -Dm755 tools/linux-x86/${_e} -t ${pkgdir}/usr/lib/${pkgname}/tools/linux-x86 + done + + # wrapper + install -Dm755 ${srcdir}/${pkgname}.sh ${pkgdir}/usr/bin/${pkgname} + install -Dm755 ${srcdir}/aml-update.sh ${pkgdir}/usr/bin/aml-update + + # udev rules + install -Dm644 tools/_install_/70-persistent-usb-ubuntu14.rules ${pkgdir}/usr/lib/udev/rules.d/70-persistent-usb-amlogic.rules + + # doc + install -Dm644 docs/Amlogic_update_usb_tool_user_guide.pdf -t ${pkgdir}/usr/share/doc/${pkgname} +} + +# vim: set sw=2 ts=2 et: @@ -1,7 +1,7 @@ pkgbase = aml-flash-tool pkgdesc = Linux version of Amlogic USB Burning Tool. pkgver = 4.9 - pkgrel = 2 + pkgrel = 3 url = https://github.com/khadas/utils/tree/master/aml-flash-tool arch = x86_64 license = unknown @@ -11,9 +11,11 @@ pkgbase = aml-flash-tool options = !strip source = aml-flash-tool-4.9::git+https://github.com/khadas/utils# source = aml-flash-tool.sh + source = aml-update.sh source = 0001-BTW_I-use-Arch.patch sha256sums = SKIP sha256sums = a31b6e5633e81eeb3e447a0077ca5abc2bd7bb22e38910693681776a315151fc + sha256sums = dca48e7f21d6edf6c49ac268b1a501cdd1eb7ab7b36fcdba5f9cf89d1d1a7a6f sha256sums = d9a1e81742452298b4181470a3791910c781fdbfaba55c301cb9578a165c61f6 pkgname = aml-flash-tool @@ -2,20 +2,24 @@ pkgname=aml-flash-tool pkgver=4.9 -pkgrel=2 +pkgrel=3 pkgdesc="Linux version of Amlogic USB Burning Tool." arch=('x86_64') url="https://github.com/khadas/utils/tree/master/aml-flash-tool" license=('unknown') depends=('libusb' 'libusb-compat') +# aml-update : update - Amlogic update USB tool(Ver 1.7.2) 2018/04 +# aml-flash-tool: flash-tool - Version : 4.9 source=("${pkgname}-${pkgver}::git+https://github.com/khadas/utils#" "${pkgname}.sh" + "aml-update.sh" "0001-BTW_I-use-Arch.patch") provides=('aml-flash') options=('!strip') sha256sums=('SKIP' 'a31b6e5633e81eeb3e447a0077ca5abc2bd7bb22e38910693681776a315151fc' + 'dca48e7f21d6edf6c49ac268b1a501cdd1eb7ab7b36fcdba5f9cf89d1d1a7a6f' 'd9a1e81742452298b4181470a3791910c781fdbfaba55c301cb9578a165c61f6') prepare() { @@ -51,6 +55,7 @@ package() { # wrapper install -Dm755 ${srcdir}/${pkgname}.sh ${pkgdir}/usr/bin/${pkgname} + install -Dm755 ${srcdir}/aml-update.sh ${pkgdir}/usr/bin/aml-update # udev rules install -Dm644 tools/_install_/70-persistent-usb-ubuntu14.rules ${pkgdir}/usr/lib/udev/rules.d/70-persistent-usb-amlogic.rules diff --git a/aml-update.sh b/aml-update.sh new file mode 100644 index 000000000000..5c8a62675c01 --- /dev/null +++ b/aml-update.sh @@ -0,0 +1,3 @@ +#!/bin/sh + +exec /usr/lib/aml-flash-tool/tools/linux-x86/update "$@" |