-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathbuild.sbt
113 lines (102 loc) · 3.34 KB
/
build.sbt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
import CommonSettings.autoImport._
ThisBuild / organization := "com.github.mgdigital"
ThisBuild / organizationName := "MGDigital"
ThisBuild / organizationHomepage := Some(url("/~https://github.com/mgdigital"))
ThisBuild / scmInfo := Some(
ScmInfo(
url("/~https://github.com/mgdigital/Chromaprint.scala"),
"scm:git@github.com:mgdigital/Chromaprint.scala.git"
)
)
ThisBuild / developers := List(
Developer(
id = "MGDigital",
name = "Mike Gibson",
email = "chromaprint@mgdigital.co.uk",
url = url("/~https://github.com/mgdigital")
)
)
ThisBuild / description := "A Scala implementation of the Chromaprint/AcoustID audio fingerprinting algorithm."
ThisBuild / licenses := List("Apache-2.0" -> new URL("http://www.apache.org/licenses/LICENSE-2.0.txt"))
ThisBuild / homepage := Some(url("/~https://github.com/mgdigital/Chromaprint.scala"))
val mapAll = "runtime->runtime;test->test;compile->compile"
lazy val core = (project in file("./src/core"))
.settings(
name := "chromaprint-core",
libraryDependencies ++= Seq(
Dependencies.fs2,
Dependencies.spire
)
)
.disablePlugins(org.bytedeco.sbt.javacpp.Plugin, AssemblyPlugin)
.enablePlugins(GitVersioning, CodecsPlugin)
lazy val acoustid = (project in file("./src/acoustid"))
.settings(
name := "chromaprint-acoustid",
libraryDependencies ++= Seq(
Dependencies.circeGeneric,
Dependencies.http4sClient,
Dependencies.http4sDsl,
Dependencies.http4sCirce
)
)
.disablePlugins(org.bytedeco.sbt.javacpp.Plugin, AssemblyPlugin)
.enablePlugins(GitVersioning)
.dependsOn(core % mapAll)
lazy val cli = (project in file("./src/cli"))
.settings(
name := "chromaprint-cli",
libraryDependencies ++= Seq(
Dependencies.console4Cats,
Dependencies.decline,
Dependencies.http4sClient,
)
)
.disablePlugins(org.bytedeco.sbt.javacpp.Plugin, AssemblyPlugin)
.enablePlugins(GitVersioning)
.dependsOn(
core % mapAll,
acoustid % mapAll
)
lazy val breeze = (project in file("./src/breeze"))
.settings(
name := "chromaprint-breeze",
libraryDependencies ++= Seq(
Dependencies.breezeCore,
Dependencies.breezeNatives
),
dependencyOverrides ++= Seq(
Dependencies.spire
)
)
.disablePlugins(org.bytedeco.sbt.javacpp.Plugin, AssemblyPlugin)
.enablePlugins(GitVersioning)
.dependsOn(core % mapAll)
lazy val fftw = (project in file("./src/fftw"))
.settings(
name := "chromaprint-fftw",
javaCppPresetLibs := Seq(
"fftw" -> Dependencies.Versions.javaCppFftw
),
javaCppVersion := Dependencies.Versions.javaCpp
)
.disablePlugins(AssemblyPlugin)
.enablePlugins(GitVersioning)
.dependsOn(core % mapAll)
lazy val root = (project in file("."))
.settings(
name := "chromaprint",
mainClass := Some("chromaprint.Main"),
sourceDirectory := baseDirectory.value / "src" / "dist",
sourceDirectories in Test ++= Seq("acoustid", "breeze", "cli", "core")
.map(m => baseDirectory.value / "target" / "modules" / s"chromaprint-$m"),
baseRoot := baseDirectory.value,
target := baseTarget.value,
libraryDependencies ++= Seq(
Dependencies.http4sBlazeClient,
)
)
.disablePlugins(org.bytedeco.sbt.javacpp.Plugin)
.enablePlugins(GitVersioning, CodecsPlugin)
.aggregate(core, acoustid, cli, breeze)
.dependsOn(core, acoustid, cli, breeze)