Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 739776 | Differences between
and this patch

Collapse All | Expand All

(-)file_not_specified_in_diff (-1 lines)
Line 99424 Link Here
99424
--
99425
.../files/kvazaar-2.0.0-fix-avx2-flags.patch  | 33 +++++++++++++++++++
825027
.../files/kvazaar-2.0.0-fix-avx2-flags.patch  | 33 +++++++++++++++++++
99426
media-libs/kvazaar/kvazaar-2.0.0.ebuild       |  6 +++-
825028
media-libs/kvazaar/kvazaar-2.0.0.ebuild       |  6 +++-
99427
media-libs/kvazaar/kvazaar-2.1.0.ebuild       |  4 +++
825029
media-libs/kvazaar/kvazaar-2.1.0.ebuild       |  4 +++
99428
3 files changed, 42 insertions(+), 1 deletion(-)
825030
3 files changed, 42 insertions(+), 1 deletion(-)
99429
create mode 100644 media-libs/kvazaar/files/kvazaar-2.0.0-fix-avx2-flags.patch
825031
create mode 100644 media-libs/kvazaar/files/kvazaar-2.0.0-fix-avx2-flags.patch
(-)a/media-libs/kvazaar/files/kvazaar-2.0.0-fix-avx2-flags.patch (+33 lines)
Line 0 Link Here
1
From 99423a825027c862bbfd50e112a1846a013b01a7 Mon Sep 17 00:00:00 2001
2
From: "Francisco Blas (klondike) Izquierdo Riera" <klondike@klondike.es>
3
Date: Tue, 4 Oct 2022 10:03:44 +0200
4
Subject: [PATCH] Enable -mpopcnt and -mlzcnt on AVX2
5
6
When -mpopcnt or -mlzcnt are explicitly enabled or disabled
7
(when using -march=native for example), kvazaar builds fail
8
on older CPUs without support for these flags (see
9
https://github.com/ultravideo/kvazaar/issues/228 and
10
https://bugs.gentoo.org/739776 ).
11
12
Ensuring these flags are on as done with the rest of AVX2 flags
13
solves the compilation issues, although it may be a better
14
approach to provide a configuration option so that only the
15
specific version matching the build system supported flags is
16
created in such cases.
17
---
18
 src/Makefile.am | 2 +-
19
 1 file changed, 1 insertion(+), 1 deletion(-)
20
21
diff --git a/src/Makefile.am b/src/Makefile.am
22
index 79880a98..c972c5be 100644
23
--- a/src/Makefile.am
24
+++ b/src/Makefile.am
25
@@ -226,7 +226,7 @@ endif #HAVE_PPC
26
 if HAVE_X86
27
 
28
 if HAVE_AVX2_GCC
29
-libavx2_la_CFLAGS = -mavx2 -mbmi -mabm -mbmi2
30
+libavx2_la_CFLAGS = -mavx2 -mbmi -mabm -mpopcnt -mlzcnt -mbmi2
31
 endif
32
 if HAVE_AVX2_CLANG
33
 libavx2_la_CFLAGS = -mavx2 -mbmi -mpopcnt -mlzcnt -mbmi2
(-)a/media-libs/kvazaar/kvazaar-2.0.0.ebuild (-1 / +5 lines)
Lines 1-4 Link Here
1
# Copyright 1999-2021 Gentoo Authors
1
# Copyright 1999-2022 Gentoo Authors
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
3
4
EAPI=7
4
EAPI=7
Lines 35-40 DEPEND="${RDEPEND} Link Here
35
	abi_x86_64? ( ${ASM_DEP} )
35
	abi_x86_64? ( ${ASM_DEP} )
36
"
36
"
37
37
38
PATCHES=(
39
	"${FILESDIR}/${P}-fix-avx2-flags.patch"
40
)
41
38
src_prepare() {
42
src_prepare() {
39
	default
43
	default
40
	sed -e "/^dist_doc_DATA/s/COPYING //" -i Makefile.am || die
44
	sed -e "/^dist_doc_DATA/s/COPYING //" -i Makefile.am || die
(-)a/media-libs/kvazaar/kvazaar-2.1.0.ebuild (-1 / +4 lines)
Lines 35-40 DEPEND="${RDEPEND} Link Here
35
	abi_x86_64? ( ${ASM_DEP} )
35
	abi_x86_64? ( ${ASM_DEP} )
36
"
36
"
37
37
38
PATCHES=(
39
	"${FILESDIR}/${PN}-2.0.0-fix-avx2-flags.patch"
40
)
41
38
src_prepare() {
42
src_prepare() {
39
	default
43
	default
40
	sed -e "/^dist_doc_DATA/s/COPYING //" -i Makefile.am || die
44
	sed -e "/^dist_doc_DATA/s/COPYING //" -i Makefile.am || die
41
- 

Return to bug 739776