@@ -79,6 +79,45 @@ <h4 id="visual-studio">Visual Studio</h4>
7979< code > ide\hotspot-visualstudio</ code > subfolder of the build output
8080folder. The file can be opened in Visual Studio via
8181< code > File -> Open -> Project/Solution</ code > .</ p >
82+ < h4 id ="eclipse-cdt "> Eclipse CDT</ h4 >
83+ < p > The make system can generate an Eclipse CDT Workspace that enables
84+ Eclipse indexing for the C and C++ sources throughout the entire
85+ codebase, as well as registering all common make targets to be runnable
86+ from the Eclipse explorer. This can be done after configuring by
87+ running:</ p >
88+ < pre > < code > make eclipse-native-env</ code > </ pre >
89+ < p > After this is run, simply open and import the workspace in Eclipse
90+ through
91+ < code > File -> Import -> Projects from Folder or Archive</ code > and
92+ at < code > Import source</ code > click on the directory
93+ < code > ide\eclipse</ code > , which can be found in the build output
94+ folder.</ p >
95+ < p > If this doesn't work, you can also try
96+ < code > File -> Import -> Existing Projects into Workspace</ code >
97+ instead.</ p >
98+ < p > Setting up an Eclipse Workspace is relatively lightweight compared to
99+ other supported IDEs, but requires that your CDT installation has Cross
100+ GCC support enabled at the moment, even if you aren't cross compiling.
101+ The Visual C++ compiler is, at present, not supported as an indexer.</ p >
102+ < p > If desired, you can instead request make to only include indexing
103+ support for just the Java Virtual Machine instead of the entire native
104+ codebase, by running:</ p >
105+ < pre > < code > make eclipse-hotspot-env</ code > </ pre >
106+ < p > If you think your particular Eclipse installation can handle the
107+ strain, the make system also supports generating a combined Java and
108+ C/C++ Workspace for Eclipse which can then conveniently switch between
109+ Java and C/C++ natures during development by running:</ p >
110+ < pre > < code > make eclipse-mixed-env</ code > </ pre >
111+ < p > Do note that this generates all features that come with both Java and
112+ C/C++ natures.</ p >
113+ < p > By default, the Eclipse Workspace is located in the ide subdirectory
114+ in the build output. To share the JDK's source directory with the
115+ Eclipse Workspace, you can instead run:</ p >
116+ < pre > < code > make eclipse-shared-<ENV>-env</ code > </ pre >
117+ < p > Eclipse support in the JDK is relatively new, so do keep in mind that
118+ not everything may work at the moment. As such, the resulting Workspace
119+ also has compilation database parsing support enabled, so you can pass
120+ Eclipse the compile commands file (see below) if all else fails.</ p >
82121< h4 id ="compilation-database "> Compilation Database</ h4 >
83122< p > The make system can generate generic native code indexing support in
84123the form of a < a
@@ -105,5 +144,28 @@ <h4 id="intellij-idea">IntelliJ IDEA</h4>
105144< p > In order to run the tests from the IDE, you can use the JTReg plugin.
106145Instructions for building and using the plugin can be found < a
107146href ="https://github.com/openjdk/jtreg/tree/master/plugins/idea "> here</ a > .</ p >
147+ < h4 id ="eclipse "> Eclipse</ h4 >
148+ < p > Eclipse JDT is a widely used Java IDE and has been for a very long
149+ time, being a popular choice alongside IntelliJ IDEA for Java
150+ development. Likewise, the JDK now includes support for developing its
151+ Java sources with Eclipse, which can be achieved by setting up a Java
152+ Workspace by running:</ p >
153+ < pre > < code > make eclipse-java-env</ code > </ pre >
154+ < p > After the workspace has been generated you can import it in the same
155+ way as you would with Eclipse CDT:</ p >
156+ < p > Follow
157+ < code > File -> Import -> Projects from Folder or Archive</ code > and
158+ select the < code > ide\eclipse</ code > directory in the build output folder
159+ to import the newly created Java Workspace.</ p >
160+ < p > If doing so results in an error, you can also import the JDK via
161+ < code > File -> Import -> Existing Projects into Workspace</ code > as
162+ a last resort.</ p >
163+ < p > Alternatively, if you want a Java Workspace inside the JDK's source
164+ directory, you can instead run:</ p >
165+ < pre > < code > make eclipse-shared-java-env</ code > </ pre >
166+ < p > As mentioned above for Eclipse CDT, you can create a combined Java
167+ and C/C++ Workspace which can conveniently switch between Java and C/C++
168+ natures during development by running:</ p >
169+ < pre > < code > make eclipse-mixed-env</ code > </ pre >
108170</ body >
109171</ html >
0 commit comments