Quantcast
Channel: Active questions tagged gcc - Stack Overflow
Browsing all 21994 articles
Browse latest View live
↧

How do I find the actual GCC error in compiler output?

I'm trying to compile some old software from source on debian-based linux. The build failed:make[2]: Leaving directory '/home/owner/kallistios/utils/dc-chain/build-gcc-sh-elf-4.7.3' Makefile:871:...

View Article


GCC reordering up across load with `memory_order_seq_cst`. Is this allowed?

Using a simplified version of a basic seqlock , gcc reorders a nonatomic load up across an atomic load(memory_order_seq_cst) when compiling the code with -O3. This reordering isn't observed when...

View Article


Compiling C++ in VSCode gives me an undefined reference

normally i use VS19 for C++ programming, but i wanted to try if it works on VSCode on my Macbook, so i wrote i real simple programmmain#include <iostream> #include "test.hpp" using namespace std;...

View Article

Linking Fortran and C++ binaries using gcc

I can use gcc to make calls between C and C++ or between C and Fortran by using g++ or gfortran, respectively. But if I try to make procedure calls between C++ and Fortran I get errors when compiling...

View Article

A strange question of transferring a project from debian to ubuntu

I have an ics project assignment which I firstly wrote, compiled and run on the debian. When I try to transfer the project to ubuntu 19.10 and 18.04, I found a Dynamic Link Library wrong of stdio2.h as...

View Article


How do I install imagemagick with homebrew?

I'm trying to install Imagemagick on OSX Lion but something is not working as expected.-> brew install imagemagick /usr/local/git/bin/git ==> Cloning https://github.com/adamv/ImageMagick.git...

View Article

What's the right behavior when overloading operator delete without...

The following code behaves differently with clang (version 5.0.0-3~16.04.1 on x86_64-pc-linux-gnu) and gcc (9.2.0).void operator delete(void* ptr) noexcept { std::cout << "overloaded...

View Article

Image may be NSFW.
Clik here to view.

How to configure Visual Studio Code on UBUNTU to compile gstreamer files

I have gstreamer and VSC installed on UBUNTU 18.04, and I can compile and run gstreamer tutorials from system command prompt by using instructions here:...

View Article


Using builtin overflow functions with uint64_t types

I am currently writing a program which makes heavy use of the uint64_t type, to enhance compatibility across platforms. As it happens, there are a lot of possibilities for overflows in my program, so I...

View Article


don't understand the difference between "gcc -c file.c" and "gcc -o file.c"...

Command :`gcc -c -Wall hello.c` Here is the error : while calling ./hello.obash: ./hello.o: cannot execute binary file: Exec format error need help please ..

View Article

Can't find file executable in your configured search path for gnc gcc compiler

My problem is that code::blocks error message tells me that it can't find file executable in the search path for gnc gcc compiler. Although, I don't know what that means. Also I typed out some...

View Article

What is it called when a block returns a value?

I came across this code recently, which doesn't look legal to me (but gcc compiles it). I don't so much mind the construction as want a name for it:#define MAX(a,b) \ ({ \ typeof(a) _a = (a); \...

View Article

What is the execution order of xxxxboard.c in u-boot?

The board.c contains many functions but no main function,and will all functions be executed in order?Is there an order of execution?eg: int get_memory_base_size() int dram_init(void) int...

View Article


Compiling CMSIS DSP and NN for GCC Linux

I'm trying to find away to Compile CMSIS DSP and NN sources for GCC Linux. I need to do that for the unit test of the project. Does anyone know how to do it?

View Article

LD_LIBRARY_PATH doesn't seem to work

I'm trying to compile a test file:gcc -o test test.c -lg2c but I get the error:/usr/bin/ld: cannot find -lg2c If I use:gcc -o test test.c -L/usr/lib/gcc/x86_64-redhat-linux/3.4.6 -lg2c then it works...

View Article


Floating Point Multiply Bug Using gcc 2.7.0 on Amiga with 68881 - Any...

For the heck of it, I decided to see if a program I started writing on an Amiga many years ago and much further developed on other machines would still compile and run on an Amiga (after being...

View Article

R package installation in Linux

I am trying to install a R package in Ubuntu using the following commands:R CMD INSTALL rpart_4.1-5.tar.gz install.packages("/home/rpart_4.1-5.tar.gz", repos = NULL, type="source") * installing to...

View Article


MinGW g++: Multiple definition of vsnprintf when using to_string

I just started using MinGW for Windows. When trying to create executable usingg++ a.cpp -o a.exe -std=c++14for the code below:#include <string> using namespace std; int main() { string x =...

View Article

gcc shows different warnings depending on optimisation level

I compiled a C program with -O0 -Wall and then -O1, -O2, -O3 and I received different warning messages, some of them actually important enough that they showed actual bugs (for instance a function...

View Article

Compiler optimization of strcmp I don't understand, against a constant string

In order to improve my binary exploitation skills, and deepen my understanding in low level environments I tried solving challenges in pwnable.kr, The first challenge- called fd has the following C...

View Article
Browsing all 21994 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>