From c21a9b8518a78acd905a5ca33be5e194af38a535 Mon Sep 17 00:00:00 2001 From: "Dan R. K. Ports" Date: Tue, 2 Jun 2026 17:16:53 -0700 Subject: [PATCH] ipmitool: use iana-enterprise-numbers port instead of build-time DL Previously, the port tried to download this file at build time. Eliminating this makes the build reproducible, and also fixes problems when the upstream URL changes. Fixes: https://trac.macports.org/ticket/67161 --- sysutils/ipmitool/Portfile | 7 +- .../ipmitool/files/enterprise-numbers.patch | 65 ++++++++++++++----- 2 files changed, 52 insertions(+), 20 deletions(-) diff --git a/sysutils/ipmitool/Portfile b/sysutils/ipmitool/Portfile index 0df18b40835..6eac5a2e4ef 100644 --- a/sysutils/ipmitool/Portfile +++ b/sysutils/ipmitool/Portfile @@ -8,7 +8,7 @@ PortGroup legacysupport 1.1 legacysupport.newest_darwin_requires_legacy 10 codeberg.setup IPMITool ipmitool 1_8_19 IPMITOOL_ -revision 0 +revision 1 # Distfile changed when the upstream source moved from github to codeberg # (same git tag, but a different auto-generated tarball). dist_subdir ${name}/${codeberg.version}_1 @@ -42,11 +42,10 @@ autoreconf.args depends_build port:autoconf \ port:automake \ port:libtool \ - port:curl \ - path:libexec/coreutils/libstdbuf.so:coreutils \ - port:wget + path:libexec/coreutils/libstdbuf.so:coreutils depends_lib path:lib/libssl.dylib:openssl \ port:readline +depends_run port:iana-enterprise-numbers patchfiles arm64-delloem.patch \ enterprise-numbers.patch diff --git a/sysutils/ipmitool/files/enterprise-numbers.patch b/sysutils/ipmitool/files/enterprise-numbers.patch index 3c7f162c74b..8118229ad43 100644 --- a/sysutils/ipmitool/files/enterprise-numbers.patch +++ b/sysutils/ipmitool/files/enterprise-numbers.patch @@ -1,43 +1,76 @@ -Fix enterprise-numbers URL - -IANA has changed their URL scheme, and the content at the old URL for -enterprise-numbers switched from text/plain to text/html. - -Fix Makefile.am to use the new URL -https://github.com/ipmitool/ipmitool/commit/1edb0e27e44196d1ebe449aba0b9be22d376bcb6 - -Also fix manpages (no corresponding upstream commit; repository is archived and -no longer accepts contributions) --- Makefile.am.orig +++ Makefile.am -@@ -41,7 +41,7 @@ MAINTAINERCLEANFILES = Makefile.in aclocal.m4 configure configure-stamp \ +@@ -41,44 +41,21 @@ $(distdir).tar.gz $(distdir).tar.bz2 SUBDIRS = lib src include doc contrib control -IANA_PEN = http://www.iana.org/assignments/enterprise-numbers -+IANA_PEN = http://www.iana.org/assignments/enterprise-numbers.txt dist-hook: cp control/ipmitool.spec $(distdir) + + .PHONY: install-pen-database uninstall-pen-database +-.INTERMEDIATE: %.o %.la enterprise-numbers ++.INTERMEDIATE: %.o %.la + +-if DOWNLOAD +- +-enterprise-numbers: +- @echo Downloading IANA PEN database... +- @$(DOWNLOAD) "$(IANA_PEN)" > tmpfile.$$PPID || {\ +- echo "FAILED to download the IANA PEN database"; \ +- rm tmpfile.$$PPID; \ +- false; \ +- } +- @mv tmpfile.$$PPID $@ +- +-install-pen-database: enterprise-numbers +- mkdir -m 755 -p $(DESTDIR)$(IANADIR) +- $(INSTALL_DATA) $< $(DESTDIR)$(IANADIR)/ +- +-uninstall-pen-database: +- -rm -rf $(DESTDIR)$(IANADIR)/enterprise-numbers +- +-else +- + install-pen-database: +- @echo "*** NOT installing the IANA PEN database." +- @echo "*** Don't know how to download it." ++ @echo "*** Not installing the IANA PEN database; it is provided by the" ++ @echo "*** iana-enterprise-numbers MacPorts port." + + uninstall-pen-database: +- @echo "*** NOT uninstalling the IANA PEN database." +- @echo "*** It was installed manually (if ever)." ++ @echo "*** Not uninstalling the IANA PEN database; it is provided by the" ++ @echo "*** iana-enterprise-numbers MacPorts port." + +-endif +- + install-data-local: install-pen-database + mkdir -p $(DESTDIR)$(DOCDIR) + $(INSTALL_DATA) $(DOCLIST) $(DESTDIR)$(DOCDIR) --- doc/ipmievd.8.in.orig +++ doc/ipmievd.8.in -@@ -221,7 +221,7 @@ +@@ -221,7 +221,8 @@ .SH FILES .TP .B @IANADIR@/enterprise-numbers -system IANA PEN registry taken from http://www.iana.org/assignments/enterprise-numbers -+system IANA PEN registry taken from http://www.iana.org/assignments/enterprise-numbers.txt ++system IANA PEN registry taken from ++https://www.iana.org/assignments/enterprise-numbers.txt .TP .B ~/@IANAUSERDIR@/enterprise-numbers user's override for the system IANA PEN registry, this file if it exists is loaded instead --- doc/ipmitool.1.in.orig +++ doc/ipmitool.1.in -@@ -3831,7 +3831,7 @@ +@@ -3831,7 +3831,8 @@ .SH FILES .TP .B @IANADIR@/enterprise-numbers -system IANA PEN registry taken from http://www.iana.org/assignments/enterprise-numbers -+system IANA PEN registry taken from http://www.iana.org/assignments/enterprise-numbers.txt ++system IANA PEN registry taken from ++https://www.iana.org/assignments/enterprise-numbers.txt .TP .B ~/@IANAUSERDIR@/enterprise-numbers user's override for the system IANA PEN registry, this file if it exists is loaded instead