summaryrefslogtreecommitdiff
path: root/src/eclipse
diff options
context:
space:
mode:
authorSimon Schaefer <mail@antoras.de>2013-09-21 22:38:18 +0200
committerSimon Schaefer <mail@antoras.de>2013-09-22 00:31:38 +0200
commitd0c8698aa62e821163f3029e0f5cd8bd3d89d793 (patch)
tree5510ec52576defd4a900b54b657ff284f3174421 /src/eclipse
parent884e1ce762d98b29594146d37b85384581d9ba96 (diff)
downloadscala-d0c8698aa62e821163f3029e0f5cd8bd3d89d793.tar.gz
scala-d0c8698aa62e821163f3029e0f5cd8bd3d89d793.tar.bz2
scala-d0c8698aa62e821163f3029e0f5cd8bd3d89d793.zip
Update of Eclipse project files
- Update of project dependencies - Deletion of scala-xml project - Deletion of scala-parser-combinators project - Update of .gitignore to match nested .cache files
Diffstat (limited to 'src/eclipse')
-rw-r--r--src/eclipse/README.md71
-rw-r--r--src/eclipse/partest/.classpath6
-rw-r--r--src/eclipse/partest/.project10
-rw-r--r--src/eclipse/repl/.classpath1
-rw-r--r--src/eclipse/scala-parser-combinators/.classpath7
-rw-r--r--src/eclipse/scala-parser-combinators/.project30
-rw-r--r--src/eclipse/scala-xml/.classpath7
-rw-r--r--src/eclipse/scala-xml/.project30
-rw-r--r--src/eclipse/scaladoc/.classpath7
9 files changed, 57 insertions, 112 deletions
diff --git a/src/eclipse/README.md b/src/eclipse/README.md
index 2bb1a4da8f..d3644aad1c 100644
--- a/src/eclipse/README.md
+++ b/src/eclipse/README.md
@@ -1,46 +1,63 @@
Eclipse project files
=====================
-Import all projects inside Eclipse by choosing File/Import Existing Projects
-and navigate to src/eclipse. Check all projects and click ok.
+The following points describe how to get Scala to run in Eclipse:
-IMPORTANT
-=========
+0. To get Scala to work inside of Eclipse Kepler it is necessary to build the Scala IDE by your own
+because for the moment there is no update site provided for the newest development version
+of Scala. To do so enter the following commands one after the other:
-1. You need to define a `path variable` inside Eclipse. Define SCALA_BASEDIR in
-Preferences/General/Workspace/Linked Resources. The value should be the absolute
-path to your scala checkout. All paths in project files are relative to this one,
+ git clone https://github.com/scala-ide/scala-ide.git
+ cd scala-ide
+ ./build-all.sh clean install -Pscala-2.11.x -Psbt-new -Peclipse-kepler -DskipTests
+
+ After that you have an update site in `scala-ide/org.scala-ide.sdt.update-site/target/site`, which needs to be
+installed in Eclipse.
+
+0. The second thing that needs to be done is building Scala in order to get all necessary
+dependencies. To do that simply enter
+
+ ant
+
+ and wait until it is completed. To verify that everything has been built successfully, execute the REPL that can be found
+at `scala/build/pack/bin/scala`.
+
+0. Import all projects inside of Eclipse by choosing `File/Import Existing Projects`
+and navigate to `scala/src/eclipse`. Check all projects and click ok.
+
+0. You need to define a `path variable` inside Eclipse. Define `SCALA_BASEDIR` in
+`Preferences/General/Workspace/Linked Resources`. The value should be the absolute
+path to your Scala checkout. All paths in the project files are relative to this one,
so nothing will work before you do so.
-Additionally, we start using Maven dependencies (e.g. junit) so you need to define
-`classpath variable` inside Eclipse. Define `M2_REPO` in Java/Build Path/Classpath Variables
-to point to your local Maven repository (e.g. $HOME/.m2/repository).
-2. The Eclipse Java compiler does not allow certain calls to restricted APIs in the
+ The same `SCALA_BASEDIR` variable needs to be defined as a `classpath variable` in
+`Java/Build Path/Classpath Variables`.
+
+ Additionally, we start using Maven dependencies (e.g. `JUnit`) so you need to define another
+`classpath variable` inside Eclipse. Define `M2_REPO` in `Java/Build Path/Classpath Variables`
+to point to your local Maven repository (e.g. `$HOME/.m2/repository`).
+
+ Lastly, the JRE used by Eclipse needs to know the path to the `JLine` library, which is used by the REPL.
+To set the JAR file, navigate to `Java/Installed JREs`, select the default JRE, press `Edit/Add External JARs...`
+and enter the path to JLine whose location is `SCALA_BASEDIR/build/deps/repl/jline-2.11.jar` (`SCALA_BASEDIR` cannot be entered,
+it needs to be replaced with its absolute path).
+
+0. The Eclipse Java compiler does not allow certain calls to restricted APIs in the
JDK. The Scala library uses such APIs, so you'd see this error:
Access restriction: The method compareAndSwapObject(Object, long, Object, Object)
from the type Unsafe is not accessible due to restriction on required library.
-You can *fix* it by allowing calls to restricted APIs in `Java=>Compiler=>Errors/Warnings=>Deprecated and Restricted API`
-settings.
-
-3. The IDE guesses the Scala library version by looking for `library.properties` inside
-the library jar. The `scala-library` project does not have such a file, so you will see
-an error about incompatible libraries. You can work around it by adding a `library.properties`
-inside `src/library` with the following contents:
- #Mon, 04 Jun 2012 02:08:56 +0200
- version.number=2.10.0-20120603-141530-b34313db72
- maven.version.number=2.10.0-SNAPSHOT
- osgi.version.number=2.10.0.v20120603-141530-b34313db72
- copyright.string=Copyright 2002-2013 LAMP/EPFL
+ You can *fix* it by allowing calls to restricted APIs in `Java/Compiler/Errors/Warnings/Deprecated and Restricted API`
+settings.
-4. Project files are tracked by Git, so adding them to `.gitignore` won't prevent them
+0. Project files are tracked by Git, so adding them to `.gitignore` won't prevent them
from being shown as dirty in `git status`. You can still ignore them by telling Git to
consider them unchanged:
git update-index --assume-unchanged `find src/eclipse -iname .classpath -or -iname .project`
-If you want to go back to normal (for instance, to commit your changes to project files), run:
+ If you want to go back to normal (for instance, to commit your changes to project files), run:
git update-index --no-assume-unchanged `find src/eclipse -iname .classpath -or -iname .project`
@@ -51,5 +68,5 @@ The compiler project depends on the library, reflect, and asm projects. The
builder will take care of the correct ordering, and changes in one project will
be picked up by the dependent projects.
-The output directory is set to be build/quick, so the runner scripts in quick
-work as they are (run an ant build to have them generated once) \ No newline at end of file
+The output directory is set to be `build/quick`, so the runner scripts in quick
+work as they are (they are generated after an ant build).
diff --git a/src/eclipse/partest/.classpath b/src/eclipse/partest/.classpath
index 5a4448e01a..2214517d92 100644
--- a/src/eclipse/partest/.classpath
+++ b/src/eclipse/partest/.classpath
@@ -1,14 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry kind="src" path="partest-extras"/>
+ <classpathentry kind="src" path="partest-extras"/>
<classpathentry combineaccessrules="false" kind="src" path="/asm"/>
<classpathentry combineaccessrules="false" kind="src" path="/repl"/>
<classpathentry kind="var" path="M2_REPO/com/googlecode/java-diff-utils/diffutils/1.3.0/diffutils-1.3.0.jar"/>
<classpathentry kind="var" path="M2_REPO/org/scala-tools/testing/test-interface/0.5/test-interface-0.5.jar"/>
- <classpathentry kind="var" path="M2_REPO/org/scala-lang/modules/scala-partest_2.11.0-M4/1.0-RC3/scala-partest_2.11.0-M4-1.0-RC3.jar"/>
+ <classpathentry kind="var" path="M2_REPO/org/scala-lang/modules/scala-partest_2.11.0-M4/1.0-RC4/scala-partest_2.11.0-M4-1.0-RC4.jar"/>
<classpathentry kind="var" path="SCALA_BASEDIR/lib/ant/ant.jar"/>
<classpathentry kind="con" path="org.scala-ide.sdt.launching.SCALA_CONTAINER"/>
<classpathentry kind="con" path="org.scala-ide.sdt.launching.SCALA_COMPILER_CONTAINER"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="output" path="build-quick-partest-extras"/>
+ <classpathentry kind="output" path="build-quick-partest-extras"/>
</classpath>
diff --git a/src/eclipse/partest/.project b/src/eclipse/partest/.project
index 5f52d4bf8f..5c0c851b80 100644
--- a/src/eclipse/partest/.project
+++ b/src/eclipse/partest/.project
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
- <name>partest-extras</name>
+ <name>partest-extras</name>
<comment></comment>
<projects>
</projects>
@@ -17,9 +17,9 @@
</natures>
<linkedResources>
<link>
- <name>build-quick-partest-extras</name>
+ <name>build-quick-partest-extras</name>
<type>2</type>
- <locationURI>SCALA_BASEDIR/build/quick/classes/partest-extras</locationURI>
+ <locationURI>SCALA_BASEDIR/build/quick/classes/partest-extras</locationURI>
</link>
<link>
<name>lib</name>
@@ -27,9 +27,9 @@
<locationURI>SCALA_BASEDIR/lib</locationURI>
</link>
<link>
- <name>partest-extras</name>
+ <name>partest-extras</name>
<type>2</type>
- <locationURI>SCALA_BASEDIR/src/partest-extras</locationURI>
+ <locationURI>SCALA_BASEDIR/src/partest-extras</locationURI>
</link>
</linkedResources>
</projectDescription>
diff --git a/src/eclipse/repl/.classpath b/src/eclipse/repl/.classpath
index 748fa6c9c8..601a231aeb 100644
--- a/src/eclipse/repl/.classpath
+++ b/src/eclipse/repl/.classpath
@@ -6,5 +6,6 @@
<classpathentry kind="con" path="org.scala-ide.sdt.launching.SCALA_CONTAINER"/>
<classpathentry kind="con" path="org.scala-ide.sdt.launching.SCALA_COMPILER_CONTAINER"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+ <classpathentry kind="var" path="SCALA_BASEDIR/build/deps/repl/jline-2.11.jar"/>
<classpathentry kind="output" path="build-quick-repl"/>
</classpath>
diff --git a/src/eclipse/scala-parser-combinators/.classpath b/src/eclipse/scala-parser-combinators/.classpath
deleted file mode 100644
index 7eab7094eb..0000000000
--- a/src/eclipse/scala-parser-combinators/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="src-parser-combinators"/>
- <classpathentry kind="con" path="org.scala-ide.sdt.launching.SCALA_CONTAINER"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="output" path="build-quick-parser-combinators"/>
-</classpath>
diff --git a/src/eclipse/scala-parser-combinators/.project b/src/eclipse/scala-parser-combinators/.project
deleted file mode 100644
index d94523f56d..0000000000
--- a/src/eclipse/scala-parser-combinators/.project
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>scala-parser-combinators</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.scala-ide.sdt.core.scalabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.scala-ide.sdt.core.scalanature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
- <linkedResources>
- <link>
- <name>build-quick-parser-combinators</name>
- <type>2</type>
- <locationURI>SCALA_BASEDIR/build/quick/classes/parser-combinators</locationURI>
- </link>
- <link>
- <name>src-parser-combinators</name>
- <type>2</type>
- <locationURI>SCALA_BASEDIR/src/parser-combinators</locationURI>
- </link>
- </linkedResources>
-</projectDescription>
diff --git a/src/eclipse/scala-xml/.classpath b/src/eclipse/scala-xml/.classpath
deleted file mode 100644
index b90d951640..0000000000
--- a/src/eclipse/scala-xml/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="src-xml"/>
- <classpathentry kind="con" path="org.scala-ide.sdt.launching.SCALA_CONTAINER"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="output" path="build-quick-xml"/>
-</classpath>
diff --git a/src/eclipse/scala-xml/.project b/src/eclipse/scala-xml/.project
deleted file mode 100644
index 8b0f7f6864..0000000000
--- a/src/eclipse/scala-xml/.project
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>scala-xml</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.scala-ide.sdt.core.scalabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.scala-ide.sdt.core.scalanature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
- <linkedResources>
- <link>
- <name>build-quick-xml</name>
- <type>2</type>
- <locationURI>SCALA_BASEDIR/build/quick/classes/xml</locationURI>
- </link>
- <link>
- <name>src-xml</name>
- <type>2</type>
- <locationURI>SCALA_BASEDIR/src/xml</locationURI>
- </link>
- </linkedResources>
-</projectDescription>
diff --git a/src/eclipse/scaladoc/.classpath b/src/eclipse/scaladoc/.classpath
index 4b9327796b..1135a5c311 100644
--- a/src/eclipse/scaladoc/.classpath
+++ b/src/eclipse/scaladoc/.classpath
@@ -1,12 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="scaladoc"/>
- <classpathentry combineaccessrules="false" kind="src" path="/scala-partest"/>
<classpathentry kind="var" path="SCALA_BASEDIR/lib/ant/ant.jar"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry combineaccessrules="false" kind="src" path="/scala-compiler"/>
<classpathentry combineaccessrules="false" kind="src" path="/scala-library"/>
- <classpathentry combineaccessrules="false" kind="src" path="/scala-xml"/>
- <classpathentry combineaccessrules="false" kind="src" path="/scala-parser-combinators"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/partest-extras"/>
+ <classpathentry kind="var" path="M2_REPO/org/scala-lang/modules/scala-xml_2.11.0-M4/1.0-RC3/scala-xml_2.11.0-M4-1.0-RC3.jar"/>
+ <classpathentry kind="var" path="M2_REPO/org/scala-lang/modules/scala-parser-combinators_2.11.0-M4/1.0-RC1/scala-parser-combinators_2.11.0-M4-1.0-RC1.jar"/>
+ <classpathentry kind="var" path="M2_REPO/org/scala-lang/modules/scala-partest_2.11.0-M4/1.0-RC4/scala-partest_2.11.0-M4-1.0-RC4.jar"/>
<classpathentry kind="output" path="build-quick-scaladoc"/>
</classpath>