efibootmgr: new package
authorOskari Rauta <oskari.rauta@gmail.com>
Thu, 12 Jan 2023 08:56:08 +0000 (10:56 +0200)
committerDaniel Golle <daniel@makrotopia.org>
Wed, 18 Jan 2023 14:02:39 +0000 (14:02 +0000)
Co-authored-by: Tianling Shen <cnsztl@gmail.com>
Signed-off-by: Oskari Rauta <oskari.rauta@gmail.com>
utils/efibootmgr/Makefile [new file with mode: 0644]

diff --git a/utils/efibootmgr/Makefile b/utils/efibootmgr/Makefile
new file mode 100644 (file)
index 0000000..fc53f87
--- /dev/null
@@ -0,0 +1,55 @@
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=efibootmgr
+PKG_VERSION:=18
+PKG_RELEASE:=1
+
+PKG_SOURCE_PROTO:=git
+PKG_SOURCE_URL:=https://github.com/rhboot/efibootmgr.git
+PKG_SOURCE_DATE:=2022-11-12
+PKG_SOURCE_VERSION:=1904f9cd5a48207d49e393ac8de824f54ccfb697
+PKG_MIRROR_HASH:=0355e00bb54d468ecbaa106aa703dd389f2f2f4c7b7afb78a258cec10d75f78d
+
+PKG_LICENSE:=GPL-2.0-only
+PKG_LICENSE_FILES:=COPYING
+PKG_MAINTAINER:=OSkari Rauta <oskari.rauta@gmail.com>
+
+PKG_BUILD_PARALLEL:=1
+PKG_INSTALL:=1
+
+include $(INCLUDE_DIR)/package.mk
+
+define Package/efibootmgr
+  SECTION:=utils
+  CATEGORY:=Utilities
+  TITLE:=Application to modify the EFI Boot Manager
+  DEPENDS:=@TARGET_x86_64 +efivar +libpopt
+  URL:=https://github.com/rhboot/efibootmgr
+endef
+
+define Package/efibootmgr/description
+  This is efibootmgr, a Linux user-space application to modify the
+  Intel Extensible Firmware Interface (EFI) Boot Manager.
+  This application can create and destroy boot entries, change
+  the boot order, change the next running boot option, and more.
+
+  Details on the EFI Boot Manager are available from the
+  EFI Specification, v1.02 or above, available from:
+  http://www.uefi.org
+
+  Note: efibootmgr requires either the efivarfs or the legacy
+  efivars kernel module to be loaded prior to use.
+endef
+
+MAKE_VARS += \
+       EFIDIR="/boot/EFI" \
+       PCDIR="$(STAGING_DIR)/usr/lib/pkgconfig" \
+       EXTRAINCDIR="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/usr/include/efivar" \
+       EXTRALIBDIR="-L$(STAGING_DIR)/usr/lib"
+
+define Package/efibootmgr/install
+       $(INSTALL_DIR) $(1)/usr/sbin
+       $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/{efibootdump,efibootmgr} $(1)/usr/sbin/
+endef
+
+$(eval $(call BuildPackage,efibootmgr))