[MPlayer-users] config.mak ${DATADIR} vs ${prefix}

NAGY Andras nagya at inf.elte.hu
Sat Jan 5 22:34:01 CET 2002


The following code in configure...

,----
| # Atmos: moved this here, to be correct, if --prefix is specified
| test -z "$_datadir" && _datadir=$_prefix"/share/mplayer"
| test -z "$_confdir" && _confdir=$_datadir
`----

... generates the following config.mak excerpt:

,----
| prefix = /usr/local
| DATADIR = /usr/local/share/mplayer
| CONFDIR = /usr/local/share/mplayer
`----


It is common practice in local package handling to configure a GNU
autoconf package (or a package with a similar interface, like mplayer)
with prefix=/usr/local, but specify a different prefix on
installation, like `make install prefix=/usr/local/stow/mplayer-x.xx'
and make symlinks from /usr/local to this directory, probably with the
help of stow[1].

This is possible, as GNU autoconf follows the policy of not extracting
values of configuration parameters if that is not necessary.  GNU
autoconf would have generated the following makefile from this info:

,----
| prefix = /usr/local
| DATADIR = ${prefix}/share/mplayer
| CONFDIR = ${prefix}/share/mplayer
`----

The ${var} syntax is suitable for bourne shells, perl, make etc.  


Mplayer currently does not support this type of
configuration/installation, although it used to do this (perhaps
implicitly) in previous versions.  Please modify the configure script
to generate a reference to ${prefix} in the above code instead of
substituting it's value.


Andras




More information about the MPlayer-users mailing list