Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Real time embedded FreeRTOS mailing list 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem TCP & FAT Training




Loading

Missing ulICCIAR when linking C++ application

Posted by scwoods751 on June 29, 2015

I am new to freeRTOS. I went through tutorials to get c applications built and tested on a Xilinx ZC702 board (Cortex A9) and they work fine. I tried to create a very basic c++ application (hello world) but it will not link. Several objects are missing, including ulICCIAR, that are defined in port.c and referenced in portASM.s (this is where the linkage fails). I am using Xilinx SDK on Windows 7. I assume this is a name mangling problem or a toolchain setup problem but I have not been able to find help anywhere on the internet. I was hoping someone using freeRTOS might be able to assist me.


Missing ulICCIAR when linking C++ application

Posted by rtel on June 30, 2015

We don't actually use C++ ourselves, but lot of people do use FreeRTOS in C++ applications, and even provide C++ frameworks.

What we do do is have extern "C" in the header files of the core code to ensure the core code can be built as C in an otherwise C++ application. I don't think this is the issue in this case though.

ulICCIAR is declared in the relevant port.c source file, then used in portASM.S. I suspect the name is being mangled in the C file so the .S file cannot use the original name.

Are you building the FreeRTOS source files as C code? It should then link in a C++ application.

Regards.


Missing ulICCIAR when linking C++ application

Posted by scwoods751 on June 30, 2015

I created the application as c++ and included the FreeRTOS code as-is in the application. The toolchain is set to g++ and the build log indicates the g++ compiler is used on port.c module. I thought the g++ compiler would treat c modules as c code and cc/cpp modules as c++ code. Is there a way to build the FreeRTOS modules separately and then just link them in as a module (like a lib)?


Missing ulICCIAR when linking C++ application

Posted by scwoods751 on June 30, 2015

I changed the toolchain to use the gcc compiler (override g++) for every c module in the project and then added in the include paths for every c module as well. It then built with no linkage problems. There must be a way to change to gcc compiler and include paths for c modules only once at the top level of the project instead of having to override every c file independently but I could not find it in the Xilinx SDK. Anyhow the project finally builds... now I need to figure out why initializing basic hardware doesn't work. Thanks for your help. Any other pointers would be appreciated.


Missing ulICCIAR when linking C++ application

Posted by scwoods751 on June 30, 2015

Figured out why the basic hardware was not initializing... script.ld was generic and was missing the FreeRTOS vector table stuff. All good now.


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




Copyright (C) 2004-2010 Richard Barry. Copyright (C) 2010-2016 Real Time Engineers Ltd.
Any and all data, files, source code, html content and documentation included in the FreeRTOSTM distribution or available on this site are the exclusive property of Real Time Engineers Ltd.. See the files license.txt (included in the distribution) and this copyright notice for more information. FreeRTOSTM and FreeRTOS.orgTM are trade marks of Real Time Engineers Ltd.

Latest News:

FreeRTOS V9.0.0 is now available for download.


Free TCP/IP and file system demos for the RTOS


Sponsored Links

⇓ Now With No Code Size Limit! ⇓
⇑ Free Download Without Registering ⇑


FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

Renesas Electronics Gold Alliance RTOS Partner.jpg

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

Atmel RTOS partner supporting ARM Cortex-M3 and AVR32 microcontrollers

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

Xilinx Microblaze and Zynq partner

Silicon Labs low power RTOS partner

Altera RTOS partner for Nios II and Cortex-A9 SoC

Freescale Alliance RTOS Member supporting ARM and ColdFire microcontrollers

Infineon ARM Cortex-M microcontrollers

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

Cypress RTOS partner supporting ARM Cortex-M3

Fujitsu RTOS partner supporting ARM Cortex-M3 and FM3

Microsemi (previously Actel) RTOS partner supporting ARM Cortex-M3

Atollic Partner

IAR Partner

Keil ARM Partner

Embedded Artists