diff options
author | Sandy Ryza <sandy@cloudera.com> | 2014-11-14 14:21:57 -0800 |
---|---|---|
committer | Patrick Wendell <pwendell@gmail.com> | 2014-11-14 14:21:57 -0800 |
commit | f5f757e4ed80759dc5668c63d5663651689f8da8 (patch) | |
tree | 148a4f9284c41d3ee8bce0a339d6c66e52aeac9a /repl | |
parent | bbd8f5bee81d5788c356977c173dd1edc42c77a3 (diff) | |
download | spark-f5f757e4ed80759dc5668c63d5663651689f8da8.tar.gz spark-f5f757e4ed80759dc5668c63d5663651689f8da8.tar.bz2 spark-f5f757e4ed80759dc5668c63d5663651689f8da8.zip |
SPARK-4375. no longer require -Pscala-2.10
It seems like the winds might have moved away from this approach, but wanted to post the PR anyway because I got it working and to show what it would look like.
Author: Sandy Ryza <sandy@cloudera.com>
Closes #3239 from sryza/sandy-spark-4375 and squashes the following commits:
0ffbe95 [Sandy Ryza] Enable -Dscala-2.11 in sbt
cd42d94 [Sandy Ryza] Update doc
f6644c3 [Sandy Ryza] SPARK-4375 take 2
Diffstat (limited to 'repl')
-rw-r--r-- | repl/pom.xml | 117 |
1 files changed, 42 insertions, 75 deletions
diff --git a/repl/pom.xml b/repl/pom.xml index bd688c8c1e..c2bf9fdfbc 100644 --- a/repl/pom.xml +++ b/repl/pom.xml @@ -35,6 +35,8 @@ <sbt.project.name>repl</sbt.project.name> <deb.install.path>/usr/share/spark</deb.install.path> <deb.user>root</deb.user> + <extra.source.dir>scala-2.10/src/main/scala</extra.source.dir> + <extra.testsource.dir>scala-2.10/src/test/scala</extra.testsource.dir> </properties> <dependencies> @@ -122,86 +124,51 @@ </environmentVariables> </configuration> </plugin> + <!-- Include a source dir depending on the Scala version --> + <plugin> + <groupId>org.codehaus.mojo</groupId> + <artifactId>build-helper-maven-plugin</artifactId> + <executions> + <execution> + <id>add-scala-sources</id> + <phase>generate-sources</phase> + <goals> + <goal>add-source</goal> + </goals> + <configuration> + <sources> + <source>src/main/scala</source> + <source>${extra.source.dir}</source> + </sources> + </configuration> + </execution> + <execution> + <id>add-scala-test-sources</id> + <phase>generate-test-sources</phase> + <goals> + <goal>add-test-source</goal> + </goals> + <configuration> + <sources> + <source>src/test/scala</source> + <source>${extra.testsource.dir}</source> + </sources> + </configuration> + </execution> + </executions> + </plugin> </plugins> </build> <profiles> <profile> - <id>scala-2.10</id> - <build> - <plugins> - <plugin> - <groupId>org.codehaus.mojo</groupId> - <artifactId>build-helper-maven-plugin</artifactId> - <executions> - <execution> - <id>add-scala-sources</id> - <phase>generate-sources</phase> - <goals> - <goal>add-source</goal> - </goals> - <configuration> - <sources> - <source>src/main/scala</source> - <source>scala-2.10/src/main/scala</source> - </sources> - </configuration> - </execution> - <execution> - <id>add-scala-test-sources</id> - <phase>generate-test-sources</phase> - <goals> - <goal>add-test-source</goal> - </goals> - <configuration> - <sources> - <source>src/test/scala</source> - <source>scala-2.10/src/test/scala</source> - </sources> - </configuration> - </execution> - </executions> - </plugin> - </plugins> - </build> - </profile> - <profile> <id>scala-2.11</id> - <build> - <plugins> - <plugin> - <groupId>org.codehaus.mojo</groupId> - <artifactId>build-helper-maven-plugin</artifactId> - <executions> - <execution> - <id>add-scala-sources</id> - <phase>generate-sources</phase> - <goals> - <goal>add-source</goal> - </goals> - <configuration> - <sources> - <source>src/main/scala</source> - <source>scala-2.11/src/main/scala</source> - </sources> - </configuration> - </execution> - <execution> - <id>add-scala-test-sources</id> - <phase>generate-test-sources</phase> - <goals> - <goal>add-test-source</goal> - </goals> - <configuration> - <sources> - <source>src/test/scala</source> - <source>scala-2.11/src/test/scala</source> - </sources> - </configuration> - </execution> - </executions> - </plugin> - </plugins> - </build> + <activation> + <property><name>scala-2.11</name></property> + </activation> + <properties> + <extra.source.dir>scala-2.11/src/main/scala</extra.source.dir> + <extra.testsource.dir>scala-2.11/src/test/scala</extra.testsource.dir> + </properties> </profile> </profiles> </project> |