]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
Bump required minimum version of blkid to 2.37
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sun, 17 Aug 2025 13:05:53 +0000 (22:05 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Fri, 2 Jan 2026 02:12:05 +0000 (11:12 +0900)
Major distributions already have blkid >= 2.37.
Let's bump the minimal required version.

Note, util-linux (which provides blkid) 2.37 was released on 2021-06-01.

See also #38608.

README
meson.build
src/udev/udev-builtin-blkid.c

diff --git a/README b/README
index 4fcd1117771297c1d62e0bc6c8fcdd5e4a0ea6eb..2985d5c4fa512a5e068cc69fc3ac0c23fbacb1c9 100644 (file)
--- a/README
+++ b/README
@@ -216,7 +216,7 @@ REQUIREMENTS:
         libmount >= 2.30 (from util-linux)
                 (util-linux *must* be built without --enable-libmount-support-mtab)
         libseccomp >= 2.3.1 (optional)
-        libblkid >= 2.24 (from util-linux) (optional)
+        libblkid >= 2.37 (from util-linux) (optional)
         libkmod >= 15 (optional)
         PAM >= 1.1.2 (optional)
         libcryptsetup >= 2.0.1 (optional),
index 3b179d64e09f6793373e7abf46051198c2c9861e..90604e41910fd5c0199b42b5ced6f828e55b9edd 100644 (file)
@@ -1229,10 +1229,9 @@ conf.set10('HAVE_AUDIT', libaudit.found())
 libaudit_cflags = libaudit.partial_dependency(includes: true, compile_args: true)
 
 libblkid = dependency('blkid',
+                      version : '>=2.37.0',
                       required : get_option('blkid'))
 conf.set10('HAVE_BLKID', libblkid.found())
-conf.set10('HAVE_BLKID_PROBE_SET_HINT',
-           libblkid.found() and cc.has_function('blkid_probe_set_hint', dependencies : libblkid))
 libblkid_cflags = libblkid.partial_dependency(includes: true, compile_args: true)
 
 libkmod = dependency('libkmod',
index 5e7f78eebced8f440db432c10c88fb4abf02c2ac..6ec02674b9fd62966a9b1f06b3ac8c5627652fdd 100644 (file)
@@ -458,21 +458,11 @@ static int builtin_blkid(UdevEvent *event, int argc, char *argv[]) {
 
                 switch (option) {
                 case 'H':
-#if HAVE_BLKID_PROBE_SET_HINT
                         errno = 0;
                         r = sym_blkid_probe_set_hint(pr, optarg, 0);
                         if (r < 0)
                                 return log_device_error_errno(dev, errno_or_else(ENOMEM), "Failed to use '%s' probing hint: %m", optarg);
                         break;
-#else
-                        /* Use the hint <name>=<offset> as probing offset for old versions */
-                        optarg = strchr(optarg, '=');
-                        if (!optarg)
-                                /* no value means 0, do nothing for old versions */
-                                break;
-                        ++optarg;
-                        _fallthrough_;
-#endif
                 case 'o':
                         r = safe_atoi64(optarg, &offset);
                         if (r < 0)
@@ -489,7 +479,7 @@ static int builtin_blkid(UdevEvent *event, int argc, char *argv[]) {
         sym_blkid_probe_set_superblocks_flags(pr,
                 BLKID_SUBLKS_LABEL | BLKID_SUBLKS_UUID |
                 BLKID_SUBLKS_TYPE | BLKID_SUBLKS_SECTYPE |
-#ifdef BLKID_SUBLKS_FSINFO
+#ifdef BLKID_SUBLKS_FSINFO /* since util-linux 2.39 */
                 BLKID_SUBLKS_FSINFO |
 #endif
                 BLKID_SUBLKS_USAGE | BLKID_SUBLKS_VERSION);