Questions tagged [gcc]

The GCC (GNU Compiler Collection) is a set of compilers for various high-level languages. Use this tag for questions related to how to install and use the GCC.

Filter by
Sorted by
Tagged with
-1 votes
1 answer
22 views

SOLVED Sudo is broken, missing libgcc_s.so

tl;dr Which version of gcc should I install? Not sure exactly how it happened. It might have been caused by the last upgrade but sudo somehow broken. Any sudo command I try to run outputs the same: $ ...
mixcas's user avatar
  • 1
0 votes
1 answer
947 views

What's the simplest way to get GCC 11, 12 or 13 onto the latest Raspberry OS?

The latest Raspberry OS comes with GCC 10, which is seriously outdated by now. apt does not know of any versions beyond gcc-10. How should I get a newer version onto the system? Is there an unofficial ...
Violet Giraffe's user avatar
0 votes
0 answers
22 views

pari gp ínstallation in rpi

I am trying to compile one of a project with pari library dependency but i am facing below error while running the configuration file. Its installing just fine in ubuntu and windows but not here. I ...
avr's user avatar
  • 1
1 vote
0 answers
45 views

quadmath on Raspberry Pi 64 bit

Good afternoon, am I correct in understanding that gcc's quadmath cannot be used / built on a Raspberry Pi 4? The gcc compiler there does not recognise it, and it does not appear installable with sudo ...
AJS's user avatar
  • 11
0 votes
2 answers
3k views

Makefile file format not recognized when using cross compiler

I setup a container to cross compile my program so taht i can run it on a Raspberry Pi. It compiles fine when using ${CC} but prints: /usr/bin/arm-linux-gnueabihf-gcc -o test main.o CAcquireData.o ...
MisdeBug's user avatar
3 votes
1 answer
8k views

Updating to newest GCC/G++

After updating my Raspbian Pi 4B through sudo apt update && sudo apt upgrade -y, I noticed that it has quite old GCC/G++ version 8.3.0 while there exists already release of 11.2. Can anyone ...
Arty's user avatar
  • 131
1 vote
0 answers
1k views

Failed building wheel for pandas on model 3B+

I'm trying to install pandas in a Python virtualenv on a RPi model 3B+, but its wheel fails to build. Pandas does however successfully build/install for the system Python (py3.7.3, pip 18.1). Could ...
jrbergen's user avatar
  • 111
0 votes
0 answers
926 views

Package gcc-arm-linux-gnueabi is not available, but is referred to by another package

I try to compile a piece of software with a pre-defined Docker-enviroment, where following packages are getting installed: gcc-arm-linux-gnueabi, g++-arm-linux-gnueabi, gcc-arm-linux-gnueabihf and g++-...
Standard's user avatar
  • 113
4 votes
2 answers
3k views

Running ARM64 binaries on RP4

I'm trying to run an ARM64 binary on my RP4 with arm_64bit enabled in /boot/config.txt. I get an error: No such file or directory. Running file cloudflared-linux-arm64 I get: cloudflared-linux-arm64: ...
bertday's user avatar
  • 151
-1 votes
1 answer
554 views

Pi 4 doesn't recognize .o file format? [closed]

Was trying to compile some .c files along with one .o file using gcc, and it failed with an error message saying: .o file format not recognized. The same files got compiled on centOS vm though.
Steve's user avatar
  • 1
1 vote
1 answer
2k views

How can I fix "atomic" related issues in my build?

I'm trying to build gRPC using this tutorial (https://lzqblog.top/2018-11-08/Cross-compile-gRPC-for-ARM/) but I still get "atomic" related issues (undefined reference: __atomic_fetch_add_8 )....
Don Madrino's user avatar
-1 votes
1 answer
176 views

Code not compiling on raspberry pi 4 but compiles fine on rasperry pi 3 B

https://github.com/ABHIRAMSHIBU/rpimultiboot/ I have this code, currently I didn't polish it at all because its under development. But I am having an issue with compiling this. I have a sdcard with ...
Abhiram Shibu's user avatar
1 vote
2 answers
6k views

