# crt1_dir directory where crt1 object is found
# have_crt0 "yes"/"no" if crt0 is/isn't provided.
# "" if crt0 is provided when sys_dir is set
+# noinclude list of include files to not install
newlib_cflags=
libm_machine_dir=
signal_dir=signal
stdio_dir=stdio
stdio64_dir=
+xdr_dir=
syscall_dir=
unix_dir=
+noinclude=
mach_add_setjmp=
crt1=
crt1_dir=
bfin)
machine_dir=bfin
;;
+ cr16*)
+ machine_dir=cr16
+ ;;
cris | crisv32)
machine_dir=cris
;;
d30v*)
machine_dir=d30v
;;
- ep9312)
- machine_dir=arm
- ;;
fido)
machine_dir=m68k
newlib_cflags="${newlib_cflags} -DCOMPACT_CTYPE"
powerpc*)
machine_dir=powerpc
;;
+ rl78)
+ machine_dir=rl78
+ newlib_cflags="${newlib_cflags} -DPREFER_SIZE_OVER_SPEED -DSMALL_MEMORY"
+ ;;
rx)
machine_dir=rx
default_newlib_io_long_long="yes"
# FIXME: Might wish to make MALLOC_ALIGNMENT more generic.
newlib_cflags="${newlib_cflags} -DMALLOC_ALIGNMENT=8"
;;
- strongarm)
- machine_dir=arm
- ;;
- xscale)
- machine_dir=xscale
- ;;
- thumb)
- machine_dir=arm
- ;;
tic4x|c4x)
machine_dir=tic4x
;;
+ tic6x)
+ machine_dir=tic6x
+ ;;
tic80*)
machine_dir=tic80
;;
;;
v810)
;;
- v850)
- machine_dir=v850
- newlib_cflags="${newlib_cflags} -DPREFER_SIZE_OVER_SPEED -mv850 "
- ;;
- v850e)
+ v850*)
machine_dir=v850
newlib_cflags="${newlib_cflags} -DPREFER_SIZE_OVER_SPEED "
;;
*-*-cygwin*)
posix_dir=posix
stdio64_dir=stdio64
+ xdr_dir=xdr
;;
*-*-netware*)
signal_dir=
bfin-*-*)
sys_dir=
;;
+ cr16-*-*)
+ sys_dir=
+ ;;
crx*)
sys_dir=
;;
d30v*)
sys_dir=
;;
- ep9312-*-*)
- sys_dir=arm
- if [ "x${newlib_may_supply_syscalls}" = "xno" ] ; then
- have_crt0="no"
- fi
- ;;
frv*)
sys_dir=
;;
default_newlib_io_long_long="yes"
default_newlib_atexit_dynamic_alloc="no"
;;
- strongarm-*-*)
- sys_dir=arm
- if [ "x${newlib_may_supply_syscalls}" = "xno" ] ; then
- have_crt0="no"
- fi
- ;;
- thumb-*-*)
- sys_dir=arm
- if [ "x${newlib_may_supply_syscalls}" = "xno" ] ; then
- have_crt0="no"
- fi
+ tic6x*)
+ newlib_cflags="${newlib_cflags} -DMISSING_SYSCALL_NAMES"
+ have_crt0="no"
;;
tic80*)
sys_dir=tic80
v810-*-*)
sys_dir=sysnec810
;;
- v850-*-*)
- sys_dir=sysnecv850
- ;;
- v850e-*-*)
- sys_dir=sysnecv850
- ;;
- v850ea-*-*)
+ v850*-*-*)
sys_dir=sysnecv850
+ if [ "x${newlib_may_supply_syscalls}" = "xno" ] ; then
+ have_crt0="no"
+ fi
;;
w65-*-*)
sys_dir=w65
;;
- xscale-*-*)
- sys_dir=arm
- if [ "x${newlib_may_supply_syscalls}" = "xno" ] ; then
- have_crt0="no"
- fi
- ;;
z8k-*-coff)
sys_dir=z8ksim
;;
*-*-rtems*)
default_newlib_io_long_long="yes"
default_newlib_io_c99_formats="yes"
+ newlib_cflags="${newlib_cflags} -D_COMPILING_NEWLIB"
newlib_cflags="${newlib_cflags} -DMALLOC_PROVIDED -DEXIT_PROVIDED -DSIGNAL_PROVIDED -DREENTRANT_SYSCALLS_PROVIDED -DHAVE_NANOSLEEP -DHAVE_BLKSIZE -DHAVE_FCNTL -DHAVE_ASSERT_FUNC"
# turn off unsupported items in posix directory
newlib_cflags="${newlib_cflags} -D_NO_GETLOGIN -D_NO_GETPWENT -D_NO_GETUT -D_NO_GETPASS -D_NO_SIGSET -D_NO_WORDEXP -D_NO_POPEN"
# to create the program's environment.
# If --disable-newlib-supplied-syscalls is specified, then the end-user
# may specify the protocol via gcc spec files supplied by libgloss.
-# See also thumb below.
if [ "x${newlib_may_supply_syscalls}" = "xyes" ] ; then
# newlib_cflags="${newlib_cflags} -DARM_RDP_MONITOR"
newlib_cflags="${newlib_cflags} -DARM_RDI_MONITOR"
newlib_cflags="${newlib_cflags} -DHAVE_RENAME -D_USE_WRITE -DCOMPACT_CTYPE"
syscall_dir=syscalls
;;
+ cr16-*-*)
+ syscall_dir=syscalls
+ ;;
crx-*-*)
newlib_cflags="${newlib_cflags} -DHAVE_RENAME -DMISSING_SYSCALL_NAMES"
syscall_dir=
newlib_cflags="${newlib_cflags} -DABORT_MESSAGE -DSMALL_MEMORY -DMISSING_SYSCALL_NAMES"
syscall_dir=
;;
- ep9312-*-*)
- syscall_dir=syscalls
- if [ "x${newlib_may_supply_syscalls}" = "xyes" ] ; then
- newlib_cflags="${newlib_cflags} -DARM_RDI_MONITOR"
- fi
- ;;
fido-*-elf)
newlib_cflags="${newlib_cflags} -DHAVE_RENAME -DHAVE_SYSTEM -DMISSING_SYSCALL_NAMES"
syscall_dir=
newlib_cflags="${newlib_cflags} -DTARGET_PTR_SIZE=64" ;;
esac
;;
- strongarm-*-*)
- syscall_dir=syscalls
- ;;
- thumb-*-pe)
- syscall_dir=syscalls
-# Don't use the debugging protocols just yet.
- ;;
- thumb-*-*)
- syscall_dir=syscalls
-# 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.
-# If neither are defined, then hard coded defaults will be used
-# to create the program's environment.
-# If --disable-newlib-supplied-syscalls is specified, then the end-user
-# may specify the protocol via gcc spec files supplied by libgloss.
- if [ "x${newlib_may_supply_syscalls}" = "xyes" ] ; then
-# newlib_cflags="${newlib_cflags} -DARM_RDP_MONITOR"
- newlib_cflags="${newlib_cflags} -DARM_RDI_MONITOR"
- fi
+ tic6x*)
+ syscall_dir=
+ newlib_cflags="${newlib_cflags} -DCLOCK_PROVIDED"
;;
tic80*)
syscall_dir=syscalls
;;
- v850-*-*)
- syscall_dir=syscalls
- ;;
- v850e-*-*)
- syscall_dir=syscalls
- ;;
- v850ea-*-*)
+ v850*-*-*)
syscall_dir=syscalls
;;
w65-*-*)
xc16x-*)
syscall_dir=syscalls
;;
- xscale-*-*)
- syscall_dir=syscalls
- newlib_cflags="${newlib_cflags} -DHAVE_SYSTEM -DHAVE_RENAME"
- if [ "x${newlib_may_supply_syscalls}" = "xyes" ] ; then
- newlib_cflags="${newlib_cflags} -DARM_RDI_MONITOR"
- fi
- ;;
xstormy16-*-*)
syscall_dir=syscalls
;;
fi
fi
+# Remove rpc headers if xdr_dir not specified
+if [ "x${xdir_dir}" = "x" ]; then
+ noinclude="${noinclude} rpc/types.h rpc/xdr.h"
+fi
+
if test -z "${have_crt0}" && test -n "${sys_dir}"; then
have_crt0="yes"
fi