Message ID | 20101104.070842.177589926.kkojima@rr.iij4u.or.jp |
---|---|
State | New |
Headers | show |
On 11/03/2010 11:08 PM, Kaz Kojima wrote: > I've noticed that config.gcc missed to newlib-stdint.h to tm_file > for sh64-elf and it causes many testsuite failures. Tested for > cross sh64-elf and native i686-pc-linux-gnu. Applied on trunk. > > Regards, > kaz > -- > 2010-11-03 Kaz Kojima<kkojima@gcc.gnu.org> > > * config.gcc (sh64*)<tm_file>: Add newlib-stdint.h for > newlib targets. > > --- ORIG/trunk/gcc/config.gcc 2010-10-15 10:11:34.000000000 +0900 > +++ trunk/gcc/config.gcc 2010-11-01 23:36:23.000000000 +0900 > @@ -2328,6 +2328,9 @@ sh-*-symbianelf* | sh[12346l]*-*-symbian > sh64*) > tmake_file="${tmake_file} sh/t-sh64" > tm_file="${tm_file} sh/sh64.h" > + if test x$with_newlib = xyes; then > + tm_file="${tm_file} newlib-stdint.h" > + fi > extra_headers="shmedia.h ushmedia.h sshmedia.h" > ;; > *-*-symbianelf*) This patch doesn't seem right to me, for 2 reasons: a) The fact a target is using newlib is independent of the architecture (here sh64). b) It is wrong to key using "newlib-stdint.h" to $with_newlib, because its possible to build recent gccs with --with-newlib, but without using newlib-stdint.h with a couple of tweaks to newlib (remove its stdint.h) and config.gcc (use use_gcc_stdint=provide). RTEMS is likely going to apply this approach in near future (I am working on it). Ralf
Ralf Corsepius <ralf.corsepius@rtems.org> wrote: > This patch doesn't seem right to me, for 2 reasons: > > a) The fact a target is using newlib is independent of the architecture > (here sh64). > > b) It is wrong to key using "newlib-stdint.h" to $with_newlib, because > its possible to build recent gccs with --with-newlib, but without using > newlib-stdint.h with a couple of tweaks to newlib (remove its stdint.h) > and config.gcc (use use_gcc_stdint=provide). > > RTEMS is likely going to apply this approach in near future (I am > working on it). I agree that my patch isn't best approach in general. It's simply a simple fix for sh64-elf testsuite failures. sh64 isn't a real target for almost folks and sh64-elf with newlib may be a uniqe target which is valuable to test. Of course, your plan looks fine. Regards, kaz
--- ORIG/trunk/gcc/config.gcc 2010-10-15 10:11:34.000000000 +0900 +++ trunk/gcc/config.gcc 2010-11-01 23:36:23.000000000 +0900 @@ -2328,6 +2328,9 @@ sh-*-symbianelf* | sh[12346l]*-*-symbian sh64*) tmake_file="${tmake_file} sh/t-sh64" tm_file="${tm_file} sh/sh64.h" + if test x$with_newlib = xyes; then + tm_file="${tm_file} newlib-stdint.h" + fi extra_headers="shmedia.h ushmedia.h sshmedia.h" ;; *-*-symbianelf*)