summaryrefslogtreecommitdiff
path: root/filesystems
diff options
context:
space:
mode:
authorAlexander Shursha <kekek2@ya.ru>2024-12-19 10:34:06 +0300
committerMatthias Andree <mandree@FreeBSD.org>2025-06-30 16:48:23 +0200
commit96f0ac0d877ab5f0b4c48fceb84b2ea9c29927b9 (patch)
treef4f7ad7908c690ca338f7a94045481590fb62a2c /filesystems
parentmisc/libuuid: Add new port (diff)
filesystems/libblkid: Add new port
Diffstat (limited to 'filesystems')
-rw-r--r--filesystems/Makefile1
-rw-r--r--filesystems/libblkid/Makefile32
-rw-r--r--filesystems/libblkid/distinfo3
-rw-r--r--filesystems/libblkid/files/patch-meson.build59
-rw-r--r--filesystems/libblkid/pkg-descr5
-rw-r--r--filesystems/libblkid/pkg-plist29
6 files changed, 129 insertions, 0 deletions
diff --git a/filesystems/Makefile b/filesystems/Makefile
index 06b3f1f189ca..e5e504cb16f4 100644
--- a/filesystems/Makefile
+++ b/filesystems/Makefile
@@ -43,6 +43,7 @@
SUBDIR += jmtpfs
SUBDIR += kio-fuse
SUBDIR += libbde
+ SUBDIR += libblkid
SUBDIR += libfsapfs
SUBDIR += libfsext
SUBDIR += libfsfat
diff --git a/filesystems/libblkid/Makefile b/filesystems/libblkid/Makefile
new file mode 100644
index 000000000000..f628c92cb681
--- /dev/null
+++ b/filesystems/libblkid/Makefile
@@ -0,0 +1,32 @@
+PORTNAME= libblkid
+DISTVERSIONPREFIX= v
+DISTVERSION= 2.41
+CATEGORIES= filesystems
+
+MAINTAINER= arrowd@FreeBSD.org
+COMMENT= Library to identify block devices (disks) as to their content
+WWW= https://github.com/util-linux/util-linux
+
+LICENSE= BSD3CLAUSE
+LICENSE_FILE= ${WRKSRC}/Documentation/licenses/COPYING.BSD-3-Clause
+
+USES= bison meson pkgconfig tar:xz
+
+USE_GITHUB= yes
+GH_ACCOUNT= util-linux
+GH_PROJECT= util-linux
+
+USE_LDCONFIG= yes
+OPTIONS_SUB= yes
+# disable all Meson features because the project has gazillion of them and we only need few
+MESON_ARGS= --auto-features=disabled \
+ -Db_lundef=false \
+ -Dprogram-tests=false \
+ -Dallow-32bit-time=true \
+ -Dbuild-libblkid=enabled \
+ -Dbuild-libsmartcols=enabled # dependency of libblkid
+
+OPTIONS_DEFINE= MANPAGES
+MANPAGES_BUILD_DEPENDS= asciidoctor:textproc/rubygem-asciidoctor
+
+.include <bsd.port.mk>
diff --git a/filesystems/libblkid/distinfo b/filesystems/libblkid/distinfo
new file mode 100644
index 000000000000..c983115c941c
--- /dev/null
+++ b/filesystems/libblkid/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1742552423
+SHA256 (util-linux-util-linux-v2.41_GH0.tar.gz) = 277407acf21815006eb4bb2ee9c2fa2ea6f4f84bfc57486c460c6bc8c77a4445
+SIZE (util-linux-util-linux-v2.41_GH0.tar.gz) = 16079500
diff --git a/filesystems/libblkid/files/patch-meson.build b/filesystems/libblkid/files/patch-meson.build
new file mode 100644
index 000000000000..757fff747c84
--- /dev/null
+++ b/filesystems/libblkid/files/patch-meson.build
@@ -0,0 +1,59 @@
+--- meson.build.orig 2025-03-18 12:50:51 UTC
++++ meson.build
+@@ -861,7 +861,7 @@ conf.set('HAVE_DECL_VMADDR_CID_LOCAL', have ? 1 : fals
+ prefix : '#include <sys/socket.h>')
+ conf.set('HAVE_DECL_VMADDR_CID_LOCAL', have ? 1 : false)
+
+-build_plymouth_support = (not build_plymouth_support.disabled() and
++build_plymouth_support = (not build_plymouth_support.disabled() and
+ have_tiocglcktrmios and
+ have_sock_cloexec and
+ have_sock_nonblock and
+@@ -1870,14 +1870,7 @@ endif
+ bashcompletions += ['zramctl']
+ endif
+
+-exe = executable(
+- 'prlimit',
+- prlimit_sources,
+- include_directories : includes,
+- link_with : [lib_common,
+- lib_smartcols],
+- install_dir : usrbin_exec_dir,
+- install : true)
++exe = disabler()
+ if not is_disabler(exe)
+ exes += exe
+ manadocs += prlimit_manadocs
+@@ -1993,15 +1986,7 @@ endif
+ bashcompletions += ['swapoff']
+ endif
+
+-exe = executable(
+- 'lscpu',
+- lscpu_sources,
+- include_directories : includes,
+- link_with : [lib_common,
+- lib_smartcols],
+- dependencies : [rtas_libs],
+- install_dir : usrbin_exec_dir,
+- install : true)
++exe = disabler()
+ if not is_disabler(exe)
+ exes += exe
+ manadocs += lscpu_manadocs
+@@ -2023,13 +2008,7 @@ endif
+ bashcompletions += ['chcpu']
+ endif
+
+-exe = executable(
+- 'wdctl',
+- wdctl_sources,
+- include_directories : includes,
+- link_with : [lib_common,
+- lib_smartcols],
+- install : true)
++exe = disabler()
+ if not is_disabler(exe)
+ exes += exe
+ manadocs += wdctl_manadocs
diff --git a/filesystems/libblkid/pkg-descr b/filesystems/libblkid/pkg-descr
new file mode 100644
index 000000000000..52777d437567
--- /dev/null
+++ b/filesystems/libblkid/pkg-descr
@@ -0,0 +1,5 @@
+The libblkid library is used to identify block devices (disks) as to their
+content (e.g., filesystem type) as well as extracting additional information
+such as filesystem labels/volume names, unique identifiers/serial numbers.
+A common use is to allow use of LABEL= and UUID= tags instead of hard-coding
+specific block device names into configuration files.
diff --git a/filesystems/libblkid/pkg-plist b/filesystems/libblkid/pkg-plist
new file mode 100644
index 000000000000..31f9a10f43fe
--- /dev/null
+++ b/filesystems/libblkid/pkg-plist
@@ -0,0 +1,29 @@
+bin/column
+bin/fincore
+bin/renice
+bin/setpgid
+bin/setsid
+include/blkid/blkid.h
+include/libsmartcols/libsmartcols.h
+lib/libblkid.a
+lib/libblkid.so
+lib/libblkid.so.1
+lib/libblkid.so.1.1.0
+lib/libsmartcols.a
+lib/libsmartcols.so
+lib/libsmartcols.so.1
+lib/libsmartcols.so.1.1.0
+libdata/pkgconfig/blkid.pc
+libdata/pkgconfig/smartcols.pc
+sbin/blkid
+sbin/readprofile
+sbin/wipefs
+%%MANPAGES%%share/man/man1/column.1.gz
+%%MANPAGES%%share/man/man1/fincore.1.gz
+%%MANPAGES%%share/man/man1/renice.1.gz
+%%MANPAGES%%share/man/man3/libblkid.3.gz
+%%MANPAGES%%share/man/man5/scols-filter.5.gz
+%%MANPAGES%%share/man/man5/terminal-colors.d.5.gz
+%%MANPAGES%%share/man/man8/blkid.8.gz
+%%MANPAGES%%share/man/man8/readprofile.8.gz
+%%MANPAGES%%share/man/man8/wipefs.8.gz