--- Begin Message ---
Maybe useful to replace u-boot-tools.
Requirement for the upcoming swupdate package.
Link: https://github.com/sbabic/libubootenv
Signed-off-by: Alexander Dahl <[email protected]>
---
rules/libubootenv.in | 15 +++++++++++
rules/libubootenv.make | 58 ++++++++++++++++++++++++++++++++++++++++++
2 files changed, 73 insertions(+)
create mode 100644 rules/libubootenv.in
create mode 100644 rules/libubootenv.make
diff --git a/rules/libubootenv.in b/rules/libubootenv.in
new file mode 100644
index 000000000..70f6d9863
--- /dev/null
+++ b/rules/libubootenv.in
@@ -0,0 +1,15 @@
+## SECTION=system_libraries
+
+config LIBUBOOTENV
+ tristate
+ select HOST_CMAKE
+ select LIBYAML
+ select ZLIB
+ prompt "libubootenv"
+ help
+ Generic library and tools to access and modify U-Boot
+ environment from User Space.
+
+ https://github.com/sbabic/libubootenv
+
+# vim: ft=kconfig noet tw=72 ts=8 sw=8
diff --git a/rules/libubootenv.make b/rules/libubootenv.make
new file mode 100644
index 000000000..d4e678152
--- /dev/null
+++ b/rules/libubootenv.make
@@ -0,0 +1,58 @@
+# -*-makefile-*-
+#
+# Copyright (C) 2025 by Alexander Dahl <[email protected]>
+#
+# For further information about the PTXdist project and license conditions
+# see the README file.
+#
+
+#
+# We provide this package
+#
+PACKAGES-$(PTXCONF_LIBUBOOTENV) += libubootenv
+
+#
+# Paths and names
+#
+LIBUBOOTENV_VERSION := 0.3.6
+LIBUBOOTENV_MD5 := 7d6b623e8da435cf36e7fcd419a03e43
+LIBUBOOTENV := libubootenv-$(LIBUBOOTENV_VERSION)
+LIBUBOOTENV_SUFFIX := tar.gz
+LIBUBOOTENV_URL :=
https://github.com/sbabic/libubootenv/archive/refs/tags/v$(LIBUBOOTENV_VERSION).$(LIBUBOOTENV_SUFFIX)
+LIBUBOOTENV_SOURCE := $(SRCDIR)/$(LIBUBOOTENV).$(LIBUBOOTENV_SUFFIX)
+LIBUBOOTENV_DIR := $(BUILDDIR)/$(LIBUBOOTENV)
+LIBUBOOTENV_LICENSE := MIT AND CC0-1.0 AND LGPL-2.1-or-later
+LIBUBOOTENV_LICENSE_FILES := \
+ file://LICENSES/MIT.txt;md5=838c366f69b72c5df05c96dff79b35f2 \
+ file://LICENSES/CC0-1.0.txt;md5=0ceb3372c9595f0a8067e55da801e4a1 \
+
file://LICENSES/LGPL-2.1-or-later.txt;md5=4fbd65380cdd255951079008b364516c
+
+# ----------------------------------------------------------------------------
+# Prepare
+# ----------------------------------------------------------------------------
+
+LIBUBOOTENV_CONF_TOOL := cmake
+LIBUBOOTENV_CONF_OPT := \
+ $(CROSS_CMAKE_USR) \
+ -DBUILD_DOC=OFF
+
+# ----------------------------------------------------------------------------
+# Target-Install
+# ----------------------------------------------------------------------------
+
+$(STATEDIR)/libubootenv.targetinstall:
+ @$(call targetinfo)
+
+ @$(call install_init, libubootenv)
+ @$(call install_fixup, libubootenv,PRIORITY,optional)
+ @$(call install_fixup, libubootenv,SECTION,base)
+ @$(call install_fixup, libubootenv,AUTHOR,"Alexander Dahl
<[email protected]>")
+ @$(call install_fixup, libubootenv,DESCRIPTION,missing)
+
+ @$(call install_lib, libubootenv, 0, 0, 0644, libubootenv)
+
+ @$(call install_finish, libubootenv)
+
+ @$(call touch)
+
+# vim: ft=make noet tw=72 ts=8 sw=8
--
2.39.5
--- End Message ---