comparison configure.ac @ 35:9bf8b9f0f09d

fixed unexpanded $prefix in template paths i.e. I hacked the AutoHELLstuff even more ugly :-/
author meillo@marmaro.de
date Fri, 07 May 2010 16:42:58 +0200
parents 2c09cca4cab9
children 8071dc6c6ed1
comparison
equal deleted inserted replaced
34:8ea86ac25658 35:9bf8b9f0f09d
1 dnl Process this file with autoconf to produce a configure script. 1 dnl Process this file with autoconf to produce a configure script.
2 2
3 AC_PREREQ(2.59) 3 AC_PREREQ(2.59)
4 AC_INIT(masqmail, 0.2.21, oku@debian.org) 4 AC_INIT(masqmail, 0.2.21, meillo@marmaro.de)
5 AC_CONFIG_SRCDIR([src/masqmail.c]) 5 AC_CONFIG_SRCDIR([src/masqmail.c])
6 AM_CONFIG_HEADER(config.h) 6 AM_CONFIG_HEADER(config.h)
7 AM_INIT_AUTOMAKE() 7 AM_INIT_AUTOMAKE()
8 8
9 AC_PREFIX_DEFAULT(/usr) 9 AC_PREFIX_DEFAULT(/usr)
269 with_confdir='/etc/masqmail' 269 with_confdir='/etc/masqmail'
270 ) 270 )
271 AC_DEFINE_UNQUOTED(CONF_DIR, "${with_confdir}", [The configuration file location]) 271 AC_DEFINE_UNQUOTED(CONF_DIR, "${with_confdir}", [The configuration file location])
272 AC_SUBST(with_confdir) 272 AC_SUBST(with_confdir)
273 273
274 dnl well, /me/ thought that autoconf should make things _easy_ ...
275 test "x$prefix" = xNONE && prefix="$ac_default_prefix" 274 test "x$prefix" = xNONE && prefix="$ac_default_prefix"
276 AC_DEFINE_UNQUOTED(DATA_DIR, "`eval echo \""$datadir"\"`/masqmail", [The data directory]) 275
276 dnl well, /me/ thought that autoconf should make things _easy_ ... -- oku
277 dnl I needed the two `eval's to get the variable expanded in all cases -- meillo
278 dnl this is just horrible! -- meillo
279 AC_DEFINE_UNQUOTED(DATA_DIR, "`eval eval echo $datadir`/masqmail", [The data directory])
277 280
278 dnl gymnastics to get the correct path where masqmail should be installed 281 dnl gymnastics to get the correct path where masqmail should be installed
279 dnl we need this to call ourselves in failmsg.c 282 dnl we need this to call ourselves in failmsg.c
280 if test "x${exec_prefix}" != 'xNONE'; then 283 if test "x${exec_prefix}" != 'xNONE'; then
281 AC_DEFINE_UNQUOTED(SBINDIR, "${exec_prefix}/sbin", [The sbin directory]) 284 AC_DEFINE_UNQUOTED(SBINDIR, "${exec_prefix}/sbin", [The sbin directory])
286 AC_DEFINE_UNQUOTED(SBINDIR, "/usr/sbin") 289 AC_DEFINE_UNQUOTED(SBINDIR, "/usr/sbin")
287 fi 290 fi
288 fi 291 fi
289 292
290 AC_OUTPUT(Makefile \ 293 AC_OUTPUT(Makefile \
291 tests/Makefile \
292 src/Makefile \ 294 src/Makefile \
293 src/base64/Makefile \ 295 src/base64/Makefile \
294 src/md5/Makefile \ 296 src/md5/Makefile \
295 src/libident/Makefile 297 src/libident/Makefile
296 ) 298 )