summaryrefslogtreecommitdiff
path: root/libre/linux-libre-firmware/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'libre/linux-libre-firmware/PKGBUILD')
-rw-r--r--libre/linux-libre-firmware/PKGBUILD73
1 files changed, 52 insertions, 21 deletions
diff --git a/libre/linux-libre-firmware/PKGBUILD b/libre/linux-libre-firmware/PKGBUILD
index 73aab20d1..68e91458f 100644
--- a/libre/linux-libre-firmware/PKGBUILD
+++ b/libre/linux-libre-firmware/PKGBUILD
@@ -5,13 +5,19 @@
pkgname=linux-libre-firmware
pkgver=1.3.1
-pkgrel=1
+pkgrel=2
epoch=1
pkgdesc='Firmware files for Linux-libre'
arch=(any)
url='https://jxself.org/firmware'
license=(GPL3)
-makedepends=(arm-linux-gnueabi-gcc arm-none-eabi-gcc cmake sh-elf-gcc sh-elf-newlib xtensa-elf-gcc)
+makedepends=(arm-linux-gnueabi-gcc # av7110
+ arm-none-eabi-gcc # aica
+ avr-gcc avr-libc dfu-util # atusb
+ sh-elf-gcc sh-elf-newlib cmake # carl9170fw
+ xtensa-elf-gcc # ath9k_htc
+)
+optdepends=('dfu-util: to flash the atusb firmware')
provides=(linux-firmware)
conflicts=(linux-firmware
linux-firmware-git
@@ -26,37 +32,62 @@ conflicts=(linux-firmware
rt2870usb-fw
rt2x00-rt61-fw
rt2x00-rt71w-fw
- amd-ucode
openfwwf
ath9k-htc-firmware)
replaces=(${conflicts[@]})
options=(!buildflags !makeflags)
-source=("$url/$pkgname-$pkgver.tar.lz"{,.asc}
- 0001-Add-offline-files-and-a-toolchain-option-in-Makefile.patch)
+source=(
+ "$url/$pkgname-$pkgver.tar.lz"{,.asc}
+ 0001-Update-carl9170-to-latest-upstream.patch
+ 0002-Add-firmware-for-the-ATUSB-IEEE-802.15.4-USB-Adapter.patch
+ 0003-Update-INSTALL-document.patch
+ 0004-atusb-Build-updates.patch
+ 0006-Makefile-Change-spaces-for-atusb-to-tab.patch
+ 0007-Makefile-Add-atusb-to-all.patch
+ 0008-Makefile-Set-shell-to-bin-bash.patch
+)
sha512sums=('d827ec7024b4900dcdf6af8cdd4e72b02596d0ade5c2262460cd573785300498e6aa655b9a59cd22e38a6a787826a564ae33acfac52e68df1d082445e66f18df'
'SKIP'
- '1aa4b3a463c0d24f295df2ea13e30d3b11a1af7abef3e03558036b07143b3262178a3b7ab6cc0cc7c255044f833e7df9a3cb18b98978e55737852fe0185dc22e')
+ '07263a406cb15c9f91f41c8fb6d4307875665b8106adf526353d64306611458e11ce311842caa9efa623091c897ec9f87cfe54584c9c47590195867958cf4086'
+ 'a4e8752cfee8dfd0b17ff798d2b5ea7a773ebcf688f7614d1c1a92fe7f092c626a289069a472bc873a77c9cf52f1e37953b0ba47c37a9dfb2a763a695ca77625'
+ '1665ce62de148383fe4f30aa5714ef6bb1dfd4eed110415995069830b36a4b1aafb05e4cd6cf428dc0817e2affb91740e41b3fab8d2385683d6c18790bbf5afd'
+ '0168ba0f3a8f3938a96b7f72d081283ca04b7ba90c5474d8ccf0716d6964137980f49623c5489271158a48827319a20ee4f19bd94f5bb956ee97d5ba637070c1'
+ 'fa006627935beb7ae78fad5b63423a54e4eae384761ff618fff173250fb5d0c7eef9d5a707733d037edc95259ef59c9053c4245b80a004928b6809ea1cb43cf8'
+ '8014d9eccb4c5193d1b4b056e163b5631c207adc78522e413650eb053c90e7b9e333c9e5cb6f73b63985e27020f4c69e7b791176702c55f711f6db95387e6bff'
+ '59560f16978b2fd7d8c828d7609ee4f71cbdc902b70cfb87feca686958dd4df05c61c5e1bfa5e0c2a060f23185a0b9e5d07d487e172764767cdc4b26a6240b79')
validpgpkeys=('F611A908FFA165C699584ED49D0DB31B545A3198') # Jason Self
-prepare() {
- cd $srcdir/$pkgname-$pkgver/src
+prepare(){
+ cd $pkgname-$pkgver/src
- patch -p1 -i $srcdir/0001-Add-offline-files-and-a-toolchain-option-in-Makefile.patch
+ local src
+ for src in "${source[@]}"; do
+ src="${src%%::*}"
+ src="${src##*/}"
+ [[ $src = *.patch ]] || continue
+ echo "Applying patch $src..."
+ patch -Np1 < "$srcdir/$src"
+ done
- # Build carl9170 with the default config
- sed '71s/autogen.sh/autogen.sh --alldefconfig/' -i Makefile
-}
-
-build() {
- cd $srcdir/$pkgname-$pkgver
- make toolchains= -C src
+ # Use our cross compilers and build carl9170fw with the default config
+ sed -e 's|$PWD/../toolchain/inst/bin/||g' \
+ -e 's|${CMAKE_SOURCE_DIR}/toolchain/inst/bin/||g' \
+ -e '/CMAKE_FIND_ROOT_PATH/d' \
+ -e 's/: ath9k_htc_toolchain$/:/' \
+ -e 's/: carl9170fw-toolchain$/:/' \
+ -e '/cd carl9170fw && .\/autogen.sh$/ s/$/ --alldefconfig/' \
+ -i Makefile \
+ ath9k_htc/target_firmware/configure \
+ carl9170fw/extra/sh-elf-linux.cmake
}
-package() {
- cd $srcdir/$pkgname-$pkgver
+build(){
+ make -C $pkgname-$pkgver/src
+}
- install -dm755 $pkgdir/usr/lib/firmware
- make -C src prefix=$pkgdir/usr/lib/firmware install
+package(){
+ cd $pkgname-$pkgver/src
- install -Dm644 src/WHENCE $pkgdir/usr/share/licenses/$pkgname/WHENCE
+ make prefix=$pkgdir/usr/lib/firmware install
+ install -Dm644 WHENCE $pkgdir/usr/share/licenses/$pkgname/WHENCE
}