Index: lib/ada.exp =================================================================== RCS file: /cvs/src/src/gdb/testsuite/lib/ada.exp,v retrieving revision 1.3 diff -u -p -r1.3 ada.exp --- lib/ada.exp 1 Apr 2004 18:42:08 -0000 1.3 +++ lib/ada.exp 2 Feb 2005 13:44:41 -0000 @@ -409,12 +409,16 @@ if {[info procs find_gnatmake] == ""} { proc gdb_compile_ada {source dest type options} { + set srcdir [file dirname $source] + set gprdir [file dirname $srcdir] set objdir [file dirname $dest] append options " ada" - append options " additional_flags=-P$objdir/gnat_ada" + append options " additional_flags=-P$gprdir/gnat_ada" + append options " additional_flags=-XSRC=[file tail $srcdir]" + append options " additional_flags=-XOBJ=$objdir" - set result [target_compile $source $dest $type $options] + set result [target_compile [file tail $source] $dest $type $options] # The Ada build always produces some output, even when the build # succeeds. Thus, we can not use the output the same way we do in Index: configure.ac =================================================================== RCS file: /cvs/src/src/gdb/testsuite/configure.ac,v retrieving revision 1.1 diff -u -p -r1.1 configure.ac --- configure.ac 7 Jan 2005 21:53:23 -0000 1.1 +++ configure.ac 2 Feb 2005 13:42:41 -0000 @@ -109,7 +109,7 @@ AC_CHECK_HEADERS(pthread.h) AC_EXEEXT AC_OUTPUT([Makefile \ - gdb.ada/Makefile gdb.ada/gnat_ada.gpr:gdb.ada/gnat_ada.gin \ + gdb.ada/Makefile \ gdb.arch/Makefile gdb.asm/Makefile gdb.base/Makefile \ gdb.cp/Makefile gdb.disasm/Makefile gdb.dwarf2/Makefile \ gdb.fortran/Makefile gdb.java/Makefile gdb.mi/Makefile \ Index: gdb.ada/Makefile.in =================================================================== RCS file: /cvs/src/src/gdb/testsuite/gdb.ada/Makefile.in,v retrieving revision 1.1 diff -u -p -r1.1 Makefile.in --- gdb.ada/Makefile.in 1 Apr 2004 00:53:50 -0000 1.1 +++ gdb.ada/Makefile.in 2 Feb 2005 13:44:41 -0000 @@ -1,7 +1,7 @@ VPATH = @srcdir@ srcdir = @srcdir@ -EXECUTABLES = null_record +EXECUTABLES = null_record/null_record fixed_points/fixed_points MISCELLANEOUS = @@ -9,13 +9,16 @@ all info install-info dvi install uninst @echo "Nothing to be done for $@..." clean mostlyclean: - -gnatclean -Pgnat_ada -q $(EXECUTABLES) + -find . -name '*.o' -print | xargs rm -f + -find . -name '*.ali' -print | xargs rm -f + -find . -name 'b~*.ad[sb]' -print | xargs rm -f + -rm -f *~ a.out xgdb *.x *.ci *.tmp -rm -f *~ *.o a.out xgdb *.x *.ci *.tmp -rm -f core core.coremaker coremaker.core corefile $(EXECUTABLES) -rm -f $(MISCELLANEOUS) twice-tmp.c distclean maintainer-clean realclean: clean -rm -f *~ core - -rm -f Makefile config.status config.log gnat_ada.gpr + -rm -f Makefile config.status config.log -rm -f *-init.exp -rm -fr *.log summary detail *.plog *.sum *.psum site.* Index: gdb.ada/null_record.exp =================================================================== RCS file: /cvs/src/src/gdb/testsuite/gdb.ada/null_record.exp,v retrieving revision 1.4 diff -u -p -r1.4 null_record.exp --- gdb.ada/null_record.exp 21 Oct 2004 03:55:07 -0000 1.4 +++ gdb.ada/null_record.exp 2 Feb 2005 13:44:41 -0000 @@ -21,8 +21,9 @@ if $tracelevel then { load_lib "ada.exp" -set testfile "null_record" -set srcfile ${testfile}.adb +set testdir "null_record" +set testfile "${testdir}/null_record" +set srcfile ${srcdir}/${subdir}/${testfile}.adb set binfile ${objdir}/${subdir}/${testfile} if {[gdb_compile_ada "${srcfile}" "${binfile}" executable [list debug ]] != "" } { Index: gdb.ada/fixed_points.exp =================================================================== RCS file: /cvs/src/src/gdb/testsuite/gdb.ada/fixed_points.exp,v retrieving revision 1.1 diff -u -p -r1.1 fixed_points.exp --- gdb.ada/fixed_points.exp 13 Dec 2004 16:04:20 -0000 1.1 +++ gdb.ada/fixed_points.exp 2 Feb 2005 13:44:41 -0000 @@ -21,8 +21,9 @@ if $tracelevel then { load_lib "ada.exp" -set testfile "fixed_points" -set srcfile ${testfile}.adb +set testdir "fixed_points" +set testfile "${testdir}/fixed_points" +set srcfile ${srcdir}/${subdir}/${testfile}.adb set binfile ${objdir}/${subdir}/${testfile} if {[gdb_compile_ada "${srcfile}" "${binfile}" executable [list debug ]] != "" } { @@ -34,8 +35,8 @@ gdb_start gdb_reinitialize_dir $srcdir/$subdir gdb_load ${binfile} -set bp_location [gdb_get_line_number "Set breakpoint here"] -runto "${srcfile}:$bp_location" +set bp_location [gdb_get_line_number "Set breakpoint here" ${testdir}/fixed_points.adb] +runto "fixed_points.adb:$bp_location" gdb_test "print base_object" \ ".* = -50" \