diff --git a/.SRCINFO b/.SRCINFO index 7048f4157f6e..da1bc4a458ec 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,7 +1,7 @@ pkgbase = elilo-efi pkgdesc = UEFI version of LILO Boot Loader pkgver = 3.16 - pkgrel = 1 + pkgrel = 2 url = http://sourceforge.net/projects/elilo/ install = elilo-efi.install arch = any @@ -10,14 +10,14 @@ pkgbase = elilo-efi depends = dosfstools depends = efibootmgr options = !strip - options = purge + options = !purge options = !libtool options = !emptydirs options = !makeflags source = http://downloads.sourceforge.net/project/elilo/elilo/elilo-3.16/elilo-3.16-all.tar.gz - source = elilo.conf.example + source = elilo.conf sha1sums = bd0bd4f1b3dc2d23a304f957ffbf907ae104f323 - sha1sums = b961f6181504f7d1bf4b14f76c0477159fc54445 + sha1sums = 2366629b137572f91774a0bdf907864dd7fe3172 pkgname = elilo-efi diff --git a/PKGBUILD b/PKGBUILD index 416f6d783ba9..6168f02ca888 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -4,7 +4,7 @@ _pkgname="elilo" pkgname="${_pkgname}-efi" pkgver="3.16" -pkgrel="1" +pkgrel="2" pkgdesc="UEFI version of LILO Boot Loader" arch=('any') url="http://sourceforge.net/projects/elilo/" @@ -12,74 +12,94 @@ license=('GPL') makedepends=('gnu-efi-libs') depends=('dosfstools' 'efibootmgr') -options=('!strip' 'purge' '!libtool' '!emptydirs' '!makeflags') +options=('!strip' '!purge' '!libtool' '!emptydirs' '!makeflags') install="${pkgname}.install" source=("http://downloads.sourceforge.net/project/elilo/elilo/elilo-${pkgver}/elilo-${pkgver}-all.tar.gz" - "elilo.conf.example") + "elilo.conf") sha1sums=('bd0bd4f1b3dc2d23a304f957ffbf907ae104f323' - 'b961f6181504f7d1bf4b14f76c0477159fc54445') + '2366629b137572f91774a0bdf907864dd7fe3172') + +_build_elilo-efi-x86_64() { + + cp -r "${srcdir}/elilo-${pkgver}-source" "${srcdir}/elilo-${pkgver}-x86_64" + cd "${srcdir}/elilo-${pkgver}-x86_64/" + + ## Unset all compiler FLAGS + unset CFLAGS + unset CPPFLAGS + unset CXXFLAGS + unset LDFLAGS + unset MAKEFLAGS + + echo + make ARCH="x86_64" + echo + +} + +_build_elilo-efi-ia32() { + + cp -r "${srcdir}/elilo-${pkgver}-source" "${srcdir}/elilo-${pkgver}-ia32" + cd "${srcdir}/elilo-${pkgver}-ia32/" + + ## Unset all compiler FLAGS + unset CFLAGS + unset CPPFLAGS + unset CXXFLAGS + unset LDFLAGS + unset MAKEFLAGS + + echo + make ARCH="ia32" + echo + +} build() { if [[ "${CARCH}" != "x86_64" ]]; then echo "${pkgname} package can be built only in a x86_64 system. Exiting." exit 1 - else - cd "${srcdir}/" - bsdtar xf "${srcdir}/elilo-${pkgver}-source.tar.gz" fi + bsdtar -C "${srcdir}/" -xf "${srcdir}/elilo-${pkgver}-source.tar.gz" + cd "${srcdir}/elilo-${pkgver}-source/" + + ## Delete unwanted files rm -f "${srcdir}"/*.efi || true rm -f "${srcdir}/elilo-${pkgver}-source.tar.gz" || true - ## Fix ARCH Makefile variable - sed 's|ARCH :=|ARCH ?=|g' -i "${srcdir}/elilo-${pkgver}-source/Make.defaults" || true + ## Enable gnu-efi ms_abi support + sed 's|-fno-stack-protector|-DGNU_EFI_USE_MS_ABI -fno-stack-protector|g' -i "${srcdir}/elilo-${pkgver}-source/Make.defaults" || true + + ## Use "uname -m" to determine ARCH sed 's|dpkg-architecture -qDEB_BUILD_ARCH|uname -m|g' -i "${srcdir}/elilo-${pkgver}-source/Make.defaults" || true - ## Fix -Werror issues + ## Fix -Werror build failure sed 's|DEBUGFLAGS = -Wall|DEBUGFLAGS = -Wall -Wno-error|g' -i "${srcdir}/elilo-${pkgver}-source/Make.defaults" || true - ## Enable ext2 drivers - build fails for now - # sed 's|^CONFIG_ext2fs=n|CONFIG_ext2fs=y|g' -i "${srcdir}/elilo-${pkgver}-source/Make.defaults" || true + ## Compile elilox64.efi + _build_elilo-efi-x86_64 - cp -r "${srcdir}/elilo-${pkgver}-source" "${srcdir}/elilo-${pkgver}-x86_64" - cd "${srcdir}/elilo-${pkgver}-x86_64/" - - unset CFLAGS - unset CPPFLAGS - unset CXXFLAGS - unset LDFLAGS - unset MAKEFLAGS - - ARCH="x86_64" make - echo - - cp -r "${srcdir}/elilo-${pkgver}-source" "${srcdir}/elilo-${pkgver}-ia32" - cd "${srcdir}/elilo-${pkgver}-ia32/" - - unset CFLAGS - unset CPPFLAGS - unset CXXFLAGS - unset LDFLAGS - unset MAKEFLAGS - - ARCH="ia32" make - echo + ## Compile eliloia32.efi + _build_elilo-efi-ia32 } package() { + ## Install elilox64.efi and eliloia32.efi install -d "${pkgdir}/usr/lib/elilo" install -D -m0644 "${srcdir}/elilo-${pkgver}-x86_64/elilo.efi" "${pkgdir}/usr/lib/elilo/elilox64.efi" install -D -m0644 "${srcdir}/elilo-${pkgver}-ia32/elilo.efi" "${pkgdir}/usr/lib/elilo/eliloia32.efi" + ## Install example elilo.conf install -d "${pkgdir}/usr/lib/elilo/config" - install -D -m0644 "${srcdir}/elilo.conf.example" "${pkgdir}/usr/lib/elilo/config/elilo.conf" + install -D -m0644 "${srcdir}/elilo.conf" "${pkgdir}/usr/lib/elilo/config/elilo.conf" } diff --git a/elilo.conf.example b/elilo.conf similarity index 54% rename from elilo.conf.example rename to elilo.conf index f70e1f8f4e55..56f15344d429 100644 --- a/elilo.conf.example +++ b/elilo.conf @@ -2,14 +2,14 @@ prompt default=arch -timeout=10 +timeout=5 image=/EFI/arch/vmlinuz-arch.efi label=arch - append="root=PARTUUID=XXXXXXXXXX rootfstype=ext4 add_efi_memmap" + append="root=PARTUUID=XXXXXXXXXX rootfstype=XXXX efi_no_storage_paranoia add_efi_memmap" initrd=/EFI/arch/initramfs-arch.img image=/EFI/arch/vmlinuz-arch.efi label=arch-fallback - append="root=PARTUUID=XXXXXXXXXX rootfstype=ext4 add_efi_memmap" + append="root=PARTUUID=XXXXXXXXXX rootfstype=XXXX efi_no_storage_paranoia add_efi_memmap" initrd=/EFI/arch/initramfs-arch-fallback.img