#17630: Further clean up of ATLAS (or equivalent BLAS) linking
-------------------------------------+-------------------------------------
Reporter: jpflori | Owner:
Type: defect | Status: needs_work
Priority: major | Milestone: sage-6.5
Component: packages: | Resolution:
standard | Merged in:
Keywords: | Reviewers:
Authors: Jean-Pierre | Work issues:
Flori, François Bissey | Commit:
Report Upstream: N/A | 764c3b574a438ef36b3a8a29552a7691514a37fb
Branch: u/fbissey/blas | Stopgaps:
Dependencies: #18777, #18778 |
-------------------------------------+-------------------------------------
Comment (by jdemeyer):
I just got an idea: why aren't we using a `pkgconfig` file instead of
`local/share/blas_config`? I seems like `pkgconfig` is exactly meant to
solve the problems we're having on this ticket.
A typical file looks like
{{{
$ cat local/lib/pkgconfig/m4ri.pc
SAGE_ROOT=/usr/local/src/sage-config
prefix=${SAGE_ROOT}/local
exec_prefix=${prefix}
libdir=${SAGE_ROOT}/local/lib
includedir=${prefix}/include
Name: M4RI
Description: Dense linear algebra over GF(2).
Version: 20140914
Libs: -L${libdir} -lm4ri -lm
Cflags: -I${includedir}/m4ri -I${SAGE_ROOT}/local/include -g -fPIC -Wall
-pedantic -O2 -mmmx -msse -msse2 -msse3
}}}
I am sure we can make a `blas.pc` file using this format.
From the shell, you can do for example
{{{
(sage-sh) $ pkgconf --libs m4ri
-lm4ri -lm
}}}
which would replace the ugly `sed` script.
There is also a Python interface:
{{{
sage: import pkgconfig
sage: pkgconfig.libs("m4ri")
u'-L/usr/local/src/sage-config/local/lib -lm4ri -lm'
}}}
--
Ticket URL: <http://trac.sagemath.org/ticket/17630#comment:89>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.