bug-gnulib
[Top][All Lists]
Advanced

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

Re: Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".


From: Jim Meyering
Subject: Re: Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
Date: Sun, 21 Jan 2007 22:27:30 +0100

Simon Josefsson <address@hidden> wrote:
> This patch seem to cause plenty of build failures like this:

Hi Simon,

Thanks for the report.
What version of autoconf are you using on that system?

I tried to reproduce the failure like this:

    cd /tmp
    rm -rf x
    /gnulib/gnulib-tool --dir x --with-tests --create-testdir gettime

but it worked fine for me.
I tried with automake-1.10 and each of autoconf-2.60, 2.61, and 2.61a.
You may be using a bad version of sed.

Please verify the versions of sed, m4, and automake, too.
If you built autoconf with a version of m4 older than 1.4.4,
that can cause trouble, too, though I don't know if it could
cause what you're seeing.

What does this output?

    grep MKDIR_P config.status

I get this:

    MKDIR_P='/bin/mkdir -p'
      ac_MKDIR_P=$MKDIR_P
      case $MKDIR_P in
      */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
    s&@MKDIR_P@&$ac_MKDIR_P&;t t

If you see the same (modulo the precise path for mkdir), then try
tracing config.status to see why the sed substitution doesn't work:

    bash -x config.status

...
> http://autobuild.josefsson.org/gnulib/log-200701211146617069000.txt
>
> It seems like $(MKDIR_P) is empty.  The configure.ac does contain:
>
> AC_PROG_MKDIR_P
>
> However, it doesn't seem like it is getting substituted into the
> Makefile:
>
> dopio:/data/gnulib/build/gettime# grep MKDIR gllib/*
> gllib/Makefile: $(MKDIR_P) sys
> gllib/Makefile.am:      $(MKDIR_P) sys
> gllib/Makefile.in:      $(MKDIR_P) sys
> dopio:/data/gnulib/build/gettime#

Ahh... this is it.
Something is wrong with your version of automake.
I get this:

    $ grep MKDIR_P Makefile.in
    MKDIR_P = @MKDIR_P@
              */*) $(MKDIR_P) `echo "$$dist_files" | \
            $(MKDIR_P) sys

Notice that I have the definition of MKDIR_P and you don't.




reply via email to

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