Skip to main content



      Home
Home » Language IDEs » C / C++ IDE (CDT) » Including Library paths(Where are they?)
Including Library paths [message #734161] Thu, 06 October 2011 18:22 Go to next message
Eclipse UserFriend
I'm new to c++ and eclipse; I'm migrating away from vb and visual studio so that I can work on multiple platforms (I have windows at work, linux at home). I downloaded the indigo cdt which apparently comes with the cross compiler and used that as the toolchain. I started to work on my first file just to give myself a test drive of the eclipse environment on both platforms.

In linux after creating a new project, i *occasionally* get "unresolved inclusion" and "symbol could not be resolved" errors when i first start writing the code, even after a build. But then if i close and re-open the project, that error goes away and I can work as if nothing happened.

In windows no such luck. I see from other posts where I need to go into the project properties -> c/c++ general -> paths and symbols and enter the include directories, but I have no idea where the libraries for the cross compiler are located. Since it was installed with eclipse I assumed it would be in the eclipse directory somewhere, but a search for something like iostream doesn't result in any hits. I'd like to have the libraries kept with eclipse since it's on an external drive in case i need to work from a different machine at work. I would like to avoid the microsoft libraries so that I can import/export my preferences between linux and windows flavors.

Any idea why the linux environment gives me problems initially then clears up?
Any idea where the gnu c++ libraries are for the cross compiler in windows?
Am I missing a larger concept?

thanks for the help!
Re: Including Library paths [message #734207 is a reply to message #734161] Fri, 07 October 2011 00:10 Go to previous messageGo to next message
Eclipse UserFriend
Ok, to resolve the issue for the windows environment, I installed MinGW as a subdirectory of eclispse. I also added an environment variable to preferences -> c/c++ -> build -> environment. since the cdt is on a removable drive, i used ".\MinGW\bin" as the path (sans quotes). That should allow me to move from machine to machine without having to add MinGW to each machine I use.

I did notice that in the paths & symbols the includes used the absolute path of the drive, so we will see when I move to another machine whether the drive letter changes and those paths update automatically and how running programs outside of eclipse will deal with the path (since MinGW was not installed on the C drive, i did not include the MinGW in the environment variables for windows as suggested by the FAQ at MinGW, so we'll see how this all works out if i can remember to use the full path if/when running the compiler from cli).

Build reported complete so I'm calling this a successful work around--for now anyway. Wink

Still could use some pointers on the linux system anoyance, though!

cheers,

ejo

[Updated on: Fri, 07 October 2011 00:12] by Moderator

Re: Including Library paths [message #741707 is a reply to message #734207] Wed, 19 October 2011 16:31 Go to previous messageGo to next message
Eclipse UserFriend
Free bump... anyways I'm new to C++/Eclipse (Windows platform) as well, with my only experience being bash scripting in Linux.

I just got all my MinGW toolchain issues sorted out. I've yet to run Eclipse on my Linux install, so currently, I've got no input. If you find any useful guides to C/C++ programming, shoot me a weblink via PM.

[Updated on: Wed, 19 October 2011 16:32] by Moderator

Re: Including Library paths [message #742439 is a reply to message #741707] Thu, 20 October 2011 09:49 Go to previous message
Eclipse UserFriend
Josh Manning wrote on Wed, 19 October 2011 16:31
Free bump... anyways I'm new to C++/Eclipse (Windows platform) as well, with my only experience being bash scripting in Linux.

I just got all my MinGW toolchain issues sorted out. I've yet to run Eclipse on my Linux install, so currently, I've got no input. If you find any useful guides to C/C++ programming, shoot me a weblink via PM.



Hi, Josh. I know you said to PM you any links I had for tutorials, but in case any other noobs like us happen to find this post they might find them useful as well. I've had problems reaching the second link for a while (which was my personal preference)--like it isn't even in DNS anymore, so I don't know what is up with it.

There are also some pretty decent books out there. but be wary--most think you are using some form of windows with visual studio.

www dot cplusplus dot com/doc/tutorial/
www dot learncpp dot com

ejo

PS. Sorry for the links...apparently I can't post links because I don't have more than 5 messages...my apologies for trying to be helpful, Eclipse Forums...
Previous Topic:Build and Debug/Run as
Next Topic:Build Completes Then Waits?
Goto Forum:
  


Current Time: Wed Jul 30 14:19:29 EDT 2025

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

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

Back to the top