commit:     94204fb9444c7c99868f8cd1b4d952accdfda0f3
Author:     Alexander Puck Neuwirth <apn-pucky <AT> gentoo <DOT> org>
AuthorDate: Wed Aug 27 11:45:28 2025 +0000
Commit:     Alexander Puck Neuwirth <apn-pucky <AT> gentoo <DOT> org>
CommitDate: Wed Sep 10 14:13:26 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=94204fb9

sci-physics/fastjet: switch to cmake

Closes: https://bugs.gentoo.org/961037
Closes: https://bugs.gentoo.org/937115
Part-of: https://github.com/gentoo/gentoo/pull/43583
Closes: https://github.com/gentoo/gentoo/pull/43583
Signed-off-by: Alexander Puck Neuwirth <apn-pucky <AT> gentoo.org>

 ...fastjet-9999.ebuild => fastjet-3.5.1-r1.ebuild} | 48 ++++++++--------------
 sci-physics/fastjet/fastjet-9999.ebuild            | 48 ++++++++--------------
 2 files changed, 32 insertions(+), 64 deletions(-)

diff --git a/sci-physics/fastjet/fastjet-9999.ebuild 
b/sci-physics/fastjet/fastjet-3.5.1-r1.ebuild
similarity index 62%
copy from sci-physics/fastjet/fastjet-9999.ebuild
copy to sci-physics/fastjet/fastjet-3.5.1-r1.ebuild
index 086e3352290e..581b37a1da90 100644
--- a/sci-physics/fastjet/fastjet-9999.ebuild
+++ b/sci-physics/fastjet/fastjet-3.5.1-r1.ebuild
@@ -12,7 +12,7 @@ DOCS_DEPEND="
        virtual/latex-base
 "
 
-inherit autotools docs fortran-2 python-single-r1
+inherit cmake docs fortran-2 python-single-r1
 
 DESCRIPTION="A software package for jet finding in pp and e+e- collisions"
 HOMEPAGE="https://fastjet.fr/";
@@ -33,60 +33,44 @@ REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
 # special --enable-cgal-header-only argument to use these versions.
 DEPEND="
        cgal? ( >=sci-mathematics/cgal-5.4:=[shared(+)] )
-       plugins? ( sci-physics/siscone:= )
+       plugins? ( >=sci-physics/siscone-3.1.2-r1:= )
        python? (
                ${PYTHON_DEPS}
                dev-lang/swig
        )
 "
 RDEPEND="${DEPEND}"
-BDEPEND="app-shells/bash"
-
-PATCHES=(
-       "${FILESDIR}"/${PN}-3.4.0-system-siscone.patch
-       "${FILESDIR}"/${PN}-3.4.0-gfortran.patch
-)
 
 pkg_setup() {
        use python && python-single-r1_pkg_setup
        fortran-2_pkg_setup
 }
 
