From: "Arsen Arsenovic" <arsen@aarsen.me>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/proj/guru:dev commit in: sys-boot/limine/, sys-boot/limine/files/
Date: Tue, 8 Feb 2022 14:49:57 +0000 (UTC) [thread overview]
Message-ID: <1644331659.6a8d6a672e27536c0dd6550fe51802b10ba79325.arsen@gentoo> (raw)
commit: 6a8d6a672e27536c0dd6550fe51802b10ba79325
Author: Arsen Arsenović <arsen <AT> aarsen <DOT> me>
AuthorDate: Tue Feb 8 14:06:00 2022 +0000
Commit: Arsen Arsenovic <arsen <AT> aarsen <DOT> me>
CommitDate: Tue Feb 8 14:47:39 2022 +0000
URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=6a8d6a67
sys-boot/limine: new package
Package-Manager: Portage-3.0.30, Repoman-3.0.3
Signed-off-by: Arsen Arsenović <arsen <AT> aarsen.me>
sys-boot/limine/Manifest | 1 +
...ke-eltorito-efi-build-manually-toggleable.patch | 66 ++++++++++++++++++++++
sys-boot/limine/limine-2.83.ebuild | 40 +++++++++++++
sys-boot/limine/metadata.xml | 13 +++++
4 files changed, 120 insertions(+)
diff --git a/sys-boot/limine/Manifest b/sys-boot/limine/Manifest
new file mode 100644
index 000000000..036c455d6
--- /dev/null
+++ b/sys-boot/limine/Manifest
@@ -0,0 +1 @@
+DIST limine-2.83.tar.xz 1561172 BLAKE2B 2b91ca239147f6eede40b5bb21c6a3a5c44157bcaacf2bf49bf7b39471c60bd866dc499b54ab9a853d64d3db34c19544f8c7d5b657d3c73c5323314e579f2121 SHA512 716866615734fdfdbc3e947d2a02b194505e96428438c71622bdb05e48d6e700d9fd87660ae6a0e03aef8365c98adc2f51821783d6f14296380095afa6ca924b
diff --git a/sys-boot/limine/files/limine-2.83-build-Make-eltorito-efi-build-manually-toggleable.patch b/sys-boot/limine/files/limine-2.83-build-Make-eltorito-efi-build-manually-toggleable.patch
new file mode 100644
index 000000000..0ca799d15
--- /dev/null
+++ b/sys-boot/limine/files/limine-2.83-build-Make-eltorito-efi-build-manually-toggleable.patch
@@ -0,0 +1,66 @@
+From 23ee0bf491d077e3c022028cf7040dd5a7597e94 Mon Sep 17 00:00:00 2001
+From: mintsuki <mintsuki@protonmail.com>
+Date: Tue, 8 Feb 2022 15:35:54 +0100
+Subject: [PATCH] build: Make eltorito-efi build manually toggleable
+
+---
+Pulled from upstream
+
+ GNUmakefile.in | 4 ++++
+ configure.ac | 11 +++++++++++
+ 2 files changed, 15 insertions(+)
+
+diff --git a/GNUmakefile.in b/GNUmakefile.in
+index 334f7c66..fcb7d6ef 100644
+--- a/GNUmakefile.in
++++ b/GNUmakefile.in
+@@ -16,6 +16,8 @@ NASMESCAPE = $(subst ','"'$(COMMA) \"'\"$(COMMA) '"',$(1))
+ override PATH := $(BUILDDIR)/toolchain/bin:/usr/local/bin:$(PATH)
+ export PATH
+
++override BUILD_ELTORITO_EFI := @build_eltorito_efi@
++
+ WERROR ?= @werror@
+ export WERROR
+
+@@ -140,6 +142,7 @@ limine-bios: common-bios decompressor
+
+ .PHONY: limine-eltorito-efi
+ limine-eltorito-efi:
++ifeq ($(BUILD_ELTORITO_EFI), yes)
+ mkdir -p '$(call SHESCAPE,$(BINDIR))'
+ dd if=/dev/zero of='$(call SHESCAPE,$(BINDIR))/limine-eltorito-efi.bin' bs=512 count=2880 2>/dev/null
+ ( mformat -i '$(call SHESCAPE,$(BINDIR))/limine-eltorito-efi.bin' -f 1440 :: && \
+@@ -150,6 +153,7 @@ limine-eltorito-efi:
+ ( ( [ -f '$(call SHESCAPE,$(BUILDDIR))/common-uefi32/BOOTIA32.EFI' ] && \
+ mcopy -D o -i '$(call SHESCAPE,$(BINDIR))/limine-eltorito-efi.bin' '$(call SHESCAPE,$(BUILDDIR))/common-uefi32/BOOTIA32.EFI' ::/EFI/BOOT ) || true ) \
+ ) || rm -f '$(call SHESCAPE,$(BINDIR))/limine-eltorito-efi.bin'
++endif
+
+ .PHONY: limine-uefi
+ limine-uefi: limine-uefi32 limine-uefi64
+diff --git a/configure.ac b/configure.ac
+index 1d1315d6..4a4b521a 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -41,9 +41,20 @@ if ! test "x$GZIP_FOUND" = "xyes"; then
+ AC_MSG_ERROR([gzip not found, please install gzip before configuring])
+ fi
+
++BUILD_ELTORITO_EFI="yes"
++
++AC_ARG_ENABLE([eltorito-efi],
++ AS_HELP_STRING([--disable-eltorito-efi], [disable limine-eltorito-efi.bin build]),
++ BUILD_ELTORITO_EFI="$enableval")
++
+ AC_CHECK_PROG([MTOOLS_FOUND], [mcopy], [yes])
+ if ! test "x$MTOOLS_FOUND" = "xyes"; then
+ AC_MSG_WARN([mtools not found, install mtools to build limine-eltorito-efi.bin])
++ BUILD_ELTORITO_EFI="no"
++fi
++
++if test "$BUILD_ELTORITO_EFI" = "yes"; then
++ AC_SUBST(build_eltorito_efi, [yes])
+ fi
+
+ AC_ARG_VAR(HOST_CC, [C compiler for the build host [default: $CC]])
diff --git a/sys-boot/limine/limine-2.83.ebuild b/sys-boot/limine/limine-2.83.ebuild
new file mode 100644
index 000000000..368163337
--- /dev/null
+++ b/sys-boot/limine/limine-2.83.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+WANT_LIBTOOL=none
+inherit autotools
+
+DESCRIPTION="Limine is a modern, advanced x86/x86_64 BIOS/UEFI multiprotocol bootloader."
+HOMEPAGE="https://limine-bootloader.org/"
+SRC_URI="https://github.com/limine-bootloader/limine/releases/download/v${PV}/limine-${PV}.tar.xz"
+
+LICENSE="BSD-2"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="+eltorito-efi"
+
+BDEPEND="
+ sys-apps/findutils
+ dev-lang/nasm
+ app-arch/gzip
+ eltorito-efi? ( sys-fs/mtools )
+"
+PATCHES="
+ ${FILESDIR}/${PN}-2.83-build-Make-eltorito-efi-build-manually-toggleable.patch
+"
+
+src_prepare() {
+ default
+
+ eautoreconf
+}
+
+src_configure() {
+ local myconf=(
+ $(use_enable eltorito-efi)
+ )
+
+ econf "${myconf[@]}"
+}
diff --git a/sys-boot/limine/metadata.xml b/sys-boot/limine/metadata.xml
new file mode 100644
index 000000000..bd468f6c4
--- /dev/null
+++ b/sys-boot/limine/metadata.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>arsen@aarsen.me</email>
+ <name>Arsen Arsenović</name>
+ </maintainer>
+ <use>
+ <flag name="eltorito-efi">
+ Enable building eltorito-efi.bin using <pkg>sys-fs/mtools</pkg>
+ </flag>
+ </use>
+</pkgmetadata>
next reply other threads:[~2022-02-08 14:50 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-08 14:49 Arsen Arsenovic [this message]
-- strict thread matches above, loose matches on Subject: below --
2022-02-14 12:01 [gentoo-commits] repo/proj/guru:dev commit in: sys-boot/limine/, sys-boot/limine/files/ Arsen Arsenovic
2023-04-02 10:33 Arsen Arsenović
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1644331659.6a8d6a672e27536c0dd6550fe51802b10ba79325.arsen@gentoo \
--to=arsen@aarsen.me \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox