[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] Add a helper for board entries that are lists
From: |
Maciej W. Rozycki |
Subject: |
[PATCH] Add a helper for board entries that are lists |
Date: |
Tue, 10 Jun 2014 19:27:07 +0100 |
User-agent: |
Alpine 1.10 (DEB 962 2008-03-14) |
Hi,
This change in conjunction with the GDB test suite stuff posted here:
http://sourceware.org/ml/gdb-patches/2014-06/msg00426.html
has been used successfully since 2005, unchanged since its inception
(hence my old e-mail address giving correct credit). It adds a helper for
easy maintenance of board entries that are lists, e.g. you'd use:
add_board_info gdb_init_commands "set remotetimeout 5"
add_board_info gdb_init_commands "set debug remote 2"
to have a two-element `gdb_init_commands' list. This is especially useful
in cases where individual list elements are added in different scripts.
Would you please consider applying it?
2014-06-10 Maciej W. Rozycki <address@hidden>
* lib/targetdb.exp (add_board_info): New procedure.
Maciej
dejagnu-add-board-info.diff
diff --git a/lib/targetdb.exp b/lib/targetdb.exp
index da5c40f..93c4876 100644
--- a/lib/targetdb.exp
+++ b/lib/targetdb.exp
@@ -73,6 +73,15 @@ proc set_board_info { entry value } {
}
}
+#
+# Add VALUE to ENTRY for the current board being defined.
+#
+proc add_board_info { entry value } {
+ global board_info board;
+
+ lappend board_info($board,$entry) $value;
+}
+
# Fill in ENTRY with VALUE for the current target.
#
proc set_currtarget_info { entry value } {
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [PATCH] Add a helper for board entries that are lists,
Maciej W. Rozycki <=