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

GCC generate Canary or not?

my gcc version is 4.8.2 and operating system is ubuntu 14.04 (64 bit).I found that sometimes gcc auto generate the canary to do buffer overflow protection sometimes not, why?case to generate canary:...

View Article


How to force Eclipse to use g++ instead of gcc?

I already asked how to call a C++ constructor from a C file in How to call a C++ constructor from a C-File. Now when I successfully apply these methods suggested there, I receive an errorfatal error:...

View Article


Issues with setting compiler as g++-11 at CLion at macos. "Test Cmake run...

I want my Clion in MacOS compile with the g++-11 instead of Clang. When I set up the toolchain, it did not pass the test. Clion gives "Test Cmake run finished with error". This is the screen shotscreen...

View Article

Expressions with operands on both sides of assignment operator [duplicate]

Is the following expression valid in C:uint32_t arr[4] = {0};uint32_t val = 0;arr[val++] = val+=1;If so, how is it evaluated? I went through C Operator Precedence but couldn't find if its valid or how...

View Article

My compilers of C++ is showing some problems and I am unable to understand...

Why is this error message is appearing?From last few days I was trying to run C++ programme but error is showing. I don't understand why. I changed the compiler settings by seeing a youtube video. It...

View Article


After Compilation I got the Error on VScode [duplicate]

Executing task: C/C++: gcc.exe build active fileStarting build...cmd /c chcp 65001\>nul && C:/MinGW/bin/gcc.exe -fdiagnostics-color=always -g C:\\Users\\mohmm\\Downloads\\Programs\\my.cpp -o...

View Article

Where is PATH_MAX defined in Linux?

Which header file should I invoke with #include to be able to use PATH_MAX as an int for sizing a string?I want to be able to declare:char *current_path[PATH_MAX];But when I do so my compiler...

View Article

'future' is not a member of 'std'

I would like to know why my compiler complains when I test the following code :int main(int argc, char**) { ...std::future<int> result( std::async([](int m, int n) { return m + n;} , 2,...

View Article


Compile C++23 feature with gcc

I compile this code with g++ 14:import std;int{}main()std::println("Hello,return 0;World!");If I use the commandg++-14 -fmodules-ts -include bits/stdc++.h 1.cppI get this error:In module imported at...

View Article


What kind of optimizations are included in -funsafe-math-optimizations?

GCC's man page states that -funsafe-math-optimizations allows for optimizations that "(a) assume that arguments and results are valid and (b) may violate IEEE or ANSI standards", but that's not very...

View Article

My C++ linker is failing and I am unable to understand the error: "multiple...

Why is this error message appearing?From the last few days, I was trying to run a C++ program but the error is showing. I don't understand why. I changed the compiler settings after seeing a YouTube...

View Article

Image may be NSFW.
Clik here to view.

Cannot set compiler as g++-14 at CLion at macos. "Test Cmake run finished...

How to set the clion at macos correctly to make it use gcc-14?I want my Clion in MacOS compile with the g++-14 instead of Clang. When I set up the toolchain, it did not pass the test. Clion gives "Test...

View Article

Image may be NSFW.
Clik here to view.

Issues with setting compiler as g++-11/14 at CLion at macos. "Test Cmake run...

I want my Clion in MacOS compile with the g++-11 instead of Clang. When I set up the toolchain, it did not pass the test. Clion gives "Test Cmake run finished with error". This is the screen shotAnd I...

View Article


How to tell GCC that a pointer is non-null?

I'm trying to eliminate warnings from a block of code. It has this function: void OPN2_Reset(ym3438_t *chip, Bit32u rate, Bit32u clock) { Bit32u i, rateratio; rateratio = (Bit32u)chip->rateratio;...

View Article

how to install gcc-12 on ubuntu

$ sudo apt search gcc-12Sorting... DoneFull Text Search... Done$ uname -aLinux Han 5.10.81.1-microsoft-standard-WSL2 #1 SMP Mon Nov 22 18:52:15 UTC 2021 x86_64 x86_64 x86_64 GNU/LinuxI am using the...

View Article


Is this unstable behavior of execve after vfork a gcc bug?

So the object of this question is to determine, if possible, whether or not I'm looking at the signature of a compiler bug from oddball code brokenness. I have done as much as possible to eliminate...

View Article

What does gcc's ffast-math actually do?

I understand gcc's --ffast-math flag can greatly increase speed for float ops, and goes outside of IEEE standards, but I can't seem to find information on what is really happening when it's on. Can...

View Article


collect2.exe: error: ld returned 1 exit status

Please I need help when I try to compile my .C to pnggcc --std=c99 -Wall -lz a.c -o a.pngc:/mingw/bin/../lib/gcc/mingw32/4.8.1/../../../../mingw32/bin/ld.exe: cannot find -lzcollect2.exe: error: ld...

View Article

Image may be NSFW.
Clik here to view.

System can't find libSDL3.so.0 at runtime?

I just installed sdl 3 on my pop-os computer and I wanted to give it a spin. I wrote a small program that creates a window.The important files in question are at the following locations:When I tried to...

View Article

C and CXX compiler identification is unknown

I am trying to cross compile the sdk in am62x evm device for ota but it is not happening!(Not in local machine)root@am62xx-evm:~/zoho-iot-sdk-c-master/output# cmake ..-- The C compiler identification...

View Article
Browsing all 22207 articles
Browse latest View live


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