wiringPi.h not found by gcc. Works in Raspian, not Ubuntu Mate

This is my first time posting on stack exchange so I apologize if this is too much or not enough info on the problem. A few months ago I installed Ubuntu Mate 18.04 on a Raspberry Pi 3B+ and tried to ...
Silas D.'s user avatar
3 votes
1 answer
1k views

Why does the new Raspberry Pi OS come with a version of GCC that targets ARMv6 by default?

The August 2020 version of Raspberry Pi OS ships with arm-linux-gnueabihf-gcc-8. Checking arm-linux-gnueabihf-gcc-8 -v I see that it has this option set: --with-arch=armv6. However, the new Raspberry ...
David's user avatar
  • 693
1 vote
0 answers
119 views

How do I use the proper linux header extension folder

I am trying to build a TP-Link driver and when I run make I get... "******************************************" "NO SKRC,we will use default KSRC" "******************************************" make ...
Jackie's user avatar
  • 181
1 vote
3 answers
4k views

How can I run 32-bit compiled assembly code on Rasberry PI 4 B, if possible at all?

I bought the PI 4 B for a university project, as I have to make small 32-bit ARM assembly program. However I realized it too late, that it comes with an aarch64 architecture ARM processor. I would ...
Balázs Börcsök's user avatar
1 vote
0 answers
267 views

Why does writing to I2C is too slow in Python comparing to C? [closed]

I am trying to find out why the same code in Python works 25 times slower than C even if I use CDLL, when I try to write into I2C. Below I will describe all the details what I am doing step by step. ...
Fomalhaut's user avatar
  • 111
1 vote
1 answer
1k views

symbol lookup error: undefined symbol: _ZN7QWidget8qwsEventEP8QWSEvent

I have cross-compiled executable file from QT 4.8.7. I am running it on a Raspberry PI (Ubuntu), with QT 4.8.7 and QT declarative module installed. When i run the executable file on my raspberry pi, i ...
Mehta's user avatar
  • 31
1 vote
0 answers
198 views

Strange segfault after several hours of running program

I created a program fairly closely related to hello_pi/hello_video.c. And for some reason after several hours of running the program I get these very strange segfaults that I cannot for the life of me ...
ktb92677's user avatar
  • 141
5 votes
1 answer
2k views

AddressSanitizer on Raspbian

