1995-05-31 22:21:32 +00:00
|
|
|
dnl Process this file with autoconf to produce a configure script.
|
|
|
|
AC_PREREQ(2.3)dnl
|
|
|
|
AC_INIT(gdbserve.c)
|
1994-03-25 01:38:12 +00:00
|
|
|
|
1995-05-31 22:21:32 +00:00
|
|
|
AC_CONFIG_AUX_DIR(`cd $srcdir;pwd`/../..)
|
|
|
|
AC_CANONICAL_SYSTEM
|
|
|
|
AC_ARG_PROGRAM
|
1994-03-25 01:38:12 +00:00
|
|
|
|
1995-05-31 22:21:32 +00:00
|
|
|
AC_PROG_INSTALL
|
1994-03-25 01:38:12 +00:00
|
|
|
|
|
|
|
# Map target cpu into the config cpu subdirectory name.
|
|
|
|
# The default is $target_cpu.
|
1995-05-31 22:21:32 +00:00
|
|
|
changequote(,)dnl
|
1994-03-25 01:38:12 +00:00
|
|
|
case "${target_cpu}" in
|
|
|
|
alpha) gdb_target_cpu=alpha ;;
|
|
|
|
c[12]) gdb_target_cpu=convex ;;
|
|
|
|
hppa*) gdb_target_cpu=pa ;;
|
1994-08-24 17:12:57 +00:00
|
|
|
i[345]86) gdb_target_cpu=i386 ;;
|
1994-03-25 01:38:12 +00:00
|
|
|
m68*) gdb_target_cpu=m68k ;;
|
|
|
|
np1) gdb_target_cpu=gould ;;
|
|
|
|
pn) gdb_target_cpu=gould ;;
|
|
|
|
pyramid) gdb_target_cpu=pyr ;;
|
|
|
|
sparc*) gdb_target_cpu=sparc ;;
|
|
|
|
*) gdb_target_cpu=$target_cpu ;;
|
|
|
|
esac
|
1995-05-31 22:21:32 +00:00
|
|
|
changequote([,])dnl
|
1994-03-25 01:38:12 +00:00
|
|
|
|
1995-05-31 19:31:20 +00:00
|
|
|
target_makefile_frag=${srcdir}/../config/${gdb_target_cpu}/gdbserve.mt
|
|
|
|
if [ ! -f ${target_makefile_frag} ]; then
|
1995-05-31 22:21:32 +00:00
|
|
|
AC_MSG_ERROR("*** GDBSERVE does not support target ${target}")
|
1994-03-25 01:38:12 +00:00
|
|
|
fi
|
|
|
|
|
1995-05-31 22:21:32 +00:00
|
|
|
dnl We have to assign the same value to other variables because autoconf
|
|
|
|
dnl doesn't provide a mechanism to substitute a replacement keyword with
|
|
|
|
dnl arbitrary data or pathnames.
|
|
|
|
dnl
|
|
|
|
target_makefile_frag_path=$target_makefile_frag
|
|
|
|
AC_SUBST(target_makefile_frag_path)
|
|
|
|
AC_SUBST_FILE(target_makefile_frag)
|
|
|
|
|
1995-05-31 19:31:20 +00:00
|
|
|
cpufile=`sed -n '
|
|
|
|
s/CPU_FILE[ ]*=[ ]*\([^ ]*\)/\1/p
|
|
|
|
' ${target_makefile_frag}
|
1994-03-25 01:38:12 +00:00
|
|
|
|
|
|
|
files=
|
|
|
|
links=
|
1994-08-29 22:02:57 +00:00
|
|
|
rm -f cpu.h
|
1994-08-18 06:32:55 +00:00
|
|
|
if [ "${cpufile}" != "" ]; then
|
1994-08-29 22:02:57 +00:00
|
|
|
files="${files} ${cpufile}.h"
|
|
|
|
links="${links} cpu.h"
|
1994-03-25 01:38:12 +00:00
|
|
|
fi
|
1995-05-31 22:21:32 +00:00
|
|
|
|
|
|
|
AC_LINK_FILES($files, $links)
|
|
|
|
AC_OUTPUT(Makefile)
|
|
|
|
|