setup for use with FreeBSD ports [message #1109090] |
Sat, 14 September 2013 18:31  |
Eclipse User |
|
|
|
I've only used eclipse for "stand-alone" java projects, meaning ones written from the ground up where everything about them is understood, so I probably need a lot of guidance here. It's been a while; I'm having to relearn due to lost brain cells. This has probably been answered before but I didn't find what I was looking for with a search.
I'm trying to use CDT to debug a C++ port under FreeBSD. These ports all reside under /usr/ports/<category>/<portname>/ and have their own Makefiles with the usual bazillions of dependencies, includes, and build-time defines.
When the port is expanded from its tarball, the subdirectory work/<xxx>/src is where the main C++, C, and headers sit, with subdirs under that.
In a crude attempt, I set up a project and set the source to /usr/ports/<category>/<portname>/work/<xxx>/src by adding a reference in the wizard; or at least that's what I *think* I did.
Questions:
1. When I look at the project properties, I don't see where the source is anywhere.
Where do I see the location of source files in the UI? What happens when I specify the source as a reference to some other directory?
2. When I tried an initial debug compile, I got boatloads of errors and have manually added each of the header file locations to the compile -I path. Is there a better way to do this?
3. Is there any way to actually use the Makefile structure already set up in the ports tree?
4. If instead of trying to build everything in CDT, I do debug builds within the ports make structure (e.g. cd dir, make WITH_DEBUG=yes), how do I set up CDT for use as a debugger without having it try to build everything itself?
Any and all help and suggestions welcome.
Thanks.
|
|
|
|
|
Re: setup for use with FreeBSD ports [message #1110235 is a reply to message #1110025] |
Mon, 16 September 2013 11:29  |
Eclipse User |
|
|
|
Quote:Quote: 2. When I tried an initial debug compile, I got boatloads of errors and have manually added each of the header file locations to the compile -I path. Is there a better way to do this?
Are these system include paths?
Yes and no.
They are hierarchies specific to the application being built,
not on a system path;
and hierarchies rooted at a standard system location.
e.g.
/usr/ports/graphics/lprof-devel/work/lprof/src
/usr/ports/graphics/lprof-devel/work/lprof/src/libqtlcmswidgets
/usr/local/include
/usr/local/include/Qt4
/usr/local/include/Qt4/Qt
Quote:Quote:
4. If instead of trying to build everything in CDT, I do debug builds within the ports make structure (e.g. cd dir, make WITH_DEBUG=yes), how do I set up CDT for use as a debugger without having it try to build everything itself?
http://help.eclipse.org/kepler/topic/org.eclipse.cdt.doc.user/tasks/cdt_t_debug_prog.htm?cp=9_3_5_1_0
You can define the executable in the debug config.
Thanks.
The most recent freebsd port is indigo 3.7, but switching to help for that
and interpreting (the help does not match the dialog I get) seemed to work,
at least for starters.
|
|
|
Powered by
FUDForum. Page generated in 0.04742 seconds