How to build Eclipse in Eclipsehttps://www.eclipse.org/forums/index.php/mv/msg/324097/838163/#msg_838163
(This is my first posting here. I really want to get answers from you.)]]>Jongwook Kim2012-04-06T16:59:52-00:00Re: How to build Eclipse in Eclipsehttps://www.eclipse.org/forums/index.php/mv/msg/324097/843941/#msg_843941
Jongwook Kim wrote on Fri, 06 April 2012 12:59

I'm finding guides to build and debug Eclipse within Eclipse.
(This is my first posting here. I really want to get answers from you.)

There is a guide at wiki.eclipse.org/Linux_Tools_Project/Eclipse_Build on building Eclipse from source on Linux.

As for debugging an instance of Eclipse, I've had to do this for particular components (eg. org.eclipse.equinox.simpleconfigurator). Just make sure you have the sources available for the components you wish to debug with breakpoints set where needed and launch a child Eclipse session (Make sure to do this from the debug configuration).

You could also use remote debugging. There's a pretty good resource on its usage here : aectann.wikidot.com/java-remote-debug . The only difference is that when you launch the instance of eclipse you wish to debug, you would prefix the remote debug options with the "-vmargs" flag to ensure they get passed to the jvm.

Hope this helps.
]]>Roland Grunberg2012-04-13T14:23:57-00:00Re: How to build Eclipse in Eclipsehttps://www.eclipse.org/forums/index.php/mv/msg/324097/844013/#msg_844013
I don't guess Eclipse developers build Eclipse on Linux as described in wiki.eclipse.org/Linux_Tools_Project/Eclipse_Build. Am I wrong?

Could you elaborate debugging (with breakpoints)? Is it the way Eclipse developers do actually?]]>Jongwook Kim2012-04-13T15:47:18-00:00Re: How to build Eclipse in Eclipsehttps://www.eclipse.org/forums/index.php/mv/msg/324097/847938/#msg_847938
Jongwook Kim wrote on Fri, 13 April 2012 11:47

Thank you Roland, I still have some questions:

I don't guess Eclipse developers build Eclipse on Linux as described in wiki.eclipse.org/Linux_Tools_Project/Eclipse_Build. Am I wrong?

Could you elaborate debugging (with breakpoints)? Is it the way Eclipse developers do actually?

If you're talking about the Eclipse instances found here : www.eclipse.org/downloads/ , then no they aren't built exactly the same way. The "eclipse-build" project is an attempt to build Eclipse from sources on Linux distros. One of the reasons for this is that some distributions do not allow things to be pre-built and so everything must be built from source.

Another reason is to provide the Eclipse package as a part of that distribution's package management system.

I don't know exactly if there's only one way Eclipse developers debug things. From my personal experience, when debugging Eclipse itself, it's much easier to do it remotely because you're not dependent on using the same instance. For example, if you're attempting to debug a broken Eclipse installation (let's say it won't even start), you can't launch the first instance, let alone a child. You could however start that broken instance in debug mode (at some point early in the startup process), and debug from a working Eclipse instance.

Using breakpoints seems pretty standard to me. Often all that's required is to inspect certain values at a point in the code (in some cases maybe even doing a hot-code insertion)

There's a lot of good documentation out there on the above topics.]]>Roland Grunberg2012-04-17T20:07:15-00:00Re: How to build Eclipse in Eclipsehttps://www.eclipse.org/forums/index.php/mv/msg/324097/847980/#msg_847980
Thanks for comments!]]>Jongwook Kim2012-04-17T21:06:44-00:00Re: How to build Eclipse in Eclipsehttps://www.eclipse.org/forums/index.php/mv/msg/324097/849012/#msg_849012
Jongwook Kim wrote on Tue, 17 April 2012 17:06

What about compile-time (syntax) errors? Eclipse developers will not build Eclipse to fix a typo every time. I believe they compile Eclipse (sources) using Eclipse tool (instance), namely "build Eclipse in Eclipse".

Thanks for comments!

My view of Eclipse is as more of a set of plugins, so I think that when an Eclipse developer is coding/debugging for the platform, they're often only looking at one set of components (p2,help system,jdt,etc.) and not the platform as a whole. So yes, they're using Eclipse to build/debug an Eclipse component.
]]>Roland Grunberg2012-04-18T20:04:35-00:00Re: How to build Eclipse in Eclipsehttps://www.eclipse.org/forums/index.php/mv/msg/324097/849022/#msg_849022
Jongwook Kim2012-04-18T20:15:36-00:00Re: How to build Eclipse in Eclipsehttps://www.eclipse.org/forums/index.php/mv/msg/324097/856499/#msg_856499
Jongwook Kim wrote on Wed, 18 April 2012 16:15

That's exactly what I'm finding. Do you know how to build/debug Eclipse using Eclipse?

There's some good documentation here on using remote debugging in Eclipse :

The only difference is that the application you'd be launching is Eclipse, and you'd need to add the "-vmargs" flag before specifiying the debug flags.

I'm planning on writing up a post (I'll post here) of an example showing how to debug an instance of Eclipse, just to demonstrate that it really isn't all that different.]]>Roland Grunberg2012-04-25T18:23:38-00:00