-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.sc
141 lines (110 loc) · 3.39 KB
/
build.sc
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
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
// import Mill dependency
import mill._
import mill.define.Sources
import mill.modules.Util
import mill.scalalib.TestModule.ScalaTest
import scalalib._
// support BSP
import mill.bsp._
trait CommonModule extends ScalaModule {
override def scalaVersion = "2.12.10"
override def scalacOptions = Seq("-Xsource:2.11")
private val macroParadise = ivy"org.scalamacros:::paradise:2.1.0"
override def compileIvyDeps = Agg(macroParadise)
override def scalacPluginIvyDeps = Agg(macroParadise)
}
val chisel = Agg(
ivy"edu.berkeley.cs::chisel3:3.4.3"
)
object `api-config-chipsalliance` extends CommonModule {
override def millSourcePath = os.pwd / "dependency" / "api-config-chipsalliance" / "design" / "craft"
}
object hardfloat extends SbtModule with CommonModule {
override def millSourcePath = os.pwd / "dependency" / "berkeley-hardfloat"
override def ivyDeps = super.ivyDeps() ++ chisel
}
//object `rocket-chip` extends SbtModule with CommonModule {
//
// override def ivyDeps = super.ivyDeps() ++ Agg(
// ivy"${scalaOrganization()}:scala-reflect:${scalaVersion()}",
//// ivy"org.json4s::json4s-jackson:3.6.1"
// ) ++ chisel
//
// object macros extends SbtModule with CommonModule
//
// override def millSourcePath = os.pwd / "dependency" / "rocket-chip"
//
// override def moduleDeps = super.moduleDeps ++ Seq(
// `api-config-chipsalliance`, macros, hardfloat
// )
//
//}
object gcd extends SbtModule with CommonModule { m =>
override def millSourcePath = os.pwd / "gcd"
override def forkArgs = Seq("-Xmx64G")
override def ivyDeps = super.ivyDeps() ++ chisel
override def moduleDeps = super.moduleDeps ++ Seq(
// `rocket-chip`
`api-config-chipsalliance`,
)
override def scalacPluginIvyDeps = Agg(
ivy"edu.berkeley.cs:::chisel3-plugin:3.4.3",
ivy"org.scalamacros:::paradise:2.1.1"
)
object test extends Tests with ScalaTest {
override def ivyDeps = m.ivyDeps() ++ Agg(
ivy"edu.berkeley.cs::chiseltest:0.3.3"
)
}
}
object difftest extends SbtModule { m =>
override def millSourcePath = os.pwd / "dependency" / "difftest"
override def scalaVersion = "2.13.8"
override def scalacOptions = Seq(
"-language:reflectiveCalls",
"-deprecation",
"-feature",
"-Xcheckinit",
"-P:chiselplugin:genBundleElements"
)
override def ivyDeps = Agg(
ivy"edu.berkeley.cs::chisel3:3.5.1",
)
override def scalacPluginIvyDeps = Agg(
ivy"edu.berkeley.cs:::chisel3-plugin:3.5.1",
)
object test extends Tests with ScalaTest {
override def ivyDeps = m.ivyDeps() ++ Agg(
ivy"edu.berkeley.cs::chiseltest:0.5.1"
)
}
override def forkArgs = Seq("-Xmx64G")
}
object cpu extends SbtModule { m =>
override def millSourcePath = os.pwd / "cpu"
override def scalaVersion = "2.13.8"
override def scalacOptions = Seq(
"-language:reflectiveCalls",
"-deprecation",
"-feature",
"-Xcheckinit",
"-P:chiselplugin:genBundleElements"
)
override def ivyDeps = Agg(
ivy"edu.berkeley.cs::chisel3:3.5.1",
)
override def scalacPluginIvyDeps = Agg(
ivy"edu.berkeley.cs:::chisel3-plugin:3.5.1",
)
object test extends Tests with ScalaTest {
override def ivyDeps = m.ivyDeps() ++ Agg(
ivy"edu.berkeley.cs::chiseltest:0.5.1"
)
}
override def forkArgs = Seq("-Xmx64G")
override def moduleDeps = super.moduleDeps ++ Seq(
// `rocket-chip`,
`api-config-chipsalliance`,
difftest
)
}