configure.in: Build .gdbinit for top level build dir here.
authorDoug Evans <dje@gnu.org>
Sat, 2 Aug 1997 20:10:47 +0000 (20:10 +0000)
committerDoug Evans <dje@gnu.org>
Sat, 2 Aug 1997 20:10:47 +0000 (20:10 +0000)
* configure.in: Build .gdbinit for top level build dir here.
(AC_OUTPUT): Pass oldstyle_subdirs to configure.lang.

From-SVN: r14630

gcc/configure.in

index 4a92d77..6656d09 100644 (file)
@@ -3009,6 +3009,24 @@ do
        echo "lang.$t: $x" >> Make-hooks
 done
 
+# If we're not building in srcdir, create .gdbinit.
+
+if [[ ! -f Makefile.in ]]; then
+       echo "dir ." > .gdbinit
+       echo "dir ${srcdir}" >> .gdbinit
+       if [[ x$gdb_needs_out_file_path = xyes ]]
+       then
+               echo "dir ${srcdir}/config/"`dirname ${out_file}` >> .gdbinit
+       fi
+       if [[ "x$subdirs" != x ]]; then
+               for s in $subdirs
+               do
+                       echo "dir ${srcdir}/$s" >> .gdbinit
+               done
+       fi
+       echo "source ${srcdir}/.gdbinit" >> .gdbinit
+fi
+
 # Process the language and host/target makefile fragments.
 ${CONFIG_SHELL-/bin/sh} $srcdir/configure.frag $srcdir "$subdirs" "$dep_host_xmake_file" "$dep_tmake_file"
 
@@ -3107,6 +3125,7 @@ target='${target}'
 target_alias='${target_alias}'
 srcdir='${srcdir}'
 subdirs='${subdirs}'
+oldstyle_subdirs='${oldstyle_subdirs}'
 symbolic_link='${symbolic_link}'
 program_transform_set='${program_transform_set}'
 program_transform_name='${program_transform_name}'