- update to 3.1.1:
* Use glib2 G_GNUC_UNUSED in place of UNUSED locally defined * Port to G_GNUC_INTERNAL for controlling symbols visibility * Fix some more occurrences of missing port to G_GNUC_UNUSED * dm_logging: Annotate redirect_dm_log() printf format * tests: Add NVMe persistent discovery controller tests * tests: Add NVMe controller type checks * Makefile: Fix bumpver to work with micro versions * tests: Manually remove removed PVs from LVM devices file * tests: Ignore LVM devices file for non-LVM tests * tests: Fix removing custom LVM devices file * nvme: Add bd_nvme_is_tech_avail to the API file * lvm-dbus: Fix passing size for pvresize over DBus replaced by LVM VDO) OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/libblockdev?expand=0&rev=58
This commit is contained in:
commit
c2406b5eb7
23
.gitattributes
vendored
Normal file
23
.gitattributes
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
## Default LFS
|
||||
*.7z filter=lfs diff=lfs merge=lfs -text
|
||||
*.bsp filter=lfs diff=lfs merge=lfs -text
|
||||
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.gem filter=lfs diff=lfs merge=lfs -text
|
||||
*.gz filter=lfs diff=lfs merge=lfs -text
|
||||
*.jar filter=lfs diff=lfs merge=lfs -text
|
||||
*.lz filter=lfs diff=lfs merge=lfs -text
|
||||
*.lzma filter=lfs diff=lfs merge=lfs -text
|
||||
*.obscpio filter=lfs diff=lfs merge=lfs -text
|
||||
*.oxt filter=lfs diff=lfs merge=lfs -text
|
||||
*.pdf filter=lfs diff=lfs merge=lfs -text
|
||||
*.png filter=lfs diff=lfs merge=lfs -text
|
||||
*.rpm filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.tgz filter=lfs diff=lfs merge=lfs -text
|
||||
*.ttf filter=lfs diff=lfs merge=lfs -text
|
||||
*.txz filter=lfs diff=lfs merge=lfs -text
|
||||
*.whl filter=lfs diff=lfs merge=lfs -text
|
||||
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||
*.zip filter=lfs diff=lfs merge=lfs -text
|
||||
*.zst filter=lfs diff=lfs merge=lfs -text
|
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
.osc
|
3
libblockdev-3.1.0.tar.gz
Normal file
3
libblockdev-3.1.0.tar.gz
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:41e4af66c9d78e795302d37825dfd88a4970f82da7b4ebe6487feba2afae44fb
|
||||
size 1054326
|
3
libblockdev-3.1.1.tar.gz
Normal file
3
libblockdev-3.1.1.tar.gz
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:a5cb33a53ff5969067982704f45399d02555fdb2313ed0c56eac9555397dc2db
|
||||
size 1056270
|
415
libblockdev.changes
Normal file
415
libblockdev.changes
Normal file
@ -0,0 +1,415 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Apr 10 11:29:31 UTC 2024 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- update to 3.1.1:
|
||||
* Use glib2 G_GNUC_UNUSED in place of UNUSED locally defined
|
||||
* Port to G_GNUC_INTERNAL for controlling symbols visibility
|
||||
* Fix some more occurrences of missing port to G_GNUC_UNUSED
|
||||
* dm_logging: Annotate redirect_dm_log() printf format
|
||||
* tests: Add NVMe persistent discovery controller tests
|
||||
* tests: Add NVMe controller type checks
|
||||
* Makefile: Fix bumpver to work with micro versions
|
||||
* tests: Manually remove removed PVs from LVM devices file
|
||||
* tests: Ignore LVM devices file for non-LVM tests
|
||||
* tests: Fix removing custom LVM devices file
|
||||
* nvme: Add bd_nvme_is_tech_avail to the API file
|
||||
* lvm-dbus: Fix passing size for pvresize over DBus
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Feb 12 10:06:44 UTC 2024 - Paolo Stivanin <info@paolostivanin.com>
|
||||
|
||||
- Update to 3.1.0:
|
||||
* Add BDPluginSpec constructor and use it in plugin_specs_from_names
|
||||
* overrides: Remove unused 'sys' import
|
||||
* swap: Add support for checking label and UUID format
|
||||
* fs: Add a function to check label format for F2FS
|
||||
* fs: Add a generic function to check for fs info availability
|
||||
* fs: Fix allowed UUID for generic mkfs with VFAT
|
||||
* fs: Add support for getting filesystem min size for NTFS and Ext
|
||||
* Mark NVDIMM plugin as deprecated since 3.1
|
||||
* part: Fix potential double free when getting parttype
|
||||
* Fix missing progress initialization in bd_crypto_luks_add_key
|
||||
* lvm-dbus: Fix leaking error
|
||||
* lvm-dbus: Avoid using already-freed memory
|
||||
* utils: Add expected printf string annotation
|
||||
* fs: Report reason for open() and ioctl() failures
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sat Nov 11 18:11:14 UTC 2023 - Sarah Kriesch <sarah.kriesch@opensuse.org>
|
||||
|
||||
- Add %{_libdir}/libbd_s390.so for s390x because missing file identitied
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Oct 13 08:09:53 UTC 2023 - Paolo Stivanin <info@paolostivanin.com>
|
||||
|
||||
- Update to 3.0.4:
|
||||
* plugins: use g_autofree for free'ing g_char's
|
||||
* plugins: btrfs: use g_autofree where possible for g_free
|
||||
* fs: correct btrfs set label description
|
||||
* nvme: Rework memory allocation for device ioctls
|
||||
* spec: Obsolete vdo plugin packages
|
||||
* spec: Move obsoleted devel subpackages to libblockdev-devel
|
||||
* ci: Bump actions/checkout from v3 to v4
|
||||
* part: Do not open disk read-write for read only operations
|
||||
* fs: Disable progress for ntfsresize
|
||||
* packit: Add configuration for downstream builds
|
||||
* logging: Default to DEBUG log level if compiled with --enable-debug
|
||||
* Use log function when calling a plugin function that is not loaded
|
||||
* lvm-dbus: Replace g_critical calls with bd_utils_log_format
|
||||
* tests: Fail early when recompilation fails in library_test
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Sep 29 07:48:57 UTC 2023 - Bjørn Lie <bjorn.lie@gmail.com>
|
||||
|
||||
- Update to version 3.0.3:
|
||||
* Always use "--fs ignore" with lvresize
|
||||
* nvme:
|
||||
- Use interim buffer for nvme_get_log_sanitize()
|
||||
- Generate HostID when missing
|
||||
* tests:
|
||||
- Specificy required versions when importing GLib and BlockDev
|
||||
introspection
|
||||
- Minor NVMe HostNQN fixes
|
||||
- Replace deprecated unittest assert calls
|
||||
* fs:
|
||||
- Fix leaking directories with temporary mounts
|
||||
- Fix memory leak
|
||||
* crypto: Correctly convert passphrases from Python to C
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Aug 23 01:16:38 UTC 2023 - Luciano Santos <luc14n0@opensuse.org>
|
||||
|
||||
- Update to version 3.0.2:
|
||||
* Use ntfsinfo instead of ntfscluster for faster
|
||||
bd_fs_ntfs_get_info.
|
||||
* Restrict list of exported symbols via -export-symbols-regex.
|
||||
* lib: Silence the missing DEFAULT_CONF_DIR_PATH.
|
||||
* loop: Report BD_LOOP_ERROR_DEVICE on empty loop devices.
|
||||
* fs: Fix unused error in extract_e2fsck_progress.
|
||||
* fs: Use read-only mount where possible for generic FS
|
||||
functions.
|
||||
* fs: Document that generic functions can mount filesystems.
|
||||
* fs: Avoid excess logging in extract_e2fsck_progress.
|
||||
- Restructure all sub-packages in the spec file to enhance
|
||||
maintainability.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Jun 30 10:16:53 UTC 2023 - Paolo Stivanin <info@paolostivanin.com>
|
||||
|
||||
- Update to 3.0.1:
|
||||
* New bugfix release of the libblockdev library with multiple
|
||||
fixes.
|
||||
* loop: Define LOOP_SET_BLOCK_SIZE is not defined. And remove
|
||||
bd_loop_get_autoclear definition.
|
||||
* crypto: Remove stray struct redefinition.
|
||||
* fs: Simplify struct BDFSInfo. And add missing copy and free
|
||||
functions to the header file.
|
||||
* vdo_stats: Remove unused libparted include.
|
||||
* lvm: Make _vglock_start_stop static. Fix declaration for
|
||||
bd_lvm_vdolvpoolname. And add bd_lvm_segdata_copy/free to the
|
||||
header file.
|
||||
* Make the conf.d directory versioned.
|
||||
- Changes from version 3.0.0:
|
||||
* New major release of the libblockdev library. This release
|
||||
contains a large API overhaul.
|
||||
* VDO a KBD plugins were removed.
|
||||
* New NVMe plugin was added.
|
||||
* Runtime dependencies are no longer checked during plugin
|
||||
initialization.
|
||||
* Part plugin was rewritten to use libfdisk instead of libparted
|
||||
* Crypto plugin API went through an extensive rewrite.
|
||||
* Support for new technologies was added to the crypto plugin:
|
||||
FileVault2 encryption, DM Integrity, LUKS2 tokens.
|
||||
* Filesystem plugin adds support for btrfs, F2FS, NILFS2, exFAT
|
||||
and UDF.
|
||||
* Support for new filesystem operations was added to the plugin:
|
||||
setting label and UUID, generic mkfs function and API for
|
||||
getting feature support for filesystems.
|
||||
* dmraid support was removed from the DM plugin.
|
||||
* Python 2 support was dropped.
|
||||
- Drop no longer needed libblockdev-fix-libkmod-include.patch
|
||||
- Drop no longer supported sub-packages with their dependencies,
|
||||
and their configure options, following upstream changes: python2
|
||||
(python-devel), bcache, dmraid (dmraid-devel BuildRequires) and
|
||||
kbd.
|
||||
- Add (gcc >= 11 or gcc11) boolean BuildRequires to ensure the
|
||||
package is buildable on Leap 15.5, where the gcc meta-package is
|
||||
of version 7.
|
||||
- Bump the SO version to 3 for the shared library and GI bindings
|
||||
sub-packages.
|
||||
- Add ext2fs, fdisk, and libkeyutils pkgconfig() BuildRequires.
|
||||
The first is a new dependency for the FS plugin. The second, for
|
||||
the PART plugin. And the latter, for the CRYPTO plugin (before,
|
||||
the explicit_bzero() function would be searched for).
|
||||
- Add libnvme-devel >= 1.3 BuildRequires, and pass --with-nvme to
|
||||
configure, needed for the NVMe plugin (new upstream addition).
|
||||
- Pass --with-tools to configure, ensuring we keep building the
|
||||
libblockdev tools.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Oct 7 12:08:15 UTC 2022 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- update to 2.28:
|
||||
* lvm: Fix bd_lvm_get_supported_pe_sizes in Python on 32bit
|
||||
* tests: Create bigger devices for XFS tests
|
||||
* tests: Use ext instead of xfs in MountTestCase.test_mount_ro_device
|
||||
* mpath: Memory leak fix
|
||||
* spec: Require the same version utils from plugins
|
||||
* mdraid: Try harder to get container UUID in bd_md_detail
|
||||
* Add a test case for DDF arrays/containers
|
||||
* mdraid: Do not ignore errors from bd_md_canonicalize_uuid in bd_md_examine
|
||||
* mdraid: Try harder to get container UUID in bd_md_examine
|
||||
* mdraid: Fix copy-paste error when checking return value
|
||||
* tests: Wait for raid and mirrored LVs to be synced before removing
|
||||
* tests: Make smaller images for test_lvcreate_type
|
||||
* dm: Fix comparing DM RAID member devices UUID
|
||||
* mdraid: Fix use after free
|
||||
* ci: Add .lgtm.yaml config for LGTM
|
||||
* ci: Add GitHub actions for running rpmbuilds and csmock
|
||||
* mpath: Fix potential NULL pointer dereference
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jul 27 18:01:59 UTC 2022 - Sarah Kriesch <sarah.kriesch@opensuse.org>
|
||||
|
||||
- Update to version 2.27:
|
||||
+ Fix for s390x: Remove double fclose in bd_s390_dasd_online
|
||||
+ fs: Return BD_FS_ERROR_UNKNOWN_FS on mounting unknown
|
||||
filesystem
|
||||
+ overrides: Fix translating exceptions in ErrorProxy
|
||||
+ vdo_stats: Default to 100 % savings for invalid savings values
|
||||
+ lvm-dbus: Add support for changing compression and
|
||||
deduplication
|
||||
+ lvm:
|
||||
- Fix reading statistics for VDO pools with VDO 8
|
||||
- Do not set global config to and empty string
|
||||
- Do not include duplicate entries in bd_lvm_lvs output
|
||||
- Use correct integer type in for comparison
|
||||
+ crypto: Remove useless comparison in progress report in
|
||||
luks_format
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Jan 27 17:26:35 UTC 2022 - Bjørn Lie <bjorn.lie@gmail.com>
|
||||
|
||||
- Stop packaging deprecated libbd_vdo2 and libbd_vdo-devel, via
|
||||
passing without-vdo to configure. Also add Obsoletes for both
|
||||
packages aswell as the 2 alternative package names they provided.
|
||||
Standalone vdo modules are deprecated in udisks2 since version
|
||||
2.9.0, and we have stopped building them there, and udisks2 was
|
||||
the only known consumer of libblockdevs vdo support, stop
|
||||
building them here also.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Jan 18 13:06:33 UTC 2022 - Fabian Vogt <fvogt@suse.com>
|
||||
|
||||
- Remove unnecessary dependency of libbd_part2 on multipath-tools
|
||||
(bsc#1194771)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Nov 18 23:58:04 UTC 2021 - Luciano Santos <luc14n0@linuxmail.org>
|
||||
|
||||
- Fix lack of dependency on libblockdev-lvm needed by libblockdev
|
||||
package. The lvm-cache-stats binary needs the logical volume
|
||||
plugin to work (boo#1183948).
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Sun Nov 14 16:20:46 UTC 2021 - Luciano Santos <luc14n0@linuxmail.org>
|
||||
|
||||
- Update to version 2.26:
|
||||
+ Fixes:
|
||||
- Deprecated glib function call;
|
||||
- Build with LLVM/clang;
|
||||
- Many memory leaks;
|
||||
- Many tests.
|
||||
- Fix dbus.h being wrongly packaged in libbd_lvm-dbus-devl instead
|
||||
of libbd_utils-devel (boo#1189787).
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Mar 26 08:34:04 UTC 2021 - Dominique Leuenberger <dimstar@opensuse.org>
|
||||
|
||||
- Add -Wno-deprecated-declarations to cflags: dealing with
|
||||
deprecations is upstreams business and should not hinder
|
||||
downstream packages from building.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jan 20 08:14:59 UTC 2021 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- update to 2.25:
|
||||
* exec: Fix polling for stdout and stderr
|
||||
* exec: Use non-blocking read and process the buffer manually
|
||||
* exec: Clarify the BDUtilsProgExtract callback documentation
|
||||
* tests: Add bufferbloat exec tests
|
||||
* tests: Add null-byte exec tests
|
||||
* lvm: Fix bd_lvm_vdopooldata_* symbols
|
||||
* exec: Fix setting locale for util calls
|
||||
* fs: Do not report error when errors were fixed by e2fsck
|
||||
* README: Use CI status image for 2.x-branch on 2.x
|
||||
* fs: Fix compile error in ext_repair caused by cherry pick from
|
||||
master
|
||||
* Mark all GIR file constants as guint64
|
||||
* lvm: Set thin metadata limits to match limits LVM uses in
|
||||
lvcreate
|
||||
* lvm: Do not use thin_metadata_size to recommend thin metadata
|
||||
size
|
||||
* lvm: Use the UNUSED macro instead of __attribute__((unused))
|
||||
* Fix max size limit for LVM thinpool metadata
|
||||
* loop: Retry LOOP_SET_STATUS64 on EAGAIN
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Aug 20 22:11:53 UTC 2020 - Dirk Mueller <dmueller@suse.com>
|
||||
|
||||
- udpate to 2.24:
|
||||
* VDO plugin has been deprecated in this release (functionality
|
||||
replaced by LVM VDO)
|
||||
* support for creating and managing LVM VDO volumes added
|
||||
* support for unlocking of BitLocker-compatible format BITLK
|
||||
added
|
||||
* new functions for (un)freezing filesystems added
|
||||
* test suite can now be run against installed version of
|
||||
libblockdev
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Feb 4 09:35:28 UTC 2020 - Thomas Blume <thomas.blume@suse.com>
|
||||
|
||||
- fix files directive for s390 in specfile
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Sep 17 10:48:00 UTC 2019 - Heming Zhao <heming.zhao@suse.com>
|
||||
|
||||
- lvm2-clvm doesn't exist in lvm2-2.03, so change SPEC file
|
||||
libbd_lvm-dbus requires from lvm2-clvm to lvm2
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Jun 13 18:10:22 UTC 2019 - Bjørn Lie <bjorn.lie@gmail.com>
|
||||
|
||||
- Update to version 2.22:
|
||||
+ New minor release of the libblockdev library with multiple
|
||||
fixes.
|
||||
+ nvdimm: New function for getting list of supported sector sizes
|
||||
for namespaces fixes.
|
||||
+ Multiple memory leaks fixed.
|
||||
- Changes from version 2.21:
|
||||
+ crypto: Default key size for LUKS was changed to 512bit.
|
||||
+ tools:
|
||||
- New simple cli tools that use libblockdev.
|
||||
- First tool is lvm-cache-stats for displaying stats for LVM
|
||||
cache devices.
|
||||
- Use configure option --without-tools to disable building
|
||||
these.
|
||||
- Package new cli tool in main package, should possibly be moved
|
||||
into own sub-package in the future.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Feb 13 17:52:44 UTC 2019 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
||||
- Explain VDO. Fix grammar mishaps.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Jan 24 22:51:52 UTC 2019 - bjorn.lie@gmail.com
|
||||
|
||||
- Add pkgconfig(yaml-0.1) BuildRequires and pass with-vdo instead
|
||||
of without-vdo to configure, build vdo support.
|
||||
- Following the above, add new sub-packages libbd_vdo2 and
|
||||
libbd_vdo-devel, aswell as handle the new library in post(un).
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Jan 11 20:28:13 UTC 2019 - bjorn.lie@gmail.com
|
||||
|
||||
- Add pkgconfig(dbus-1) BuildRequires: Add missing BuildRequires,
|
||||
libblockdev needs dbus headerfiles during build, but configure
|
||||
does not check for it.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Nov 19 15:23:30 UTC 2018 - luc14n0@linuxmail.org
|
||||
|
||||
- Update to version 2.20:
|
||||
+ Fixes:
|
||||
- Fix parsing extra arguments for LVM methods calls in the LVM
|
||||
DBus plugin;
|
||||
- Multiple fixes for running tests on Debian testing.
|
||||
+ Development: Vagrantfile template was added for easy
|
||||
development machine setup.
|
||||
- Changes from version 2.19:
|
||||
+ Features:
|
||||
- vdo: new functions to get statistical data for existing VDO
|
||||
volumes (bd_vdo_get_stats);
|
||||
- crypto: support for passing extra arguments for key
|
||||
derivation function when creating LUKS2 format.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Jun 28 03:22:34 UTC 2018 - luc14n0@linuxmail.org
|
||||
|
||||
- Update to version 2.18:
|
||||
+ New plugin: vdo, support for creating and managing VDO volumes.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri May 4 02:53:53 UTC 2018 - luc14n0@linuxmail.org
|
||||
|
||||
- Update to version 2.17:
|
||||
+ New plugin: nvdimm, support for NVDIMM namespaces management;
|
||||
+ LUKS2 support for creating LUKS2 format including authenticated
|
||||
disk encryption. Multiple new functions for working with LUKS
|
||||
devices (suspend/resume, header backup, metadata size...);
|
||||
+ Extended support for opening TrueCrypt/VeraCrypt volumes.
|
||||
- Drop pkgconfig(nss) and libvolume_key-devel BuildRequires now
|
||||
that they are optional and pass without-escrow to configure:
|
||||
libvolume_key's code is ancient and nearly dead upstream.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Mar 28 03:13:10 UTC 2018 - luc14n0@linuxmail.org
|
||||
|
||||
- Resplit plugins to avoid pulling clusterlvm support by default
|
||||
into the dependency chain (bsc#1086447).
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Mar 5 23:28:39 UTC 2018 - luc14n0@linuxmail.org
|
||||
|
||||
- Move all plugins into the shared library subpackage and their
|
||||
respective development files into the devel one.
|
||||
- Add '-only' to LGPL License tag to comply with SPDX 3.0.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Feb 21 23:40:34 UTC 2018 - luc14n0@linuxmail.org
|
||||
|
||||
- Update to version 2.16:
|
||||
* Features:
|
||||
- LUKS 2 support for luks_open/close and
|
||||
luks_add/remove/change_key.
|
||||
- Progress report support for ext filesystem checks.
|
||||
- Changes from version 2.15:
|
||||
* Features:
|
||||
- The file system plugin is now split into multiple source
|
||||
files making it easier to add support for more file systems
|
||||
and technologies.
|
||||
* Fixes:
|
||||
- How GPT patition flags are set;
|
||||
- Check the btrfs module availability as part of checking the
|
||||
btrfs plugin's dependencies;
|
||||
- Memory leaks in bd_fs_vfat_get_info();
|
||||
- The file system plugin's dependency checking mechanisms.
|
||||
- Add libblockdev-fix-libkmod-include.patch as openSUSE doesn't use
|
||||
/usr/include/ but /usr/include/kmod to place libkmod.h.
|
||||
- Conditionalize the use of Python 2's bindings and turn it off
|
||||
defaulting Python 3.
|
||||
- Drop s390's plugin due to the lack of a file still not present
|
||||
in s390-tools package.
|
||||
- Drop BuildRoot tag since RPM already handles this itself.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Jan 18 23:26:58 UTC 2018 - jengelh@inai.de
|
||||
|
||||
- Remove excess Provides, BuildRequires and %ifs.
|
||||
- Fix %description line mismatch for s390x parts.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Nov 28 22:38:39 UTC 2017 - luc14n0@linuxmail.org
|
||||
|
||||
- Initial package, version 2.14:
|
||||
* Features:
|
||||
- Added function to get DM device subsystem.
|
||||
- Support for the NTFS file system.
|
||||
- pkg-config definitions improvements.
|
||||
* Fixes:
|
||||
- Fix BSSize memory leaks.
|
||||
- Fixes for issues discovered by coverity.
|
||||
- Support for the 'Legacy boot' GPT flag.
|
||||
|
756
libblockdev.spec
Normal file
756
libblockdev.spec
Normal file
@ -0,0 +1,756 @@
|
||||
#
|
||||
# spec file for package libblockdev
|
||||
#
|
||||
# Copyright (c) 2024 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
# upon. The license for this file, and modifications and additions to the
|
||||
# file, is the same license as for the pristine package itself (unless the
|
||||
# license for the pristine package is not an Open Source License, in which
|
||||
# case the license is the MIT License). An "Open Source License" is a
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
|
||||
### PLUGINS ###
|
||||
%bcond_without btrfs_plugin
|
||||
%bcond_without crypto_plugin
|
||||
%bcond_without dm_plugin
|
||||
%bcond_with escrow_plugin
|
||||
%bcond_without fs_plugin
|
||||
%bcond_without loop_plugin
|
||||
%bcond_without lvm_plugin
|
||||
%bcond_without lvmdbus_plugin
|
||||
%bcond_without mdraid_plugin
|
||||
%bcond_without mpath_plugin
|
||||
%bcond_with nvdimm_plugin
|
||||
%bcond_without nvme_plugin
|
||||
%bcond_without part_plugin
|
||||
%bcond_without swap_plugin
|
||||
###
|
||||
%bcond_without gi_bindings
|
||||
%bcond_without gtk_doc
|
||||
%bcond_without python_bindings
|
||||
%bcond_without utils
|
||||
%bcond_without tools
|
||||
|
||||
%define soversion 3
|
||||
|
||||
Name: libblockdev
|
||||
Version: 3.1.1
|
||||
Release: 0
|
||||
Summary: A library for low-level manipulation with block devices
|
||||
License: LGPL-2.1-only
|
||||
Group: Development/Libraries/C and C++
|
||||
URL: https://github.com/storaged-project/libblockdev
|
||||
Source0: %{url}/releases/download/%{version}-1/libblockdev-%{version}.tar.gz
|
||||
Source1: %{url}/raw/%{version}-1/NEWS.rst
|
||||
|
||||
###############################################################################
|
||||
# M A I N P A C K A G E
|
||||
###############################################################################
|
||||
|
||||
%if %{with gtk_doc}
|
||||
BuildRequires: gtk-doc
|
||||
%endif
|
||||
BuildRequires: pkgconfig
|
||||
BuildRequires: (gcc >= 11 or gcc11)
|
||||
BuildRequires: pkgconfig(ext2fs)
|
||||
BuildRequires: pkgconfig(fdisk)
|
||||
BuildRequires: pkgconfig(libnvme) >= 1.3
|
||||
# There is a s390x plugin that, until vtoc.h is provided by s390-tools*, can't
|
||||
# be added:
|
||||
# https://github.com/ibm-s390-linux/s390-tools/blob/master/include/lib/vtoc.h
|
||||
#BuildRequires: s390-tools-devel
|
||||
BuildRequires: pkgconfig(blkid) >= 2.23.0
|
||||
BuildRequires: pkgconfig(bytesize) >= 0.1
|
||||
BuildRequires: pkgconfig(dbus-1)
|
||||
BuildRequires: pkgconfig(devmapper) >= 1.02.93
|
||||
BuildRequires: pkgconfig(gio-2.0) >= 2.42.2
|
||||
BuildRequires: pkgconfig(glib-2.0) >= 2.42.2
|
||||
BuildRequires: pkgconfig(gobject-2.0) >= 2.42.2
|
||||
BuildRequires: pkgconfig(libcryptsetup) >= 2.3.0
|
||||
BuildRequires: pkgconfig(libkeyutils)
|
||||
BuildRequires: pkgconfig(libkmod) >= 19
|
||||
BuildRequires: pkgconfig(libparted) >= 3.1
|
||||
BuildRequires: pkgconfig(libudev) >= 216
|
||||
BuildRequires: pkgconfig(mount) >= 2.23.0
|
||||
BuildRequires: pkgconfig(yaml-0.1)
|
||||
Requires: libblockdev%{soversion} >= %{version}
|
||||
%if %{with tools}
|
||||
### lvm-cache-stats binary needs LVM's plugin to work (boo#1183948) ###
|
||||
Requires: libblockdev-lvm >= %{version}
|
||||
%endif
|
||||
|
||||
%description
|
||||
The LibBlockDev is a C library with GObject introspection support that can be
|
||||
used for doing low-level operations with block devices, like setting up LVM,
|
||||
BTRFS, LUKS or MD RAID. The library uses plugins (LVM, BTRFS,...) and serves as
|
||||
a wrapper around its plugins' functionality. All the plugins, however, can
|
||||
be used as standalone libraries. One of the core principles of LibBlockDev is
|
||||
that it is stateless from the storage configuration's perspective (e.g. it has
|
||||
no information about VGs when creating an LV).
|
||||
|
||||
%files
|
||||
%doc NEWS.rst
|
||||
%{_bindir}/lvm-cache-stats
|
||||
%{_bindir}/vfat-resize
|
||||
%dir %{_sysconfdir}/libblockdev
|
||||
%dir %{_sysconfdir}/libblockdev/%{soversion}
|
||||
%dir %{_sysconfdir}/libblockdev/%{soversion}/conf.d
|
||||
%config %{_sysconfdir}/libblockdev/%{soversion}/conf.d/10-lvm-dbus.cfg
|
||||
%config %{_sysconfdir}/libblockdev/%{soversion}/conf.d/00-default.cfg
|
||||
|
||||
###############################################################################
|
||||
# D E V E L F I L E S
|
||||
###############################################################################
|
||||
|
||||
%package devel
|
||||
Summary: Development files for the LibBlockDev library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: glib2-devel
|
||||
Requires: libblockdev%{soversion} >= %{version}
|
||||
|
||||
%description devel
|
||||
This package provides header files, pkg-config modules and API documentation
|
||||
needed for development with the LibBlockDev library.
|
||||
|
||||
%files devel
|
||||
%doc %{_datadir}/gtk-doc/html/libblockdev
|
||||
%{_libdir}/libblockdev.so
|
||||
%{_libdir}/pkgconfig/blockdev.pc
|
||||
%{_datadir}/gir-1.0/BlockDev-%{soversion}.0.gir
|
||||
%dir %{_includedir}/blockdev
|
||||
%{_includedir}/blockdev/blockdev.h
|
||||
%{_includedir}/blockdev/plugins.h
|
||||
%{_includedir}/blockdev/logging.h
|
||||
%ifarch s390x
|
||||
%{_libdir}/libbd_s390.so
|
||||
%{_includedir}/blockdev/s390.h
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# S H A R E D L I B R A R Y
|
||||
###############################################################################
|
||||
|
||||
%package -n libblockdev%{soversion}
|
||||
Summary: A library for low-level manipulation with block devices
|
||||
Group: System/Libraries
|
||||
|
||||
%description -n libblockdev%{soversion}
|
||||
The LibBlockDev is a C library with GObject introspection support that can be
|
||||
used for doing low-level operations with block devices like setting up LVM,
|
||||
BTRFS, LUKS or MD RAID. The library uses plugins (LVM, BTRFS,...) and serves as
|
||||
a wrapper around its plugins' functionality. All the plugins, however, can
|
||||
be used as standalone libraries. One of the core principles of LibBlockDev is
|
||||
that it is stateless from the storage configuration's perspective (e.g. it has
|
||||
no information about VGs when creating an LV).
|
||||
|
||||
%ldconfig_scriptlets -n libblockdev%{soversion}
|
||||
|
||||
%files -n libblockdev%{soversion}
|
||||
%license LICENSE
|
||||
%{_libdir}/libblockdev.so.%{soversion}
|
||||
%{_libdir}/libblockdev.so.%{soversion}.?.?
|
||||
%ifarch s390x
|
||||
%{_libdir}/libbd_s390.so.%{soversion}
|
||||
%{_libdir}/libbd_s390.so.%{soversion}.?.?
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# G O B J E C T I N T R O S P E C T I O N B I N D I N G S
|
||||
###############################################################################
|
||||
|
||||
%if %{with gi_bindings}
|
||||
%package -n typelib-1_0-BlockDev-%{soversion}_0
|
||||
Summary: GI bindings for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
BuildRequires: pkgconfig(gobject-introspection-1.0) >= 1.3.0
|
||||
|
||||
%description -n typelib-1_0-BlockDev-%{soversion}_0
|
||||
This package provides the GObject Introspection bindings for LibBlockDev, which
|
||||
provides low-level manipulation of block devices.
|
||||
|
||||
%files -n typelib-1_0-BlockDev-%{soversion}_0
|
||||
%{_libdir}/girepository-1.0/BlockDev-%{soversion}.0.typelib
|
||||
|
||||
###############################################################################
|
||||
# P Y T H O N 3 B I N D I N G S
|
||||
###############################################################################
|
||||
|
||||
%if %{with python_bindings}
|
||||
%package -n python3-%{name}
|
||||
Summary: Python 3 GI bindings for the LibBlockDev library
|
||||
Group: Development/Libraries/Python
|
||||
BuildRequires: python3-devel
|
||||
BuildRequires: python3-gobject
|
||||
|
||||
Requires: python3-bytesize
|
||||
Requires: python3-gobject
|
||||
|
||||
%description -n python3-%{name}
|
||||
This package contains enhancements to the GObject Introspection bindings for
|
||||
LibBlockDev, in Python 3.
|
||||
|
||||
%files -n python3-%{name}
|
||||
%{python3_sitearch}/gi/overrides/BlockDev.py
|
||||
%endif
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# B T R F S P L U G I N
|
||||
###############################################################################
|
||||
|
||||
%if %{with btrfs_plugin}
|
||||
%package -n libbd_btrfs%{soversion}
|
||||
Summary: The Btrfs plugin for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Provides: libblockdev-btrfs = %{version}
|
||||
|
||||
%description -n libbd_btrfs%{soversion}
|
||||
This LibBlockDev library plugin (and, at the same time, a standalone library)
|
||||
provides Btrfs-related functionality.
|
||||
|
||||
%files -n libbd_btrfs%{soversion} -f btrfs-plugin.filelist
|
||||
|
||||
%package -n libbd_btrfs-devel
|
||||
Summary: Development files for the libbd_btrfs plugin/library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_btrfs%{soversion} >= %{version}
|
||||
Requires: libbd_utils-devel >= %{version}
|
||||
Provides: libblockdev-btrfs-devel = %{version}
|
||||
|
||||
%description -n libbd_btrfs-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_btrfs plugin/library.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_btrfs%{soversion}
|
||||
|
||||
%files -n libbd_btrfs-devel -f btrfs-plugin-devel.filelist
|
||||
%dir %{_includedir}/blockdev
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# C R Y P T O P L U G I N
|
||||
###############################################################################
|
||||
|
||||
%if %{with crypto_plugin}
|
||||
%package -n libbd_crypto%{soversion}
|
||||
Summary: The Crypto plugin for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Provides: libblockdev-crypto = %{version}
|
||||
|
||||
%description -n libbd_crypto%{soversion}
|
||||
This LibBlockDev library plugin (and, at the same time, a standalone library)
|
||||
provides functionality related to LUKS-style encrypted devices.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_crypto%{soversion}
|
||||
|
||||
%files -n libbd_crypto%{soversion} -f crypto-plugin.filelist
|
||||
|
||||
%package -n libbd_crypto-devel
|
||||
Summary: Development files for the libbd_crypto plugin/library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_crypto%{soversion} >= %{version}
|
||||
Provides: libblockdev-crypto-devel = %{version}
|
||||
|
||||
%description -n libbd_crypto-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_crypto plugin/library..
|
||||
|
||||
%files -n libbd_crypto-devel -f crypto-plugin-devel.filelist
|
||||
%dir %{_includedir}/blockdev
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# D E V I C E M A P P E R P L U G I N
|
||||
###############################################################################
|
||||
|
||||
%if %{with dm_plugin}
|
||||
%package -n libbd_dm%{soversion}
|
||||
Summary: The Device Mapper plugin for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Requires: device-mapper
|
||||
Requires: dmraid
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Provides: libblockdev-dm = %{version}
|
||||
|
||||
%description -n libbd_dm%{soversion}
|
||||
This LibBlockDev library plugin (and, at the same time, a standalone library)
|
||||
provides functionality related to Device Mapper.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_dm%{soversion}
|
||||
|
||||
%files -n libbd_dm%{soversion} -f dm-plugin.filelist
|
||||
|
||||
%package -n libbd_dm-devel
|
||||
Summary: Development files for the libbd_dm plugin/library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: device-mapper-devel
|
||||
Requires: dmraid-devel
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_dm%{soversion} >= %{version}
|
||||
Requires: libbd_utils-devel
|
||||
Requires: systemd-devel
|
||||
Provides: libblockdev-dm-devel = %{version}
|
||||
|
||||
%description -n libbd_dm-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_dm plugin/library..
|
||||
|
||||
%files -n libbd_dm-devel -f dm-plugin-devel.filelist
|
||||
%dir %{_includedir}/blockdev
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# F I L E S Y S T E M P L U G I N
|
||||
###############################################################################
|
||||
|
||||
%if %{with fs_plugin}
|
||||
%package -n libbd_fs%{soversion}
|
||||
Summary: The FS plugin for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Requires: device-mapper
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Provides: libblockdev-fs = %{version}
|
||||
|
||||
%description -n libbd_fs%{soversion}
|
||||
This LibBlockDev library plugin (and, at the same time, a standalone library)
|
||||
provides functionality related to operations with file systems.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_fs%{soversion}
|
||||
|
||||
%files -n libbd_fs%{soversion} -f fs-plugin.filelist
|
||||
|
||||
%package -n libbd_fs-devel
|
||||
Summary: Development files for the libbd_fs plugin/library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: dosfstools
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_fs%{soversion} >= %{version}
|
||||
Requires: libbd_utils-devel
|
||||
Requires: xfsprogs
|
||||
Provides: libblockdev-fs-devel = %{version}
|
||||
|
||||
%description -n libbd_fs-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_fs plugin/library..
|
||||
|
||||
%files -n libbd_fs-devel -f fs-plugin-devel.filelist
|
||||
%dir %{_includedir}/blockdev
|
||||
%dir %{_includedir}/blockdev/fs
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# L O O P P L U G I N
|
||||
###############################################################################
|
||||
|
||||
%if %{with loop_plugin}
|
||||
%package -n libbd_loop%{soversion}
|
||||
Summary: The loop plugin for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Provides: libblockdev-loop = %{version}
|
||||
|
||||
%description -n libbd_loop%{soversion}
|
||||
This LibBlockDev library plugin (and, at the same time, a standalone library)
|
||||
provides functionality related to loop devices.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_loop%{soversion}
|
||||
|
||||
%files -n libbd_loop%{soversion} -f loop-plugin.filelist
|
||||
|
||||
%package -n libbd_loop-devel
|
||||
Summary: Development files for the libblockdev-loop plugin/library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_loop%{soversion} = %{version}
|
||||
Requires: libbd_utils-devel >= %{version}
|
||||
Provides: libblockdev-loop-devel = %{version}
|
||||
|
||||
%description -n libbd_loop-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_loop plugin/library.
|
||||
|
||||
%files -n libbd_loop-devel -f loop-plugin-devel.filelist
|
||||
%dir %{_includedir}/blockdev
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# L V M P L U G I N
|
||||
###############################################################################
|
||||
|
||||
%if %{with lvm_plugin}
|
||||
%package -n libbd_lvm%{soversion}
|
||||
Summary: The LVM plugin for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Requires: lvm2
|
||||
# For thin_metadata_size.
|
||||
Requires: thin-provisioning-tools
|
||||
Provides: libblockdev-lvm = %{version}
|
||||
|
||||
%description -n libbd_lvm%{soversion}
|
||||
This LibBlockDev library plugin (and, at the same time, a standalone library)
|
||||
provides LVM-related functionality.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_lvm%{soversion}
|
||||
|
||||
%files -n libbd_lvm%{soversion} -f lvm-plugin.filelist
|
||||
|
||||
%package -n libbd_lvm-devel
|
||||
Summary: Development files for the libblockdev-lvm plugin/library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_lvm%{soversion} = %{version}
|
||||
Requires: libbd_utils-devel >= %{version}
|
||||
Provides: libblockdev-lvm-devel = %{version}
|
||||
|
||||
%description -n libbd_lvm-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_lvm plugin/library.
|
||||
|
||||
%files -n libbd_lvm-devel -f lvm-plugin-devel.filelist
|
||||
%dir %{_includedir}/blockdev
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# L V M D B U S P L U G I N
|
||||
###############################################################################
|
||||
|
||||
%if %{with lvmdbus_plugin}
|
||||
%package -n libbd_lvm-dbus%{soversion}
|
||||
Summary: The LVM plugin for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Requires: lvm2
|
||||
# For thin_metadata_size.
|
||||
Requires: thin-provisioning-tools
|
||||
Provides: libblockdev-lvm-dbus = %{version}
|
||||
|
||||
%description -n libbd_lvm-dbus%{soversion}
|
||||
This LibBlockDev library plugin (and, at the same time, a standalone library)
|
||||
provides LVM-related functionality utilizing the LVM D-Bus API.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_lvm-dbus%{soversion}
|
||||
|
||||
%files -n libbd_lvm-dbus%{soversion} -f lvm-dbus-plugin.filelist
|
||||
|
||||
%package -n libbd_lvm-dbus-devel
|
||||
Summary: Development files for the libblockdev-lvm-dbus plugin/library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_lvm-dbus%{soversion} = %{version}
|
||||
Requires: libbd_lvm-devel >= %{version}
|
||||
Requires: libbd_utils-devel >= %{version}
|
||||
Provides: libblockdev-lvm-dbus-devel = %{version}
|
||||
|
||||
%description -n libbd_lvm-dbus-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_lvm-dbus plugin/library.
|
||||
|
||||
%files -n libbd_lvm-dbus-devel -f lvm-dbus-plugin-devel.filelist
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# M D R A I D P L U G I N
|
||||
###############################################################################
|
||||
|
||||
%if %{with mdraid_plugin}
|
||||
%package -n libbd_mdraid%{soversion}
|
||||
Summary: The MD RAID plugin for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Requires: mdadm
|
||||
Provides: libblockdev-mdraid = %{version}
|
||||
|
||||
%description -n libbd_mdraid%{soversion}
|
||||
This LibBlockDev library plugin (and, at the same time, a standalone library)
|
||||
provides functionality related to MD RAID.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_mdraid%{soversion}
|
||||
|
||||
%files -n libbd_mdraid%{soversion} -f mdraid-plugin.filelist
|
||||
|
||||
%package -n libbd_mdraid-devel
|
||||
Summary: Development files for the libblockdev-mdraid plugin/library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_mdraid%{soversion} = %{version}
|
||||
Requires: libbd_utils-devel >= %{version}
|
||||
Provides: libblockdev-mdraid-devel = %{version}
|
||||
|
||||
%description -n libbd_mdraid-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_mdraid plugin/library.
|
||||
|
||||
%files -n libbd_mdraid-devel -f mdraid-plugin-devel.filelist
|
||||
%dir %{_includedir}/blockdev
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# M U L T I P A T H P L U G I N
|
||||
###############################################################################
|
||||
|
||||
%if %{with mpath_plugin}
|
||||
%package -n libbd_mpath%{soversion}
|
||||
Summary: The multipath plugin for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Requires: multipath-tools
|
||||
Provides: libblockdev-mpath = %{version}
|
||||
|
||||
%description -n libbd_mpath%{soversion}
|
||||
This LibBlockDev library plugin (and, at the same time, a standalone library)
|
||||
provides functionality related to multipath devices.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_mpath%{soversion}
|
||||
|
||||
%files -n libbd_mpath%{soversion} -f mpath-plugin.filelist
|
||||
|
||||
%package -n libbd_mpath-devel
|
||||
Summary: Development files for the libblockdev-mpath plugin/library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_mpath%{soversion} = %{version}
|
||||
Requires: libbd_utils-devel >= %{version}
|
||||
Provides: libblockdev-mpath-devel = %{version}
|
||||
|
||||
%description -n libbd_mpath-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_mpath plugin/library.
|
||||
|
||||
%files -n libbd_mpath-devel -f mpath-plugin-devel.filelist
|
||||
%dir %{_includedir}/blockdev
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# N V M E P L U G I N
|
||||
###############################################################################
|
||||
|
||||
%if %{with nvme_plugin}
|
||||
%package -n libbd_nvme%{soversion}
|
||||
Summary: The NVMe plugin for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Provides: libblockdev-nvme = %{version}
|
||||
|
||||
%description -n libbd_nvme%{soversion}
|
||||
This LibBlockDev library plugin (and, at the same time, a standalone library)
|
||||
provides NVMe-related functionality.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_nvme%{soversion}
|
||||
|
||||
%files -n libbd_nvme%{soversion} -f nvme-plugin.filelist
|
||||
|
||||
%package -n libbd_nvme-devel
|
||||
Summary: Development files for the libblockdev-nvme plugin/library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_nvme%{soversion} >= %{version}
|
||||
Requires: libbd_utils-devel
|
||||
Provides: libblockdev-nvme-devel = %{version}
|
||||
|
||||
%description -n libbd_nvme-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_nvme plugin/library.
|
||||
|
||||
%files -n libbd_nvme-devel -f nvme-plugin-devel.filelist
|
||||
%dir %{_includedir}/blockdev
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# P A R T I T I O N I N G P L U G I N
|
||||
###############################################################################
|
||||
|
||||
%if %{with part_plugin}
|
||||
%package -n libbd_part%{soversion}
|
||||
Summary: The partitioning plugin for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Requires: gptfdisk
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Requires: util-linux
|
||||
Provides: libblockdev-part = %{version}
|
||||
|
||||
%description -n libbd_part%{soversion}
|
||||
This LibBlockDev library plugin (and, at the same time, a standalone library)
|
||||
provides functionality related to partitioning.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_part%{soversion}
|
||||
|
||||
%files -n libbd_part%{soversion} -f part-plugin.filelist
|
||||
|
||||
%package -n libbd_part-devel
|
||||
Summary: Development files for the libblockdev-part plugin/library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_part%{soversion} = %{version}
|
||||
Requires: libbd_utils-devel >= %{version}
|
||||
Provides: libblockdev-part-devel = %{version}
|
||||
|
||||
%description -n libbd_part-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_part plugin/library.
|
||||
|
||||
%files -n libbd_part-devel -f part-plugin-devel.filelist
|
||||
%dir %{_includedir}/blockdev
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# S W A P P L U G I N
|
||||
###############################################################################
|
||||
|
||||
%if %{with swap_plugin}
|
||||
%package -n libbd_swap%{soversion}
|
||||
Summary: The swap plugin for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Requires: util-linux
|
||||
Provides: libblockdev-swap = %{version}
|
||||
|
||||
%description -n libbd_swap%{soversion}
|
||||
This LibBlockDev library plugin (and, at the same time, a standalone library)
|
||||
provides functionality related to swap devices.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_swap%{soversion}
|
||||
|
||||
%files -n libbd_swap%{soversion} -f swap-plugin.filelist
|
||||
|
||||
%package -n libbd_swap-devel
|
||||
Summary: Development files for the libblockdev-swap plugin/library
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_swap%{soversion} = %{version}
|
||||
Requires: libbd_utils-devel >= %{version}
|
||||
Provides: libblockdev-swap-devel = %{version}
|
||||
|
||||
%description -n libbd_swap-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_swap plugin/library.
|
||||
|
||||
%files -n libbd_swap-devel -f swap-plugin-devel.filelist
|
||||
%dir %{_includedir}/blockdev
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
# U T I L I T Y L I B R A R Y
|
||||
###############################################################################
|
||||
|
||||
%if %{with utils}
|
||||
%package -n libbd_utils%{soversion}
|
||||
Summary: Utility functions library for the LibBlockDev library
|
||||
Group: System/Libraries
|
||||
Provides: libblockdev-utils = %{version}
|
||||
|
||||
%description -n libbd_utils%{soversion}
|
||||
This library provides utility functions used by the LibBlockDev library
|
||||
and its plugins.
|
||||
|
||||
%ldconfig_scriptlets -n libbd_utils%{soversion}
|
||||
|
||||
%files -n libbd_utils%{soversion} -f utils-plugin.filelist
|
||||
|
||||
%package -n libbd_utils-devel
|
||||
Summary: Development files for libblockdev-utils
|
||||
Group: Development/Libraries/C and C++
|
||||
Requires: glib2-devel
|
||||
Requires: libbd_utils%{soversion} >= %{version}
|
||||
Provides: libblockdev-utils-devel = %{version}
|
||||
|
||||
%description -n libbd_utils-devel
|
||||
This package contains header files and pkg-config files needed for development
|
||||
with the libbd_utils library.
|
||||
|
||||
%files -n libbd_utils-devel -f utils-plugin-devel.filelist
|
||||
%{_libdir}/pkgconfig/blockdev-utils.pc
|
||||
%dir %{_includedir}/blockdev
|
||||
%{_includedir}/blockdev/{dbus,dev_utils,exec,extra_arg,module,sizes}.h
|
||||
%endif
|
||||
|
||||
###############################################################################
|
||||
|
||||
%prep
|
||||
%autosetup -p1
|
||||
# Place NEWS.rst in the source tree for %%doc'ing it later.
|
||||
install -m 644 -t . %{SOURCE1}
|
||||
|
||||
%build
|
||||
# A bit of auto magic for exporting the CC variable when we don't have a
|
||||
# /usr/bin/cc symlink to a gcc >= 11
|
||||
if [ ! -f %{_bindir}/cc ]; then
|
||||
%define __gcc %(ls -1 %{_bindir}/gcc-[0-9][0-9] | tail -1)
|
||||
export CC=%{__gcc}
|
||||
fi
|
||||
%configure \
|
||||
--disable-static \
|
||||
--with%{!?with_btrfs_plugin:out}-btrfs \
|
||||
--with%{!?with_crypto_plugin:out}-crypto \
|
||||
--with%{!?with_dm_plugin:out}-dm \
|
||||
--with%{!?with_escrow_plugin:out}-escrow \
|
||||
--with%{!?with_fs_plugin:out}-fs \
|
||||
--with%{!?with_gtk_doc:out}-gtk-doc \
|
||||
--%{?with_gi_bindings:en}%{!?with_gi_bindings:dis}able-introspection \
|
||||
--with%{!?with_tools:out}-tools \
|
||||
--with%{!?with_nvdimm_plugin:out}-nvdimm \
|
||||
--with%{!?with_nvme_plugin:out}-nvme \
|
||||
--with%{!?with_loop_plugin:out}-loop \
|
||||
--with%{!?with_lvm_plugin:out}-lvm \
|
||||
--with%{!?with_lvmdbus_plugin:out}-lvm-dbus \
|
||||
--with%{!?with_mdraid_plugin:out}-mdraid \
|
||||
--with%{!?with_mpath_plugin:out}-mpath \
|
||||
--with%{!?with_part_plugin:out}-part \
|
||||
--with%{!?with_swap_plugin:out}-swap \
|
||||
;
|
||||
|
||||
%make_build
|
||||
|
||||
%install
|
||||
%make_install
|
||||
find %{buildroot} -name "*.la" -print -type f -delete
|
||||
|
||||
%{?with_btrfs_plugin: %global plugins %{?plugins} btrfs}
|
||||
%{?with_crypto_plugin: %global plugins %{?plugins} crypto}
|
||||
%{?with_dm_plugin: %global plugins %{?plugins} dm}
|
||||
%{?with_escrow_plugin: %global plugins %{?plugins} escrow}
|
||||
%{?with_fs_plugin: %global plugins %{?plugins} fs}
|
||||
%{?with_nvdimm_plugin: %global plugins %{?plugins} nvdimm}
|
||||
%{?with_nvme_plugin: %global plugins %{?plugins} nvme}
|
||||
%{?with_loop_plugin: %global plugins %{?plugins} loop}
|
||||
%{?with_lvm_plugin: %global plugins %{?plugins} lvm}
|
||||
%{?with_lvmdbus_plugin: %global plugins %{?plugins} lvm-dbus}
|
||||
%{?with_mdraid_plugin: %global plugins %{?plugins} mdraid}
|
||||
%{?with_mpath_plugin: %global plugins %{?plugins} mpath}
|
||||
%{?with_part_plugin: %global plugins %{?plugins} part}
|
||||
%{?with_swap_plugin: %global plugins %{?plugins} swap}
|
||||
%{?with_utils: %global plugins %{?plugins} utils}
|
||||
|
||||
echo %{?plugins}
|
||||
|
||||
for plugin in %{?plugins}; do
|
||||
ls -1 %{buildroot}%{_libdir}/libbd_${plugin}.so.%{soversion}* \
|
||||
> ${plugin}-plugin.filelist
|
||||
ls -1 %{buildroot}%{_libdir}/libbd_${plugin}.so \
|
||||
> ${plugin}-plugin-devel.filelist
|
||||
|
||||
test "${plugin}" = lvm-dbus && continue
|
||||
|
||||
ls -1 %{buildroot}%{_includedir}/blockdev/${plugin}.h \
|
||||
>> ${plugin}-plugin-devel.filelist
|
||||
|
||||
if [ "${plugin}" = fs ]; then
|
||||
ls -1 %{buildroot}%{_includedir}/blockdev/${plugin}/* \
|
||||
>> ${plugin}-plugin-devel.filelist
|
||||
fi
|
||||
done
|
||||
|
||||
sed -i -r 's,%{buildroot}(.*),\1,' ./*.filelist
|
||||
|
||||
%changelog
|
Loading…
Reference in New Issue
Block a user