This is the mail archive of the newlib@sourceware.org mailing list for the newlib project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

some questions about compiling newlib


Dear all:
my questions are:
1. in sys/config.h, it will try to determine the machine we try to
compile. Like
#if defined(__mips__) && !defined(__rtems__)
#define __ATTRIBUTE_IMPURE_PTR__ __attribute__((__section__(".sdata")))
#endif

where we give the define like __mips__?
I grep the '__mips__' in whole source code but I cannot find any clue.

newlib-1.17.0.monta_noUclibc# grep -rw '__mips__' *
newlib/ChangeLog:	* libc/include/sys/config.h[__mips__]: Don't bother
newlib/ChangeLog:	[__rtems__][__mips__]: No need to undef the
__ATTRIBUTE_IMPURE_PTR__
newlib/ChangeLog:	* libc/include/machine/setjmp.h: Added __mips__ case.
newlib/libc/sys/linux/linuxthreads/kernel-features.h:#if
__LINUX_KERNEL_VERSION >= 131879 || defined __powerpc__ || defined
__mips__
newlib/libc/sys/linux/dl/kernel-features.h:#if __LINUX_KERNEL_VERSION
>= 131879 || defined __powerpc__ || defined __mips__
newlib/libc/include/machine/setjmp.h:#ifdef __mips__
newlib/libc/include/sys/config.h:#if defined(__mips__) && !defined(__rtems__)
newlib-1.17.0.monta_noUclibc#


2. I try to compile newlib under mips-toolchain.
But I get the error attached at the end of mail while compiling impure.c.
it seems somewhere declare _global_impure_ptr and assign it with
different section type. But i cannot find out where it is.

mips2_fp_le-gcc
-B/media/sdb1/Novatek2/newlib-1.17.0.monta_noUclibc/mipsel/newlib/
-isystem /media/sdb1/Novatek2/newlib-1.17.0.monta_noUclibc/mipsel/newlib/targ-include
-isystem /media/sdb1/Novatek2/newlib-1.17.0.monta_noUclibc/newlib/libc/include
-B/media/sdb1/Novatek2/newlib-1.17.0.monta_noUclibc/mipsel/libgloss/mips
-L/media/sdb1/Novatek2/newlib-1.17.0.monta_noUclibc/mipsel/libgloss/libnosys
-L/media/sdb1/Novatek2/newlib-1.17.0.monta_noUclibc/libgloss/mips
-DPACKAGE_NAME=\"newlib\" -DPACKAGE_TARNAME=\"newlib\"
-DPACKAGE_VERSION=\"1.17.0\" -DPACKAGE_STRING=\"newlib\ 1.17.0\"
-DPACKAGE_BUGREPORT=\"\"  -I. -I../../../.././newlib/libc/reent -O2
-DMISSING_SYSCALL_NAMES -fno-builtin      -g -O2   -c -o
lib_a-impure.o `test -f 'impure.c' || echo
'../../../.././newlib/libc/reent/'`impure.c
../../../.././newlib/libc/reent/impure.c:17: error: _global_impure_ptr
causes a section type conflict

appreciate your help,
miloody


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]