public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/git-annex] f45: upstream blake3 patch for non-x86_64 archs
@ 2026-11-16 13:40 Jens Petersen
0 siblings, 0 replies; only message in thread
From: Jens Petersen @ 2026-11-16 13:40 UTC (permalink / raw)
To: git-commits
A new commit has been pushed.
Repo : rpms/git-annex
Branch : f45
Commit : ae09b3df55e89d4c47d735e5dad9c085579bdd22
Author : Jens Petersen <petersen@redhat.com>
Date : 2026-11-16T21:01:36+08:00
Stats : +110/-2 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/git-annex/c/ae09b3df55e89d4c47d735e5dad9c085579bdd22?branch=f45
Log:
upstream blake3 patch for non-x86_64 archs
---
diff --git a/2a3b564ad9454ca2195ed15fc83050f771dc85af.patch b/2a3b564ad9454ca2195ed15fc83050f771dc85af.patch
new file mode 100644
index 0000000..1b21233
--- /dev/null
+++ b/2a3b564ad9454ca2195ed15fc83050f771dc85af.patch
@@ -0,0 +1,103 @@
+From 2a3b564ad9454ca2195ed15fc83050f771dc85af Mon Sep 17 00:00:00 2001
+From: Joey Hess <joeyh@joeyh.name>
+Date: Thu, 25 Jun 2026 10:25:49 -0400
+Subject: [PATCH] fix build on non-x86 with default build flags
+
+---
+ blake3/CHANGELOG.md | 6 ++++++
+ blake3/blake3.cabal | 24 ++++++++++++++++--------
+ 2 files changed, 22 insertions(+), 8 deletions(-)
+
+diff --git a/blake3/CHANGELOG.md b/blake3/CHANGELOG.md
+index 49d7179..74504cd 100644
+--- a/blake3/CHANGELOG.md
++++ b/blake3/CHANGELOG.md
+@@ -1,3 +1,9 @@
++# Version 0.3.2
++
++* Build on non-x86 systems without needing to explicitly disable
++ x86-specific build flags.
++
++
+ # Version 0.3.1
+
+ * Depend on `ram` rather than the unmaintained library `memory`.
+diff --git a/blake3/blake3.cabal b/blake3/blake3.cabal
+index 0395acb..5a7a4fe 100644
+--- a/blake3/blake3.cabal
++++ b/blake3/blake3.cabal
+@@ -21,22 +21,22 @@ extra-source-files:
+ cbits/LICENSE
+
+ flag avx512
+- description: Enable AVX-512 instructions
++ description: Enable AVX-512 instructions (only used for x86)
+ default: True
+ manual: True
+
+ flag avx2
+- description: Enable AVX2 instructions
++ description: Enable AVX2 instructions (only used for x86)
+ default: True
+ manual: True
+
+ flag sse41
+- description: Enable SSE 4.1 instructions
++ description: Enable SSE 4.1 instructions (only used for x86)
+ default: True
+ manual: True
+
+ flag sse2
+- description: Enable SSE 2 instructions
++ description: Enable SSE 2 instructions (only used for x86)
+ default: True
+ manual: True
+
+@@ -66,8 +66,10 @@ library
+ asm-sources: cbits/blake3_avx512_x86-64_unix.S
+ elif arch(x86_64) && os(windows)
+ asm-sources: cbits/blake3_avx512_x86-64_windows_gnu.S
+- else
++ elif arch(x86_64) || arch(i386)
+ c-sources: cbits/blake3_avx512.c
++ else
++ cc-options: -DBLAKE3_NO_AVX512
+ else
+ cc-options: -DBLAKE3_NO_AVX512
+
+@@ -77,8 +79,10 @@ library
+ asm-sources: cbits/blake3_avx2_x86-64_unix.S
+ elif arch(x86_64) && os(windows)
+ asm-sources: cbits/blake3_avx2_x86-64_windows_gnu.S
+- else
++ elif arch(x86_64) || arch(i386)
+ c-sources: cbits/blake3_avx2.c
++ else
++ cc-options: -DBLAKE3_NO_AVX2
+ else
+ cc-options: -DBLAKE3_NO_AVX2
+
+@@ -88,8 +92,10 @@ library
+ asm-sources: cbits/blake3_sse41_x86-64_unix.S
+ elif arch(x86_64) && os(windows)
+ asm-sources: cbits/blake3_sse41_x86-64_windows_gnu.S
+- else
++ elif arch(x86_64) || arch(i386)
+ c-sources: cbits/blake3_sse41.c
++ else
++ cc-options: -DBLAKE3_NO_SSE41
+ else
+ cc-options: -DBLAKE3_NO_SSE41
+
+@@ -99,8 +105,10 @@ library
+ asm-sources: cbits/blake3_sse2_x86-64_unix.S
+ elif arch(x86_64) && os(windows)
+ asm-sources: cbits/blake3_sse2_x86-64_windows_gnu.S
+- else
++ elif arch(x86_64) || arch(i386)
+ c-sources: cbits/blake3_sse2.c
++ else
++ cc-options: -DBLAKE3_NO_SSE2
+ else
+ cc-options: -DBLAKE3_NO_SSE2
+
diff --git a/git-annex.spec b/git-annex.spec
index 319684e..7697a04 100644
--- a/git-annex.spec
+++ b/git-annex.spec
@@ -30,7 +30,9 @@ Source4: https://hackage.haskell.org/package/%{libmagic}/%{libmagic}.tar.
Source5: https://hackage.haskell.org/package/%{ram}/%{ram}.tar.gz
Source6: https://hackage.haskell.org/package/%{tastytap}/%{tastytap}.tar.gz
# End cabal-rpm sources
-Patch0: %{name}-default-flags.patch
+Patch0: git-annex-default-flags.patch
+# https://github.com/k0001/hs-blake3/pull/10 for non-x86_64
+Patch1: https://github.com/k0001/hs-blake3/commit/2a3b564ad9454ca2195ed15fc83050f771dc85af.patch
%if %{defined fedora}
BuildRequires: bash-completion-devel
@@ -192,11 +194,14 @@ This package contains the documentation for %{name} in HTML format.
%prep
# Begin cabal-rpm setup:
%setup -q -a1 -a2 -a3 -a4 -a5 -a6
-%autopatch -p1
+%patch -P0 -p1
# End cabal-rpm setup
cabal-tweak-drop-dep persistent-template
cabal-tweak-drop-dep yesod-default
+( cd %{blake3}
+ %patch -P1 -p2
+)
%build
# Begin cabal-rpm build:
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-11-16 13:40 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-16 13:40 [rpms/git-annex] f45: upstream blake3 patch for non-x86_64 archs Jens Petersen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox