Hello World Example

Gedare Bloom gedare at rtems.org
Fri Mar 23 15:56:47 UTC 2012


On Fri, Mar 23, 2012 at 9:00 AM, Dhruva T.B. <dhruva92 at gmail.com> wrote:

> Ok, these are the steps I took   ( I had sudo access throughout) -:
> 1) Downloaded and extracted the tarballs for binutils, gcc-core, gcc-g++,
> gdb, newlib, mpc and mpfr.
> 2) Then for binutils created a seperate  folder and ran ../binutils-2.20/*configure
> --target=sparc-rtems4.10* *--prefix=/opt/rtems4.10*.
>
For GSOC you should use rtems4.11. You will need to redo these steps to
build updated tools. You can find the current patches you will need to
apply in http://git.rtems.org/rtems-crossrpms.git/tree/patches

That will also give you hints about which versions of the tools to
download. The wiki instructions are somewhat outdated.


>     Then ran *make all *followed by make info and finally make install.
> 3) Then ran a similar configure script for gcc -:
>      ->cd ../gcc-4.63/
>      -> ln -s ../newlib-1.20.0/newlib
>      -> cd ..; -> mkdir gcc-temp;
>      -> cd gcc-temp
>      -> ../gcc-4.63/*configure --target=sparc-rtems4.10 --with-gnu-as
> --with-newlib --verbose --enable-threads --enable-languages="c,c++"
> --prefix=/opt/rtems4.10*
>      -> make all; -> make info; -> make install
>
> 4)  At this point I ran the bootstrap inside my rtems-4.10.2 folder. I
> also set my path with *export PATH=/opt/rtems4.10/bin:$PATH*

The path must be set before compiling gcc, or it won't find the binutils.
I'd be surprised that your gcc compile worked.


>
> 5) Then I cd into a directory called b-rtems and ran the configure code in
> it with ../rtems-4.10.2/*configure --target=sparc-rtems4.10
> --enable-rtemsbsp=sis --enable-        tests=samples --disable-posix
> --disable-itran --prefix=/opt/rtems4.10*
> I then ran make all and got the following as the last couple of lines of
> output -:
> make[5]: *** [kern/libnetworking_a-uipc_
> socket.o] Error 1
> make[5]: Leaving directory
> `/home/dhruva/RTEMS/Tools/b-rtems/sparc-rtems4.10/c/sis/cpukit/libnetworking'
> make[4]: *** [all-recursive] Error 1
> make[4]: Leaving directory
> `/home/dhruva/RTEMS/Tools/b-rtems/sparc-rtems4.10/c/sis/cpukit'
> make[3]: *** [all] Error 2
> make[3]: Leaving directory
> `/home/dhruva/RTEMS/Tools/b-rtems/sparc-rtems4.10/c/sis/cpukit'
> make[2]: *** [all-recursive] Error 1
> make[2]: Leaving directory
> `/home/dhruva/RTEMS/Tools/b-rtems/sparc-rtems4.10/c/sis'
> make[1]: *** [all-recursive] Error 1
> make[1]: Leaving directory
> `/home/dhruva/RTEMS/Tools/b-rtems/sparc-rtems4.10/c'
> make: *** [all-recursive] Error 1
>
>
> 6) Not sure what the error is here but I ran make install anyway.
>
> You'd have to scroll back farther to see where the error started.


> I then checked the sparc-rtems4.10/c/sis/testsuites/samples/ticker
> directory and only found a Makefile there.
> Not sure where I am going wrong.
>
> Try just typing 'make' there.


> I then went back to the original rtems4.10 directory and found my way to
> the testsuites ticker folder. I tried sparc-rtems4.10-gcc init.c to see
> what would happen and got an error about missing header file 'rtems.h'. Not
> sure where its supposed to be but hoping that might help.
>
> Can't compile from within the source tree.


> Hoping to find a fix that doesn't begin with -' Start over, except...'  :).
>
>
> --
> Dhruva T.B.,
> 3rd Year Electronics And Instrumentation Engineer,
> Birla Institute Of Technology And Science (BITS)-Pilani, Goa,
> India
>
> Contact : +91-9503817694
>
>
> _______________________________________________
> rtems-users mailing list
> rtems-users at rtems.org
> http://www.rtems.org/mailman/listinfo/rtems-users
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/users/attachments/20120323/685b49b3/attachment-0001.html>


More information about the users mailing list