2006-06-05 Shaun Jackman <sjackman@gmail.com>
configure.host (newlib_cflags) [arm, thumb, xscale]: Remove -DABORT_PROVIDED flag. * newlib/libc/sys/arm/syscalls.c (kill, exit): Sync with libgloss. * newlib/libc/sys/arm/libcfunc.c (abort): Ditto.
This commit is contained in:
parent
9a9ac027e8
commit
6ea486a6df
|
@ -1,3 +1,10 @@
|
|||
2006-06-05 Shaun Jackman <sjackman@gmail.com>
|
||||
|
||||
configure.host (newlib_cflags) [arm, thumb, xscale]: Remove
|
||||
-DABORT_PROVIDED flag.
|
||||
* newlib/libc/sys/arm/syscalls.c (kill, exit): Sync with libgloss.
|
||||
* newlib/libc/sys/arm/libcfunc.c (abort): Ditto.
|
||||
|
||||
2006-06-05 Jeff Johnston <jjohnstn@redhat.com>
|
||||
|
||||
* Makefile.am (AM_MAKEFLAGS): Pass CCASFLAGS.
|
||||
|
|
|
@ -510,11 +510,11 @@ case "${host}" in
|
|||
;;
|
||||
arm-*-pe)
|
||||
syscall_dir=syscalls
|
||||
newlib_cflags="${newlib_cflags} -DABORT_PROVIDED -DHAVE_GETTIMEOFDAY"
|
||||
newlib_cflags="${newlib_cflags} -DHAVE_GETTIMEOFDAY"
|
||||
;;
|
||||
arm-*-*)
|
||||
syscall_dir=syscalls
|
||||
newlib_cflags="${newlib_cflags} -DABORT_PROVIDED -DHAVE_GETTIMEOFDAY"
|
||||
newlib_cflags="${newlib_cflags} -DHAVE_GETTIMEOFDAY"
|
||||
# If newlib is supplying syscalls, select which debug protocol is being used.
|
||||
# ARM_RDP_MONITOR selects the Demon monitor.
|
||||
# ARM_RDI_MONITOR selects the Angel monitor.
|
||||
|
@ -553,7 +553,7 @@ case "${host}" in
|
|||
;;
|
||||
ep9312-*-*)
|
||||
syscall_dir=syscalls
|
||||
newlib_cflags="${newlib_cflags} -DABORT_PROVIDED -DHAVE_GETTIMEOFDAY"
|
||||
newlib_cflags="${newlib_cflags} -DHAVE_GETTIMEOFDAY"
|
||||
if [ "x${newlib_may_supply_syscalls}" = "xyes" ] ; then
|
||||
newlib_cflags="${newlib_cflags} -DARM_RDI_MONITOR"
|
||||
fi
|
||||
|
@ -660,16 +660,16 @@ case "${host}" in
|
|||
;;
|
||||
strongarm-*-*)
|
||||
syscall_dir=syscalls
|
||||
newlib_cflags="${newlib_cflags} -DABORT_PROVIDED -DHAVE_GETTIMEOFDAY"
|
||||
newlib_cflags="${newlib_cflags} -DHAVE_GETTIMEOFDAY"
|
||||
;;
|
||||
thumb-*-pe)
|
||||
syscall_dir=syscalls
|
||||
newlib_cflags="${newlib_cflags} -DABORT_PROVIDED -DHAVE_GETTIMEOFDAY"
|
||||
newlib_cflags="${newlib_cflags} -DHAVE_GETTIMEOFDAY"
|
||||
# Don't use the debugging protocols just yet.
|
||||
;;
|
||||
thumb-*-*)
|
||||
syscall_dir=syscalls
|
||||
newlib_cflags="${newlib_cflags} -DABORT_PROVIDED -DHAVE_GETTIMEOFDAY"
|
||||
newlib_cflags="${newlib_cflags} -DHAVE_GETTIMEOFDAY"
|
||||
# If newlib is supplying syscalls, select which debug protocol is being used.
|
||||
# ARM_RDP_MONITOR selects the Demon monitor.
|
||||
# ARM_RDI_MONITOR selects the Angel monitor.
|
||||
|
@ -700,7 +700,7 @@ case "${host}" in
|
|||
;;
|
||||
xscale-*-*)
|
||||
syscall_dir=syscalls
|
||||
newlib_cflags="${newlib_cflags} -DABORT_PROVIDED -DHAVE_GETTIMEOFDAY"
|
||||
newlib_cflags="${newlib_cflags} -DHAVE_GETTIMEOFDAY"
|
||||
newlib_cflags="${newlib_cflags} -DHAVE_SYSTEM -DHAVE_RENAME"
|
||||
if [ "x${newlib_may_supply_syscalls}" = "xyes" ] ; then
|
||||
newlib_cflags="${newlib_cflags} -DARM_RDI_MONITOR"
|
||||
|
|
|
@ -23,17 +23,6 @@ do_AngelSWI (int reason, void * arg)
|
|||
#endif /* ARM_RDI_MONITOR */
|
||||
|
||||
|
||||
void
|
||||
abort (void)
|
||||
{
|
||||
#ifdef ARM_RDI_MONITOR
|
||||
do_AngelSWI (AngelSWI_Reason_ReportException,
|
||||
(void *) ADP_Stopped_RunTimeError);
|
||||
#else
|
||||
asm ("mov r0,#17\nswi %a0" :: "i" (SWI_Exit));
|
||||
#endif
|
||||
}
|
||||
|
||||
void
|
||||
alarm (void)
|
||||
{
|
||||
|
|
|
@ -12,6 +12,7 @@
|
|||
#include <sys/times.h>
|
||||
#include <errno.h>
|
||||
#include <reent.h>
|
||||
#include <signal.h>
|
||||
#include <unistd.h>
|
||||
#include "swi.h"
|
||||
|
||||
|
@ -433,30 +434,34 @@ _close (int file)
|
|||
return wrap (_swiclose (file));
|
||||
}
|
||||
|
||||
void
|
||||
_exit (int n)
|
||||
int
|
||||
_kill (int pid, int sig)
|
||||
{
|
||||
/* FIXME: return code is thrown away. */
|
||||
|
||||
(void)pid; (void)sig;
|
||||
#ifdef ARM_RDI_MONITOR
|
||||
do_AngelSWI (AngelSWI_Reason_ReportException,
|
||||
(void *) ADP_Stopped_ApplicationExit);
|
||||
/* Note: The pid argument is thrown away. */
|
||||
switch (sig) {
|
||||
case SIGABRT:
|
||||
return do_AngelSWI (AngelSWI_Reason_ReportException,
|
||||
(void *) ADP_Stopped_RunTimeError);
|
||||
default:
|
||||
return do_AngelSWI (AngelSWI_Reason_ReportException,
|
||||
(void *) ADP_Stopped_ApplicationExit);
|
||||
}
|
||||
#else
|
||||
asm ("swi %a0" :: "i" (SWI_Exit));
|
||||
#endif
|
||||
n = n;
|
||||
}
|
||||
|
||||
int
|
||||
_kill (int n, int m)
|
||||
void
|
||||
_exit (int status)
|
||||
{
|
||||
#ifdef ARM_RDI_MONITOR
|
||||
return do_AngelSWI (AngelSWI_Reason_ReportException,
|
||||
(void *) ADP_Stopped_ApplicationExit);
|
||||
#else
|
||||
asm ("swi %a0" :: "i" (SWI_Exit));
|
||||
#endif
|
||||
n = n; m = m;
|
||||
/* There is only one SWI for both _exit and _kill. For _exit, call
|
||||
the SWI with the second argument set to -1, an invalid value for
|
||||
signum, so that the SWI handler can distinguish the two calls.
|
||||
Note: The RDI implementation of _kill throws away both its
|
||||
arguments. */
|
||||
_kill(status, -1);
|
||||
}
|
||||
|
||||
int
|
||||
|
|
Loading…
Reference in New Issue