diff options
Diffstat (limited to 'project')
-rw-r--r-- | project/nativefat.scala.disabled | 47 |
1 files changed, 0 insertions, 47 deletions
diff --git a/project/nativefat.scala.disabled b/project/nativefat.scala.disabled deleted file mode 100644 index e1cfcd3..0000000 --- a/project/nativefat.scala.disabled +++ /dev/null @@ -1,47 +0,0 @@ -import sbt._ -import Keys._ -import NativeKeys._ -import java.io.File -import scala.collection.mutable.HashSet - -object NativeFatKeys { - - val NativeFat = config("nativeFat") - - -} - -object NativeFatDefaults { - import NativeFatKeys._ - - def highest(files: Seq[File], separator: String) = { - files.sortBy{f => - f.getName.split(separator) match { - case Array(name, version) => version - case _ => throw new RuntimeException("Error parsing file version string: " + f.getName) - } - }.last - } - - val gen = taskKey[Seq[File]]("") - - val genImpl = Def.task { - val resDir = (resourceManaged).value - val binDir = nativeTargetDirectory.value - val binarises = nativeLink.value - - val resources = for ((_, binary) <- binarises) yield { - val relative = (binary relativeTo binDir).get.getPath - val resource = resDir / "native" / relative - IO.copyFile(binary, resource) - resource - } - resources.toSeq - } - - val settings = Seq( - gen := genImpl.value, - resourceGenerators in NativeFat := Seq(genImpl) - ) - -}
\ No newline at end of file |