The Linaro CI reported a regression in test-case
gdb.dwarf2/macro-source-path-clang14-dw4.exp due to recent commit
81e5a23c7b8
("[gdb/testsuite] Fix require dwarf2_support check in some test-cases").
The problem is that the "require dwarf2_support" in its new location doesn't
work because proc dwarf2_support is not defined.
I didn't notice this because I tested all gdb.dwarf2 test-cases together, and
a different test-case had already imported the proc.
Fix this by moving load_lib dwarf.exp earlier.
Tested on x86_64-linux.
# Generate binaries imitating different ways source file paths can be passed to
# compilers. Test printing macros from those binaries.
+load_lib dwarf.exp
+
require dwarf2_support
# The do_test proc comes from macro-source-path.exp.tcl.
# Generate binaries imitating different ways source file paths can be passed to
# compilers. Test printing macros from those binaries.
+load_lib dwarf.exp
+
require dwarf2_support
# The do_test proc comes from macro-source-path.exp.tcl.
# Generate binaries imitating different ways source file paths can be passed to
# compilers. Test printing macros from those binaries.
+load_lib dwarf.exp
+
require dwarf2_support
# The do_test proc comes from macro-source-path.exp.tcl.
# Generate binaries imitating different ways source file paths can be passed to
# compilers. Test printing macros from those binaries.
+load_lib dwarf.exp
+
require dwarf2_support
# The do_test proc comes from macro-source-path.exp.tcl.
# Generate binaries imitating different ways source file paths can be passed to
# compilers. Test printing macros from those binaries.
+load_lib dwarf.exp
+
require dwarf2_support
# The do_test proc comes from macro-source-path.exp.tcl.
# The entry points for this test are in the various
# gdb.dwarf2/macro-source-path-*.exp files.
-load_lib dwarf.exp
-
standard_testfile macro-source-path.c
lassign [function_range main $srcdir/$subdir/$srcfile] \