public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/nbd] f44: Update to 3.27.1 and adapt to new tarball format
@ 2026-08-04 20:56 Pablo Greco
0 siblings, 0 replies; only message in thread
From: Pablo Greco @ 2026-08-04 20:56 UTC (permalink / raw)
To: git-commits
A new commit has been pushed.
Repo : rpms/nbd
Branch : f44
Commit : 6759ec9834a8bafe016adf7e2fc25c37a93fb90f
Author : Pablo Greco <psgreco@gmail.com>
Date : 2026-05-02T06:32:33-07:00
Stats : +136/-4 in 4 file(s)
URL : https://src.fedoraproject.org/rpms/nbd/c/6759ec9834a8bafe016adf7e2fc25c37a93fb90f?branch=f44
Log:
Update to 3.27.1 and adapt to new tarball format
---
diff --git a/.gitignore b/.gitignore
index 5cbe819..0eabddd 100644
--- a/.gitignore
+++ b/.gitignore
@@ -20,3 +20,4 @@
/nbd-3.24.tar.xz
/nbd-3.25.tar.xz
/nbd-3.27.0.tar.xz
+/nbd-3.27.1.tar.gz
diff --git a/89ba7b5379548d6ebbfa36db15f2b8e3787a09ea.patch b/89ba7b5379548d6ebbfa36db15f2b8e3787a09ea.patch
new file mode 100644
index 0000000..90e80d9
--- /dev/null
+++ b/89ba7b5379548d6ebbfa36db15f2b8e3787a09ea.patch
@@ -0,0 +1,118 @@
+From a80304e10e9709d4100c935bc4cdc9086e86d5ff Mon Sep 17 00:00:00 2001
+From: Wouter Verhelst <w@uter.be>
+Date: Tue, 14 Apr 2026 19:06:10 +0200
+Subject: [PATCH 1/3] Fix nbd device parsing, for reals
+
+---
+ nbd-client.c | 22 ++++++++++++++++------
+ 1 file changed, 16 insertions(+), 6 deletions(-)
+
+diff --git a/nbd-client.c b/nbd-client.c
+index c5d2b32bce8a..2e98ba5318d0 100644
+--- a/nbd-client.c
++++ b/nbd-client.c
+@@ -225,10 +225,14 @@ static void netlink_disconnect(char *nbddev) {
+ struct nl_msg *msg;
+ int driver_id;
+ int ret;
++ char *local_dev = nbddev;
+
+ int index = -1;
+ if (nbddev) {
+- if (sscanf(nbddev, "nbd%d", &index) != 1)
++ if (!strncmp(local_dev, "/dev/", 5)) {
++ local_dev += 5;
++ }
++ if (sscanf(local_dev, "nbd%d", &index) != 1)
+ err("Invalid nbd device target\n");
+ }
+ if (index < 0)
+@@ -313,13 +317,15 @@ static int netlink_check_conn(char* devname, int do_print) {
+ struct nl_msg *msg;
+ int driver_id, ret;
+ int index = -1;
++ char *local_dev = devname;
+ int connected = -1; /* -1 = unknown, 0 = connected, 1 = disconnected */
+
+ /* Parse device index from name */
+- if (sscanf(devname, "/dev/nbd%d", &index) != 1) {
+- if (sscanf(devname, "nbd%d", &index) != 1) {
+- return 2; /* Invalid device name */
+- }
++ if (!strncmp(local_dev, "/dev/", 5)) {
++ local_dev += 5;
++ }
++ if (sscanf(local_dev, "nbd%d", &index) != 1) {
++ return 2; /* Invalid device name */
+ }
+
+ /* Setup netlink socket */
+@@ -1539,7 +1545,11 @@ int main(int argc, char *argv[]) {
+ if (netlink) {
+ int index = -1;
+ if (cur_client->dev) {
+- if (sscanf(cur_client->dev, "nbd%d", &index) != 1)
++ char *local_dev = cur_client->dev;
++ if(!strncmp(local_dev, "/dev/", 5)) {
++ local_dev += 5;
++ }
++ if (sscanf(local_dev, "nbd%d", &index) != 1)
+ err("Invalid nbd device target\n");
+ }
+ netlink_configure(index, sockfds, flags, identifier);
+--
+2.54.0
+
+
+From 1523d9927ba14c93cb8d1339222fd24e98d19110 Mon Sep 17 00:00:00 2001
+From: Wouter Verhelst <w@uter.be>
+Date: Sat, 2 May 2026 00:28:37 +0200
+Subject: [PATCH 2/3] nbdtab man page: Add missing closing tag
+
+---
+ man/nbdtab.5.sgml.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/man/nbdtab.5.sgml.in b/man/nbdtab.5.sgml.in
+index 9973412cd5ab..0a18202e29e5 100644
+--- a/man/nbdtab.5.sgml.in
++++ b/man/nbdtab.5.sgml.in
+@@ -184,7 +184,7 @@ manpage.1: manpage.sgml
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+- <term><option>priority=<replaceable>GnuTLS priority string</replaceable></option>
++ <term><option>priority=<replaceable>GnuTLS priority string</replaceable></option></term>
+ <listitem>
+ <para>The GnuTLS priority string to use.</para>
+ <para>Corresponds to the <option>-y</option> option on the
+--
+2.54.0
+
+
+From 89ba7b5379548d6ebbfa36db15f2b8e3787a09ea Mon Sep 17 00:00:00 2001
+From: Wouter Verhelst <w@uter.be>
+Date: Sat, 2 May 2026 00:33:52 +0200
+Subject: [PATCH 3/3] Fix --help parsing
+
+Closes: gh-191
+---
+ args.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/args.c b/args.c
+index f56f0a4abcce..97a96c141ca0 100644
+--- a/args.c
++++ b/args.c
+@@ -156,7 +156,7 @@ blocksize:
+ client->no_optgo = true;
+ break;
+ case 'h':
+- usage_error(&result, NULL); // Will show help
++ usage_error(&result, ""); // Will show help
+ return result;
+ #if HAVE_NETLINK
+ case 'i':
+--
+2.54.0
+
diff --git a/nbd.spec b/nbd.spec
index bf6a6cc..6adb73f 100644
--- a/nbd.spec
+++ b/nbd.spec
@@ -1,13 +1,15 @@
Name: nbd
-Version: 3.27.0
+Version: 3.27.1
Release: %autorelease
Summary: Network Block Device user-space tools (TCP version)
# SPDX migration
License: GPL-2.0-only
URL: https://github.com/NetworkBlockDevice/nbd
-Source0: https://github.com/NetworkBlockDevice/nbd/releases/download/nbd-%{version}/nbd-%{version}.tar.xz
+Source0: https://github.com/NetworkBlockDevice/nbd/archive/refs/tags/%{name}-%{version}.tar.gz
Source1: nbd-server.service
Source2: nbd-server.sysconfig
+# Backport parsing fixes from main branch
+Patch1: 89ba7b5379548d6ebbfa36db15f2b8e3787a09ea.patch
BuildRequires: make
BuildRequires: gcc
@@ -18,6 +20,12 @@ BuildRequires: libnl3-devel
BuildRequires: bison
BuildRequires: docbook-utils
BuildRequires: systemd
+# We need to run autogen.sh now
+BuildRequires: autoconf
+BuildRequires: autoconf-archive
+BuildRequires: automake
+BuildRequires: libtool
+BuildRequires: flex
%{?systemd_requires}
Excludearch: %{ix86}
@@ -27,12 +35,17 @@ Tools for the Linux Kernel's network block device, allowing you to use
remote block devices over a TCP/IP network.
%prep
-%autosetup -p1
+%autosetup -p1 -n %{name}-%{name}-%{version}
+# tarball doesn't include git history, force the version it returns
+# from the release tag
+echo "echo %{version}" > support/genver.sh
+
# wait longer for nbd-server to fully start,
# five seconds may not be enough on Fedora building infra
sed -i 's/tv_sec = 5/tv_sec = 30/' tests/run/nbd-tester-client.c
%build
+./autogen.sh
%configure --enable-syslog --enable-lfs --enable-manpages
%make_build
diff --git a/sources b/sources
index 66b1ede..2b6689f 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-SHA512 (nbd-3.27.0.tar.xz) = 52b71c8a2cf3163065b34c49f95dc14205152ee11db199742257f67c17bb723965105d22b450f36df79e0b316de6d99431a5f2d336d31e1fbc18167c40de0a5a
+SHA512 (nbd-3.27.1.tar.gz) = e75372c9214ebeb66f5699d12b43bde98d8d123094a58c8dd07cc55c744523fe741c4ef4a0c54f7a1a64b817539a4817a825f89db36ae6cedeb5932a8867f966
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-08-04 20:56 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-08-04 20:56 [rpms/nbd] f44: Update to 3.27.1 and adapt to new tarball format Pablo Greco
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox