I’m building a simple C++ program and I want to temporarily substitute a system supplied shared library with a more recent version of it, for development and testing. I...
I’m compiling my C++ app using GCC 4.3. Instead of manually selecting the optimization flags I’m using -march=native, which in theory should add all optimization flags applicable to the...
I know I can generate debug symbol using -g option. However the symbol is embeded in the target file. Could gcc generate debug symbol outside the result executable/library? Like...
I’m working on a project that will read compiler error messages of a particular variety and do useful things with them. The sample codebase I’m testing this on (a...
When I’m compiling openvswitch-1.5.0, I’ve encountered the following compile error: gcc -Wstrict-prototypes -Wall -Wno-sign-compare -Wpointer-arith -Wdeclaration-after-statement -Wformat-security -Wswitch-enum -Wunused-parameter -Wstrict-aliasing -Wbad-function-cast -Wcast-align -Wstrict-prototypes -Wold-style-definition -Wmissing-prototypes -Wmissing-field-initializers -Wno-override-init -g -O2...
Is there a way for gcc/g++ to dump its preprocessor defines from the command line? I mean things like __GNUC__, __STDC__, and so on. 6 Answers 6
For convenience I added the relevant manpages below. My (mis)understanding first: If I need to separate options with ,, that means that the second -Wl is not another option...
I’m trying to debug a compilation problem, but I cannot seem to get GCC (or maybe it is make??) to show me the actual compiler and linker commands it...
I’m trying to use GCC (linux) with a makefile to compile my project. I get the following error which is can’t seem to decipher in this context: "No rule...
I keep hearing about LLVM all the time. It’s in Perl, then it’s in Haskell, then someone uses it in some other language? What is it? What exactly distinguishes...

