User forums > Help
Can't build my codes
(1/1)
Jason Killjoy:
Hi everyone, I'm having some troubles in setting up the compiler for codeblocks, so I figured you could maybe help me.
I'm using windows 10 64 bit and I'm new with fortran, so I wanted to get all at once and download codeblocks with the compiler, so I downloaded codeblocks-16.01mingw-setup.exe from http://codeblocks.org/downloads/binaries.
I installed it in D:\CodeBlocks, but when I opened it an Environmental Error poped-up: "Can't find compiler executable in your configured search path's for GNU GCC Compiler". So I went to settings-->compiler and in toolchain executables I auto-detected it in D:\CodeBlocks\MinGW. So I started a new project-->fortran application and, apart from the name, I just nexted everything (I made sure the compiler was GNU GCC Compiler). So I then had my main.f95 that showed "Hello World!", but when I went to build it I had an error:
=== Build: Debug in test (compiler: GNU GCC Compiler) ===
CreateProcess No such file or directory
=== Build failed: 1 error(s), 0 warning(s) (0 minute(s), 0 second(s)) ===
So I tried to reinstall it in C:\Program Files (x86)\Codeblocks and in C:\Program Files\Codeblocks, I repeated the same exact procedure and nothing changed.
What am I doing wrong?
sodev:
The bundled MinGW contains only a C/C++ compiler, you need to download a version with a Fortran compiler yourself.
Jason Killjoy:
Thank you for your answer, but I don't understand how can that be. Quoting from their website:
"MinGW includes:
A port of the GNU Compiler Collection (GCC), including C, C++, ADA and Fortran compilers;"
Is the one included in codeblocks' download a different one? And if so, then I should download a Fortran compiler and make what changes in Codeblocks-->settings-->compiler ?
stahta01:
--- Quote from: Jason Killjoy on March 20, 2017, 07:41:23 pm ---Thank you for your answer, but I don't understand how can that be. Quoting from their website:
"MinGW includes:
A port of the GNU Compiler Collection (GCC), including C, C++, ADA and Fortran compilers;"
Is the one included in codeblocks' download a different one? And if so, then I should download a Fortran compiler and make what changes in Codeblocks-->settings-->compiler ?
--- End quote ---
I SUGGEST YOU TRY THE ONE WITH FORTRAN in the installer name!
--- Code: ---codeblocks-16.01mingw_fortran-setup.exe
--- End code ---
FROM http://codeblocks.org/downloads/binaries
--- Quote ---NOTE: The codeblocks-16.01-setup.exe file includes Code::Blocks with all plugins. The codeblocks-16.01-setup-nonadmin.exe file is provided for convenience to users that do not have administrator rights on their machine(s).
NOTE: The codeblocks-16.01mingw-setup.exe file includes additionally the GCC/G++ compiler and GDB debugger from TDM-GCC (version 4.9.2, 32 bit, SJLJ). The codeblocks-16.01mingw_fortran-setup.exe file includes additionally to that the GFortran compiler (TDM-GCC).
NOTE: The codeblocks-16.01(mingw)-nosetup.zip files are provided for convenience to users that are allergic against installers. However, it will not allow to select plugins / features to install (it includes everything) and not create any menu shortcuts. For the "installation" you are on your own.
--- End quote ---
Tim S.
Jason Killjoy:
Thank you Tim, you are right, I just assumed it was the nonadmin version with mingw and didn't even bother to read the name.
I installed it, set GNU Fortran Compiler as my default one and it all worked.
Thank you again :)
Navigation
[0] Message Index
Go to full version