aboutsummaryrefslogtreecommitdiff
path: root/project
diff options
context:
space:
mode:
authorJakob Odersky <jodersky@gmail.com>2014-05-06 23:14:22 +0200
committerJakob Odersky <jodersky@gmail.com>2014-05-06 23:14:22 +0200
commit577ad5b12c54ccf250c9717b15ce0308fa19c453 (patch)
tree293a137feaa8446fb693508bddaf43ff680755c7 /project
parentbf6d9bfdac41dfd70c04749aa3d7efb60e9ae984 (diff)
downloadakka-serial-577ad5b12c54ccf250c9717b15ce0308fa19c453.tar.gz
akka-serial-577ad5b12c54ccf250c9717b15ce0308fa19c453.tar.bz2
akka-serial-577ad5b12c54ccf250c9717b15ce0308fa19c453.zip
make sample runnable without instralling native libries
Diffstat (limited to 'project')
-rw-r--r--project/FlowBuild.scala10
-rw-r--r--project/native.scala2
2 files changed, 9 insertions, 3 deletions
diff --git a/project/FlowBuild.scala b/project/FlowBuild.scala
index 58e7ab3..8993f30 100644
--- a/project/FlowBuild.scala
+++ b/project/FlowBuild.scala
@@ -76,7 +76,7 @@ object FlowBuild extends Build {
)
lazy val flowNative: Project = (
- Project("flow-native", file("flow-native-scala"))
+ Project("flow-native", file("flow-native-sbt"))
settings(commonSettings: _*)
settings(publishSettings: _*)
settings(NativeDefaults.settings: _*)
@@ -86,10 +86,16 @@ object FlowBuild extends Build {
)
lazy val samplesTerminal = (
- Project("flow-samples-terminal", file("flow-samples") / "flow-samples-terminal")
+ Project("flow-samples-terminal", file("flow-samples") / "terminal")
settings(commonSettings: _*)
settings(runSettings: _*)
dependsOn(flow)
+
+ //kind of dirty, but it gets the sample to run without installing native libraries
+ settings(
+ (run in Compile) <<= (run in Compile).dependsOn(nativeBuild in flowNative),
+ javaOptions += "-Djava.library.path=" + (nativeOutputDirectory in flowNative).value.getAbsolutePath()
+ )
)
}
diff --git a/project/native.scala b/project/native.scala
index edd80c1..9af8b77 100644
--- a/project/native.scala
+++ b/project/native.scala
@@ -21,7 +21,7 @@ object NativeDefaults {
val log = streams.value.log
val build = nativeBuildDirectory.value
- Process("make distclean", build) #|| Process("clean", build) ! log
+ Process("make distclean", build) #|| Process("make clean", build) ! log
}
val autoLib = Def.task {