Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 192 lines (159 sloc) 6.924 kB
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
1 /*
2 * Copyright 2012 WorldWide Conferencing, LLC
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17 import sbt._
18 import Keys._
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
19 import net.liftweb.sbt.LiftBuildPlugin._
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
20 import Dependencies._
21
22
23 object BuildDef extends Build {
24
25 lazy val liftProjects = core ++ web ++ persistence
26
27 lazy val framework =
28 liftProject("lift-framework", file("."))
29 .aggregate(liftProjects: _*)
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
30 .settings(aggregatedSetting(sources in(Compile, doc)),
31 aggregatedSetting(dependencyClasspath in(Compile, doc)),
32 publishArtifact := false)
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
33
34 // Core Projects
35 // -------------
36 lazy val core: Seq[ProjectReference] =
37 Seq(common, actor, json, json_scalaz, json_ext, util)
38
39 lazy val common =
40 coreProject("common")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
41 .settings(description := "Common Libraties and Utilities",
aa8a9e0 @indrajitr lift-common doesn't need commons-codec
indrajitr authored
42 libraryDependencies ++= Seq(slf4j_api, logback, slf4j_log4j12))
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
43
44 lazy val actor =
45 coreProject("actor")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
46 .dependsOn(common)
3de543d @indrajitr Disable parallel execution of test for lift-actor, lift-json
indrajitr authored
47 .settings(description := "Simple Actor",
48 parallelExecution in Test := false)
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
49
50 lazy val json =
51 coreProject("json")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
52 .settings(description := "JSON Library",
3de543d @indrajitr Disable parallel execution of test for lift-actor, lift-json
indrajitr authored
53 parallelExecution in Test := false,
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
54 libraryDependencies <++= scalaVersion { sv => Seq(scalap(sv), paranamer) })
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
55
56 lazy val json_scalaz =
57 coreProject("json-scalaz")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
58 .dependsOn(json)
59 .settings(description := "JSON Library based on Scalaz",
60 libraryDependencies <+= scalaVersion(scalaz))
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
61
62 lazy val json_ext =
63 coreProject("json-ext")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
64 .dependsOn(common, json)
65 .settings(description := "Extentions to JSON Library",
66 libraryDependencies ++= Seq(commons_codec, joda_time))
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
67
68 lazy val util =
69 coreProject("util")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
70 .dependsOn(actor, json)
71 .settings(description := "Utilities Library",
72 parallelExecution in Test := false,
73 libraryDependencies ++= Seq(joda_time, commons_codec, javamail, log4j, htmlparser))
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
74
75
76 // Web Projects
77 // ------------
78 lazy val web: Seq[ProjectReference] =
79 Seq(testkit, webkit, wizard)
80
81 lazy val testkit =
82 webProject("testkit")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
83 .dependsOn(util)
84 .settings(description := "Testkit for Webkit Library",
85 libraryDependencies ++= Seq(commons_httpclient, servlet_api))
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
86
87 lazy val webkit =
88 webProject("webkit")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
89 .dependsOn(util, testkit % "provided")
24db7fb @indrajitr Use updated SBT plugins from newer location, cleanup plugin config
indrajitr authored
90 .settings(yuiCompressor.Plugin.yuiSettings: _*)
91 .settings(description := "Webkit Library",
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
92 parallelExecution in Test := false,
93 libraryDependencies <++= scalaVersion { sv =>
94 Seq(commons_fileupload, servlet_api, specs(sv).copy(configurations = Some("provided")), jetty6, jwebunit)
95 },
96 initialize in Test <<= (sourceDirectory in Test) { src =>
97 System.setProperty("net.liftweb.webapptest.src.test.webapp", (src / "webapp").absString)
24db7fb @indrajitr Use updated SBT plugins from newer location, cleanup plugin config
indrajitr authored
98 })
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
99
100 lazy val wizard =
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
101 webProject("wizard")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
102 .dependsOn(webkit, db)
103 .settings(description := "Wizard Library")
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
104
105
106 // Persistence Projects
107 // --------------------
108 lazy val persistence: Seq[ProjectReference] =
109 Seq(db, proto, jpa, mapper, record, couchdb, squeryl_record, mongodb, mongodb_record, ldap)
110
111 lazy val db =
112 persistenceProject("db")
380ccf0 @dpp Addresses #1235 by being explicit that an exception was thrown in an …
dpp authored
113 .dependsOn(util, webkit)
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
114 .settings(libraryDependencies += mockito_all)
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
115
116 lazy val proto =
117 persistenceProject("proto")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
118 .dependsOn(webkit)
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
119
120 lazy val jpa =
121 persistenceProject("jpa")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
122 .dependsOn(webkit)
123 .settings(libraryDependencies ++= Seq(scalajpa, persistence_api))
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
124
125 lazy val mapper =
126 persistenceProject("mapper")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
127 .dependsOn(db, proto)
128 .settings(description := "Mapper Library",
129 parallelExecution in Test := false,
130 libraryDependencies ++= Seq(h2, derby),
131 initialize in Test <<= (crossTarget in Test) { ct =>
132 System.setProperty("derby.stream.error.file", (ct / "derby.log").absolutePath)
133 })
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
134
135 lazy val record =
136 persistenceProject("record")
94df330 @eltimn Issues 997/906 - Remove deprecated DB code from Record. Remove MongoD…
eltimn authored
137 .dependsOn(proto)
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
138
139 lazy val couchdb =
140 persistenceProject("couchdb")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
141 .dependsOn(record)
25cfda3 @fmpwizard * CouchDB Record was running tests in parallel, and were failing. Now…
fmpwizard authored
142 .settings(libraryDependencies += dispatch_http,
143 parallelExecution in Test := false)
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
144
145 lazy val squeryl_record =
146 persistenceProject("squeryl-record")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
147 .dependsOn(record, db)
148 .settings(libraryDependencies ++= Seq(h2, squeryl))
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
149
150 lazy val mongodb =
151 persistenceProject("mongodb")
bec9a49 @eltimn Issue 1227 - Add configurable ObjectId tester in JObjectParser
eltimn authored
152 .dependsOn(json_ext, util)
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
153 .settings(parallelExecution in Test := false,
154 libraryDependencies += mongo_driver,
ac92811 @indrajitr Use resourceDirectory instead of classDirectory
indrajitr authored
155 initialize in Test <<= (resourceDirectory in Test) { rd =>
156 System.setProperty("java.util.logging.config.file", (rd / "logging.properties").absolutePath)
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
157 })
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
158
159 lazy val mongodb_record =
160 persistenceProject("mongodb-record")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
161 .dependsOn(record, mongodb)
162 .settings(parallelExecution in Test := false)
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
163
164 lazy val ldap =
165 persistenceProject("ldap")
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
166 .dependsOn(mapper)
167 .settings(libraryDependencies += apacheds,
168 initialize in Test <<= (crossTarget in Test) { ct =>
169 System.setProperty("apacheds.working.dir", (ct / "apacheds").absolutePath)
170 })
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
171
172 def coreProject = liftProject("core") _
173 def webProject = liftProject("web") _
174 def persistenceProject = liftProject("persistence") _
175
176 /** Project definition helper that simplifies creation of `ProjectReference`.
177 *
178 * It is a convenience method to create a Lift `ProjectReference` module by having the boilerplate for most common
179 * activities tucked in.
180 *
181 * @param base the base path location of project module.
182 * @param prefix the prefix of project module.
183 * @param module the name of the project module. Typically, a project id is of the form lift-`module`.
184 */
185 def liftProject(base: String, prefix: String = "lift-")(module: String): Project =
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
186 liftProject(id = if (module.startsWith(prefix)) module else prefix + module,
187 base = file(base) / module.stripPrefix(prefix))
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
188
189 def liftProject(id: String, base: File): Project =
9a78397 @indrajitr - Update to SBT 0.12.0-M1
indrajitr authored
190 Project(id, base).settings(liftBuildSettings: _*)
d505b36 @indrajitr Move to SBT 0.11.2
indrajitr authored
191 }
Something went wrong with that request. Please try again.