mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-18 22:54:00 +00:00
63 lines
2.3 KiB
Bash
63 lines
2.3 KiB
Bash
# Maintainer: Oleg Rakhmanov <oleg [at] archlinuxarm [dot] org>
|
|
# Maintainer: Kevin Mihelich <kevin@archlinuxarm.org>
|
|
# Maintainer: graysky <graysky@archlinux.us>
|
|
|
|
buildarch=28
|
|
|
|
pkgname=raspberrypi-firmware
|
|
pkgver=20201215
|
|
pkgrel=1
|
|
_commitfirmware=8a5549c137dbce0e082ecf21607dc5e3feac1160
|
|
_commituserland=093b30bbc2fd083d68cc3ee07e6e555c6e592d11
|
|
pkgdesc="Firmware tools, libraries, and headers for Raspberry Pi"
|
|
arch=('armv6h' 'armv7h' 'aarch64')
|
|
url="https://github.com/raspberrypi/firmware"
|
|
license=('custom')
|
|
makedepends_aarch64=('cmake')
|
|
replaces=('raspberrypi-firmware-tools')
|
|
provides=('raspberrypi-firmware-tools')
|
|
options=(!strip)
|
|
source=('00-raspberrypi-firmware.conf')
|
|
source_armv6h=("https://github.com/raspberrypi/firmware/archive/$_commitfirmware.tar.gz")
|
|
source_armv7h=("https://github.com/raspberrypi/userland/archive/$_commitfirmware.tar.gz")
|
|
source_aarch64=("https://github.com/raspberrypi/userland/archive/$_commituserland.tar.gz"
|
|
"https://raw.githubusercontent.com/raspberrypi/firmware/master/opt/vc/LICENCE")
|
|
md5sums=('72e0d5818fc513ece1b964f25f7e7882')
|
|
md5sums_armv6h=('8387de1c197424ea62e4052604df1e52')
|
|
md5sums_armv7h=('8387de1c197424ea62e4052604df1e52')
|
|
md5sums_aarch64=('b4b3ef6a5c9ecbf11a517e29db97fd1b'
|
|
'86e53f5f5909ee66900418028de11780')
|
|
|
|
build() {
|
|
if [[ "${CARCH}" = 'aarch64' ]]; then
|
|
cd ${srcdir}/userland-${_commituserland}
|
|
cmake -DCMAKE_BUILD_TYPE=Release -DARM64=ON
|
|
make
|
|
fi
|
|
}
|
|
|
|
package() {
|
|
if [[ "${CARCH}" = 'aarch64' ]]; then
|
|
mkdir -p "${pkgdir}"/opt/vc
|
|
|
|
cd ${srcdir}/userland-${_commituserland}
|
|
make install DESTDIR="${pkgdir}"
|
|
install -m644 ../LICENCE "${pkgdir}"/opt/vc/LICENCE
|
|
rm -rf "${pkgdir}"/opt/vc/src
|
|
|
|
# Remove executable flag on shared objects
|
|
find "${pkgdir}" -type f -name '*.so' -print0 | xargs -0 chmod -x
|
|
|
|
# Create lib links
|
|
mkdir -p "${pkgdir}"/etc/ld.so.conf.d/
|
|
install -m644 ../00-raspberrypi-firmware.conf "${pkgdir}"/etc/ld.so.conf.d/00-raspberrypi-firmware.conf
|
|
else
|
|
mkdir -p "${pkgdir}"/opt/vc
|
|
|
|
cp -R "${srcdir}"/firmware-${_commitfirmware}/hardfp/opt/vc/{bin,include,lib,LICENCE} "${pkgdir}"/opt/vc
|
|
|
|
# Create lib links
|
|
mkdir -p "${pkgdir}"/etc/ld.so.conf.d/
|
|
cp "${srcdir}/00-raspberrypi-firmware.conf" "${pkgdir}"/etc/ld.so.conf.d/
|
|
fi
|
|
}
|