forked from jengelh/xxhash
Accepting request 1172038 from science
- Fix ftbfs with gcc14: OBS-URL: https://build.opensuse.org/request/show/1172038 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/xxhash?expand=0&rev=11
This commit is contained in:
commit
cfb152b9cd
16
test-tools-do-not-override-cflags.patch
Normal file
16
test-tools-do-not-override-cflags.patch
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
From: Bruno Pitrus <brunopitrus@hotmail.com>
|
||||||
|
Date: 2024-05-05 19:35:03+0000
|
||||||
|
|
||||||
|
--- xxHash-0.8.2/Makefile.old 2023-07-21 12:01:35.000000000 +0200
|
||||||
|
+++ xxHash-0.8.2/Makefile 2024-05-05 21:19:32.265851133 +0200
|
||||||
|
@@ -450,8 +450,8 @@ test-all: test test32 test-unicode clang
|
||||||
|
|
||||||
|
.PHONY: test-tools
|
||||||
|
test-tools:
|
||||||
|
- CFLAGS=-Werror $(MAKE) -C tests/bench
|
||||||
|
- CFLAGS=-Werror $(MAKE) -C tests/collisions
|
||||||
|
+ $(MAKE) -C tests/bench
|
||||||
|
+ $(MAKE) -C tests/collisions
|
||||||
|
|
||||||
|
.PHONY: test-xxh-nnn-sums
|
||||||
|
test-xxh-nnn-sums: xxhsum_and_links
|
@ -1,3 +1,11 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Sun May 5 19:35:03 UTC 2024 - Bruno Pitrus <brunopitrus@hotmail.com>
|
||||||
|
|
||||||
|
- Fix ftbfs with gcc14:
|
||||||
|
* use correct optflags also in %check
|
||||||
|
* add test-tools-do-not-override-cflags.patch
|
||||||
|
- Execute more tests
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Thu Nov 30 14:43:11 UTC 2023 - Guillaume GARDET <guillaume.gardet@opensuse.org>
|
Thu Nov 30 14:43:11 UTC 2023 - Guillaume GARDET <guillaume.gardet@opensuse.org>
|
||||||
|
|
||||||
|
17
xxhash.spec
17
xxhash.spec
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package xxhash
|
# spec file for package xxhash
|
||||||
#
|
#
|
||||||
# Copyright (c) 2023 SUSE LLC
|
# Copyright (c) 2024 SUSE LLC
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@ -24,6 +24,7 @@ License: BSD-2-Clause AND GPL-2.0-only
|
|||||||
Group: Productivity/Security
|
Group: Productivity/Security
|
||||||
URL: https://github.com/Cyan4973/xxHash
|
URL: https://github.com/Cyan4973/xxHash
|
||||||
Source0: https://github.com/Cyan4973/xxHash/archive/v%{version}.tar.gz#/xxHash-%{version}.tar.gz
|
Source0: https://github.com/Cyan4973/xxHash/archive/v%{version}.tar.gz#/xxHash-%{version}.tar.gz
|
||||||
|
Patch0: test-tools-do-not-override-cflags.patch
|
||||||
BuildRequires: gcc-c++
|
BuildRequires: gcc-c++
|
||||||
BuildRequires: pkgconfig
|
BuildRequires: pkgconfig
|
||||||
|
|
||||||
@ -60,19 +61,25 @@ functions. Hashes are identical on all platforms.
|
|||||||
%build
|
%build
|
||||||
export CFLAGS="%{optflags}"
|
export CFLAGS="%{optflags}"
|
||||||
export CXXFLAGS="%{optflags}"
|
export CXXFLAGS="%{optflags}"
|
||||||
export LDFLAGS="%{?_lto_cflags}"
|
export LDFLAGS="%{?build_ldflags}"
|
||||||
%make_build prefix=%{_prefix} libdir=%{_libdir}
|
%make_build prefix=%{_prefix} libdir=%{_libdir}
|
||||||
|
|
||||||
%install
|
%install
|
||||||
|
export CFLAGS="%{optflags}"
|
||||||
|
export CXXFLAGS="%{optflags}"
|
||||||
|
export LDFLAGS="%{?build_ldflags}"
|
||||||
%make_install prefix=%{_prefix} libdir=%{_libdir}
|
%make_install prefix=%{_prefix} libdir=%{_libdir}
|
||||||
rm -rf %{buildroot}%{_libdir}/libxxhash.a
|
rm -rf %{buildroot}%{_libdir}/libxxhash.a
|
||||||
|
|
||||||
%check
|
%check
|
||||||
|
export CFLAGS="%{optflags}"
|
||||||
|
export CXXFLAGS="%{optflags}"
|
||||||
|
export LDFLAGS="%{?build_ldflags}"
|
||||||
# not safe for parallel execution as it removes xxhash.o and recreates it with different flags
|
# not safe for parallel execution as it removes xxhash.o and recreates it with different flags
|
||||||
%make_build -j1 test
|
# the list is taken from test-all with non-working/irrelevant ones (such as ones that change the toolchain) removed
|
||||||
|
%make_build -j1 test test-unicode listL120 trailingWhitespace test-xxh-nnn-sums
|
||||||
|
|
||||||
%post -n libxxhash0 -p /sbin/ldconfig
|
%ldconfig_scriptlets -n libxxhash0
|
||||||
%postun -n libxxhash0 -p /sbin/ldconfig
|
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%license LICENSE
|
%license LICENSE
|
||||||
|
Loading…
Reference in New Issue
Block a user