- Remove patches which are all upstream.
- Update io-uring dependency minimum to 0.5.10.
- Don't add --offline to cargo-build.sh
+++ /dev/null
-From c2195221fcec63ee8b6350379fab03b82210e9e3 Mon Sep 17 00:00:00 2001
-From: Stefan Hajnoczi <stefanha@redhat.com>
-Date: Tue, 22 Nov 2022 14:03:17 -0500
-Subject: [PATCH] cargo-build.sh: support optimization=plain
-
-meson 0.64.0 added optimization=plain. It means that no optimization
-flags are explicitly passed to the compiler. This is useful in
-situations where the environment wants to control compiler flags (e.g.
-nix, rpm, etc), typically via CFLAGS, CXXFLAGS, etc.
-
-Make sure to handle optimization=plain so that cargo-build.sh doesn't
-exit early.
-
-Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
----
- src/cargo-build.sh | 5 +++++
- 1 file changed, 5 insertions(+)
-
-diff --git a/src/cargo-build.sh b/src/cargo-build.sh
-index 2ad5463..9879d44 100755
---- a/src/cargo-build.sh
-+++ b/src/cargo-build.sh
-@@ -16,6 +16,11 @@ case "${meson_debug}" in
- esac
-
- case "${meson_optimization}" in
-+ plain)
-+ # A release build without explicit optimization flags
-+ profile=release
-+ args+=( --release )
-+ ;;
- 0)
- profile=debug
- rustflags+=( -C opt-level=0 )
---
-GitLab
-
+++ /dev/null
-From 44652d6c7fe9c61ac417db9dd05ec27e3c6e20f9 Mon Sep 17 00:00:00 2001
-From: Stefan Hajnoczi <stefanha@redhat.com>
-Date: Mon, 12 Dec 2022 14:58:07 -0500
-Subject: [PATCH] cargo-build.sh: inherit $RUSTFLAGS
-
-When a packaging system like rpm invokes "meson build" in meson 0.64.0
-or later, it can use buildtype "plain" to control compiler flags itself
-via the CFLAGS, CXXFLAGS, and, in our case, RUSTFLAGS environment
-variables.
-
-Don't clobber RUSTFLAGS in src/cargo-build.sh. Simply append our own
-options to RUSTFLAGS. That way src/cargo-build.sh still controls
-compiler options when necessary, but inherits them from the build
-environment (especially in the buildtype "plain" case).
-
-See https://bugzilla.redhat.com/show_bug.cgi?id=2124697#c67 for Fedora
-packaging discussion around this topic.
-
-Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
----
- src/cargo-build.sh | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/cargo-build.sh b/src/cargo-build.sh
-index 9879d44..d4785ce 100755
---- a/src/cargo-build.sh
-+++ b/src/cargo-build.sh
-@@ -50,10 +50,10 @@ then
- fi
-
- if [[ "${profile}" == "debug" ]] && command -v cargo-clippy >/dev/null; then
-- ( set -x && RUSTFLAGS="${rustflags[*]}" cargo clippy "${args[@]}" --color always \
-+ ( set -x && RUSTFLAGS="$RUSTFLAGS ${rustflags[*]}" cargo clippy "${args[@]}" --color always \
- --locked --all-features --all-targets --workspace -- --deny warnings )
- fi
-
--( set -x && RUSTFLAGS="${rustflags[*]}" cargo build "${args[@]}" --color always \
-+( set -x && RUSTFLAGS="$RUSTFLAGS ${rustflags[*]}" cargo build "${args[@]}" --color always \
- --locked )
- cp "src/target/${profile}/libblkio.so" "src/libblkio.so.${version}"
---
-GitLab
-
-Version: 1.1.1
+Version: 1.2.1
%global forgeurl https://gitlab.com/libblkio/libblkio
%global tag v%{version}
%forgemeta
Summary: Block device I/O library
Name: libblkio
-Release: 10%{?dist}
+Release: 11%{?dist}
URL: %{forgeurl}
Source0: %{forgesource}
License: Apache-2.0 OR MIT
-# Fix for meson 0.64
-# (https://gitlab.com/libblkio/libblkio/-/merge_requests/149)
-Patch: 149.patch
-
-# Upstream commit to use $RUSTFLAGS
-# https://bugzilla.redhat.com/show_bug.cgi?id=2124697#c70
-Patch: 44652d6c7fe9c61ac417db9dd05ec27e3c6e20f9.patch
-
# Basic build requirements.
BuildRequires: gcc, gcc-c++
BuildRequires: make
BuildRequires: (crate(cfg-if/default) >= 1.0.0 with crate(cfg-if/default) < 2.0.0~)
BuildRequires: (crate(concat-idents/default) >= 1.0.0 with crate(concat-idents/default) < 2.0.0~)
BuildRequires: (crate(const-cstr/default) >= 0.3.0 with crate(const-cstr/default) < 0.4.0~)
-BuildRequires: (crate(io-uring/default) >= 0.5.8 with crate(io-uring/default) < 0.6.0~)
+BuildRequires: (crate(io-uring/default) >= 0.5.10 with crate(io-uring/default) < 0.6.0~)
BuildRequires: (crate(lazy_static/default) >= 1.0.0 with crate(lazy_static/default) < 2.0.0~)
BuildRequires: (crate(libc/default) >= 0.2.134 with crate(libc/default) < 0.3.0~)
BuildRequires: (crate(memmap2/default) >= 0.5.7 with crate(memmap2/default) < 0.6.0~)
%forgeautosetup -p1
%cargo_prep
-sed -e 's/--locked/--offline/' -i src/cargo-build.sh
+sed -e 's/--locked//' -i src/cargo-build.sh
+
%build
export RUSTFLAGS="%build_rustflags"
%changelog
-* Tue Dec 13 2022 Richard W.M. Jones <rjones@redhat.com> - 1.1.1-10
+* Wed Dec 21 2022 Richard W.M. Jones <rjones@redhat.com> - 1.2.1-11
- Initial package