Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F162974487
D57317.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
4 KB
Referenced Files
None
Subscribers
None
D57317.diff
View Options
diff --git a/sysutils/Makefile b/sysutils/Makefile
--- a/sysutils/Makefile
+++ b/sysutils/Makefile
@@ -1187,6 +1187,7 @@
SUBDIR += root-tail
SUBDIR += rovclock
SUBDIR += rpi-firmware
+ SUBDIR += rpi-usbboot
SUBDIR += rset
SUBDIR += rshim-user-space
SUBDIR += rsnapshot
diff --git a/sysutils/rpi-usbboot/Makefile b/sysutils/rpi-usbboot/Makefile
new file mode 100644
--- /dev/null
+++ b/sysutils/rpi-usbboot/Makefile
@@ -0,0 +1,22 @@
+PORTNAME= rpi-usbboot
+DISTVERSION= 20260603
+CATEGORIES= sysutils
+
+MAINTAINER= jrm@FreeBSD.org
+COMMENT= Raspberry Pi USB device provisioning tool
+WWW= https://github.com/raspberrypi/usbboot
+
+LICENSE= APACHE20
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+USES= gmake pkgconfig
+
+USE_GITHUB= yes
+GH_ACCOUNT= raspberrypi
+GH_PROJECT= usbboot
+GH_TAGNAME= 58c1051777998637083b9d7d8b8700dabf97d468
+
+ALL_TARGET= rpiboot
+MAKE_ARGS= INSTALL_PREFIX=${PREFIX} PKG_VER=${DISTVERSION}
+
+.include <bsd.port.mk>
diff --git a/sysutils/rpi-usbboot/distinfo b/sysutils/rpi-usbboot/distinfo
new file mode 100644
--- /dev/null
+++ b/sysutils/rpi-usbboot/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1780510799
+SHA256 (raspberrypi-usbboot-20260603-58c1051777998637083b9d7d8b8700dabf97d468_GH0.tar.gz) = 0826b38b1e07069edf73df0027a75e2dbe49ca09d8f9be86b10a6767c03aa9c7
+SIZE (raspberrypi-usbboot-20260603-58c1051777998637083b9d7d8b8700dabf97d468_GH0.tar.gz) = 126865434
diff --git a/sysutils/rpi-usbboot/files/patch-Makefile b/sysutils/rpi-usbboot/files/patch-Makefile
new file mode 100644
--- /dev/null
+++ b/sysutils/rpi-usbboot/files/patch-Makefile
@@ -0,0 +1,18 @@
+--- Makefile.orig 2026-05-27 13:41:12 UTC
++++ Makefile
+@@ -1,6 +1,3 @@
+-BUILD_DATE ?= $(shell date "+%Y/%m/%d")
+-PKG_VER=$(shell if [ -f debian/changelog ]; then grep rpiboot debian/changelog | head -n1 | sed 's/.*(\(.*\)).*/\1/g'; else echo local; fi)
+-GIT_VER=$(shell git rev-parse HEAD 2>/dev/null | cut -c1-8 || echo "")
+ HAVE_XXD=$(shell xxd -v >/dev/null 2>/dev/null && echo y)
+ INSTALL_PREFIX?=/usr
+ ifeq ($(OS),Windows_NT)
+@@ -10,7 +7,7 @@ rpiboot: main.c bootfiles.c decode_duid.c fmemopen.c m
+ endif
+
+ rpiboot: main.c bootfiles.c decode_duid.c fmemopen.c msd/bootcode.h msd/start.h msd/bootcode4.h
+- $(CC) -Wall -Wextra -g $(CPPFLAGS) $(CFLAGS) -o $@ main.c bootfiles.c decode_duid.c `pkg-config --cflags --libs libusb-1.0` -DGIT_VER="\"$(GIT_VER)\"" -DPKG_VER="\"$(PKG_VER)\"" -DBUILD_DATE="\"$(BUILD_DATE)\"" -DDEFAULT_MSG_DIR=\"$(DEFAULT_MSG_DIR)\" $(LDFLAGS)
++ $(CC) $(CPPFLAGS) $(CFLAGS) -o $@ main.c bootfiles.c decode_duid.c `pkg-config --cflags --libs libusb-1.0` -DPKG_VER="\"$(PKG_VER)\"" -DDEFAULT_MSG_DIR=\"$(DEFAULT_MSG_DIR)\" $(LDFLAGS)
+
+ ifeq ($(HAVE_XXD),y)
+ %.h: %.bin
diff --git a/sysutils/rpi-usbboot/files/patch-main.c b/sysutils/rpi-usbboot/files/patch-main.c
new file mode 100644
--- /dev/null
+++ b/sysutils/rpi-usbboot/files/patch-main.c
@@ -0,0 +1,11 @@
+--- main.c.orig 2026-06-03 17:54:41 UTC
++++ main.c
+@@ -480,7 +480,7 @@ void print_version(void)
+
+ void print_version(void)
+ {
+- printf("RPIBOOT: build-date %s pkg-version %s %s\n", BUILD_DATE, PKG_VER, GIT_VER);
++ printf("RPIBOOT: FreeBSD package version %s\n", PKG_VER);
+ }
+
+ void get_options(int argc, char *argv[])
diff --git a/sysutils/rpi-usbboot/pkg-descr b/sysutils/rpi-usbboot/pkg-descr
new file mode 100644
--- /dev/null
+++ b/sysutils/rpi-usbboot/pkg-descr
@@ -0,0 +1,5 @@
+The rpiboot tool provides a file server for loading software into memory
+on a Raspberry Pi for provisioning. By default, it boots the device
+with firmware that makes it appear to the host as a USB mass-storage
+device. The host operating system then treats it as a standard USB
+drive, allowing the filesystem to be accessed.
diff --git a/sysutils/rpi-usbboot/pkg-plist b/sysutils/rpi-usbboot/pkg-plist
new file mode 100644
--- /dev/null
+++ b/sysutils/rpi-usbboot/pkg-plist
@@ -0,0 +1,7 @@
+bin/rpiboot
+share/rpiboot/mass-storage-gadget64/boot.img
+share/rpiboot/mass-storage-gadget64/bootfiles.bin
+share/rpiboot/mass-storage-gadget64/config.txt
+share/rpiboot/msd/bootcode.bin
+share/rpiboot/msd/bootcode4.bin
+share/rpiboot/msd/start.elf
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Jul 19, 8:27 PM (19 h, 39 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
35248725
Default Alt Text
D57317.diff (4 KB)
Attached To
Mode
D57317: sysutils/rpi-usbboot: Raspberry Pi USB device provisioning tool
Attached
Detach File
Event Timeline
Log In to Comment