pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

u-boot-tools: Import u-boot-tools-2023.04 as wip/u-boot-tools



Module Name:	pkgsrc-wip
Committed By:	Brook Milligan <brook%nmsu.edu@localhost>
Pushed By:	brook
Date:		Tue Apr 25 08:48:22 2023 -0600
Changeset:	8e0049389abbaa44b522385de146b3624dfc199f

Modified Files:
	Makefile
Added Files:
	u-boot-tools/DESCR
	u-boot-tools/Makefile
	u-boot-tools/PLIST
	u-boot-tools/distinfo
	u-boot-tools/patches/patch-Makefile
	u-boot-tools/patches/patch-tools_Makefile

Log Message:
u-boot-tools: Import u-boot-tools-2023.04 as wip/u-boot-tools

All the existing U-Boot packages are for platform-specific bootloaders.
Missing is the set of tools to, for example, create a boot script.  This
package installs only the U-Boot tools, specifically mkimage and dumpimage
for now.  Other tools exist and may be useful to include in the future.

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=8e0049389abbaa44b522385de146b3624dfc199f

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 Makefile                                  |  1 +
 u-boot-tools/DESCR                        |  8 +++++++
 u-boot-tools/Makefile                     | 35 +++++++++++++++++++++++++++++++
 u-boot-tools/PLIST                        |  3 +++
 u-boot-tools/distinfo                     |  7 +++++++
 u-boot-tools/patches/patch-Makefile       | 15 +++++++++++++
 u-boot-tools/patches/patch-tools_Makefile | 15 +++++++++++++
 7 files changed, 84 insertions(+)

diffs:
diff --git a/Makefile b/Makefile
index 79312a7682..6b1d74f885 100644
--- a/Makefile
+++ b/Makefile
@@ -5781,6 +5781,7 @@ SUBDIR+=	u-boot-nanopi-r2s
 SUBDIR+=	u-boot-orangepi-pc2
 SUBDIR+=	u-boot-pinebook-crust
 SUBDIR+=	u-boot-sifive-unleashed
+SUBDIR+=	u-boot-tools
 SUBDIR+=	u-boot-visionfive2
 SUBDIR+=	uTox-git
 SUBDIR+=	uade
