mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-06 00:48:18 -07:00
sci-libs/blas-lapack-aux-wrapper: Update the wrappers to avoid DT_AUXILIARY
Update the wrapper approach to avoid DT_AUXILIARY in the default case. Now, libblas.so.3 & co. are symlinks to the FlexiBLAS library, so that packages use it directly; libblas.so & co. are symlinks to wrappers placed in a subdirectory, so they are only used to construct the correct DT_NEEDED entries at build time. The advantage of this approach is that it also works on musl, so we do not have to use two different solutions. We are still using the full library symlink tree for the wrapper to avoid another fight with Meson, and hopefully to reduce the risk of compatibility issues. The library still contains DT_AUXILIARY section, and it could still be used if one dlopens the top-level .so file directly (rather than the .so.3). Signed-off-by: Michał Górny <mgorny@gentoo.org>
This commit is contained in:
@@ -0,0 +1,52 @@
|
||||
# Copyright 2025 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
PYTHON_COMPAT=( python3_{11..14} )
|
||||
|
||||
inherit meson python-any-r1
|
||||
|
||||
DESCRIPTION="BLAS/LAPACK wrappers for FlexiBLAS"
|
||||
HOMEPAGE="https://gitweb.gentoo.org/proj/blas-lapack-aux-wrapper.git/"
|
||||
SRC_URI="https://dev.gentoo.org/~mgorny/dist/${P}.tar.xz"
|
||||
|
||||
LICENSE="GPL-2+"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64"
|
||||
IUSE="index64"
|
||||
|
||||
RDEPEND="
|
||||
!sci-libs/lapack[-flexiblas(-)]
|
||||
>=sci-libs/flexiblas-3.4.82-r4:=[index64(-)?]
|
||||
"
|
||||
DEPEND="
|
||||
${RDEPEND}
|
||||
sci-libs/lapack:=[flexiblas(-),index64?,lapacke]
|
||||
"
|
||||
BDEPEND="
|
||||
${PYTHON_DEPS}
|
||||
"
|
||||
|
||||
# we do not call the compiler, only the linker
|
||||
QA_FLAGS_IGNORED=".*"
|
||||
|
||||
src_configure() {
|
||||
local emesonargs=(
|
||||
-Dilp64=$(usex index64 true false)
|
||||
)
|
||||
|
||||
meson_src_configure
|
||||
}
|
||||
|
||||
src_install() {
|
||||
meson_src_install
|
||||
|
||||
local f
|
||||
cd "${ED}/usr/$(get_libdir)" || die
|
||||
mkdir blas-lapack-aux-wrapper || die
|
||||
mv lib* blas-lapack-aux-wrapper/ || die
|
||||
for f in blas-lapack-aux-wrapper/*.so; do
|
||||
ln -s "${f}" || die
|
||||
done
|
||||
}
|
||||
Reference in New Issue
Block a user