commit
6dd1f661fc
@ -0,0 +1 @@
|
|||||||
|
SOURCES/lz4-sys-1.11.1+lz4-1.10.0.crate
|
@ -0,0 +1 @@
|
|||||||
|
029e8002a9c308f54a1c5a68b32bab2d59f575ad SOURCES/lz4-sys-1.11.1+lz4-1.10.0.crate
|
@ -0,0 +1,31 @@
|
|||||||
|
diff --git a/build.rs b/build.rs
|
||||||
|
index 025b708..885b631 100644
|
||||||
|
--- a/build.rs
|
||||||
|
+++ b/build.rs
|
||||||
|
@@ -15,6 +15,18 @@ fn main() {
|
||||||
|
}
|
||||||
|
|
||||||
|
fn run() -> Result<(), Box<dyn Error>> {
|
||||||
|
+ let target = get_from_env("TARGET")?;
|
||||||
|
+
|
||||||
|
+ if !target.contains("windows")
|
||||||
|
+ && pkg_config::Config::new()
|
||||||
|
+ .print_system_libs(false)
|
||||||
|
+ .cargo_metadata(true)
|
||||||
|
+ .probe("liblz4")
|
||||||
|
+ .is_ok()
|
||||||
|
+ {
|
||||||
|
+ return Ok(());
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
let mut compiler = cc::Build::new();
|
||||||
|
compiler
|
||||||
|
.file("liblz4/lib/lz4.c")
|
||||||
|
@@ -24,7 +36,6 @@ fn run() -> Result<(), Box<dyn Error>> {
|
||||||
|
// We always compile the C with optimization, because otherwise it is 20x slower.
|
||||||
|
.opt_level(3);
|
||||||
|
|
||||||
|
- let target = get_from_env("TARGET")?;
|
||||||
|
if target.contains("windows") {
|
||||||
|
if target == "i686-pc-windows-gnu" {
|
||||||
|
// Disable auto-vectorization for 32-bit MinGW target.
|
@ -0,0 +1,16 @@
|
|||||||
|
--- lz4-sys-1.11.1+lz4-1.10.0/Cargo.toml 1970-01-01T00:00:01+00:00
|
||||||
|
+++ lz4-sys-1.11.1+lz4-1.10.0/Cargo.toml 2024-09-26T12:26:40.364633+00:00
|
||||||
|
@@ -11,7 +11,7 @@
|
||||||
|
|
||||||
|
[package]
|
||||||
|
name = "lz4-sys"
|
||||||
|
-version = "1.11.1+lz4-1.10.0"
|
||||||
|
+version = "1.11.1"
|
||||||
|
authors = [
|
||||||
|
"Jens Heyens <jens.heyens@ewetel.net>",
|
||||||
|
"Artem V. Navrotskiy <bozaro@buzzsoft.ru>",
|
||||||
|
@@ -28,3 +28,4 @@
|
||||||
|
|
||||||
|
[build-dependencies.cc]
|
||||||
|
version = "1.1"
|
||||||
|
+
|
@ -0,0 +1,8 @@
|
|||||||
|
--- lz4-sys-1.11.1+lz4-1.10.0/Cargo.toml 1970-01-01T00:00:01+00:00
|
||||||
|
+++ lz4-sys-1.11.1+lz4-1.10.0/Cargo.toml 2024-09-26T12:27:02.880946+00:00
|
||||||
|
@@ -29,3 +29,5 @@
|
||||||
|
[build-dependencies.cc]
|
||||||
|
version = "1.1"
|
||||||
|
|
||||||
|
+[build-dependencies.pkg-config]
|
||||||
|
+version = "0.3.9"
|
@ -0,0 +1,128 @@
|
|||||||
|
## START: Set by rpmautospec
|
||||||
|
## (rpmautospec version 0.7.2)
|
||||||
|
## RPMAUTOSPEC: autorelease, autochangelog
|
||||||
|
%define autorelease(e:s:pb:n) %{?-p:0.}%{lua:
|
||||||
|
release_number = 2;
|
||||||
|
base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}"));
|
||||||
|
print(release_number + base_release_number - 1);
|
||||||
|
}%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}}
|
||||||
|
## END: Set by rpmautospec
|
||||||
|
|
||||||
|
# Generated by rust2rpm 26
|
||||||
|
%bcond_without check
|
||||||
|
%global debug_package %{nil}
|
||||||
|
|
||||||
|
%global crate lz4-sys
|
||||||
|
%global upstream_version 1.11.1+lz4-1.10.0
|
||||||
|
|
||||||
|
Name: rust-lz4-sys
|
||||||
|
Version: 1.11.1
|
||||||
|
Release: %autorelease
|
||||||
|
Summary: Rust LZ4 sys package
|
||||||
|
|
||||||
|
License: MIT
|
||||||
|
URL: https://crates.io/crates/lz4-sys
|
||||||
|
Source: %{crates_source %{crate} %{upstream_version}}
|
||||||
|
# Automatically generated patch to strip dependencies and normalize metadata
|
||||||
|
Patch: lz4-sys-fix-metadata-auto.diff
|
||||||
|
# Manually created patch for downstream crate metadata changes
|
||||||
|
# * Depend on pkg-config unconditionally
|
||||||
|
Patch: lz4-sys-fix-metadata.diff
|
||||||
|
# * Link system liblz4 when available
|
||||||
|
# * https://github.com/10XGenomics/lz4-rs/pull/39
|
||||||
|
# * Squashed (to omit reverted changes to the top-level Cargo.toml) and adjusted
|
||||||
|
# to apply to the released crate; remaining changes to Cargo.toml are applied
|
||||||
|
# with “rust2rpm -p” and appear in lz4-sys-fix-metadata.diff.
|
||||||
|
Patch10: lz4-sys-1.11.0-system-liblz4.patch
|
||||||
|
|
||||||
|
BuildRequires: cargo-rpm-macros >= 24
|
||||||
|
BuildRequires: pkgconfig(liblz4)
|
||||||
|
|
||||||
|
%global _description %{expand:
|
||||||
|
Rust LZ4 sys package.}
|
||||||
|
|
||||||
|
%description %{_description}
|
||||||
|
|
||||||
|
%package devel
|
||||||
|
Summary: %{summary}
|
||||||
|
BuildArch: noarch
|
||||||
|
Requires: pkgconfig(liblz4)
|
||||||
|
|
||||||
|
%description devel %{_description}
|
||||||
|
|
||||||
|
This package contains library source intended for building other packages which
|
||||||
|
use the "%{crate}" crate.
|
||||||
|
|
||||||
|
%files devel
|
||||||
|
%license %{crate_instdir}/LICENSE
|
||||||
|
%doc %{crate_instdir}/CHANGELOG.md
|
||||||
|
%{crate_instdir}/
|
||||||
|
|
||||||
|
%package -n %{name}+default-devel
|
||||||
|
Summary: %{summary}
|
||||||
|
BuildArch: noarch
|
||||||
|
|
||||||
|
%description -n %{name}+default-devel %{_description}
|
||||||
|
|
||||||
|
This package contains library source intended for building other packages which
|
||||||
|
use the "default" feature of the "%{crate}" crate.
|
||||||
|
|
||||||
|
%files -n %{name}+default-devel
|
||||||
|
%ghost %{crate_instdir}/Cargo.toml
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%autosetup -n %{crate}-%{upstream_version} -p1
|
||||||
|
# Remove the bundled copy of liblz4.
|
||||||
|
rm -rv liblz4
|
||||||
|
%cargo_prep
|
||||||
|
|
||||||
|
%generate_buildrequires
|
||||||
|
%cargo_generate_buildrequires
|
||||||
|
|
||||||
|
%build
|
||||||
|
%cargo_build
|
||||||
|
|
||||||
|
%install
|
||||||
|
%cargo_install
|
||||||
|
|
||||||
|
%if %{with check}
|
||||||
|
%check
|
||||||
|
%cargo_test
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Sun Jan 05 2025 Arkady L. Shane <tigro@msvsphere-os.ru> - 1.11.1-2
|
||||||
|
- Rebuilt for MSVSphere 10
|
||||||
|
|
||||||
|
## START: Generated by rpmautospec
|
||||||
|
* Thu Sep 26 2024 Benjamin A. Beasley <code@musicinmybrain.net> - 1.11.1-2
|
||||||
|
- Fix missing patch file
|
||||||
|
|
||||||
|
* Thu Sep 26 2024 Benjamin A. Beasley <code@musicinmybrain.net> - 1.11.1-1
|
||||||
|
- Update to 1.11.1 (close RHBZ#2312163)
|
||||||
|
|
||||||
|
* Thu Sep 26 2024 Benjamin A. Beasley <code@musicinmybrain.net> - 1.11.0-1
|
||||||
|
- Update to 1.11.0
|
||||||
|
|
||||||
|
* Wed Aug 07 2024 Benjamin A. Beasley <code@musicinmybrain.net> - 1.10.0-1
|
||||||
|
- Update to 1.10.0 (close RHBZ#2299411)
|
||||||
|
|
||||||
|
* Sat Jul 20 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.5-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild
|
||||||
|
|
||||||
|
* Tue Jun 11 2024 Benjamin A. Beasley <code@musicinmybrain.net> - 1.9.5-1
|
||||||
|
- Update to 1.9.5 (close RHBZ#2291271)
|
||||||
|
|
||||||
|
* Mon Mar 11 2024 Benjamin A. Beasley <code@musicinmybrain.net> - 1.9.4-6
|
||||||
|
- Use rust2rpm 26 features to reduce the amount of manual packaging work
|
||||||
|
|
||||||
|
* Fri Jan 26 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.9.4-4
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Jan 04 2024 Benjamin A. Beasley <code@musicinmybrain.net> - 1.9.4-3
|
||||||
|
- Split up the system-liblz4 patch
|
||||||
|
- Apply the changes in Cargo.toml during “rust2rpm -p”
|
||||||
|
|
||||||
|
* Thu Jan 04 2024 Benjamin A. Beasley <code@musicinmybrain.net> - 1.9.4-1
|
||||||
|
- Initial package (close RHBZ#2249863)
|
||||||
|
## END: Generated by rpmautospec
|
Loading…
Reference in new issue