diff --git a/u-boot-tools/DESCR b/u-boot-tools/DESCR
new file mode 100644
index 0000000000..5e6d2f73cb
--- /dev/null
+++ b/u-boot-tools/DESCR
@@ -0,0 +1,8 @@
+This directory contains the source code for U-Boot, a boot loader for
+Embedded boards based on PowerPC, ARM, MIPS and several other
+processors, which can be installed in a boot ROM and used to
+initialize and test the hardware or to download and run application
+code.
+
+This package installs only the U-Boot tools, e.g., mkimage for making
+boot scripts.
diff --git a/u-boot-tools/Makefile b/u-boot-tools/Makefile
new file mode 100644
index 0000000000..6c06a8345c
--- /dev/null
+++ b/u-boot-tools/Makefile
@@ -0,0 +1,35 @@
+# $NetBSD$
+
+GITHUB_PROJECT=	u-boot
+GITHUB_TAG=	refs/tags/v2023.04
+DISTNAME=	v2023.04
+PKGNAME=	${GITHUB_PROJECT}-tools-${DISTNAME:S,^v,,}
+CATEGORIES=	sysutils
+MASTER_SITES=	${MASTER_SITE_GITHUB:=u-boot/}
+DIST_SUBDIR=	${GITHUB_PROJECT}
+
+MAINTAINER=	pkgsrc-users%NetBSD.org@localhost
+HOMEPAGE=	https://github.com/u-boot/u-boot/
+COMMENT=	U-Boot tools
+LICENSE=	gnu-gpl-v2
+
+WRKSRC=		${WRKDIR}/${GITHUB_PROJECT}-${DISTNAME:S,^v,,}
+USE_LANGUAGES=	c
+USE_TOOLS+=	gmake
+
+BUILD_TARGET=	defconfig oldconfig tools-only
+
+SUBST_CLASSES+=		prefix
+SUBST_STAGE.prefix=	pre-configure
+SUBST_FILES.prefix=	tools/Makefile
+SUBST_VARS.prefix=	PREFIX
+
+INSTALLATION_DIRS+=	bin
+
+do-install:
+	${INSTALL} ${WRKSRC}/tools/dumpimage ${DESTDIR}${PREFIX}/bin
+	${INSTALL} ${WRKSRC}/tools/mkimage ${DESTDIR}${PREFIX}/bin
+
+.include "../../devel/libuuid/buildlink3.mk"
+.include "../../security/gnutls/buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/u-boot-tools/PLIST b/u-boot-tools/PLIST
new file mode 100644
index 0000000000..002218209c
--- /dev/null
+++ b/u-boot-tools/PLIST
@@ -0,0 +1,3 @@
+@comment $NetBSD$
+bin/dumpimage
+bin/mkimage
diff --git a/u-boot-tools/distinfo b/u-boot-tools/distinfo
new file mode 100644
index 0000000000..cce640051f
--- /dev/null
+++ b/u-boot-tools/distinfo
@@ -0,0 +1,7 @@
+$NetBSD$
+
+BLAKE2s (u-boot/v2023.04.tar.gz) = 130772dcba462b4e649c951379468ba092c87b1e7e1e3c1e9196eb961f999cd3
+SHA512 (u-boot/v2023.04.tar.gz) = e2a6819228b98066d5c01c7b6b89ff9033d1f3805232bab2ce0d46edde3cd0b8f255d0ed4826bd9df3041b77d6f836ace7116ab2a99946080770869d51612021
+Size (u-boot/v2023.04.tar.gz) = 24620730 bytes
+SHA1 (patch-Makefile) = 50c286a95110a5c69d450720f7540ba3024c4ce3
+SHA1 (patch-tools_Makefile) = dd49cdfd40ce047f39446f42a92e9e009d5d2963
diff --git a/u-boot-tools/patches/patch-Makefile b/u-boot-tools/patches/patch-Makefile
new file mode 100644
index 0000000000..3d49678fa5
--- /dev/null
+++ b/u-boot-tools/patches/patch-Makefile
@@ -0,0 +1,15 @@
+$NetBSD$
+
+Use the native compiler for building tools.
+
+--- Makefile.orig	2023-04-03 20:38:50.000000000 +0000
++++ Makefile
+@@ -824,7 +824,7 @@ UBOOTINCLUDE    := \
+ 	-I$(srctree)/arch/$(ARCH)/include \
+ 	-include $(srctree)/include/linux/kconfig.h
+ 
+-NOSTDINC_FLAGS += -nostdinc -isystem $(shell $(CC) -print-file-name=include)
++# NOSTDINC_FLAGS += -nostdinc -isystem $(shell $(CC) -print-file-name=include)
+ 
+ # FIX ME
+ cpp_flags := $(KBUILD_CPPFLAGS) $(PLATFORM_CPPFLAGS) $(UBOOTINCLUDE) \
diff --git a/u-boot-tools/patches/patch-tools_Makefile b/u-boot-tools/patches/patch-tools_Makefile
new file mode 100644
index 0000000000..801d79e54d
--- /dev/null
+++ b/u-boot-tools/patches/patch-tools_Makefile
@@ -0,0 +1,15 @@
+$NetBSD$
+
+Add linker flags for building with native compiler.
+
+--- tools/Makefile.orig	2023-04-03 20:38:50.000000000 +0000
++++ tools/Makefile
+@@ -242,7 +242,7 @@ HOSTCFLAGS_mkeficapsule.o += \
+ HOSTCFLAGS_mkeficapsule.o += \
+ 	$(shell pkg-config --cflags uuid 2> /dev/null || echo "")
+ HOSTLDLIBS_mkeficapsule += \
+-	$(shell pkg-config --libs gnutls 2> /dev/null || echo "-lgnutls")
++	$(shell pkg-config --libs gnutls 2> /dev/null || echo "-L@PREFIX@/lib -Wl,-rpath,@PREFIX@/lib -lgnutls")
+ HOSTLDLIBS_mkeficapsule += \
+ 	$(shell pkg-config --libs uuid 2> /dev/null || echo "-luuid")
+ hostprogs-$(CONFIG_TOOLS_MKEFICAPSULE) += mkeficapsule


Home | Main Index | Thread Index | Old Index