Questions tagged [cross-compilation]

Questions should concern compiling for a platform different than the one the compiler is running on. Compiling inside a VM does not count unless it's some sort of hybrid setup i.e. the host which is a different platform is involved.

Cross-compiling is the process of creating executable code for a platform different from the one the compiler is running on. The platforms can differ concerning e.g. operating system or architecture. An example would be compiling for an embedding system on the ARM architecture on a desktop x86 platform

261 questions
162
votes
1 answer

How is Mono magical?

I'm learning C#, so I made a little C# program that says Hello, World!, then compiled it with mono-csc and ran it with mono: $ mono-csc Hello.cs $ mono Hello.exe Hello, World! I noticed that when I hit TAB in bash, Hello.exe was marked executable.…
cat
  • 3,428
  • 4
  • 22
  • 50
14
votes
1 answer

How to install a functional ARM cross-GCC toolchain on Ubuntu 18.04 (Bionic Beaver)

Context I recently installed Ubuntu 18.04, Linux foobar-VirtualBox 4.15.0-23-generic #25-Ubuntu SMP Wed May 23 18:02:16 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux on a VM. I want to cross-compile applications for Cortex-M4F CPUs with hard floating…
Tim
  • 241
  • 1
  • 2
  • 7
14
votes
3 answers

How to find out triplet without gcc?

I try to find out the triplet for my device, because i try to cross compile, but there is no gcc installed on the target device and i am not allowed to install it. With gcc installed i could just write gcc -dumpmachine Is it possible to find this…
Black
  • 1,989
  • 7
  • 28
  • 58
14
votes
5 answers

using cross-compiled Valgrind

I have downloaded the sources from the Valgrind trunk and built it for using on an embedded Linux system(Montavista Linux) powered by an ARM926(ARMv5t architecture). Everything went well until I tried to run it to check some application I've made;…
celavek
  • 745
  • 3
  • 8
  • 11
14
votes
1 answer

Cross compiling GLIBC for my ARM SoC

I am seeing something really weird inside a chroot-ed Debian armel environment. But first, a bit of backstory... This is long, but the question is complex and any potential help depends on knowing the full story. I have an embedded ARM SoC that runs…
ttsiodras
  • 2,301
  • 1
  • 21
  • 26
13
votes
1 answer

How do I cross-compile Chromium for ARM?

Goal I need to install Chromium on FriendlyARM mini210s running Linux 3.0.8 armv7l Environment Vagrant box with Ubuntu Precise64 Installed depot_tools following these guidelines Get-the-code and Linux Chromium ARM Toolchain depot_tools After…
zabumba
  • 904
  • 10
  • 28
  • 50
12
votes
3 answers

How to cross-build a Debian package

I want to build an armhf package on an amd64 machine. My armhf machine is a lot slower than my amd64 one.
tshepang
  • 64,472
  • 86
  • 223
  • 290
12
votes
1 answer

GCC error trying to exec 'cc1'

I was cross-compiling a Linux kernel for my Raspberry Pi on a laptop (running debian 7) (followed the instructions in Raspberry Pi Kernel Compilation); but when compiling with make ARCH=arm CROSS_COMPILE=${CCPREFIX} I get the following messages: …
bulkmoustache
  • 679
  • 2
  • 10
  • 22
11
votes
2 answers

How to install cross-compiler on Ubuntu 18.04?

My proc info: lscpu Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Byte Order: Little Endian CPU(s): 4 On-line CPU(s) list: 0-3 Thread(s) per core: 1 Core(s) per socket: 4 Socket(s): 1 NUMA…
MikiBelavista
  • 1,473
  • 8
  • 28
  • 38
10
votes
1 answer

How to build the GCC cross compiler for Cross Linux From Scratch (CLFS) for Beagleboard?

Currently I try to build a embedded Linux from scratch with the instructions from Cross Linux from Scratch. Everything worked fine until I tried to compile the GCC Cross-Compiler. I want to build the Linux for the Beagleboard-xM... So I choosed the…
Pascal
  • 201
  • 4
  • 8
8
votes
1 answer

Running executable file: No such file or directory

I am trying to run an executable file called i686-elf-gcc in my Kali Linux that I downloaded from this repository. It's a cross-compiler. The problem is that even though the terminal and a script that I wrote can both see that the file exists, when…
blacklister
  • 93
  • 1
  • 1
  • 3
8
votes
1 answer

how to disable test programs in cross-compiling glib

I've the following errors when trying to cross-compile glib, with the following configuration parameters: ./configure --prefix=$HOME --host=arm-hisiv400-linux checking for growing stack pointer... configure: error: in…
rainfrost
  • 377
  • 2
  • 6
  • 12
7
votes
1 answer

Error compiling buildroot

I updated my buildroot for the version "2014.08" (stable version) and I updated the Kernel version (3.12.26) of my project, when the buildroot try to build the linux-headers-3.12.26 package, occurs the following…
Pedro Durek
  • 265
  • 2
  • 7
7
votes
1 answer

Building 32-Bit on a 64-Bit system

I'm trying to build the PHP memcache extension (v2.2.6) for i386 (32bit) on my x86_64 Ubuntu 11.04. ./configure uses config.guess by default (which outputs x86_64-unknown-linux-gnu on my system) but I want to override that. How would I have to…
thwd
  • 203
  • 2
  • 7
6
votes
3 answers

Why is the Canadian Cross used for cross-compilation in Linux From Scratch?

I'm going through the Linux From Scratch 11.0 book. In III. Building the LFS Cross Toolchain and Temporary Tools, ii. Toolchain Technical Notes, there is a bit about Canadian Cross cross-compilation. I do not understand why there need to be 3 stages…
mnj
  • 271
  • 2
  • 10
1
2 3
17 18