aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/boards/cc-with-tweaks.exp
AgeCommit message (Collapse)AuthorFilesLines
2019-09-10Add Ada support to cc-with-tweaks.expTom Tromey1-0/+5
This adds Ada support to the cc-with-tweaks.exp board file, so that we can test Ada this way. The cc-with-tweaks.sh script already works reasonably well as a wrapper for gnatmake. gdb/testsuite/ChangeLog 2019-09-10 Tom Tromey <tromey@adacore.com> * boards/cc-with-tweaks.exp: Set GNATMAKE_FOR_TARGET.
2019-05-01[gdb/testsuite] Fix "unable to find usable gdb" error with cc-with-tweaks.expTom de Vries1-0/+5
When running fullpath-expand.exp with target_board=dwarf4-gdb-index, we run into: ... $ make check-gdb RUNTESTFLAGS="--target_board=dwarf4-gdb-index fullpath-expand.exp" Running src/gdb/testsuite/gdb.base/fullpath-expand.exp ... gdb compile failed, cc-with-tweaks.sh: unable to find usable gdb === gdb Summary === nr of untested testcases 1 ... The same happens with fullname.exp. The dwarf4-gdb-index.exp board file includes cc-with-tweaks.exp, which uses cc-with-tweaks.sh, which calls gdb-add-index.sh. The gdb-add-index.sh script uses a gdb executable, defaulting to gdb: ... GDB=${GDB:=gdb} ... The cc-with-tweaks.sh script tries to ensure that the build gdb executable is used by gdb-add-index.sh: ... if [ -z "$GDB" ] then if [ -f ./gdb ] then GDB="./gdb -data-directory data-directory" elif [ -f ../gdb ] then GDB="../gdb -data-directory ../data-directory" elif [ -f ../../gdb ] then GDB="../../gdb -data-directory ../../data-directory" else echo "$myname: unable to find usable gdb" >&2 exit 1 fi fi ... So, if the current directory is build/gdb/testsuite, then a gdb executable build/gdb/testsuite/../gdb will be used. However, in the case of fullpath-expand.exp the test cd's into the sources: ... set saved_pwd [pwd] cd $srcdir set err [gdb_compile "${subdir}/${srcfile} ${subdir}/${srcfile2}" $binfile \ executable {debug}] cd $saved_pwd ... and cc-with-tweaks.sh generates the "unable to find usable gdb" error. The same error occurs if we use --target_board=cc-with-dwz instead (only in this case we actually don't need gdb, we just need the GDB variable to be set in cc-with-tweaks.sh, which arguably is a bug in cc-with-tweaks.sh). Fix both errors in cc-with-tweaks.exp by generating a gdb script gdb.sh using $GDB, $GDBFLAGS and $INTERNAL_GDBFLAGS and passing this script to cc-with-tweaks.sh by setting env(GDB). Tested on x86_64-linux for gdb.base. gdb/testsuite/ChangeLog: 2019-05-01 Tom de Vries <tdevries@suse.de> * boards/cc-with-tweaks.exp: Generate gdb.sh, and pass it in env(GDB).
2019-04-11[gdb/testsuite] Add cc-with-dwz.exp and cc-with-dwz-m.expTom de Vries1-0/+4
We can use CC_WITH_TWEAKS_FLAGS when cd-ing into the gdb build subdir and invoking make check: ... $ cd $objdir/gdb $ make check \ RUNTESTFLAGS='--target_board=cc-with-tweaks' \ CC_WITH_TWEAKS_FLAGS='-z' ... But when cd-ing into the top-level build dir and invoking make check-gdb instead: ... $ cd $objdir $ make check-gdb \ RUNTESTFLAGS='--target_board=cc-with-tweaks' \ CC_WITH_TWEAKS_FLAGS='-z' ... using CC_WITH_TWEAKS_FLAGS has no effect, because CC_WITH_TWEAKS_FLAGS is not passed down from the top level Makefile. Add cc-with-dwz.exp and cc-with-dwz-m.exp, that don't require CC_WITH_TWEAKS_FLAGS to be set in the make invocation, allowing us to run these test configurations from the toplevel build dir: ... $ cd $objdir $ make check-gdb \ RUNTESTFLAGS='--target_board=cc-with-dwz' ... Tested on x86_64-linux. gdb/testsuite/ChangeLog: 2019-04-11 Tom de Vries <tdevries@suse.de> * boards/cc-with-dwz-m.exp: New file. * boards/cc-with-dwz.exp: New file. * boards/cc-with-tweaks.exp: Note that check-gdb doesn't work.
2019-01-01Update copyright year range in all GDB files.Joel Brobecker1-1/+1
This commit applies all changes made after running the gdb/copyright.py script. Note that one file was flagged by the script, due to an invalid copyright header (gdb/unittests/basic_string_view/element_access/char/empty.cc). As the file was copied from GCC's libstdc++-v3 testsuite, this commit leaves this file untouched for the time being; a patch to fix the header was sent to gcc-patches first. gdb/ChangeLog: Update copyright year range in all GDB files.
2018-06-20testsuite: Fix cc-with-tweaks.sh being executed in the wrong shellSimon Marchi1-2/+2
The cc-with-tweaks.sh script needs to be executed with bash. When trying to run this: make check RUNTESTFLAGS="--target_board=dwarf4-gdb-index" TESTS="gdb.base/return.exp" I get: gdb compile failed, /home/emaisin/src/binutils-gdb/gdb/contrib/cc-with-tweaks.sh: 174: /home/emaisin/src/binutils-gdb/gdb/contrib/cc-with-tweaks.sh: Bad substitution The reason is that the board files execute cc-with-tweaks.sh using /bin/sh, which points to dash on my machine. Remove the /bin/sh part and let the shebang choose the right interpreter. gdb/testsuite/ChangeLog: * boards/cc-with-tweaks.exp: Don't call cc-with-tweaks.sh through /bin/sh. * boards/dwarf4-gdb-index.exp: Likewise. * boards/fission-dwp.exp: Likewise.
2018-01-02Update copyright year range in all GDB filesJoel Brobecker1-1/+1
gdb/ChangeLog: Update copyright year range in all GDB files
2017-11-30Use boards/local-board.exp moreSimon Marchi1-4/+1
local-board.exp was introduced recently, containing the code required to force the gdbserver boards to be non-remote (from the DejaGNU point of view). Other board files use the same trick of forcing isremote to 0. Instead of doing it by hand in each file, include local-board.exp. gdb/testsuite/ChangeLog: * boards/cc-with-tweaks.exp: Include local-board.exp instead of setting isremote by hand. * boards/dwarf4-gdb-index.exp: Likewise. * boards/fission.exp: Likewise. * boards/stabs.exp: Likewise.
2017-01-01update copyright year range in GDB filesJoel Brobecker1-1/+1
This applies the second part of GDB's End of Year Procedure, which updates the copyright year range in all of GDB's files. gdb/ChangeLog: Update copyright year range in all GDB files.
2016-01-01GDB copyright headers update after running GDB's copyright.py script.Joel Brobecker1-1/+1
gdb/ChangeLog: Update year range in copyright notice of all files.
2015-01-01Update year range in copyright notice of all files owned by the GDB project.Joel Brobecker1-1/+1
gdb/ChangeLog: Update year range in copyright notice of all files.
2014-01-01Update Copyright year range in all files maintained by GDB.Joel Brobecker1-1/+1
2013-01-17 * boards/cc-with-tweaks.exp: New file.Doug Evans1-0/+54