User forums > Using Code::Blocks

Does not recompile changed header files?

<< < (5/8) > >>

stahta01:
@carra:

Do you try doing a full re-build before just changing something in the header file?
In other words these steps
1. Do a full re-build
2. Do a build and verify nothing is done.
3. Edit the header file
4. Do a build and see if it builds

Tim S.

ollydbg:
I download the KTool2.zip, and tested it.
First, I change

--- Code: ---"..\..\Headers\General.hpp"

--- End code ---


--- Code: ---"General.hpp"

--- End code ---

Then I build OK.

Next, I change any header file, then click build button.

I can't reproduce your issue, every thing works fine. (the cpp file will be re-compiled if a header file changes)

Jenna:

--- Quote from: ollydbg on June 21, 2012, 03:37:32 am ---I download the KTool2.zip, and tested it.
First, I change

--- Code: ---"..\..\Headers\General.hpp"

--- End code ---


--- Code: ---"General.hpp"

--- End code ---

Then I build OK.

Next, I change any header file, then click build button.

I can't reproduce your issue, every thing works fine. (the cpp file will be re-compiled if a header file changes)

--- End quote ---
i had to change it touse "/" instead of "\" on linux, and added "." to the compiler search-directories as carra did.

carra:
Done this, results are down there on red

--- Quote from: stahta01 on June 21, 2012, 12:05:38 am ---Do you try doing a full re-build before just changing something in the header file?
In other words these steps
1. Do a full re-build --> Done, everything rebuilds as usual
2. Do a build and verify nothing is done. --> Nothing to be done message
3. Edit the header file --> file modified
4. Do a build and see if it builds --> Again, nothing to be done message

--- End quote ---

Question: For those of you who cannot reproduce the bug, what is your *.depend file showing?? Because mine is this:


--- Code: ---# depslib dependency file v1.0
1340202051 source:c:\programacion\ktools2\sources\logstream\logstream.cpp
"..\..\Headers\LogStream.hpp"
<time.h>
<iostream>

1340202085 c:\programacion\ktools2\headers\logstream.hpp
<string>
<fstream>
<stdexcept>
"..\..\Headers\General.hpp"
--- End code ---

As you can see, this is consistent with the problem (there is no entry for General.hpp)

ollydbg:
It is mine

--- Code: ---# depslib dependency file v1.0
1340201559 source:c:\programacion\ktools\sources\logstream\logstream.cpp
<LogStream.hpp>
<time.h>
<iostream>

1339684374 source:c:\programacion\librerias\ktools\sources\logstream\logstream.cpp
<LogStream.hpp>
<time.h>
<iostream>

1340202051 source:c:\programacion\ktools2\sources\logstream\logstream.cpp
"..\..\Headers\LogStream.hpp"
<time.h>
<iostream>

1340202085 c:\programacion\ktools2\headers\logstream.hpp
<string>
<fstream>
<stdexcept>
"..\..\Headers\General.hpp"

1340202051 source:e:\code\cb\test_code\ktools2\sources\logstream\logstream.cpp
"..\..\Headers\LogStream.hpp"
<time.h>
<iostream>

1340242660 e:\code\cb\test_code\ktools2\headers\logstream.hpp
<string>
<fstream>
<stdexcept>
"General.hpp"

1340242644 e:\code\cb\test_code\ktools2\headers\general.hpp

--- End code ---

Note: I have change your sample file a little to avoid a build error.

--- Quote from: ollydbg on June 21, 2012, 03:37:32 am ---I download the KTool2.zip, and tested it.
First, I change

--- Code: ---"..\..\Headers\General.hpp"

--- End code ---


--- Code: ---"General.hpp"

--- End code ---

Then I build OK.

Next, I change any header file, then click build button.

I can't reproduce your issue, every thing works fine. (the cpp file will be re-compiled if a header file changes)

--- End quote ---

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version