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

VS Code will not build c++ programs with multiple .ccp source files

Note that I'm using VS Code on Ubuntu 17.10 and using the GCC Compiler.I'm having trouble building a simple program which makes use of additional .ccp files. I'm probably missing something obvious here...

View Article


How can I compile the Linux Kernel getting the output of the preprocessor too?

I know that with gcc -E you can get the output of the preprocessor, but what I have to do to get that output for every source code file in the Linux Lernel as part of the compilation process?

View Article


Cannot compile my Makefile? Undefined reference to symbol 'pow@@GLIBC_2.2.5'...

This question already has an answer here:ld: undefined reference to symbol 'log2@@GLIBC_2.2.5' 1 answerI'm trying to compile my code with a Makefile but I keep getting the error:Undefinded reference to...

View Article

Compare and swap C++0x

From the C++0x proposal on C++ Atomic Types and Operations:29.1 Order and Consistency [atomics.order]Add a new sub-clause with the following paragraphs.The enumeration memory_order specifies the...

View Article

Nasm is not recognized as internal or external command

I am working on a java compiler project coded in python open source github link ishttps://github.com/abhigarg-iitk/java_compiler this compileris working and converting java file into assembly language...

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

How to fix this C++ UBSAN vptr runtime error (runtime error: member call on...

I enabled ubsan test (-fsanitize=undefined) in my project and found some ubsan runtime errors. Can anyone help me find why it failed here? How to fix this issue on GCC and Clang?Here is the lib.so...

View Article

Not able to install Nokogiri because of gcc on MacOS Catalina

I am trying to install nokogiri on my MacOS Catalina 10.15.1 gem install nokogiri The error in the log file I see is as following "gcc -o conftest...

View Article


File not recognized: File truncated GCC error

I'm trying to compile a simple "Hello World" program in Linux using Eclipse, but I always get this:Building target: hello Invoking: GCC C++ Linker g++ -o "hello" ./src/hello.o ./src/hello.o: file not...

View Article


Should I still define _GNU_SOURCE when I compile with -std=gnu99?

I use some GNU extensions and realized that if I set gnu99 as C-standard to use, I can omit #define _GNU_SOURCE. Does gnu99 imply the _GNU_SOURCE or is it still safer to use it or mandatory to avoid...

View Article

c++ secondary dependency resolution with runpath

I have the following problem: I am trying to build software on an Ubuntu18 by using the default gnu compiler (gcc-7) and linker versions available.Now we have the case, that an executable may link a...

View Article

undefined reference to RcppArmadillo

I am new to Rcpp. I am seeking help with the following problem. It seems that the RcppArmadillo does not work. Could someone give me some suggestions? Many Thanks!g++ -m64 -I"D:/R/R-32~1.5/include"...

View Article

gcc flags to disable arithmetic optimisations

Does gcc/g++ have flags to enable or disable arithmetic optimisations, e.g. where a+a+...+a is replaced by n*a when a is an integer? In particular, can this be disabled when using -O2 or -O3?In the...

View Article


OpenMP reduction issue with Cython

I am facing an unexpected behavior of Cython (v. 0.29.13) when compiling OpenMP parallel code that is expect to perform a reduction:import cython from cython.parallel import prange, parallel cpdef...

View Article

Which function is used when loading two shared libraries with same statically...

I been reading and trying to understand how symbols get resolved within a shared library in Linux. So here is a description of what I am faced with.I am using an application (APP) that can load user...

View Article


C basic memory management implementation

I am trying to write a basic memory management system to a C library project in a GCC environment, and came here to ask if what I am doing is permitted or advisable by C standards.Basically, my code...

View Article

strtok returns zero with length one string

I'm trying to parse a CSV to a double matrix. The string could look like so "1,5\n6,4\n,4.2,6.8\0".The variables are declared outside of the loop as follows:double csv [MAX_SIZE, MAX_SIZE];...

View Article


Division and modulus using single divl instruction (i386, amd64)

I was trying to come up with inline assembly for gcc to get both division and modulus using single divl instruction. Unfortunately, I am not that good at assembly. Could someone please help me on this?...

View Article

Issues compiling Scotch with mingw toolchain on Windows

I'm trying to compile the Scotch partitioning library on Windows with the Mingw gcc toolchain (tried using both TDM GCC 5.1 and MSYS2 GCC 8.3) with identical issues (compiling on linux works...

View Article

Does the linker look for the header file

When compiling C source files, we include header files for example using #include "myheader.h".The pre-processor will expand this header file before compiling the file. However, how does it find this...

View Article
Browsing all 22024 articles
Browse latest View live


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