CW10.6 suddenly can't find files that are clearly visible in the project window

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

CW10.6 suddenly can't find files that are clearly visible in the project window

ソリューションへジャンプ
3,153件の閲覧回数
GaryOlmstead
Senior Contributor I

I've been working on this project for awhile, and it compiled just fine until this morning.  Suddenly it can't find files that have always been in the project, in the same folder, and haven't been modified in ages. They are all in the Generated Code folder.  I've tried everything I can think of, including powering the computer off and back on.  I'm out of ideas.  Any suggestions would be welcome.  I considered updating to 10.6.4, but that doesn't appear to be an option, the only CW version I could find is Eclipse, and I don't want to do that at this point in the project.

0 件の賞賛
返信
1 解決策
2,872件の閲覧回数
GaryOlmstead
Senior Contributor I

Hi Erich --

Well, I figured out what happened, but not how.  I thought that maybe instead of the IDE or compiler, there might be something wrong with the files themselves. I started looking at some the more than 100 error messages, and realized that a lot of them were missing definitions in a single header file. This was in code that had compiled fine earlier that day.  I started putting the definitions back in, and the errors started going away.  Unfortunately, I also found that some whole files disappeared, and in this case it was very recent work, and I had gotten sloppy about backing up.  So, a large chunk of work that I was actually pretty proud of went poof.

I can't imagine how it happened.  This computer has a mind of its own and sometimes selects blocks of text all by itself, and if I happen to be typing, it will overwrite the selection.  That might explain the header file, except that the missing data is not contiguous.  And it's never done that with entire files before.  I thought about hackers, but I've got pretty good protection, and why hackers would steal a few lines here and there, or delete two files out of more than 30 is beyond me.

So, I don't entirely understand what happened, but it seems to be back on the air now.  Thank you very much for your help.

Best Regards

Gary Olmstead

Ventura CA

元の投稿で解決策を見る

0 件の賞賛
返信
10 返答(返信)
2,873件の閲覧回数
GaryOlmstead
Senior Contributor I

Hi Erich --

Well, I figured out what happened, but not how.  I thought that maybe instead of the IDE or compiler, there might be something wrong with the files themselves. I started looking at some the more than 100 error messages, and realized that a lot of them were missing definitions in a single header file. This was in code that had compiled fine earlier that day.  I started putting the definitions back in, and the errors started going away.  Unfortunately, I also found that some whole files disappeared, and in this case it was very recent work, and I had gotten sloppy about backing up.  So, a large chunk of work that I was actually pretty proud of went poof.

I can't imagine how it happened.  This computer has a mind of its own and sometimes selects blocks of text all by itself, and if I happen to be typing, it will overwrite the selection.  That might explain the header file, except that the missing data is not contiguous.  And it's never done that with entire files before.  I thought about hackers, but I've got pretty good protection, and why hackers would steal a few lines here and there, or delete two files out of more than 30 is beyond me.

So, I don't entirely understand what happened, but it seems to be back on the air now.  Thank you very much for your help.

Best Regards

Gary Olmstead

Ventura CA

0 件の賞賛
返信
2,872件の閲覧回数
GaryOlmstead
Senior Contributor I

Hi Erich --

I got it looking exactly like that, and it didn't make any difference. 

I tried recreating the project from scratch.  That has worked in the past, but not this time... No difference.pastedImage_1.png

0 件の賞賛
返信
2,872件の閲覧回数
BlackNight
NXP Employee
NXP Employee

Can you verify in the Console view (compiler command line output) that indeed the correct paths with the -I option are passed to the compiler?

The options are passed with .args files:

pastedImage_1.png

pastedImage_1.png

Maybe ProjectDirPath does not get resolved on your side: does it help if you try it with an absolute path?

Otherwise: does a Project > Clean help?

I hope this helps,

Erich

0 件の賞賛
返信
2,872件の閲覧回数
GaryOlmstead
Senior Contributor I

Hi Erich --

Well, mine doesn't look like yours, but this seems to be the same screen.  It has Project_Headers, Sources and Generated_Code, but doesn't make the slightest bit of difference.

pastedImage_1.png

0 件の賞賛
返信
2,872件の閲覧回数
BlackNight
NXP Employee
NXP Employee

Hi Gary,

oh, I did not realize that you are using S08 (you did not tell this ;-) ).

Your include path for the generated code looks wrong. It should be something like this:

pastedImage_1.png

I hope this helps,

Erich

0 件の賞賛
返信
2,872件の閲覧回数
GaryOlmstead
Senior Contributor I

HI Erich --

The closest I could find was this:

pastedImage_1.png

I modified it to look like this (added the last two lines):

pastedImage_2.png

But all it did was lose a bunch of other files:

pastedImage_3.png

I'm not sure what this means.  The objects it is complaining about are defined in the folder Sources, which is four lines up from the bottom in the Paths and Symbols list.

0 件の賞賛
返信
2,872件の閲覧回数
BlackNight
NXP Employee
NXP Employee

Hi Gary,

the 'Path and Symbols' are only for the Eclipse Indexer (see Fixing the Eclipse Index | MCU on Eclipse ), but do not help the compiler to find the header files.

The setting (-I include option) for where the compiler can find the header files are in the C/C++ Build group, as shown in my screenshot.

I hope this helps,

Erich

0 件の賞賛
返信
2,872件の閲覧回数
BlackNight
NXP Employee
NXP Employee

Could you post a screenshot of what you see or more details?

Do the files actually exist on the disk, but are not displayed in the project explorer view?

It might be that you need to do a F5/Refresh on the folder in Eclipse.

pastedImage_1.png

I hope this helps,

Erich

0 件の賞賛
返信
2,872件の閲覧回数
GaryOlmstead
Senior Contributor I

Hi Erich -

Thanks for replying so promptly.  I tried the F5 command, it didn't help.  Here is the screen shot. As you can see, the files listed as "not found" on the right are clearly visible on the left.  This all worked perfectly up to yesterday morning.  I don't know what changed; nothing on purpose.  I was editing files, but none of these, and none of the "overhead" files, such as make files and the like.  I was only changing one or two  ".C" files.

pastedImage_1.png

0 件の賞賛
返信
2,872件の閲覧回数
BlackNight
NXP Employee
NXP Employee

Ah, now I see. It is not about the IDE, it is about the compiler not finding the header files.

Check your compiler include path settings if it includes the correct include paths:

pastedImage_1.png

I hope this helps,

Erich

0 件の賞賛
返信