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

Is there a way to use fopen_s() with GCC or at least create a #define about it?

MSVC compiler says that fopen() is deprecated, and recommends the use of fopen_s().Is there any way to use fopen_s() and still be portable?Any ideas for a #define?

View Article


How can I get armv7a-unknown-linux-android21 toolchain?

I'm trying to compile some kernel module for the android device. I tried to look which toolchain it uses by installing some C/C++ compiler from GPlay and looking on clang -v output.It is...

View Article


Is cmp faster with powers of two in assembly?

I was writing some code to clear the screen to a particular color. C++ code:void clear_screen(unsigned int color, void *memory, int height, int width) { unsigned int *pixel = (unsigned int *)memory;...

View Article

How to fix Ubuntu 18.04 declspec.h error?

I am trying to use "sbas_parallel.c" code in ubuntu 18.04,i install a "gcc" compiler and insert the written row below ;"gcc -fopenmp -w sbas_parallel.c -I/usr/local/include/gmt...

View Article

Image may be NSFW.
Clik here to view.

Can't get CLion to actually use GCC compiler instead of Clang?

I've tried following all the help to change my compiler to use GCC instead of Clang (on macOS) as I would like to try to use __gnu_pbds::priority_queue instead of the STL version, and it still appears...

View Article


gcc-4.9 Undefined Behavior Sanitizer

In gcc-4.9 changes it says:UndefinedBehaviorSanitizer (ubsan), a fast undefined behavior detector, has been added and can be enabled via -fsanitize=undefined. Various computations will be instrumented...

View Article

Function call in the assembly language before linking

I was going through the assembly code generated by the compiler. I am using the C programming language and GCC compiler.I wrote a function in C which adds two numbers by calling another function and...

View Article

Why -lm option is not required in MinGW GCC?

Compiler option -lm is required when compiling and linking program containing functions in math.h on Linux GCC, otherwise a link error will appear. However, -lm option is not required in MinGW GCC on...

View Article


restore broken cpp libs linux

So, I was trying to compile dlib but it spitted out many errors. Appearently, my cpp files are broken.Even as simple as compiling a cout << "Hello World"; with g++ resolves in issues.Here's the...

View Article


netinet/sctp.h: No such file or directory

I'm unable to include in any of my files. It always fails during compilation.I got the lksctp-tools package installed. I run gcc -Wall -lsctp -o client admin.c deserializer.c input_parser.c main.c...

View Article

How to add the missing os libraries to TI compiler

I am using Code Composer Studio to build application for the target EK-TM4C1294XL TI board.The TI boards come with their own compiler and the compiler is missing os libraries like wsock.lib and...

View Article

Volatile labels? [closed]

Is it possible to have volatile labels? Something like this:volatile coroutine:orcoroutine volatile:or maybe evencoroutine: volatileI want a label that won't be touched by optimizations. Is that...

View Article

How to suppress warnings for file included from header

I use GCC -Weffc++ option in my Qt project. To suppress warnings from Qt headers i add QMAKE_CXXFLAGS += -isystem $(QTDIR)\include.But this doesn't suppress all warnings, i still get annoying warnings...

View Article


How do I mangle C++ names (for GCC-compiled objects on Linux)?

I want to programmatically mangle the name of a C++ function or variable - to get the symbol name which would appear in a compiled object file. I'm using Linux and GCC.Now, why is this not trivial?...

View Article

Comparing two binary search tree

What I'm trying to do is compare two binary search trees. This is in order to count the number of repetition that occurs on them.First, I added this function that finds a specific element in a binary...

View Article


Visual Studio - CMake - Mingw64 Configuration

I'm using Visual Studio 2019 to create a cross-platform C++ CMake HelloWorld project.I've created the project using the Visual Studio 2019 Linux development with C++ toolset and created a newCMake...

View Article

Why can't I manually provide the template arguments?

I have a variadic template function f. This compiles fine (using g++ -std=c++11 and possibly using c++0x):#include <tuple>template<int ...>struct seq { };template <typename ...T, int...

View Article


Creating a whitelist (1000 random loci) from VCF file in R

Unfortunately, I am unable to use the Stacks software for genetics due to my lack of the required operating system. However, is there a way to generate a whitelist from a vcf file in R?

View Article

fatal error: json-c/json.h: No such file or directory Cross compiling on...

I am trying to compile my code on my Ubuntu x64 laptop for the Raspberry Pi. I am able to compile and run the code on Ubuntu laptop without any issue. However when I try to compile it for Raspberry Pi...

View Article

How does one create JSON-C library for ARM platform using GNU-Cross compile...

Folks,I need help to cross compile JSON-C source code available at https://github.com/json-c/json-c using the gcc compiler [GNU Cross Toolchain for the ARM processor].Thanks,GCB

View Article
Browsing all 22264 articles
Browse latest View live