<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
<META NAME="GENERATOR" CONTENT="GtkHTML/3.26.0">
</HEAD>
<BODY>
On Fri, 2011-01-21 at 17:34 +0100, Julien Cristau wrote:
<BLOCKQUOTE TYPE=CITE>
<PRE>
On Fri, Jan 21, 2011 at 08:31:23 -0500, Gaetan Nadon wrote:
> The path substitution in x11perfcomp script can be done at configuration
> time using Autoconf. This is an alternative to using sed and requires
> less Makefile work.
>
> Signed-off-by: Gaetan Nadon <<A HREF="mailto:memsize@videotron.ca">memsize@videotron.ca</A>>
> ---
> Makefile.am | 14 +------
> configure.ac | 6 +++-
> x11pcomp.cpp | 103 ------------------------------------------------------
> x11perfcomp.in | 105 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
> 4 files changed, 112 insertions(+), 116 deletions(-)
> delete mode 100644 x11pcomp.cpp
> create mode 100644 x11perfcomp.in
>
I'm not sure. Using autoconf means you get the non-expanded version of
the variable, which means you need to keep track of which variables have
to be defined in x11perfcomp.in. At least in theory that could change
in a new autoconf version.
</PRE>
</BLOCKQUOTE>
Good question, always check if what you are using is part of the public interface and not some internal implementation.<BR>
<BR>
The variables and thier relationships are all part of the public interface. These values are the default values, a user can override<BR>
with --bindir or --libdir.<BR>
<BR>
<PRE>
<TT>exec_prefix</TT>
</PRE>
<DL>
A prefix used in constructing the default values of some of the variables listed below. The default value of <TT>exec_prefix</TT> should be <TT>$(prefix)</TT>. (If you are using Autoconf, write it as ‘@exec_prefix@’.)<BR>
<BR>
</DL>
<PRE>
‘libdir’
</PRE>
<DL>
The directory for object files and libraries of object code. [...] The value of <TT>libdir</TT> should normally be ‘<TT>/usr/local/lib</TT>’, but write it as ‘<TT>$(exec_prefix)/lib</TT>’. (If you are using Autoconf, write it as ‘@libdir@’.)<BR>
<BR>
</DL>
In theory it could change, and it has in the past. The <TT>datarootdir</TT> variable was introduced upon which <TT>datadir</TT> is based. This change was done in a way that was backward compatible.<BR>
<BR>
I am confident that using these variables is safe in the long run. It also correctly supports a configuration making use of --libdir.<BR>
<BR>
<BLOCKQUOTE TYPE=CITE>
<PRE>
Cheers,
Julien
</PRE>
</BLOCKQUOTE>
</BODY>
</HTML>