[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Sane way of making installation paths available to C ?
From: |
John Levon |
Subject: |
Sane way of making installation paths available to C ? |
Date: |
Thu, 27 Feb 2003 21:03:04 +0000 |
User-agent: |
Mutt/1.3.25i |
Is there some relatively sane way of making stuff like $bindir path
available to C programs (via config.h preferably) ? I'm entirely sure
I'm not the only one who's had to solve this problem a number of times.
Currently we have (hold your bags nearby) :
if test "$prefix" = "NONE"; then
prefix="$ac_default_prefix"
fi
if test "$exec_prefix" = "NONE"; then
exec_prefix="$prefix"
fi
if test "$bindir" = "NONE"; then
bindir="$prefix/bin"
fi
if test "$datadir" = "NONE"; then
datadir="$prefix/share"
fi
OP_DATADIR=`eval echo "$datadir/$PACKAGE/"`
OP_BINDIR=`eval echo "$bindir/"`
AC_SUBST(OP_BINDIR)
AC_SUBST(OP_DATADIR)
into a version.h file.
regards
john
- Sane way of making installation paths available to C ?,
John Levon <=