I am trying to use AddressSanitizer on Raspbian. I use the following to compile my program: gcc -fsanitize=address -fno-omit-frame-pointer -g prog.c -o prog Even for the simplest program (just a ...
Szabolcs's user avatar
  • 672
-1 votes
1 answer
359 views

Not able to compile the u-boot 2017.09

This is the OS info that I am using in my pi3 (BCM 2837) board. pi@raspberrypi:~ $ uname -a Linux raspberrypi 4.14.98-v7+ #1200 SMP Tue Feb 12 20:27:48 GMT 2019 armv7l GNU/Linux [ am I using the ...
siddharthav's user avatar
3 votes
1 answer
702 views

How to compile project on Raspberry Pi, even when g++'s virtual memory exhausted despide big SWAP?

I want to build Iroha hyperledger on Raspberry Pi 3. So I've downloaded code and all dependencies and compiler gcc-8.2 (downloaded precompiled from here), then configured without tests: cmake -...
baziorek's user avatar
  • 141
3 votes
1 answer
4k views

Problem with gcc/g++ versions

I'm currently setting up Homebridge to run on my Pi using this installation guide. I have run into a problem regarding the C++ compiler section; I understand that this part of the guide is out of date ...
Rocco's user avatar
  • 133
0 votes
1 answer
582 views

GCC and makefile on Raspberry Pi running NOOBS deletes my c file

I am having an issue with my pi where I run gcc or make from the terminal and my main c file included in the compilation is deleted. I am using the wiringPi library to communicate with some sensors ...
mike's user avatar
  • 13
2 votes
1 answer
189 views

Compiling GCC 8.1.0 on Pi64

I have installed Pi64 from here. I want to compile GCC 8.1.0 as per the instructions here. However the text of the article sets the target architecture to --with-arch=armv6 which is 32bit? Should/...
graham.reeds's user avatar
6 votes
1 answer
570 views

gcc manual not found

I wanted to see gcc's maual but $ man gcc No manual entry for gcc See 'man 7 undocumented' for help when manual pages are not available. $ man gcc-XX No manual entry for gcc-XX $sudo nano /etc/apt/...
SuperPizz's user avatar
1 vote
0 answers
158 views

Installing a higiher version of GCC on Wheezy that doesn't rely on a newer glibc [closed]

We have software that we distributed to a bunch of Pis that have Raspian Wheezy. Recently, we've added in a bit of code that uses C++ standards that aren't integrated until >=gcc-4.8. If I compile on ...
Mikey A. Leonetti's user avatar
1 vote
1 answer
1k views

Adding gcc compiler to Poky image for raspberry Pi

I am using raspberry Pi 3 running a poky image built using the Yocto project. Is there any possible solution to add gcc compiler to the image? I found the cross-compilation very complicated and ...
Ahmed's user avatar
  • 45
3 votes
2 answers
6k views

Error while loading shared libraries: foo.so: cannot open shared object file: No such file or directory

I have cross compiled c++ code for raspberry pi. Below is process I followed: 1) Cloned the official toolchain from raspberry pi github. Set the environment variable of arm-linux-gnueabihf-c++ (in ....
Aniket Pawar's user avatar
0 votes
3 answers
1k views

GCC version for compiling a loadable kernel module

I am not very familiar with Linux, so may be my question is a little bit foolish. I would like to compile kernel module without recompiling the kernel (USB Wi-Fi stick driver for MT7106U chip). I ...
cyclone125's user avatar
5 votes
3 answers
10k views

What is the gcc and g++ version in Raspberry Pi 2 and 3?

I am reading an article on raspberry pi on a local magazine and they do this sudo apr-get install gcc-4.8 g++-4.8 sudo rm -rf /usr/bin/gcc sudo rm -rf /usr/bin/g++ sudo ln -s /usr/bin/gcc-4.8 /usr/...
KansaiRobot's user avatar
1 vote
0 answers
227 views

Cross Compile on maxOS fails linking System library (CMake), but other libraries succeed

tl;dr - CMake fails at linker not finding System library with precompiled RaspberryPi toolchain when other libraries work So I've been fighting this for a few days, and I believe I'm nearing the end ...
au42's user avatar
  • 11
0 votes
1 answer
730 views

Where can I get a COMPLETE libfcgi install for Pi 3B

I used apt-get to install the fastcgi package recently (sudo apt-get install libfcgi) and my Pi3B duly chuckled away then announced that it hwas finished. BUT when I tried to compile the backend to ...
OldBikerPete's user avatar
2 votes
1 answer
2k views

Raspberry Pi 2 NEON instruction set, vector report generation?

Lately I have been trying to generate a vector report of an OpenCV project implemented on the raspberry pi 2 model B, but for some reason there is no output. The same algorithm produces vector report ...
Ragesam's user avatar
  • 41
0 votes
1 answer
363 views

Cross compiler gcc on Raspbian

Is it possible to install cross compiler on Raspbian? I mean arm-linux-gcc. I would like to try compile cross platform project on Raspbian instead of on virtual machine with Ubuntu.
kmbm's user avatar
  • 1
2 votes
1 answer
276 views

Arguments for execl compiling with gcc [closed]

I have a weird problem with a Raspberry Pi 2 (model b). I'm compiling the following program in GCC in Raspbian Jessie (Linux raspberrypi 4.4.11-v7+ #888 SMP Mon May 23 20:10:33 BST 2016 armv7l GNU/...
DBNinja's user avatar
  • 21
0 votes
1 answer
2k views

G++4.9 not found, Raspberry Pi Jessie

I am trying to install gcc4.9 and g++4.9 on my raspberry pi jessie. I am following this tutorial, however when it comes to running: sudo apt-get install gcc-4.9 g++4.9 I get: Reading Package Lists....
Chud37's user avatar
  • 101
0 votes
1 answer
790 views

C Program compilation problem [closed]

I wrote a program using nano and tried to compile it using gcc command on Lx-terminal. It's showing stray error. Can anyone tell me what is the problem? For simple "hello world" program also is ...
user42939's user avatar
2 votes
0 answers
1k views

How to compile boost libraries [closed]

I'm trying to compile boost libraries that I need for compiling and installing Ocelot tracker on the Raspberry Pi. I tried with libraries from apt-get but it doesn't work. These are instructions for ...
Johnny Vodka's user avatar
1 vote
1 answer
149 views

Foreign characters showing from gcc compiler output

My locales are are set to generate en_US.ISO-8859-15 ISO-8859-15 and en_US.UTF-8 UTF-8. However the borders of raspi-config still have borders showing the accented âââ. And the gcc compiler output ...
Old Geezer's user avatar
1 vote
1 answer
419 views

CMake error while doing yotta build on Raspberry Pi

I am getting following error while I run 'yotta build' command. I am trying to install mbed client on Raspberry Pi. I am following this tutorial mbed client linux example Error: info: generate for ...
Ameya Chikodi's user avatar
2 votes
1 answer
2k views

Cross-Compiling kernel can't find gcc

I am cross compiling the Raspbian kernel since it will take about 12 hours for the Pi to do (Raspberry Pi 1). I have the build tools for ARM and the kernel in two separate folders in /home/gray/...
Gray's user avatar
  • 41
2 votes
0 answers
2k views

Which gcc compilation flags should use for RPi1 model B ? what is the ABI, architecture and CPU?

I want compile some binaries for RPi model B (revision 2.0) 512MB , I got installed arm-linux-gnueabi-gcc on Fedora 23 dnf copr enable lantw44/arm-linux-gnueabi-toolchain dnf install arm-linux-...
Sérgio's user avatar
  • 121
3 votes
1 answer
232 views

Compile GCC for Raspberry Pi 2B - Patches required?

I need to compile a modern version of GCC in order to compile CMake in order to compile OpenCV 3.0.0. So I want to compile a modern and stable version of GCC for the Raspberry Pi 2b. I've read this ...
Zelphir Kaltstahl's user avatar
2 votes
1 answer
576 views

Error compiling kernel using guide provided on Raspberry Pi website

I'm encountering errors while trying to compile the kernel from source. I've looked around but I'm not finding anything that deals with the error I'm seeing specifically. I am using the guide on the ...
nerdenator's user avatar
-1 votes
1 answer
268 views

Cannot compile anything on raspberry or works code I compile in another linux

I got a simple C++ code. The hard part is that I use -std=c++11 flag. I've tried: Compiling on Mint Code::Blocks and then move bin to run it: cannot execute binary file Compiling on gcc 4.6.3 ...
windman's user avatar
  • 79
-1 votes
1 answer
546 views

gcc -L .so and .a files [closed]

I am examining gcc with an example that uses the -L option this seems to point to a directory where I see .so and .a files. Can anyone explain the meaning of these two file types (it doesn't seem to ...
user30803's user avatar
  • 103
1 vote
2 answers
4k views

Cross-compiling to Raspbian

I have Raspbian Jessie installed on my Raspberry PI, and I have a virtual box with a fresh install of Debian Jessie for amd64 with the armhf architecture enabled, and with the ARM cross toolchain from ...
naasking's user avatar
  • 191
2 votes
2 answers
344 views

Not able to fetch register values using Mike M's BCM2835 C code

I'm attempting to utilize the bcm2835_peri_read(uint32_t*) function from Mike M's BCM2835 code, however console-output-debugging indicates I'm continually getting back my address. I'm using g++ on ...
sctjkc01's user avatar
  • 306
2 votes
2 answers
2k views

How do I compile gcc 5 for my Raspberry Pi 2 [closed]

I have a Raspberry Pi 2. What is the best way to get a functional gcc 5 (from the current trunk) on the Raspberry Pi? Since compiling gcc takes a good two hours on my x86-based computer and probably ...
FUZxxl's user avatar
  • 129