Questions tagged [g++]
48
questions
1
vote
1
answer
5k
views
How do you change versions of gcc on windows?
I've been using g++ 4.8.1, mingw. Now, I've just updated to 6.3.0, however when I use g++ in command prompt it still seems to use the older version. How do you change between versions on windows?
3
votes
2
answers
18k
views
Version `GLIBCXX_3.4.15' not found in CentOS (in file /usr/lib/libstdc++.so.6)
I try to use a program and I get the following error.
/usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.15' not found
Under /usr/lib64 the libstdc++ I see is libstdc++.so.6.0.13 (and a soft link).
...
0
votes
1
answer
4k
views
update gcc /g++ on CentOS 5.9
I would like to update gcc/g++ on my CentOS 5.9.
The version I have is 4.1.2 : Would it be possible to update it to 4.4.7 like CentOS 6.4 WITHOUT updating the entire operating system?
It looks to me ...
2
votes
0
answers
278
views
Is it possible to use Libtorch with VS Code?
I have followed the instructions provided by Pytorch to installing C++ distributions of PyTorch:
https://pytorch.org/cppdocs/installing.html
However, this command produces an error:
cmake --build . --...
0
votes
2
answers
388
views
Notepad++ NppExec: Redirect to file using '>' registers it as an argument and does not work, even though it works on the command line
Looking at the code below, it simply converts a c or c++ file, e.g. main.cpp into its state after preprocessing, e.g. main_pp.cpp.
However, running the command it generates, g++ -E "main.cpp"...
-1
votes
1
answer
205
views
Conditional statements with braces versus without braces - which is fast in C, C++ [closed]
I know this is silly, but I'm quite curious to know that is there any speed difference using conditional statement (i.e. for, if, while, do while) in C++ with braces and without braces.
FYI : I know ...
1
vote
1
answer
9k
views
Cannot find g++ after msys2 install
I want to install g++ so I can compile and run C++ code in VScode.
I started by trying to follow the VSCode-provided guide which states I need to install mysys.
I tried installing msys2 per the given ...
5
votes
1
answer
15k
views
How can I properly configure the g++ include path with mingw64?
I have installed msys2/mingw64 because I need the g++ compiler. Now, I want to compile some c++ oce which requires openblas. I have installed the package using pacman -S mingw-w64-x86_64-openblas. ...
0
votes
1
answer
408
views
Installing gcc 4.7.2 in MacOS (Monterrey)
I am trying to install gcc 4.7.2 (I need this version in order to be able to compile an old code), but I can not seem to find a proper way to do it. It looks like the only available options is to do ...
0
votes
1
answer
1k
views
How to compile text file to exe file with G++
I have c++ code saved in .txt file. Can i somehow format it with g++ compiler or i\ must change it to file.cpp?
Is there why how to compile a .txt file with g++?
Thanks for answare.
0
votes
2
answers
1k
views
How can I get g++ 7+ on windows 10?
I have just installed g++ using MinGW. When I tried g++ --version it says, that it is 6.3.0:
g++ (MinGW.org GCC-6.3.0-1) 6.3.0
Copyright (C) 2016 Free Software Foundation, Inc.
This is free software; ...
0
votes
1
answer
947
views
What is a purple file from the LS command?
I am working on a c++ project and had a failed compilation (normal kind of errors). When I ran ls (a bit of a habit), it showed a file with a seemingly random sequence of characters:
'!4'$'\377\377\...
2
votes
2
answers
4k
views
Add a permanent compiler option to g++
I am using a g++ 4.7 on Ubuntu 12.04 to compile my c++ code, and it won't be compiled unless an -std=gnu++11 option is added to my command like this:
g++ -std=gnu++11 main.cpp
Is there a way to add ...
0
votes
1
answer
149
views
Can g++ compilers be used to build linux software on macos?
On windows I am able to develop for linux using WSL2. I ususally use CLion which allows me to switch between msvc and g++ with a flip of a switch. Is it possible to do the same thing on Mac? If so, ...
0
votes
1
answer
112
views
Trouble updating G++ to version >5 using apt-get in Windows Subsystem for Linux
Context: I'm trying to run CMake as described here (under Linux-installing dependencies > Building OpenVDB). I'm in WSL.
When I do so I get this error:
CMake Deprecation Warning at CMakeLists.txt:...