1 |
Fabian Groffen writes: |
2 |
|
3 |
> |
4 |
> perhaps unifdef can easily help you out here? |
5 |
> |
6 |
Well if I get what that program does it strips the supplied #ifs and |
7 |
#ifdefs from the code. |
8 |
The problem is not that I can't ignore them with my parser. But that I |
9 |
probably should respect them in some way. |
10 |
Otherwise I might miss some essential dependecies or optional ones. |
11 |
|
12 |
But I might for now, just as you probably suggested, ignore those #ifs |
13 |
as you shouldn't have defined deps that you'll need to compile the |
14 |
program inside #ifs. |
15 |
|
16 |
Right now I store the includes for each file like this (python syntax): |
17 |
[{set with global includes},{set with local},{dictionary with #ifdefs}] |
18 |
|
19 |
And the dict with #ifdefs point in turn to a list of the same structure |
20 |
as above. |
21 |
|
22 |
So I should be able to support looking up what get's pulled in when |
23 |
different stuff is defined. |
24 |
But the problem comes with stuff like the GTK_CHECK. As I don't really |
25 |
know how I should check for stuff like that. |