diff options
author | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2015-09-21 15:45:45 -0300 |
---|---|---|
committer | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2015-09-21 16:21:10 -0300 |
commit | b16d50a21274437da1d49a6a146dc602242f97c8 (patch) | |
tree | 8f1ce6d2d04d6285cbd70a16ebac54274f93e31d /libre/linux-libre | |
parent | 8fea3ee0368ff4feb42c07b728efd1e70cf0fea4 (diff) | |
download | abslibre-b16d50a21274437da1d49a6a146dc602242f97c8.tar.gz abslibre-b16d50a21274437da1d49a6a146dc602242f97c8.tar.bz2 abslibre-b16d50a21274437da1d49a6a146dc602242f97c8.zip |
linux-libre: add some changes based on linux-armv7 to adapt for u-Boot usage
* rename vmlinuz-linux-libre to zImage
* rename uImage-linux-libre-{armada-{370-smileplug,370-mirabox,xp-openblocks-ax3-4},dove-{d3plug,cubox}} to uImage
* backup linux-libre-dtb and previous linux-libre armv7h changes to ~emulatorman for GRUB armv7h porting and avoid conflicts with another kernel installed
Diffstat (limited to 'libre/linux-libre')
-rw-r--r-- | libre/linux-libre/PKGBUILD | 77 |
1 files changed, 68 insertions, 9 deletions
diff --git a/libre/linux-libre/PKGBUILD b/libre/linux-libre/PKGBUILD index 8a82ade79..27d39d582 100644 --- a/libre/linux-libre/PKGBUILD +++ b/libre/linux-libre/PKGBUILD @@ -170,7 +170,7 @@ build() { if [ "${CARCH}" != "armv7h" ]; then make ${MAKEFLAGS} LOCALVERSION= bzImage modules else - make ${MAKEFLAGS} LOCALVERSION= zImage modules + make ${MAKEFLAGS} LOCALVERSION= zImage modules dtbs fi } @@ -180,8 +180,6 @@ _package() { depends=('coreutils' 'linux-libre-firmware' 'kmod') if [ "${CARCH}" != "armv7h" ]; then depends+=('mkinitcpio>=0.7') - else - depends+=("linux-libre-dtb=${pkgver}") fi optdepends=('crda: to set the correct wireless channels of your country') provides=("${_replacesarchkernel[@]/%/=${_archpkgver}}") @@ -207,12 +205,8 @@ _package() { if [ "${CARCH}" != "armv7h" ]; then cp arch/$KARCH/boot/bzImage "${pkgdir}/boot/vmlinuz-${pkgbase}" else - cp arch/$KARCH/boot/zImage "${pkgdir}/boot/vmlinuz-${pkgbase}" - - for _arm in armada-{370-smileplug,370-mirabox,xp-openblocks-ax3-4} dove-{d3plug,cubox}; do - cat arch/$KARCH/boot/zImage /boot/dtbs/${_arm}.dtb > myimage-${_arm} - mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n "${pkgname}" -d myimage-${_arm} "${pkgdir}/boot/uImage-${pkgbase}-${_arm}" - done + cp arch/$KARCH/boot/zImage "${pkgdir}/boot/zImage" + cp arch/$KARCH/boot/dts/*.dtb "${pkgdir}/boot/dtbs" fi # set correct depmod command for install @@ -406,7 +400,72 @@ _package-docs() { rm -f "${pkgdir}/usr/lib/modules/${_kernver}/build/Documentation/DocBook/Makefile" } +_package-smileplug() { + pkgdesc="The ${pkgbase^} kernel - Marvell SMILE Plug" + arch=('armv7h') + depends=("${pkgbase}") + + cd "${srcdir}/${_srcname}" + + mkdir -p "${pkgdir}/boot" + cat arch/$KARCH/boot/zImage arch/$KARCH/boot/dts/armada-370-smileplug.dtb > myimage + mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n "${pkgbase}" -d myimage "${pkgdir}/boot/uImage" +} + +_package-mirabox() { + pkgdesc="The ${pkgbase^} kernel - Globalscale Mirabox" + arch=('armv7h') + depends=("${pkgbase}") + + cd "${srcdir}/${_srcname}" + + mkdir -p "${pkgdir}/boot" + cat arch/$KARCH/boot/zImage arch/$KARCH/boot/dts/armada-370-mirabox.dtb > myimage + mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n "${pkgbase}" -d myimage "${pkgdir}/boot/uImage" +} + +_package-ax3() { + pkgdesc="The ${pkgbase^} kernel - OpenBlocks AX3-4" + arch=('armv7h') + depends=("${pkgbase}") + + cd "${srcdir}/${_srcname}" + + mkdir -p "${pkgdir}/boot" + cat arch/$KARCH/boot/zImage arch/$KARCH/boot/dts/armada-xp-openblocks-ax3-4.dtb > myimage + mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n "${pkgbase}" -d myimage "${pkgdir}/boot/uImage" +} + +_package-d3plug() { + pkgdesc="The ${pkgbase^} kernel - Globalscale D3Plug" + arch=('armv7h') + depends=("${pkgbase}") + + cd "${srcdir}/${_srcname}" + + mkdir -p "${pkgdir}/boot" + cat arch/$KARCH/boot/zImage arch/$KARCH/boot/dts/dove-d3plug.dtb > myimage + mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n "${pkgbase}" -d myimage "${pkgdir}/boot/uImage" +} + +_package-cubox() { + pkgdesc="The ${pkgbase^} kernel - SolidRun Cubox (Marvell)" + arch=('armv7h') + depends=("${pkgbase}") + + cd "${srcdir}/${_srcname}" + + mkdir -p "${pkgdir}/boot" + cat arch/$KARCH/boot/zImage arch/$KARCH/boot/dts/dove-cubox.dtb > myimage + mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e 0x00008000 -n "${pkgbase}" -d myimage "${pkgdir}/boot/uImage" +} + pkgname=("${pkgbase}" "${pkgbase}-headers" "${pkgbase}-docs") + +if [ "$CARCH" = "armv7h" ]; then + pkgname+=("${pkgbase}-smileplug" "${pkgbase}-mirabox" "${pkgbase}-ax3" "${pkgbase}-d3plug" "${pkgbase}-cubox") +fi + for _p in ${pkgname[@]}; do eval "package_${_p}() { $(declare -f "_package${_p#${pkgbase}}") |