MantisBT - CMake
View Issue Details
0012262CMakeCMakepublic2011-06-09 15:532012-01-03 14:59
Amine Khaldi 
Alex Neundorf 
normalmajoralways
closedfixed 
CMake-2-8 
CMake 2.8.7CMake 2.8.7 
0012262: Dependencies aren't tracked for preprocessed asm
We (ReactOS) use preprocessed asm files, that have includes, as source files in our modules.

CMake currently doesn't track these includes for those asm source files.

The only solution we see is to maintain a list of OBJECT_DEPENDS applied to every single preprocessed asm source file we have, which is far from practical.
Create a project with a preprocessed asm file that includes a dummy header, then after compiling the first time, alter the header and recompile, and you'll see that the project isn't properly recompiled.
No tags attached.
zip testcase.zip (873) 2011-12-18 10:56
https://public.kitware.com/Bug/file/4147/testcase.zip
Issue History
2011-06-09 15:53Amine KhaldiNew Issue
2011-06-09 16:55Alex NeundorfAssigned To => Alex Neundorf
2011-06-09 16:55Alex NeundorfStatusnew => assigned
2011-10-05 15:57Alex NeundorfNote Added: 0027529
2011-10-05 15:57Alex NeundorfStatusassigned => closed
2011-10-05 15:57Alex NeundorfResolutionopen => fixed
2011-12-16 17:15David ColeFixed in Version => CMake 2.8.7
2011-12-16 17:15David ColeTarget Version => CMake 2.8.7
2011-12-17 03:22Amine KhaldiNote Added: 0027997
2011-12-17 03:22Amine KhaldiStatusclosed => feedback
2011-12-17 03:22Amine KhaldiResolutionfixed => reopened
2011-12-18 09:12Alex NeundorfNote Added: 0027999
2011-12-18 10:56Amine KhaldiFile Added: testcase.zip
2011-12-18 10:57Amine KhaldiNote Added: 0028002
2011-12-18 10:57Amine KhaldiStatusfeedback => assigned
2011-12-18 10:59Amine KhaldiNote Edited: 0028002bug_revision_view_page.php?bugnote_id=28002#r467
2011-12-18 13:09Alex NeundorfNote Added: 0028005
2011-12-19 09:42Amine KhaldiNote Added: 0028008
2012-01-03 14:59Alex NeundorfNote Added: 0028149
2012-01-03 14:59Alex NeundorfStatusassigned => closed
2012-01-03 14:59Alex NeundorfResolutionreopened => fixed

Notes
(0027529)
Alex Neundorf   
2011-10-05 15:57   
Fixed and pushed to the cmake stage in the "DependencyScanningForASM" branch, also already merged into next.
Can you please verify that it works for you too ?
It does enable dependency scanning for the test project I have here.

Alex
(0027997)
Amine Khaldi   
2011-12-17 03:22   
Hi,

Alex, I tested it per your request at that time, but it wasn't possible to add any replies here (the status didn't permit ?).

The header includes (including .h files) are correctly tracked now, but we also use the .inc extension for asm includes (for example #include <syscalls.inc>) but these are not being tracked at all.

Is it possible to track all the files included through #include regardless of their extension ?

Amine
(0027999)
Alex Neundorf   
2011-12-18 09:12   
It works here for me, and I also don't see a place in the code where this would be extension-dependent.

Can you create a small testcase ?

Alex
(0028002)
Amine Khaldi   
2011-12-18 10:57   
(edited on: 2011-12-18 10:59)
In the attached testcase, target 'foo' uses #include "" and the dependencies are well tracked, but target 'bar' uses #include <> and the dependencies aren't tracked at all.

I reported previously that the .inc file wasn't tracked, but it turns out it's not about extensions, it's about #include "something" vs #include <something>, because that file was included using <>.

Amine.

(0028005)
Alex Neundorf   
2011-12-18 13:09   
Ok, fixed.
It is now in the UseEnabledLanguagesForDirectoryInformationFileIncludePath branch on cmake stage.
It is a bit intrusive, hopefully it will still be accepted for 2.8.7.
(0028008)
Amine Khaldi   
2011-12-19 09:42   
The fix is confirmed. Thank you for working on it.
(0028149)
Alex Neundorf   
2012-01-03 14:59   
Works now, as confirmed by the reporter.