autoconf-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: AC_CONFIG_COMMANDS problem


From: Akim Demaille
Subject: Re: AC_CONFIG_COMMANDS problem
Date: Fri, 26 Sep 2003 14:19:04 +0200
User-agent: Gnus/5.1002 (Gnus v5.10.2) Emacs/21.3 (gnu/linux)

 > Hello,

 > I sent this bug report almost a year ago but never received a
 > response, nor has the problem been addressed, so I thought I would
 > try again.

Thanks for insisting :)

 > In Autoconf 2.57 (all releases) and in the CVS version, there is a
 > problem with AC_CONFIG_COMMANDS when it is used to create a file in
 > a directory which does not already exist at the time config.status
 > is run.  Consider the following configure.ac:

 > AC_PREREQ([2.57])
 > AC_INIT([myprog], [0])
 > AC_CONFIG_COMMANDS([foo/bar], [echo "test" > foo/bar])
 > AC_OUTPUT

 > This results in a config.status which produces these error messages:

 > configure: creating ./config.status
 > ./config.status: line 1: cd: foo: No such file or directory
 > ./config.status: line 1: cd: foo: No such file or directory
 > ./config.status: line 1: cd: foo: No such file or directory
 > ./config.status: line 1: cd: foo: No such file or directory
 > config.status: executing foo/bar commands

[... a lot of interesting details ...]

Well, I've always meant to enforce more or less the first argument to
be a file, so that Automake can extract a valid rule to update
AC_CONFIG_COMMANDS results just as it does for AC_CONFIG_FILES.  So it
seems to me that we could add an automatic

      test -d $(dirname $1) || mkdir -p $(dirname $1)

for AC_CONFIG_COMMANDS.  If people don't want this mkdir, it's because
they are not creating a file, so it has no reason to look like a
qualified path in the first place.

How about that?




reply via email to

[Prev in Thread] Current Thread [Next in Thread]