GNU bug report logs - #7833
automake uses two different values for DejaGNU srcdir

Previous Next

Package: automake;

Reported by: Ian Lance Taylor <iant <at> google.com>

Date: Wed, 12 Jan 2011 22:05:01 UTC

Severity: normal

Tags: patch

Done: Stefano Lattarini <stefano.lattarini <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Ian Lance Taylor <iant <at> google.com>
To: Stefano Lattarini <stefano.lattarini <at> gmail.com>
Cc: 7833 <at> debbugs.gnu.org
Subject: bug#7833: automake uses two different values for DejaGNU srcdir
Date: Thu, 13 Jan 2011 12:49:12 -0800
Stefano Lattarini <stefano.lattarini <at> gmail.com> writes:

> Relative (as I expected):
>
>   $ cat dejagnu-srcdir-is-absolute.dir/site.exp 
>   ## these variables are automatically generated by make ##
>   # Do not edit here.  If you wish to override these values
>   # edit the last section
>   set srcdir .
>   set objdir /home/stefano/src/automake/tests/dejagnu-srcdir-is-absolute.dir
>   ## All variables above are generated by configure. Do Not Edit ##
>
> But then, why the testcase suceeds?  I would expect it to fail!

1) Does it matter?  It seems clear to me that if automake is going to
specify the srcdir in two different ways, that the two ways should use
the same value.

2) DejaGNU is a horrible program and the problem is subtle, even more
subtle than I thought.  DejaGNU loads site.exp, then uses the current
value of $srcdir to find and run the tool init script.  That is where it
was going wrong for me.  After that, it reprocesses the command line
options, setting srcdir back to what it was before.  If you create a
file "lib/tcl.exp" and add a line
    send_user "tcl.exp: $srcdir\n"
you will see that while executing tcl.exp, srcdir is ".".

Ian




This bug report was last modified 13 years and 268 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.