mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2026-09-25 22:54:54 +08:00
Adding the infrastructure for gdb.
This commit is contained in:
+6
-5
@@ -1,4 +1,4 @@
|
||||
# Makefile.in generated automatically by automake 1.4 from Makefile.am
|
||||
# Makefile.in generated automatically by automake 1.4a from Makefile.am
|
||||
|
||||
# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
|
||||
# This Makefile.in is free software; the Free Software Foundation
|
||||
@@ -46,9 +46,10 @@ AUTOMAKE = @AUTOMAKE@
|
||||
AUTOHEADER = @AUTOHEADER@
|
||||
|
||||
INSTALL = @INSTALL@
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@ $(AM_INSTALL_PROGRAM_FLAGS)
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||
INSTALL_STRIP_FLAG =
|
||||
transform = @program_transform_name@
|
||||
|
||||
NORMAL_INSTALL = :
|
||||
@@ -98,7 +99,7 @@ mkinstalldirs
|
||||
|
||||
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
|
||||
|
||||
TAR = tar
|
||||
TAR = gtar
|
||||
GZIP_ENV = --best
|
||||
all: all-redirect
|
||||
.SUFFIXES:
|
||||
@@ -251,7 +252,7 @@ distdir: $(DISTFILES)
|
||||
@for file in $(DISTFILES); do \
|
||||
d=$(srcdir); \
|
||||
if test -d $$d/$$file; then \
|
||||
cp -pr $$/$$file $(distdir)/$$file; \
|
||||
cp -pr $$d/$$file $(distdir)/$$file; \
|
||||
else \
|
||||
test -f $(distdir)/$$file \
|
||||
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
|
||||
@@ -290,7 +291,7 @@ uninstall: uninstall-recursive
|
||||
all-am: Makefile $(SCRIPTS) $(DATA)
|
||||
all-redirect: all-recursive
|
||||
install-strip:
|
||||
$(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install
|
||||
$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
|
||||
installdirs: installdirs-recursive
|
||||
installdirs-am:
|
||||
|
||||
|
||||
Vendored
+3
-1
@@ -1,4 +1,4 @@
|
||||
dnl aclocal.m4 generated automatically by aclocal 1.4
|
||||
dnl aclocal.m4 generated automatically by aclocal 1.4a
|
||||
|
||||
dnl Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
|
||||
dnl This file is free software; the Free Software Foundation
|
||||
@@ -21,6 +21,8 @@ dnl AM_INIT_AUTOMAKE(package,version, [no-define])
|
||||
|
||||
AC_DEFUN(AM_INIT_AUTOMAKE,
|
||||
[AC_REQUIRE([AC_PROG_INSTALL])
|
||||
dnl We require 2.13 because we rely on SHELL being computed by configure.
|
||||
AC_PREREQ([2.13])
|
||||
PACKAGE=[$1]
|
||||
AC_SUBST(PACKAGE)
|
||||
VERSION=[$2]
|
||||
|
||||
Vendored
+14
-9
@@ -689,6 +689,7 @@ else
|
||||
fi
|
||||
|
||||
|
||||
|
||||
PACKAGE=scripts
|
||||
|
||||
VERSION=19991020-0
|
||||
@@ -701,7 +702,7 @@ fi
|
||||
|
||||
missing_dir=`cd $ac_aux_dir && pwd`
|
||||
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
|
||||
echo "configure:705: checking for working aclocal" >&5
|
||||
echo "configure:706: checking for working aclocal" >&5
|
||||
# Run test in a subshell; some versions of sh will print an error if
|
||||
# an executable is not found, even if stderr is redirected.
|
||||
# Redirect stdin to placate older versions of autoconf. Sigh.
|
||||
@@ -714,7 +715,7 @@ else
|
||||
fi
|
||||
|
||||
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
|
||||
echo "configure:718: checking for working autoconf" >&5
|
||||
echo "configure:719: checking for working autoconf" >&5
|
||||
# Run test in a subshell; some versions of sh will print an error if
|
||||
# an executable is not found, even if stderr is redirected.
|
||||
# Redirect stdin to placate older versions of autoconf. Sigh.
|
||||
@@ -727,7 +728,7 @@ else
|
||||
fi
|
||||
|
||||
echo $ac_n "checking for working automake""... $ac_c" 1>&6
|
||||
echo "configure:731: checking for working automake" >&5
|
||||
echo "configure:732: checking for working automake" >&5
|
||||
# Run test in a subshell; some versions of sh will print an error if
|
||||
# an executable is not found, even if stderr is redirected.
|
||||
# Redirect stdin to placate older versions of autoconf. Sigh.
|
||||
@@ -740,7 +741,7 @@ else
|
||||
fi
|
||||
|
||||
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
|
||||
echo "configure:744: checking for working autoheader" >&5
|
||||
echo "configure:745: checking for working autoheader" >&5
|
||||
# Run test in a subshell; some versions of sh will print an error if
|
||||
# an executable is not found, even if stderr is redirected.
|
||||
# Redirect stdin to placate older versions of autoconf. Sigh.
|
||||
@@ -753,7 +754,7 @@ else
|
||||
fi
|
||||
|
||||
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
|
||||
echo "configure:757: checking for working makeinfo" >&5
|
||||
echo "configure:758: checking for working makeinfo" >&5
|
||||
# Run test in a subshell; some versions of sh will print an error if
|
||||
# an executable is not found, even if stderr is redirected.
|
||||
# Redirect stdin to placate older versions of autoconf. Sigh.
|
||||
@@ -774,16 +775,16 @@ test -f ./setup.cache || cp ./setup.def ./setup.cache
|
||||
# redhat uses /usr/src/redhat
|
||||
# others might use /usr/src
|
||||
echo $ac_n "checking for rpm SPECS directory""... $ac_c" 1>&6
|
||||
echo "configure:778: checking for rpm SPECS directory" >&5
|
||||
echo "configure:779: checking for rpm SPECS directory" >&5
|
||||
if test -d /usr/src/packages/SPECS;
|
||||
then
|
||||
RPM_SPECSdir=/usr/src/packages/SPECS;
|
||||
RPM_SPECSdir=/usr/src/packages/SPECS;
|
||||
elif test -d /usr/src/redhat/SPECS;
|
||||
then
|
||||
RPM_SPECSdirs=/usr/src/redhat/SPECS;
|
||||
RPM_SPECSdir=/usr/src/redhat/SPECS;
|
||||
elif test -d /usr/src/SPECS/;
|
||||
then
|
||||
RPM_SPECSdir=/usr/src/SPECS;
|
||||
RPM_SPECSdir=/usr/src/SPECS;
|
||||
fi
|
||||
if test x"$RPM_SPECSdir" = x; then
|
||||
{ echo "configure: error: not found" 1>&2; exit 1; }
|
||||
@@ -914,8 +915,10 @@ ac_given_INSTALL="$INSTALL"
|
||||
trap 'rm -fr `echo "Makefile
|
||||
mkbinutilspec
|
||||
mkgccnewlibspec
|
||||
mkgdbspec
|
||||
binutils/Makefile
|
||||
gccnewlib/Makefile
|
||||
gdb/Makefile
|
||||
" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
|
||||
EOF
|
||||
cat >> $CONFIG_STATUS <<EOF
|
||||
@@ -1007,8 +1010,10 @@ cat >> $CONFIG_STATUS <<EOF
|
||||
CONFIG_FILES=\${CONFIG_FILES-"Makefile
|
||||
mkbinutilspec
|
||||
mkgccnewlibspec
|
||||
mkgdbspec
|
||||
binutils/Makefile
|
||||
gccnewlib/Makefile
|
||||
gdb/Makefile
|
||||
"}
|
||||
EOF
|
||||
cat >> $CONFIG_STATUS <<\EOF
|
||||
|
||||
@@ -35,6 +35,8 @@ AC_OUTPUT(
|
||||
Makefile
|
||||
mkbinutilspec
|
||||
mkgccnewlibspec
|
||||
mkgdbspec
|
||||
binutils/Makefile
|
||||
gccnewlib/Makefile
|
||||
gdb/Makefile
|
||||
)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Makefile.in generated automatically by automake 1.4 from Makefile.am
|
||||
# Makefile.in generated automatically by automake 1.4a from Makefile.am
|
||||
|
||||
# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
|
||||
# This Makefile.in is free software; the Free Software Foundation
|
||||
@@ -46,9 +46,10 @@ AUTOMAKE = @AUTOMAKE@
|
||||
AUTOHEADER = @AUTOHEADER@
|
||||
|
||||
INSTALL = @INSTALL@
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@ $(AM_INSTALL_PROGRAM_FLAGS)
|
||||
INSTALL_PROGRAM = @INSTALL_PROGRAM@
|
||||
INSTALL_DATA = @INSTALL_DATA@
|
||||
INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||
INSTALL_STRIP_FLAG =
|
||||
transform = @program_transform_name@
|
||||
|
||||
NORMAL_INSTALL = :
|
||||
@@ -94,7 +95,7 @@ DIST_COMMON = Makefile.am Makefile.in
|
||||
|
||||
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
|
||||
|
||||
TAR = tar
|
||||
TAR = gtar
|
||||
GZIP_ENV = --best
|
||||
all: all-redirect
|
||||
.SUFFIXES:
|
||||
@@ -136,7 +137,7 @@ distdir: $(DISTFILES)
|
||||
@for file in $(DISTFILES); do \
|
||||
d=$(srcdir); \
|
||||
if test -d $$d/$$file; then \
|
||||
cp -pr $$/$$file $(distdir)/$$file; \
|
||||
cp -pr $$d/$$file $(distdir)/$$file; \
|
||||
else \
|
||||
test -f $(distdir)/$$file \
|
||||
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
|
||||
@@ -165,7 +166,7 @@ uninstall: uninstall-am
|
||||
all-am: Makefile $(DATA)
|
||||
all-redirect: all-am
|
||||
install-strip:
|
||||
$(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install
|
||||
$(MAKE) $(AM_MAKEFLAGS) INSTALL_STRIP_FLAG=-s install
|
||||
installdirs:
|
||||
$(mkinstalldirs) $(DESTDIR)$(RPM_SPECSdir)
|
||||
|
||||
|
||||
+13
-5
@@ -19,10 +19,10 @@ Provides: @target_alias@-gdb
|
||||
Autoreqprov: on
|
||||
Packager: corsepiu@faw.uni-ulm.de and joel@OARcorp.com
|
||||
|
||||
Version: @Version@
|
||||
Version: gdb@gdb_version@
|
||||
Summary: gdb for target @target_alias@
|
||||
Source0: gdb-4.18.tar.gz
|
||||
Patch0: gdb-4.18-rtems-19991015.diff
|
||||
Source0: gdb-@gdb_version@.tar.gz
|
||||
Patch0: gdb-@gdb_version@-rtems-@gdb_patch_version@.diff
|
||||
|
||||
Buildroot: /tmp
|
||||
# Patch:
|
||||
@@ -37,7 +37,7 @@ Authors:
|
||||
...
|
||||
|
||||
%prep
|
||||
# untar the sources inside @target_alias@-gdb-@Version@
|
||||
# untar the sources inside @target_alias@-gdb
|
||||
%setup -c -n @target_alias@-gdb -a 0
|
||||
|
||||
%patch0 -p0
|
||||
@@ -45,7 +45,7 @@ Authors:
|
||||
%build
|
||||
test -d build || mkdir build
|
||||
( cd build
|
||||
../gdb-4.18/configure --target=@target_alias@ \
|
||||
../gdb-@gdb_version@/configure --target=@target_alias@ \
|
||||
--verbose --prefix=/opt/rtems
|
||||
|
||||
test -d $RPM_BUILD_ROOT/opt \
|
||||
@@ -64,6 +64,14 @@ test -d build || mkdir build
|
||||
)
|
||||
|
||||
%files
|
||||
%dir /opt/rtems
|
||||
%dir /opt/rtems/bin
|
||||
%dir /opt/rtems/include
|
||||
%dir /opt/rtems/info
|
||||
%dir /opt/rtems/lib
|
||||
%dir /opt/rtems/man
|
||||
%dir /opt/rtems/man/man1
|
||||
|
||||
%doc /opt/rtems/info/gdb.info*
|
||||
%doc /opt/rtems/info/mmalloc.info*
|
||||
%doc /opt/rtems/info/readline.info*
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
RTEMS_DIR=`dirname $0`
|
||||
|
||||
CFG=user.cfg
|
||||
dst=/usr/src/packages/SPECS
|
||||
dst=/usr/src/redhat/SPECS
|
||||
|
||||
usage()
|
||||
{
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
RTEMS_DIR=`dirname $0`
|
||||
|
||||
CFG=user.cfg
|
||||
dst=/usr/src/packages/SPECS
|
||||
dst=/usr/src/redhat/SPECS
|
||||
|
||||
usage()
|
||||
{
|
||||
|
||||
+42
-20
@@ -1,33 +1,55 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# Usage: mktoolspec CPU
|
||||
# Usage: mkgdbspec CPU
|
||||
#
|
||||
|
||||
RTEMS_DIR=`dirname $0`
|
||||
RTEMS_VERSION=`grep Version ${RTEMS_DIR}/../VERSION | \
|
||||
sed -e 's%RTEMS[ ]*Version[ ]*\(.*\)[ ]*%\1%g'`
|
||||
CFG=user.cfg
|
||||
dst=/usr/src/redhat/SPECS
|
||||
|
||||
target_alias=$1
|
||||
release=0
|
||||
usage()
|
||||
|
||||
# Some linux distributions use /usr/src/packages
|
||||
# redhat uses /usr/src/redhat
|
||||
# others might use /usr/src
|
||||
if test -d /usr/src/packages/SPECS;
|
||||
echo "$0 [options] <target_alias>"
|
||||
echo " options:"
|
||||
echo " -cfg <user.cfg>"
|
||||
echo " -o <rpm-spec-dir>"
|
||||
exit 1 ;
|
||||
|
||||
|
||||
while test $# -ge 2; do
|
||||
case $1 in
|
||||
-cfg)
|
||||
shift
|
||||
CFG=$1
|
||||
shift
|
||||
;;
|
||||
-o)
|
||||
shift
|
||||
dst=$1
|
||||
shift
|
||||
;;
|
||||
-*)
|
||||
echo "invalid option $1";
|
||||
usage
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
if test ! $# -eq 1;
|
||||
then
|
||||
dst=/usr/src/packages/SPECS;
|
||||
elif test -d /usr/src/redhat/SPECS;
|
||||
then
|
||||
dst=/usr/src/redhat/SPECS;
|
||||
elif test -d /usr/src/SPECS/;
|
||||
then
|
||||
dst=/usr/src/SPECS;
|
||||
echo "Invalid number of arguments"
|
||||
usage
|
||||
fi
|
||||
|
||||
sed -e "s%@Version@%${RTEMS_VERSION}%g" \
|
||||
-e "s%@bsp@%${bsp}%g" \
|
||||
-e "s%@Release@%${release}%g" \
|
||||
-e "s%@target_alias@%${target_alias}%g" \
|
||||
# target to build for
|
||||
target_alias=$1
|
||||
|
||||
rpm_release=0
|
||||
|
||||
sed -e "s%@Release@%${rpm_release}%g" \
|
||||
-e "s%@target_alias@%${target_alias}%g" \
|
||||
-e "s%@gdb_version@%${gdb_version}%g" \
|
||||
-e "s%@gdb_patch_version@%${gdb_patch_version}%g" \
|
||||
< ${RTEMS_DIR}/gdb.spec.in \
|
||||
> ${dst}/$target_alias-gdb.spec
|
||||
|
||||
|
||||
@@ -0,0 +1,67 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# Usage: mkgdbspec CPU
|
||||
#
|
||||
|
||||
RTEMS_DIR=`dirname $0`
|
||||
CFG=user.cfg
|
||||
dst=@RPM_SPECSdir@
|
||||
|
||||
usage()
|
||||
|
||||
echo "$0 [options] <target_alias>"
|
||||
echo " options:"
|
||||
echo " -cfg <user.cfg>"
|
||||
echo " -o <rpm-spec-dir>"
|
||||
exit 1 ;
|
||||
|
||||
|
||||
while test $# -ge 2; do
|
||||
case $1 in
|
||||
-cfg)
|
||||
shift
|
||||
CFG=$1
|
||||
shift
|
||||
;;
|
||||
-o)
|
||||
shift
|
||||
dst=$1
|
||||
shift
|
||||
;;
|
||||
-*)
|
||||
echo "invalid option $1";
|
||||
usage
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
if test ! $# -eq 1;
|
||||
then
|
||||
echo "Invalid number of arguments"
|
||||
usage
|
||||
fi
|
||||
|
||||
# target to build for
|
||||
target_alias=$1
|
||||
|
||||
rpm_release=0
|
||||
|
||||
sed -e "s%@Release@%${rpm_release}%g" \
|
||||
-e "s%@target_alias@%${target_alias}%g" \
|
||||
-e "s%@gdb_version@%${gdb_version}%g" \
|
||||
-e "s%@gdb_patch_version@%${gdb_patch_version}%g" \
|
||||
< ${RTEMS_DIR}/gdb.spec.in \
|
||||
> ${dst}/$target_alias-gdb.spec
|
||||
|
||||
case ${target} in
|
||||
powerpc*)
|
||||
echo "/opt/rtems/bin/@target_alias@-run"
|
||||
;;
|
||||
sparc*)
|
||||
echo "/opt/rtems/bin/@target_alias@-run"
|
||||
echo "/opt/rtems/bin/@target_alias@-sis"
|
||||
;;
|
||||
*) ;;
|
||||
esac >> ${dst}/$target_alias-gdb.spec
|
||||
|
||||
echo Generated ${dst}/$target_alias-gdb.spec.
|
||||
Reference in New Issue
Block a user