CodeSourcery is a supplier of open-source "Sourcery CodeBench" toolchains (integrating GCC, GDB, etc.) for ARM, MIPS, Power, x86, and other embedded processor architectures. Sourcery CodeBench has both free (as in beer) "Lite" editions and commercially-supported versions of the toolchains. CodeSourcery is a part of Mentor Graphics.
Questions tagged [codesourcery]
61 questions
99
votes
6 answers
How to stop MinGW and MSYS from mangling path names given at the command line
On Windows, I'm cross-compiling a program for ARM/Linux using CodeSourcery's cross-compiler suite. I use MinGW MSYS as my command interpreter, and very often it will mangle my paths and pathnames. For example, to build my program, I…

Ted Middleton
- 6,859
- 10
- 51
- 71
22
votes
1 answer
Is it possible to run a native arm binary on a non-rooted android phone?
Well, I've been diving in the murky waters of low-level Android programming (native C/C++ using the CodeSourcery toolchain). I tried out the executable on an emulator and it worked. I'd like to try it out on a real device. So I plugged in my nexus…

AnimatedRNG
- 1,859
- 3
- 26
- 39
15
votes
3 answers
When is .ARM.exidx is used
I am working on Contiki 2.7 with the mbxxx target. While building my code the linker complained about an overlap of .ARM.exidx and .data sections. After some tinkering around with the linker script contiki-2.7/cpu/stm32w108/gnu-stm32w108.ld I fixed…

user2668988
- 267
- 1
- 2
- 12
13
votes
4 answers
GCC alias to function outside of translation unit -AKA- is this even the right tool for the job?
I'm working with FreeRTOS on an STM32 (Cortex-M3), and using the CMSIS library from ST to bootstrap everything.
The CMSIS library defines the weak symbol SVC_Handler in the startup ".s" file. It must be overridden somewhere in order to get your…

Brian McFarland
- 9,052
- 6
- 38
- 56
13
votes
2 answers
set global gcc default search paths
when running
arm-none-linux-gnueabi-gcc -print-search-dirs | grep libraries | sed 's/:/\n/g'
I get the following output:
libraries
…

Chris H
- 6,433
- 5
- 33
- 51
13
votes
6 answers
Cross-Compiling for RaspBerry Pi
With a Raspberry Pi and from my computer, I'm trying to cross-compile a simple helloWorld written in C++. I'm using the Code Sourcery toolchain for Linux to compile.
When copying the helloWorld binary to the Pi by TFTP and giving it execution…

Cesar Ortiz
- 884
- 1
- 8
- 25
13
votes
2 answers
Anyway to see list of preprocessor defined macros?
I'd like to see all macros that are defined by the invocation of the compiler I'm using. Is there any way to do this? I have seen in the manual it says you can use cpp -dM but this doesn't work for me. Perhaps I'm doing something wrong?
When I…

Brandon Yates
- 2,022
- 3
- 22
- 33
7
votes
2 answers
Cross-Compiling Armadillo Linear Algebra Library
I enjoy using the Armadillo Linear Algebra Library. It becomes extremely nice when porting octave .m files over to C++, especially when you have to use the eigen methods.
However I ran into issues when I had to take my program from my native…

Matt
- 653
- 1
- 8
- 20
6
votes
1 answer
gdb - generate-core-file for remote target?
I'm debugging with the Codesourcery version of gdb for ARM (i.e. arm-none-eabi-gdb) and attempting to generate a corefile for later inspection. OpenOCD is my GDB target. All gdb tells me when I run 'gcore' or 'generate-core-file' is "Can't create…

Brian McFarland
- 9,052
- 6
- 38
- 56
6
votes
1 answer
GCC arm-none-eabi (Codesourcery) and C++ Exceptions
I am using Raisonance's Ride7/Codesourcery (a.k.a Sourcery CodeBench Lite) with an STM32F4 board developing a bare metal HMI platform.
I will be making use of C++ exceptions in this system, but any exception I throw ends with a "Terminate called…

Verax
- 2,409
- 5
- 27
- 42
5
votes
1 answer
CodeSourcery linker errors to static library
I have created two static libraries for use with a C program I am writing for an ARM STM32F4xx processor using Mentor Graphics CodeSourcery. I have added the libraries and their directories to the build settings in the project as I believe they are…

Jared
- 1,449
- 2
- 19
- 40
5
votes
1 answer
Making use of -mfloat-abi=hard and -mfpu=vfp/neon Codesourcery Lite 2013.05-24
To make use of vfp or neon I added -mfpu=vfp and -mfloat-abi=hard to my cross compilation. The Programm is a very simple hellofloat.cpp which then doesn't compile any more with the Sourcery CodeBench Lite 2013.05-24.
#include
#include…

eactor
- 862
- 3
- 14
- 34
4
votes
1 answer
Qt Arm Remote Debugging
I am working on LPC1768. I want to debug test_ram.elf file using arm-none-eabi-gdb on qt creator.
I downloaded code to test from http://www.yagarto.de/download/yagarto/LPC1768Test.zip
Unfortunetely, I couldn’t handle remote debugging. I want to…

esa55
- 53
- 1
- 6
4
votes
2 answers
Error: Target CPU does not support ARM mode
I'm trying to cross=compile a simple program with inline assembly for a variety of ARM processors. It contains the assembly instruction QSUB which according to this document is both a valid ARM and Thumb-2 instruction.
This compiles fine for me when…

Brandon Yates
- 2,022
- 3
- 22
- 33
4
votes
2 answers
Cross-compiling Linux kernel for ARM on Windows using Sourcery Toolchain
I am trying to cross-compile a Linux kernel for an ARM-target (Freescale i.Mx28) on a Windows host. I know that this approach is not the best one compared to using a Linux host, but unfortunately it's not up to me to decide that.
The restrictions…

Tobi
- 2,001
- 2
- 27
- 49