This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

C compiler on target

Hi,


Can any point me to have a C compiler on target embedded platform, I want a C compiler on ARM cortex A-8.

Cheers,

--Mike

  • Mike,

    See if the below pointer will help:

    wiki.linaro.org/.../GCCNative

    BR
    Pavel
  • Hi Pavel,

    I have tried it but it fails with following error when I do a make,

    checking for struct tms... yes
    checking for clock_t... yes
    checking for F_SETLKW... yes
    checking if mkdir takes one argument... no
    Unknown CPU given in --with-arch=armv7-a.
    Makefile:3907: recipe for target 'configure-gcc' failed
    make[1]: *** [configure-gcc] Error 1
    make[1]: Leaving directory build'
    Makefile:843: recipe for target 'all' failed
    make: *** [all] Error 2

    Cheers,
    --Mike

  • Hi Pavel,

    When I do a configure I see that, its configuring for x86,

    ../gcc-linaro/configure --disable-bootstrap --enable-languages=c,c++ --with-mode=thumb --with-arch=armv7-a --with-tune=cortex-a9 --with-float=softfp --with-fpu=neon --prefix=/gcc-linaro-install/
    checking build system type... x86_64-unknown-linux-gnu
    checking host system type... x86_64-unknown-linux-gnu
    checking target system type... x86_64-unknown-linux-gnu
    checking for a BSD-compatible install... /usr/bin/install -c
    checking whether ln works... yes
    checking whether ln -s works... yes
    checking for a sed that does not truncate output... /bin/sed
    checking for gawk... gawk
    checking for libatomic support... yes
    checking for libcilkrts support... yes
    checking for libitm support... yes
    .....

    Cheers,
    --Mike
  • Mike,

    Are you trying the 'configure' and 'make' commands from the target board or from the host PC?

    BR
    Pavel
  • Hi Pavel,

    I am running the configure script on host PC.

    Cheers,
    --Mike
  • Mike,

    Per mine understanding, 'configure' and 'make' should be executed from within the target platform.

    BR
    Pavel
  • Hi Pavel,

    I want to build a native compiler, If I run make and configure on target how will it compile (make will call GCC in target board)

    Cheers,
    Mike
  • Mike,

    I agree with your point. But if you run make and configure on host PC, you will create a native compiler for the host PC. And I do not see instruction how to transfer this native compiler from the host PC to the target platform.

    Seems we do not have official native C compiler for Cortex-A8 ARM based boards. I will also check this with the toolchain team, but there will be delay, as they are out of office these days.

    BR
    Pavel
  • Hi Pavel,

    Thanks, I will be waiting for your response.

    Cheers,
    Mike
  • Mike,

    On the example given we have:

    checking build system type... armv7l-unknown-linux-gnueabi
    checking host system type... armv7l-unknown-linux-gnueabi
    checking target system type... armv7l-unknown-linux-gnueabi

    This makes me think this build is for ARM based device, not x86 desktop machine.

    BR
    Pavel
  • Hi Pavel,

    Yes the example says 'armv7l-unknown-linux-gnueabi' but what is the point in doing this, if we the target already has the GCC into it.

    Cheers,
    --Mike
  • Mike,

    This page seems to instruct how to install Linaro GCC on ARM platform which has already older version of GCC into it. As I am unable to find other native compiler make and install instructions, let us wait for feedback from the toolchain team.

    BR
    Pavel