Conflict when modifying newlib/openrisc to work for RTEMS
Joel Sherrill
joel.sherrill at OARcorp.com
Tue Mar 18 18:26:02 UTC 2014
On 3/18/2014 1:07 PM, Hesham Moustafa wrote:
> Hi,
>
> I am working on modifying or1k newlib port to be built for RTEMS.
> Building and installing
> newlib with --target=or1k-elf is done successfully, however, when I
> try to build newlib
> with --target=or1k-rtems4.11 I got conflict error.
>
> part of this error is
> "sys/rtems/crt0.c:72:22: error: conflicting types for ‘read’"
>
Hmmm... how old is there newlib?
What's the prototype for read() versus unistd.h (or whereever it turns
out to
be prototyped)?
It may also be possible that the or1k port doesn't have the underlying type
definitions complete or correct.
http://pubs.opengroup.org/onlinepubs/009695399/functions/read.html
isn't the latest but read() requires ssize_t and size_t to be correctly and
consistently defined for a target.
You may end up having to reproduce the compile of crt0.c by hand and
change the -c to a -E .. changing the output file.. and see what really
is being preprocessed
> or1k/newlib port implements some stuff at libgloss (including or1k/crt0.S)
>
rtems uses nothing in libgloss.
> I just use --target=or1k-xxx --prefix=xxx as configuration options for
> newlib.
>
The RTEMS builds take more. Check rtems-source-builder. Also if you are
not building or1k-rtems tools including binutils and gcc+newlib together
at the same time, it may be causing issues.
> Thanks,
> Hesham
--
Joel Sherrill, Ph.D. Director of Research & Development
joel.sherrill at OARcorp.com On-Line Applications Research
Ask me about RTEMS: a free RTOS Huntsville AL 35805
Support Available (256) 722-9985
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/devel/attachments/20140318/18318d23/attachment-0001.html>
More information about the devel
mailing list