User forums > Help

Compiler issues

(1/2) > >>

ConradBuff1:
Hi, I'm having some trouble getting programs to build and compile. I've downloaded the .exe file with the inbuilt compiler but it doesn't seem to working correctly. Tried a number of suggestions others have made on the forum but these haven't worked.

Here's the build log:
-------------- Build: Debug in asdfasdf (compiler: GNU GCC Compiler)---------------

gcc.exe  -o bin\Debug\asdfasdf.exe obj\Debug\main.o   
gcc.exe: error: obj\Debug\main.o: No such file or directory
gcc.exe: fatal error: no input files
compilation terminated.
Process terminated with status 1 (0 minute(s), 0 second(s))
2 error(s), 0 warning(s) (0 minute(s), 0 second(s))
 
Any help would be greatly appreciated.

stahta01:
https://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F

Please post an full rebuild log in code tags.

Tim S.

ConradBuff1:
Hi Tim,

Thank you for your prompt response.

I am running Code::Blocks version 20.03 on Windows 10. The compiler I use is the GNU GCC Compiler (Mingw) that was bundled with the install file (unsure of version number).

When I open a new project and attempt to build the "Hello World!" program, I receive the error messages "No such file or directory" and "error: no input files".

Build log:

--- Code: ----------------- Clean: Debug in Project (compiler: GNU GCC Compiler)---------------

Cleaned "Project - Debug"

-------------- Build: Debug in Project (compiler: GNU GCC Compiler)---------------

gcc.exe  -o bin\Debug\Project.exe obj\Debug\main.o   
gcc.exe: error: obj\Debug\main.o: No such file or directory
gcc.exe: fatal error: no input files
compilation terminated.
Process terminated with status 1 (0 minute(s), 0 second(s))
2 error(s), 0 warning(s) (0 minute(s), 0 second(s))

--- End code ---

I have already tried a few suggestions relating to the compiler's installation directory (manually selecting the folder, auto-detection. I received confirmation that the installation path was detected each time), but this was not successful.

Please let me know if you require anything further.

stahta01:
Under tab projects; expand the project name Project

Right click on the source file main.c and select properties from the menu.
Select tab Build; checkmark compile leave link checked.
Click okay button
Rebuild project.

What my build log looks like

--- Code: ----------------- Clean: Debug in Project (compiler: GNU GCC Compiler)---------------

Cleaned "Project - Debug"

-------------- Build: Debug in Project (compiler: GNU GCC Compiler)---------------

gcc.exe -Wall -g  -c H:\devel\cb_projects\test\Project\main.c -o obj\Debug\main.o
gcc.exe  -o bin\Debug\Project.exe obj\Debug\main.o   
Output file is bin\Debug\Project.exe with size 247.67 KB
Process terminated with status 0 (0 minute(s), 0 second(s))
0 error(s), 0 warning(s) (0 minute(s), 0 second(s))

--- End code ---

ConradBuff1:
Both 'compile file' and 'link file' were already checked when producing the build log.

Navigation

[0] Message Index

[#] Next page

Go to full version