ld: map option for run_dump_test requires no program.
authorAndrew Burgess <andrew.burgess@embecosm.com>
Tue, 28 Jul 2015 18:14:37 +0000 (19:14 +0100)
committerAndrew Burgess <andrew.burgess@embecosm.com>
Tue, 4 Aug 2015 10:25:37 +0000 (11:25 +0100)
When using run_dump_test with the map option to compare the linker map
file produced, no additional dump program should be required.  A dump
program can still be given if needed, but leaving it off will no longer
produce an error.

ld/testsuite/ChangeLog:

* ld/ld-lib.exp (run_dump_test): When using the map option, no
program is required.

ld/testsuite/ChangeLog
ld/testsuite/lib/ld-lib.exp

index aaecbeb25ce54b7d224a2bed6cd1b71466480078..727bcaded7768a48b0c54a6b2e5767bb7c37438f 100644 (file)
@@ -1,3 +1,8 @@
+2015-08-04  Andrew Burgess  <andrew.burgess@embecosm.com>
+
+       * ld/ld-lib.exp (run_dump_test): When using the map option, no
+       program is required.
+
 2015-08-04  Andrew Burgess  <andrew.burgess@embecosm.com>
 
        * ld/ld-lib.exp (run_dump_test): Add error_output and
index 8bb06ff5238c6219cc04f60e4c98e49554dae3dc..6904499a10d97370f03de6c10c00b7c317ddefba 100644 (file)
@@ -761,6 +761,7 @@ proc run_dump_test { name {extra_options {}} } {
            }
        }
        if { $program == "" \
+                 && $opts(map) == "" \
                  && $opts(warning) == "" \
                  && $opts(warning_output) == "" \
                  && $opts(error) == "" \
@@ -995,6 +996,10 @@ proc run_dump_test { name {extra_options {}} } {
             } else {
                 pass "$testname (map file check)"
             }
+
+            if { $program == "" } then {
+                return
+            }
         }
     } else {
        set objfile "tmpdir/dump0.o"