commit:     38ef80f7c87a6c640df9c801289dd28de96a0321
Author:     David Roman <davidroman96 <AT> gmail <DOT> com>
AuthorDate: Thu Feb  1 10:40:22 2024 +0000
Commit:     Yixun Lan <dlan <AT> gentoo <DOT> org>
CommitDate: Thu Feb 22 12:10:56 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=38ef80f7

sci-libs/kissfft: add cmake patch

Also:
- update EAPI 7 -> 8
- add python12 support

Signed-off-by: David Roman <davidroman96 <AT> gmail.com>
Signed-off-by: Yixun Lan <dlan <AT> gentoo.org>

 sci-libs/kissfft/files/kissfft-131.1.0-cmake.patch | 26 ++++++++++++++++++++++
 ...ssfft-9999.ebuild => kissfft-131.1.0-r1.ebuild} |  9 ++++----
 sci-libs/kissfft/kissfft-9999.ebuild               |  9 ++++----
 3 files changed, 36 insertions(+), 8 deletions(-)

diff --git a/sci-libs/kissfft/files/kissfft-131.1.0-cmake.patch 
b/sci-libs/kissfft/files/kissfft-131.1.0-cmake.patch
new file mode 100644
index 000000000000..a3cb3e468e17
--- /dev/null
+++ b/sci-libs/kissfft/files/kissfft-131.1.0-cmake.patch
@@ -0,0 +1,26 @@
+diff --git a/kissfft-config.cmake.in b/kissfft-config.cmake.in
+index cd7139a..7d6c7a2 100644
+--- a/kissfft-config.cmake.in
++++ b/kissfft-config.cmake.in
+@@ -66,14 +66,19 @@ foreach(_kissfft_datatype simd int16 int32 float double)
+ endforeach()
+ 
+ if(_kissfft_datatype_detected)
+-    if(NOT TARGET kissfft::kissfft-${_kissfft_datatype_detected})
+-        message(FATAL_ERROR "kissfft with 
datatype=${_kissfft_datatype_detected} is not installed")
++    if(TARGET kissfft::kissfft-${_kissfft_datatype_detected}-openmp)
++      set(_kissfft_openmp_detected "-openmp")
+     endif()
++
++    if(NOT TARGET 
kissfft::kissfft-${_kissfft_datatype_detected}${_kissfft_openmp_detected})
++        message(FATAL_ERROR "kissfft with 
datatype=${_kissfft_datatype_detected}${_kissfft_openmp_detected} is not 
installed")
++    endif()
++
+     if(TARGET kissfft::kissfft)
+         message(SEND_ERROR "kissfft::kissfft already exists. You cannot use 2 
find_package's with datatype that are visible to eachother.")
+     else()
+         add_library(kissfft::kissfft INTERFACE IMPORTED)
+-        set_property(TARGET kissfft::kissfft PROPERTY 
INTERFACE_LINK_LIBRARIES kissfft::kissfft-${_kissfft_datatype_detected})
++        set_property(TARGET kissfft::kissfft PROPERTY 
INTERFACE_LINK_LIBRARIES 
kissfft::kissfft-${_kissfft_datatype_detected}${_kissfft_openmp_detected})
+     endif()
+ endif()

diff --git a/sci-libs/kissfft/kissfft-9999.ebuild 
b/sci-libs/kissfft/kissfft-131.1.0-r1.ebuild
similarity index 88%
copy from sci-libs/kissfft/kissfft-9999.ebuild
copy to sci-libs/kissfft/kissfft-131.1.0-r1.ebuild
index 238fe43ab8ee..14e039c7eec1 100644
--- a/sci-libs/kissfft/kissfft-9999.ebuild
+++ b/sci-libs/kissfft/kissfft-131.1.0-r1.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2023 Gentoo Authors
+# Copyright 1999-2024 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=7
+EAPI=8
 
-PYTHON_COMPAT=( python3_{9..11} )
+PYTHON_COMPAT=( python3_{9..12} )
 
 inherit cmake python-any-r1 toolchain-funcs
 
@@ -15,7 +15,7 @@ if [[ ${PV} == *9999 ]] ; then
        inherit git-r3
 else
        SRC_URI="https://github.com/mborgerding/kissfft/archive/${PV}.tar.gz -> 
${P}.tar.gz"
-       KEYWORDS="~amd64 ~arm ~arm64 ~x86"
+       KEYWORDS="~amd64 ~arm ~arm64 ~riscv ~x86"
 fi
 
 LICENSE="BSD"
@@ -34,6 +34,7 @@ DEPEND="
 
 PATCHES=(
        "${FILESDIR}"/${PN}-131.1.0-cross.patch
+       "${FILESDIR}"/${PN}-131.1.0-cmake.patch
 )
 
 python_check_deps() {

diff --git a/sci-libs/kissfft/kissfft-9999.ebuild 
b/sci-libs/kissfft/kissfft-9999.ebuild
index 238fe43ab8ee..14e039c7eec1 100644
--- a/sci-libs/kissfft/kissfft-9999.ebuild
+++ b/sci-libs/kissfft/kissfft-9999.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2023 Gentoo Authors
+# Copyright 1999-2024 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=7
+EAPI=8
 
-PYTHON_COMPAT=( python3_{9..11} )
+PYTHON_COMPAT=( python3_{9..12} )
 
 inherit cmake python-any-r1 toolchain-funcs
 
@@ -15,7 +15,7 @@ if [[ ${PV} == *9999 ]] ; then
        inherit git-r3
 else
        SRC_URI="https://github.com/mborgerding/kissfft/archive/${PV}.tar.gz -> 
${P}.tar.gz"
-       KEYWORDS="~amd64 ~arm ~arm64 ~x86"
+       KEYWORDS="~amd64 ~arm ~arm64 ~riscv ~x86"
 fi
 
 LICENSE="BSD"
@@ -34,6 +34,7 @@ DEPEND="
 
 PATCHES=(
        "${FILESDIR}"/${PN}-131.1.0-cross.patch
+       "${FILESDIR}"/${PN}-131.1.0-cmake.patch
 )
 
 python_check_deps() {

Reply via email to