diff options
author | Ben Elliston <bje@gnu.org> | 2016-03-20 20:20:15 +1100 |
---|---|---|
committer | Ben Elliston <bje@gnu.org> | 2016-03-20 20:22:13 +1100 |
commit | 210f13127ae563fabc31f71e71751a4921ec32ba (patch) | |
tree | 2214ff8edbd2894fba9398f46d4944df53e82938 | |
parent | 77c5f5d7b242ab38e71d81bbfd09e812eb394b6f (diff) | |
download | dejagnu-210f13127ae563fabc31f71e71751a4921ec32ba.zip dejagnu-210f13127ae563fabc31f71e71751a4921ec32ba.tar.gz dejagnu-210f13127ae563fabc31f71e71751a4921ec32ba.tar.bz2 |
* runtest.exp: Load .dejagnurc last not first.
(load_file): Update comment about Tcl 7.5a2.
* doc/user.xml (Customizing DejaGnu): Document new search order
for site.exp files.
* doc/dejagnu.texi: Regenerate.
* NEWS: Update.
-rw-r--r-- | ChangeLog | 9 | ||||
-rw-r--r-- | NEWS | 4 | ||||
-rw-r--r-- | doc/dejagnu.texi | 6 | ||||
-rw-r--r-- | doc/user.xml | 6 | ||||
-rw-r--r-- | runtest.exp | 17 |
5 files changed, 26 insertions, 16 deletions
@@ -1,5 +1,14 @@ 2016-03-20 Ben Elliston <bje@gnu.org> + * runtest.exp: Load .dejagnurc last not first. + (load_file): Update comment about Tcl 7.5a2. + * doc/user.xml (Customizing DejaGnu): Document new search order + for site.exp files. + * doc/dejagnu.texi: Regenerate. + * NEWS: Update. + +2016-03-20 Ben Elliston <bje@gnu.org> + * lib/dg.exp (dg-runtest): Improve arg naming to remove a FIXME. 2016-03-20 Ben Elliston <bje@gnu.org> @@ -15,7 +15,9 @@ Changes since 1.5.3: procedures, a copy of the procedure should be made and placed in the lib directory of the testsuite. 5. Support was added for testing the D compiler. - +6. ~/.dejagnurc is now loaded last, not first. This allows the user to + have the ability to override anything in their environment (even + the site.exp file specified by $DEJAGNU). Changes since 1.4.4: diff --git a/doc/dejagnu.texi b/doc/dejagnu.texi index 99dd8f1..e0a0c41 100644 --- a/doc/dejagnu.texi +++ b/doc/dejagnu.texi @@ -1060,7 +1060,7 @@ it is possible to execute a testsuite merely by typing DejaGnu supports two @file{site.exp} files. The multiple instances of @file{site.exp} are -loaded in a fixed order built into DejaGnu. The first file loaded +loaded in a fixed order. The first file loaded is the local file @file{site.exp}, and then the optional global @file{site.exp} file as pointed to by the @code{DEJAGNU} environment @@ -1090,8 +1090,8 @@ site.exp} in the testsuite directory, after the test suite is configured. You can also have a file in your home directory called -@file{.dejagnurc}. This gets loaded first before the -other config files. Usually this is used for personal stuff, like +@file{.dejagnurc}. This gets loaded after the other +config files. Usually this is used for personal stuff, like setting the @code{all_flag} so all the output gets printed, or your own verbosity levels. This file is usually restricted to setting command line options. diff --git a/doc/user.xml b/doc/user.xml index 2e9bb81..b9c8d51 100644 --- a/doc/user.xml +++ b/doc/user.xml @@ -744,7 +744,7 @@ <para>&dj; supports two <filename>site.exp</filename> files. The multiple instances of <filename>site.exp</filename> are - loaded in a fixed order built into &dj;. The first file loaded + loaded in a fixed order. The first file loaded is the local file <filename>site.exp</filename>, and then the optional global <filename>site.exp</filename> file as pointed to by the <symbol>DEJAGNU</symbol> environment @@ -774,8 +774,8 @@ suite is configured.</para> <para>You can also have a file in your home directory called - <filename>.dejagnurc</filename>. This gets loaded first before the - other config files. Usually this is used for personal stuff, like + <filename>.dejagnurc</filename>. This gets loaded after the other + config files. Usually this is used for personal stuff, like setting the <symbol>all_flag</symbol> so all the output gets printed, or your own verbosity levels. This file is usually restricted to setting command line options.</para> diff --git a/runtest.exp b/runtest.exp index f63e5b3..ccd2a4d 100644 --- a/runtest.exp +++ b/runtest.exp @@ -307,9 +307,8 @@ proc load_file { args } { set found 0 foreach file [lrange $args $i end] { verbose "Looking for $file" 2 - # In Tcl7.5a2, "file exists" can fail if the filename looks - # like ~/FILE and the environment variable HOME does not - # exist. + # In Tcl, "file exists" fails if the filename looks like + # ~/FILE and the environment variable HOME does not exist. if {! [catch {file exists $file} result] && $result} { set found 1 verbose "Found $file" @@ -614,17 +613,14 @@ verbose "Login name is $logname" # All are sourced in order. # # Search order: -# $HOME/.dejagnurc -> $base_dir/$configfile -> $objdir/$configfile -# -> installed -> $DEJAGNU -# -# ??? It might be nice to do $HOME last as it would allow it to be the -# ultimate override. Though at present there is still $DEJAGNU. +# $base_dir/$configfile -> $objdir/$configfile -> +# installed -> $DEJAGNU -> $HOME/.dejagnurc # # For the normal case, we rely on $base_dir/$configfile to set # host_triplet and target_triplet. # -load_file ~/.dejagnurc $base_dir/$configfile +load_file $base_dir/$configfile # # If objdir didn't get set in $base_dir/$configfile, set it to $base_dir. @@ -881,6 +877,9 @@ if {[info exists env(DEJAGNU)]} { } } +# Load user .dejagnurc file last as the ultimate override. +load_file ~/.dejagnurc + if {![info exists boards_dir]} { set boards_dir "" } |