Skip to main content



      Home
Home » Language IDEs » C / C++ IDE (CDT) » header files couldn't be included!
header files couldn't be included! [message #764448] Mon, 12 December 2011 02:46 Go to next message
Eclipse UserFriend
Hello guys.
Sometimes I really don't understand eclipse Confused


I have a project which needs tcl.h to be included from Path "C:\Program Files\TCL\includes".

So I tried first: Project>Properties>C/C++ Build>Environment. I insert to the value INCLUDES the path "C:\Program Files\TCL\includes". But this does not work. I don't understand why....

Then I tried to insert the path "C:\Program Files\TCL\includes" to Project>Properties>C/C++ Build>GCC C++ Compiler>Includes.
The Build command is now:
g++ -IC:\Program\ Files\TCL\include\ -ID:\eclipse\ workspace\tclodbc_2.5.1\tclodbc -O0 -g3 -Wall -c -fmessage-length=0 -o tclodbc\statemnt.o ..\tclodbc\statemnt.cxx
In file included from ..\tclodbc\statemnt.cxx:50:0:
..\tclodbc\/tclodbc.hxx:102:17: fatal error: tcl.h: No such file or directory

So the header file tcl.h is still not found.

Can somebody help, please? Embarrassed
Thanks!
blackxx






Re: header files couldn't be included! [message #764525 is a reply to message #764448] Mon, 12 December 2011 05:59 Go to previous messageGo to next message
Eclipse UserFriend
Quote:
Then I tried to insert the path "C:\Program Files\TCL\includes" to Project>Properties>C/C++ Build>GCC C++ Compiler>Includes.

That's correct.
Perhaps there is a problem with the path containing a space. Which Eclipse version do you use? AFAIK, this problem should be already fixed.
Re: header files couldn't be included! [message #764577 is a reply to message #764525] Mon, 12 December 2011 08:21 Go to previous messageGo to next message
Eclipse UserFriend
Hi.

I use this version:

Eclipse SDK
Version: 3.7.1
Build id: M20110909-1335

Eclipse CDT P2 Customizations for SDK installation
Version: 1.0.0.201109151620
Build id: @build@



Re: header files couldn't be included! [message #764734 is a reply to message #764577] Mon, 12 December 2011 14:10 Go to previous messageGo to next message
Eclipse UserFriend
abras3,

for a test copy the whole folder "\TCL\includes" into a path without spaces
(lets say c:\test\TCL\includes) and try this. I guess this works and the problem is the space in the path.

You should consider to change your configuration. In my humble opinion it is a bad design to have source files under "C:\program files" !


Regards,
Klaus
Re: header files couldn't be included! [message #765002 is a reply to message #764734] Tue, 13 December 2011 03:46 Go to previous messageGo to next message
Eclipse UserFriend
Quote:
I have a project which needs tcl.h to be included from Path "C:\Program Files\TCL\includes".


Quote:
g++ -IC:\Program\ Files\TCL\include\ -ID:\eclipse\ workspace\tclodbc_2.5.1\tclodbc -O0 -g3 -Wall -c -fmessage-length=0 -o tclodbc\statemnt.o ..\tclodbc\statemnt.cxx
In file included from ..\tclodbc\statemnt.cxx:50:0:


You misspelled the include path (the prefix 's' is missing).
Re: header files couldn't be included! [message #765130 is a reply to message #764448] Tue, 13 December 2011 08:26 Go to previous messageGo to next message
Eclipse UserFriend

@Klaus
Thank you for your help! I tried a path without spaces and everythink worked fine.
But now I have an other question:
After I could compile my project I tried again to compile with the old path "C:\Program Files\TCL\include". And this worked fine, too. How can that be???

And why it's not allowed to use Project>Properties>C/C++ Build>Environment ??



@Axel
Hi Axel. Thank you for posting, but I think I just forgot the prefix 's' by posting
my problem to this forum. In my project the path was right.
Re: header files couldn't be included! [message #765274 is a reply to message #765130] Tue, 13 December 2011 13:47 Go to previous message
Eclipse UserFriend
abras3 wrote on Tue, 13 December 2011 08:26

Thank you for your help! I tried a path without spaces and everythink worked fine.
But now I have an other question:
After I could compile my project I tried again to compile with the old path "C:\Program Files\TCL\include". And this worked fine, too. How can that be???


Eclipse "caches" the paths from the older build. So i guess it's using the paths of the headers you made under "path without spaces".
You could clear the cache:

http://wiki.eclipse.org/CDT/User/NewIn80#Scanner_Discovery

Regards,
Klaus
Previous Topic:Drop to Frame Implementation
Next Topic:Remote debugging setting
Goto Forum:
  


Current Time: Sun Jul 13 14:24:15 EDT 2025

Powered by FUDForum. Page generated in 0.06709 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top