#10202: Make freetype have ${SAGE_LOCAL} as its prefix in the pkgconfig file
---------------------------+------------------------------------------------
Reporter: jason | Owner: leif
Type: enhancement | Status: new
Priority: critical | Milestone: sage-4.7
Component: packages | Keywords:
Author: | Upstream: N/A
Reviewer: | Merged:
Work_issues: |
---------------------------+------------------------------------------------
Comment(by jason):
I take that back about this ticket being doomed. In fact, the solution is
*much* easier. Instead of defining `${SAGE_ROOT}` at the top of pkg-
config, we should wrap the system pkg-config using the --define-variable
option:
{{{
--define-variable=VARIABLENAME=VARIABLEVALUE
This sets a global value for a variable, overriding the
value in any files. Most packages define the vari-
able "prefix", for example, so you can say:
$ pkg-config --print-errors --define-variable=prefix=/foo
\
--variable=prefix glib-2.0
/foo
}}}
So if we have a pkg-config in `$SAGE_ROOT/local/bin` which is something
like:
{{{
#!/bin/sh
pkg-config --define-variable=SAGE_ROOT=<whatever> $*
}}}
then we don't have to keep mucking with the .pc files every time our
location moves. We just need to do a simple string substitution the first
time Sage is built or the first time any package makes a .pc file.
This solves both the main problem of this ticket and the problem with
double-initialization.
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/10202#comment:15>
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 post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.