summaryrefslogtreecommitdiff
path: root/sci-libs/nlopt
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2022-09-14 11:10:11 +0100
committerV3n3RiX <venerix@koprulu.sector>2022-09-14 11:10:11 +0100
commit81b8f20732954c4508baf2f77472b5435e3f851f (patch)
tree4180177cb7ba85eab50159ce96218c2419fb24a6 /sci-libs/nlopt
parent946859e0e36904cffb3e0ccbccb6b7b1347c1cc8 (diff)
gentoo auto-resync : 14:09:2022 - 11:10:10
Diffstat (limited to 'sci-libs/nlopt')
-rw-r--r--sci-libs/nlopt/Manifest4
-rw-r--r--sci-libs/nlopt/nlopt-2.6.2-r1.ebuild109
-rw-r--r--sci-libs/nlopt/nlopt-2.7.1-r2.ebuild (renamed from sci-libs/nlopt/nlopt-2.7.1.ebuild)50
3 files changed, 33 insertions, 130 deletions
diff --git a/sci-libs/nlopt/Manifest b/sci-libs/nlopt/Manifest
index 72dc534a71e6..7903b980298f 100644
--- a/sci-libs/nlopt/Manifest
+++ b/sci-libs/nlopt/Manifest
@@ -1,6 +1,4 @@
-DIST nlopt-2.6.2.tar.gz 2040229 BLAKE2B f1f4124de574600ddbef8a885bbdd3a4f57b469b2f958ce94bbc831cf9bfa8a845e438fccfe4ab219a73a5675b8d880f6d49e0e7cbe9d0966777b0d2344521d4 SHA512 61e5c01140a57c0ad2a0acd82ad50dce1b5679dc281e55cbbc332e876b19a689013100617545a42b721d8c487df37d6ccd67859171243433fe29468f259b556b
DIST nlopt-2.7.1.tar.gz 2044180 BLAKE2B 6d459f94a26ee6dd7f72c73c48992bd047150aa525bc4ad088c8516127afc5c7843f6fbb6726c2f845271b87934c13e0892a063362ab50df51f92e81979111fb SHA512 e23cb522fc696010574c14b72be85acc0f8ccf0bf208bf2b8789c57d6c5a6e6d419ee10330581518b1c1567018ae909b626ce7761d4fbd5bf112916871e420e2
-EBUILD nlopt-2.6.2-r1.ebuild 2307 BLAKE2B 9c57f104122725bb2660bde7259ff187256d26cffbb4f0bd399acd2b07dcbac522ea4c83ea2196c84a274fe3c188ee61830e0e09d93505a78df1d74618505364 SHA512 858cc72c427ec512c1ef07619fc44230b1b5fe9b1ca68899341a80c13db7a9a1ac82cc8a8dd3d419a832519739ec672361ee3acdb058f31140df9195101fefd9
EBUILD nlopt-2.7.1-r1.ebuild 2135 BLAKE2B 3ec2db52921253d9b5b47447496e4c589ec2d75003193a0476e82c146fd51f5aa838c4c9958f992f15285e86eb8392e32181e7ba2c612a8ca9ce0c0ccba89965 SHA512 eecdc3bf5bc76269aa8c786c2c032b35447b52f17ac07c11f3824540b5f9309989090a0b993e6b0e9804823461671fc8c7878f918071da45bfebd52c4fff6aeb
-EBUILD nlopt-2.7.1.ebuild 1989 BLAKE2B 9250bcd302e71a9d261930c8ec91646d5b9981a9aaec70274bc1e2c006f15e40d787c6ba7c7f02fbd31cf9c47144fb7a97017954d9ffe0ca9845a7b6914a479e SHA512 d618cf5a1f7ee9d41e6cc7e9a5756b9fa59668bade2428bbcae8a4f4e782268e095f9dbdeb95eaee0c23aa1c5508f18cdde7b869328063f1becb8c13d278651b
+EBUILD nlopt-2.7.1-r2.ebuild 2139 BLAKE2B 540a0706ed5d84e034c87f96a9790e07c559e6e71961b16889975a731dd32cdcd4c194abe088560558d0993c599feb65da21ef737eabbe7137e88097fcff8029 SHA512 80f750456e97f7cf2a557f1de1863f87e2136a9ef2ead9a652a0615d0d5ffad5b9d119f4b4c535421d5293a4a7b8dcd19e1539533ab213dee8052b8abec65a0d
MISC metadata.xml 1096 BLAKE2B 2b35b6f79c882fbae26b6bc68c75e30b0e2d48f540696cbbc48f06c2686e89a1a5f582d59d2c1ee3b47d5f813f4dbc20cd1d35228c7f968e327e41bb2f1f4da9 SHA512 5776b4b8faa1a6406f1d65bcd9de9ce4087580d98b5c3272804d442905c34d64c6e7d632022425e6e13b12161c94a99906a6196c3624b5b9b4aa1eac6fe9aa1e
diff --git a/sci-libs/nlopt/nlopt-2.6.2-r1.ebuild b/sci-libs/nlopt/nlopt-2.6.2-r1.ebuild
deleted file mode 100644
index 01368b67d508..000000000000
--- a/sci-libs/nlopt/nlopt-2.6.2-r1.ebuild
+++ /dev/null
@@ -1,109 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-PYTHON_COMPAT=( python3_{8..10} )
-
-inherit python-r1 cmake fortran-2
-
-DESCRIPTION="Non-linear optimization library"
-HOMEPAGE="https://ab-initio.mit.edu/nlopt/"
-SRC_URI="https://github.com/stevengj/nlopt/archive/v${PV}.tar.gz -> ${P}.tar.gz"
-
-LICENSE="LGPL-2.1 MIT"
-KEYWORDS="amd64 ~arm64 x86 ~amd64-linux ~x86-linux"
-SLOT="0"
-IUSE="cxx guile octave python static-libs test"
-REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
-RESTRICT="!test? ( test )"
-
-RDEPEND="
- guile? ( dev-scheme/guile:* )
- octave? ( sci-mathematics/octave )
- python? (
- ${PYTHON_DEPS}
- dev-python/numpy[${PYTHON_USEDEP}]
- )
- "
-DEPEND="
- ${RDEPEND}
- python? ( dev-lang/swig )
- "
-
-src_prepare() {
- cmake_src_prepare
- use python && python_copy_sources
-}
-
-src_configure() {
- local mycmakeargs=(
- -DNLOPT_CXX=$(usex cxx)
- -DNLOPT_FORTRAN=$(usex test)
- -DNLOPT_GUILE=$(usex guile)
- -DNLOPT_OCTAVE=$(usex octave)
- -DNLOPT_PYTHON=$(usex python)
- -DNLOPT_SWIG=$(usex python)
- -DNLOPT_TESTS=$(usex test)
- )
- if use python; then
- python_foreach_impl run_in_build_dir cmake_src_configure
- else
- cmake_src_configure
- fi
- if use static-libs; then
- mycmakeargs+=(
- -DBUILD_SHARED_LIBS=OFF
- )
- BUILD_DIR="${S}_static-libs" run_in_build_dir cmake_src_configure
- fi
-}
-
-src_compile() {
- if use python; then
- python_foreach_impl run_in_build_dir cmake_src_compile
- else
- cmake_src_compile
- fi
- if use static-libs; then
- BUILD_DIR="${S}_static-libs" run_in_build_dir cmake_src_compile
- fi
-}
-
-src_test() {
- do_test() {
- local a f
- cd "${BUILD_DIR}"/test
- for a in {1..$(usex cxx 9 7)}; do
- for f in {5..9}; do
- ./testopt -a $a -o $f || die "algorithm $a function $f failed"
- done
- done
- }
- if use python; then
- python_foreach_impl run_in_build_dir do_test
- else
- do_test
- fi
- if use static-libs; then
- BUILD_DIR="${S}_static-libs" run_in_build_dir do_test
- fi
-}
-
-nlopt_install() {
- cmake_src_install
- python_optimize
-}
-
-src_install() {
- if use python; then
- python_foreach_impl run_in_build_dir nlopt_install
- else
- cmake_src_install
- fi
- if use static-libs; then
- BUILD_DIR="${S}_static-libs" run_in_build_dir dolib.a libnlopt.a
- fi
- local r
- for r in */README; do newdoc ${r} README.$(dirname ${r}); done
-}
diff --git a/sci-libs/nlopt/nlopt-2.7.1.ebuild b/sci-libs/nlopt/nlopt-2.7.1-r2.ebuild
index 10e6b998d4e3..b49baaa4267f 100644
--- a/sci-libs/nlopt/nlopt-2.7.1.ebuild
+++ b/sci-libs/nlopt/nlopt-2.7.1-r2.ebuild
@@ -1,7 +1,7 @@
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=7
+EAPI=8
PYTHON_COMPAT=( python3_{8..10} )
@@ -12,7 +12,7 @@ HOMEPAGE="https://github.com/stevengj/nlopt"
SRC_URI="https://github.com/stevengj/nlopt/archive/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="LGPL-2.1 MIT"
-KEYWORDS="amd64 ~arm64 x86 ~amd64-linux ~x86-linux"
+KEYWORDS="~amd64 ~arm64 ~x86 ~amd64-linux ~x86-linux"
SLOT="0"
IUSE="cxx guile octave python test"
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
@@ -20,19 +20,18 @@ RESTRICT="!test? ( test )"
RDEPEND="
guile? ( dev-scheme/guile:* )
- octave? ( >=sci-mathematics/octave-6 )
+ octave? ( >=sci-mathematics/octave-6:= )
python? (
${PYTHON_DEPS}
dev-python/numpy[${PYTHON_USEDEP}]
)
"
-DEPEND="
- ${RDEPEND}
- python? ( dev-lang/swig )
- "
+DEPEND="${RDEPEND}"
+BDEPEND="python? ( dev-lang/swig )"
src_prepare() {
cmake_src_prepare
+
use python && python_copy_sources
}
@@ -45,22 +44,33 @@ src_configure() {
-DNLOPT_GUILE=$(usex guile)
-DNLOPT_OCTAVE=$(usex octave)
-DNLOPT_MATLAB=OFF
- -DNLOPT_PYTHON=$(usex python)
+ -DNLOPT_PYTHON=OFF
-DNLOPT_SWIG=$(usex python)
-DNLOPT_TESTS=$(usex test)
)
+
+ cmake_src_configure
+
if use python; then
- python_foreach_impl run_in_build_dir cmake_src_configure
- else
- cmake_src_configure
+ python_configure() {
+ local mycmakeargs=(
+ ${mycmakeargs[@]}
+ -DNLOPT_PYTHON=ON
+ -DINSTALL_PYTHON_DIR="$(python_get_sitedir)"
+ )
+
+ cmake_src_configure
+ }
+
+ python_foreach_impl run_in_build_dir python_configure
fi
}
src_compile() {
+ cmake_src_compile
+
if use python; then
python_foreach_impl run_in_build_dir cmake_src_compile
- else
- cmake_src_compile
fi
}
@@ -74,10 +84,11 @@ src_test() {
done
done
}
+
+ do_test
+
if use python; then
python_foreach_impl run_in_build_dir do_test
- else
- do_test
fi
}
@@ -87,11 +98,14 @@ nlopt_install() {
}
src_install() {
+ cmake_src_install
+
if use python; then
python_foreach_impl run_in_build_dir nlopt_install
- else
- cmake_src_install
fi
+
local r
- for r in */README; do newdoc ${r} README.$(dirname ${r}); done
+ for r in */README; do
+ newdoc ${r} README.$(dirname ${r})
+ done
}