User forums > Help

updation compiler version

(1/2) > >>

maxcy:
Newby to this IDE! I am fooling around with <string_view> so I need to update to a much newer compiler to get this library to work. I finally got the newest compiler version downloaded and extracted into a folder. I noticed that this IDE has a MinGW folder to use it's compiler. I would like to know if all I have to do is copy and paste the new MinGW folder over the existing one in this IDE setup?  In DevC++ I have to add in the new compiler in it's compiler setup menu. I don't see anything like this in this IDE, but would like to make sure before I screw something up!
maxcy / wt1v

stahta01:

--- Quote from: maxcy on July 16, 2023, 06:36:50 pm ---Newby to this IDE! I am fooling around with <string_view> so I need to update to a much newer compiler to get this library to work. I finally got the newest compiler version downloaded and extracted into a folder. I noticed that this IDE has a MinGW folder to use it's compiler. I would like to know if all I have to do is copy and paste the new MinGW folder over the existing one in this IDE setup?  In DevC++ I have to add in the new compiler in it's compiler setup menu. I don't see anything like this in this IDE, but would like to make sure before I screw something up!
maxcy / wt1v

--- End quote ---

DO NOT COPY THE FILES OVER THE ONES IN THE MINGW FOLDER!

Tim S.

maxcy:
main.cpp (attached) will not compile. The version of g++ that is in the CodeBlock compiler is 8.1.0 and the new compiler that I installed is 13.1.0. So the string_view library is not being found by the old compiler.  I did try to install a new compiler version! Attached (globalcompilersettings) is the compiler setting that I made in accordance to the documentation on using a new compiler!  In the compiler list I have in the toolChain Executables tab, GNU GCC compiler selected, and you can see the path to the new compiler folder on the C drive. If I select a different compiler from the list, the path to a new folder shows up, so it is safe to think that the folder to the new compiler is OK! But the old compiler is still being used when I go back and compile this code!  How do I get this IDE to recognize the new compiler and not use the old one?  It took me 5 minutes to do this same task when I used my DevC++, but this IDE is very frustrating when trying to do such a simple task!
naxcy / wt1v

stahta01:
Set the compiler installation directory to the value of the new one you installed.

Edit: If you installed the C::B without the MINGW compiler, it might find the new compiler by clicking on auto detect; but, I am guessing CB would take the one in the mingw sub-folder if it exists. Note: Deleting the CB mingw sub-folder might bring back that ability; but, it fails to find the new compilers alot of the time.

Edit2: https://wiki.codeblocks.org/index.php/Installing_a_supported_compiler

Tim S.

maxcy:
When I first tried CB all was well until I tried to use an example that used the string_view example.  I downloaded and  installed the new compiler, version 13.1.0 to fix this problem.  I can see the path to new minGW folder when I select it from the compiler list, so I know that it got installed.  However, when I go to use the new g++ when I actually make a compilation, it still uses the old version in the CB directory!  I'm going to go back into the CB directory for minGW and rename it (keeping it for backup in case I need to undo my experiment) so the IDE can no longer find it and try this example once again.  If it still happens my only conclusion is that the version 13.1.0 g++ is not new enough!? I do appreciate any help on this quagmire. BTW I have tried auto detect and did not see any response. maxcy / wt1v

Navigation

[0] Message Index

[#] Next page

Go to full version