Questions tagged [cross-compilation]

Questions about cross compilation - creating executable code for a platform different than the one on which compiler is running.

A cross compiler is a compiler capable of creating executable code for a platform other than the one on which the compiler is running. Cross compiler tools are used to generate executables for embedded system or multiple platforms. It is used to compile for a platform upon which it is not feasible to do the compiling, like microcontrollers that don't support an operating system. It has become more common to use this tool for paravirtualization where a system may have one or more platforms in use.

119 questions
16
votes
1 answer

How do I cross-compile my application for Ubuntu 12.04 armhf architecture on a Ubuntu 12.04 i386 host?

I have a large application I have written. I can successfully compile the application in the following scenarios: in a native compilation for the i386 host running Ubuntu 12.04 natively on a PandaBoard running Ubuntu 12.04 (this takes a long…
Jonathan Cave
  • 171
  • 1
  • 1
  • 4
13
votes
4 answers

fatal error: netlink/genl/genl.h: No such file or directory

I am cross-compiling hostapd for openwrt. I am getting fatal error: netlink/genl/genl.h: No such file or directory. I already have libnl-3.2.24 installed. If i directly compile (not cross-compile) then hostapd is compiling properly without any…
Rafal
  • 233
  • 1
  • 2
  • 4
13
votes
3 answers

How to use apt-get to download multi-arch library?

Is it possible to force apt-get to download a multi-architecture binary of the library I want to install? Or is apt-get not the right tool for this?
radj
  • 593
  • 2
  • 5
  • 7
12
votes
1 answer

How do I create a DMG file on linux Ubuntu for MacOS

I cross compiled a program on linux for MacOS and now I want that MacOS binary to convert to DMG file for MacOS. Is there a way to convert a MacOS binary on Linux (Ubuntu) into DMG file for MacOS?
9
votes
1 answer

Building a windows executable in qt on a Linux system

I have been having the hardest time trying to compile a .pro file in Linux to make a windows executable. I have read all the links in the world on using mingw and nothing has worked as of yet. Is there something I'm missing or does anyone have a…
Sagebrushwilly
  • 103
  • 1
  • 1
  • 3
9
votes
3 answers

Is there way to compile Qt5 programs, written with c++, to Ubuntu Touch?

I'm creating a program with Qt5 and C++, and I would like to compile my program for Ubuntu Touch Preview or Ubuntu desktop arm. I'm running those systems on Nexus 7. I have found the right C++ compiler (arm-linux-gnueabihf-g++), but how can I get…
8
votes
1 answer

14.04.01 32-bit: Missing g++ 64-bit include files when cross-compiling

So, I've got 32-bit Xubuntu 14.04.1 installed. We have some interface code where we intend to release SOs for the various platforms we support, and Windows DLLs. (Yes I know, binary release bad, but also not relevant here.) I'm trying to build…
Graham
  • 202
  • 1
  • 2
  • 8
8
votes
3 answers

How to cross-compile programs for the Raspberry Pi with gcc?

I am fond of using gcc to compile small little C and C++ programs on my main computer. However, I also have a Raspberry Pi, and, being a 700-MHz single-core computer, I would prefer to not have to do my development work on it every time I want to…
fouric
  • 4,498
  • 13
  • 36
  • 68
7
votes
1 answer

How to Cross Build Latest Stable Qemu with x86_64-w64-mingw32

Installed the mingw and cloned the "latest stable" branch of QEMU with sudo apt-get install -y mingw-w64 cd ~/ git clone -b stable-2.2 git://git.qemu.org/qemu.git cd ~/qemu Then from @http://wiki.qemu.org/Hosts/W32#Building_QEMU_for_W64 I…
GlassGhost
  • 105
  • 1
  • 9
6
votes
2 answers

Error while loading shared library libz.so.1 while cross compiling for arm-linux

I'm trying to cross compile an opencv app on Ubuntu 14.04 to run on an ARM core. I can compile the open cv app fine on Ubuntu with g++ test.c -o test -I /usr/include/opencv -I /usr/include/opencv2 -L /usr/local/lib/ -lopencv_core -lopencv_imgproc…
Mark Corrigan
  • 181
  • 1
  • 1
  • 5
6
votes
0 answers

Cross compile for ARM using gcc-multilibs

There are various questions available in AskUbuntu related to Cross compiling. They were not of much help to me. I used to work on gcc-4.5/4.6 for ARM. It was available in Ubuntu repo under the name gcc-4.*-arm-linux-gnueabi My host linux is running…
Anoop K P
  • 306
  • 3
  • 11
6
votes
3 answers

Cross-compilation issues with GCC/G++

I am using gcc to compile a C++ application on my CI server (http://ci.berboe.co.uk) and as the vps that it is compiled on has the x86-64 architecture I need to cross-compile to get the compiled program to work on x86 computers. I have installed…
hifkanotiks
  • 113
  • 1
  • 1
  • 8
5
votes
2 answers

Help with cross-compiling for ARM

I have recently been trying to cross-compile programs for ARM. However, when I run make, I always get an error within a minute or less that says something like /usr/lib/gcc-cross/arm-linux-gnueabihf/4.8/../../../../arm-linux-gnueabihf/bin/ld:…
John Scott
  • 1,442
  • 6
  • 23
  • 48
5
votes
3 answers

Install crossbuild-essential-armhf on amd64

Right now, while working on my laptop (amd64), I can already compile code through SSH on a BeagleBone (armhf). What I'm trying to do now, is being able to use any IDE to debug that code (Code::Blocks, KDevelop, or Qt Creator). So, I thought of…
Joao Pincho
  • 159
  • 1
  • 1
  • 5
5
votes
1 answer

fatal error: avr/io.h: No such file or directory compilation terminated

How to load avr/io.h header files in the gcc compiler..I'm using 12.04 version of Ubuntu.. When ever i run a AVR program this kind of error is generating fatal error: avr/io.h: No such file or directory. compilation terminated."
yashwanth
  • 81
  • 1
  • 2
  • 4
1
2 3 4 5 6 7 8