-src_prepare() {
-       default
-       eautoreconf
-}
-
 src_configure() {
-       # only bash compatible
-       local -x CONFIG_SHELL="${BROOT}/bin/bash"
-       local myeconfargs=(
-               "$(use_enable cgal cgal-header-only)"
-               "$(use_enable plugins monolithic)"
-               "$(use_enable plugins allplugins)"
-               "$(use_enable plugins allcxxplugins)"
-               "--enable-shared"
-               "--enable-static=no"
-               "--disable-static"
-               "--disable-auto-ptr"
-               "$(use_enable python pyext)"
-               "$(use_enable python swig)"
+       local mycmakeargs=(
+               -DFASTJET_ENABLE_CGAL=$(usex cgal)
+               -DFASTJET_ENABLE_ALLPLUGINS=$(usex plugins)
+               -DFASTJET_ENABLE_ALLCXXPLUGINS=$(usex plugins)
+               -DFASTJET_ENABLE_PYTHON=$(usex python)
+               -DFASTJET_BUILD_EXAMPLES=$(usex examples)
+               -DFASTJET_HAVE_AUTO_PTR_INTERFACE=OFF
+               -DFASTJET_USE_INSTALLED_SISCONE=ON
        )
-       econf "${myeconfargs[@]}"
+       use python && mycmakeargs+=(
+               -DFASTJET_CUSTOM_PYTHON_INSTALL="$(python_get_sitedir)"
+       )
+       cmake_src_configure
 }
 
 src_compile() {
-       default
+       cmake_src_compile
        docs_compile
 }
 
 src_install() {
-       default
+       cmake_src_install
        use python && python_optimize
        if use examples; then
-               emake -C example maintainer-clean
-               find example -iname 'makefile*' -delete || die
-
                docinto examples
                dodoc -r example/.
                docompress -x /usr/share/doc/${PF}/examples

diff --git a/sci-physics/fastjet/fastjet-9999.ebuild 
b/sci-physics/fastjet/fastjet-9999.ebuild
index 086e3352290e..581b37a1da90 100644
--- a/sci-physics/fastjet/fastjet-9999.ebuild
+++ b/sci-physics/fastjet/fastjet-9999.ebuild
@@ -12,7 +12,7 @@ DOCS_DEPEND="
        virtual/latex-base
 "
 
-inherit autotools docs fortran-2 python-single-r1
+inherit cmake docs fortran-2 python-single-r1
 
 DESCRIPTION="A software package for jet finding in pp and e+e- collisions"
 HOMEPAGE="https://fastjet.fr/";
@@ -33,60 +33,44 @@ REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
 # special --enable-cgal-header-only argument to use these versions.
 DEPEND="
        cgal? ( >=sci-mathematics/cgal-5.4:=[shared(+)] )
-       plugins? ( sci-physics/siscone:= )
+       plugins? ( >=sci-physics/siscone-3.1.2-r1:= )
        python? (
                ${PYTHON_DEPS}
                dev-lang/swig
        )
 "
 RDEPEND="${DEPEND}"
-BDEPEND="app-shells/bash"
-
-PATCHES=(
-       "${FILESDIR}"/${PN}-3.4.0-system-siscone.patch
-       "${FILESDIR}"/${PN}-3.4.0-gfortran.patch
-)
 
 pkg_setup() {
        use python && python-single-r1_pkg_setup
        fortran-2_pkg_setup
 }
 
-src_prepare() {
-       default
-       eautoreconf
-}
-
 src_configure() {
-       # only bash compatible
-       local -x CONFIG_SHELL="${BROOT}/bin/bash"
-       local myeconfargs=(
-               "$(use_enable cgal cgal-header-only)"
-               "$(use_enable plugins monolithic)"
-               "$(use_enable plugins allplugins)"
-               "$(use_enable plugins allcxxplugins)"
-               "--enable-shared"
-               "--enable-static=no"
-               "--disable-static"
-               "--disable-auto-ptr"
-               "$(use_enable python pyext)"
-               "$(use_enable python swig)"
+       local mycmakeargs=(
+               -DFASTJET_ENABLE_CGAL=$(usex cgal)
+               -DFASTJET_ENABLE_ALLPLUGINS=$(usex plugins)
+               -DFASTJET_ENABLE_ALLCXXPLUGINS=$(usex plugins)
+               -DFASTJET_ENABLE_PYTHON=$(usex python)
+               -DFASTJET_BUILD_EXAMPLES=$(usex examples)
+               -DFASTJET_HAVE_AUTO_PTR_INTERFACE=OFF
+               -DFASTJET_USE_INSTALLED_SISCONE=ON
        )
-       econf "${myeconfargs[@]}"
+       use python && mycmakeargs+=(
+               -DFASTJET_CUSTOM_PYTHON_INSTALL="$(python_get_sitedir)"
+       )
+       cmake_src_configure
 }
 
 src_compile() {
-       default
+       cmake_src_compile
        docs_compile
 }
 
 src_install() {
-       default
+       cmake_src_install
        use python && python_optimize
        if use examples; then
-               emake -C example maintainer-clean
-               find example -iname 'makefile*' -delete || die
-
                docinto examples
                dodoc -r example/.
                docompress -x /usr/share/doc/${PF}/examples

Reply via email to