User forums > Using Code::Blocks
Object file not being updated
Jec1201961:
So I install codeblocks
Write the traditional hello world program, compile, build and run it. It works
I make some changes to refresh my C Skills.. Very rusty
//C hello world example
#include <stdio.h>
int main()
{
char InString[10]="Hello6789";
int Counter;
for ( Counter = 0;Counter <= 10; Counter++ )
{
printf("Value of Counter is: %d\n", Counter);
}
return 0;
}
I get a warning about the unused InString variable.. no big deal. It compiles, builds and when I run it, it still says Hello World.
The obj and/or exe file are not being updated.
I am not sure why.. any help appreciated
stahta01:
http://wiki.codeblocks.org/index.php/FAQ-Compiling_%28errors%29#Q:_How_do_I_troubleshoot_a_compiler_problem.3F
Jec1201961:
so I read the link.. here is my build log
mingw32-g++.exe -o bin\Debug\CleanString.exe obj\Debug\main.o obj\Debug\TestProg.o
mingw32-g++.exe: error: obj\Debug\main.o: No such file or directory
Process terminated with status 1 (0 minute(s), 0 second(s))
1 error(s), 1 warning(s) (0 minute(s), 0 second(s))
I understand the main.o is missing but I have no idea how to get it back
BlueHazzard:
please make a "Build->clean" and then "Build->Build" and repost the log (this steps are exactly described in the FAQ http://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F ). In your log, we can only see that the main.o is missing, but not why. If the "Build->clean" is greyed out, you are not using a project. For that case see this: http://forums.codeblocks.org/index.php/topic,20845.msg142383.html#msg142383
greetings
Jec1201961:
Did the Build--> Clean
Log Entries
-------------- Clean: Debug in CleanString (compiler: GNU GCC Compiler)---------------
Cleaned "CleanString - Debug"
Done.
Next I did the Build ---> Build
Log Entries
||=== Build: Debug in CleanString (compiler: GNU GCC Compiler) ===|
||WARNING: Can't read file's timestamp: H:\CodeBlocks Projects\C Stuff\CleanString\main.c|
obj\Debug\main.o||No such file or directory|
||=== Build failed: 1 error(s), 1 warning(s) (0 minute(s), 1 second(s)) ===|
for info, I am using CodeBlocks Version 13.12 o Windows 7
Navigation
[0] Message Index
[#] Next page
Go to full version