Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem


Loading

syscalls.c compilation errors.

Posted by JIA Pei on February 28, 2012


Hi, FreeRTOS:


Sorry for my very entry level questions.


Working environment:
1) OS: Windows7
2) freeRTOS: FreeRTOSV7.1.0.exe
3) Eclipse: Indigo Service Release 2
4) No ARM-board connected to my computer yet

I'm now testing "ARM7_AT91SAM7X256_Eclipse" and I followed “my modified steps”
from http://www.freertos.org/index.html?http://www.freertos.org/Eclipse.html,
as the current Eclipse version has already been updated to Indigo.

However, I'm now having 2 compilation errors for file syscalls.c,
1) Assignment to itself 'r = r', etc. (A lot of "Assignment to itself" errors.)
2) Symbol 'caddr_t' could not be resolved

What's more, if I ignore the above 2 errors and build it directly, I got
"make: arm-elf-gcc: Command not found"
Do i have to install arm-elf, in order to make everything successfully compiled?


And, as for me, it's apparent that there does exist "Assignment to itself", and what is "caddr_t" ?
should it be defined as
typedef void *caddr_t; ?
If so, there must be some file which has already defined the above line "typedef void *caddr_t;", where is the file?


Please can anybody help me out and thank you very much.


Cheers
Pei

RE: syscalls.c compilation errors.

Posted by Richard on February 28, 2012
Eclipse is just the IDE, it has nothing to do with the compilation - it just calls the compiler and displays the results. You therefore need to use an Eclipse distribution that has the compiler included, or install the compiler separately. Note the instructions you are following is for (I think) Eclipse Europa, which is very different to the latest Eclipse releases.

“However, I'm now having 2 compilation errors for file syscalls.c,”


I don't understand how you are getting compiler errors if you don't have the compiler installed? I suspect you are seeing some sort of annoying parsing of the code done by Eclipse itself. I have heard that newer versions of Eclipse do this and spit out all sorts of spurious errors - if this is the case just turn that feature off in Eclipse.

“1) Assignment to itself 'r = r', etc. (A lot of "Assignment to itself" errors.)”


That syscalls file is a third party file, and looking at this, I think it is just a crude way of preventing the compiler warning that r is not used. You can replace it with ( void ) r; for a better method or doing the same thing.

“2) Symbol 'caddr_t' could not be resolved”


Presumably this is just because you are not actually compiling the code, and this is an Eclipse spurious error.

You will have to use a GCC version that requires syscalls.c. If, once the compiler is installed, you get "multiple definitions of" errors then you can remove the syscalls file.

Regards.


[ Back to the top ]    [ About FreeRTOS ]    [ Privacy ]    [ Sitemap ]    [ ]


Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.

Latest News

NXP tweet showing LPC5500 (ARMv8-M Cortex-M33) running FreeRTOS.

Meet Richard Barry and learn about running FreeRTOS on RISC-V at FOSDEM 2019

Version 10.1.1 of the FreeRTOS kernel is available for immediate download. MIT licensed.

View a recording of the "OTA Update Security and Reliability" webinar, presented by TI and AWS.


Careers

FreeRTOS and other embedded software careers at AWS.



FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

Espressif ESP32

IAR Partner

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

Renesas

STMicro RTOS partner supporting ARM7, ARM Cortex-M3, ARM Cortex-M4 and ARM Cortex-M0

Texas Instruments MCU Developer Network RTOS partner for ARM and MSP430 microcontrollers

OpenRTOS and SafeRTOS

Xilinx Microblaze and Zynq partner