Revision 1929
Added by brooke over 20 years ago
build.xml | ||
---|---|---|
30 | 30 |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
31 | 31 |
--> |
32 | 32 |
<project name="metacat" default="jar" basedir="."> |
33 |
<target name="oracle"> |
|
33 |
|
|
34 |
<property file="build.properties"/> <!-- USER SPECIFIC PROPS --> |
|
35 |
|
|
36 |
<target name="check-db"> |
|
37 |
<condition property="use-oracle"> |
|
38 |
<equals arg1="${database}" arg2="oracle" /> |
|
39 |
</condition> |
|
40 |
<condition property="use-postgresql"> |
|
41 |
<equals arg1="${database}" arg2="postgresql" /> |
|
42 |
</condition> |
|
43 |
<condition property="use-sqlserver"> |
|
44 |
<equals arg1="${database}" arg2="sqlserver" /> |
|
45 |
</condition> |
|
46 |
</target> |
|
47 |
|
|
48 |
<target name="oracle" if="use-oracle"> |
|
34 | 49 |
<!-- Customize these properties if you are using oracle --> |
35 |
<property name="jdbc-connect" |
|
36 |
value="jdbc:oracle:thin:@pine.nceas.ucsb.edu:1521:knb"/> |
|
50 |
<echo message="Using oracle..."/> |
|
37 | 51 |
<property name="dbDriver" value="oracle.jdbc.driver.OracleDriver"/> |
38 | 52 |
<property name="dbAdapter" value="edu.ucsb.nceas.dbadapter.OracleAdapter"/> |
39 |
<property name="oracle_home" value="/usr/local/oracle/8.1.6" /> |
|
40 |
<property name="jdbc" value="${oracle_home}/jdbc/lib/classes111.zip" /> |
|
53 |
<property name="jdbc" value="${jdbc_base}/classes111.zip" /> |
|
41 | 54 |
<!-- Property to indicate is not MSSQL installation--> |
42 | 55 |
<property name="other" value="yes"/> |
43 | 56 |
</target> |
44 | 57 |
|
45 |
<target name="postgresql"> |
|
58 |
<target name="postgresql" if="use-postgresql">
|
|
46 | 59 |
<!-- Customize these properties if you are using postgres --> |
47 |
<property name="jdbc-connect" |
|
48 |
value="jdbc:postgresql://localhost/exp"/> |
|
60 |
<echo message="Using PostgreSQL..."/> |
|
49 | 61 |
<property name="dbDriver" value="org.postgresql.Driver"/> |
50 | 62 |
<property name="dbAdapter" |
51 | 63 |
value="edu.ucsb.nceas.dbadapter.PostgresqlAdapter"/> |
... | ... | |
54 | 66 |
<property name="other" value="yes"/> |
55 | 67 |
</target> |
56 | 68 |
|
57 |
<target name="sqlserver"> |
|
69 |
<target name="sqlserver" if="use-sqlserver">
|
|
58 | 70 |
<!-- Customize these properties if you are using SQL server --> |
59 |
<property name="jdbc-connect" |
|
60 |
value="jdbc:microsoft:sqlserver://fatali.nceas.ucsb.edu:1433"/> |
|
71 |
<echo message="Using SQL Server..."/> |
|
61 | 72 |
<property name="dbDriver" value="com.microsoft.jdbc.sqlserver.SQLServerDriver"/> |
62 | 73 |
<property name="dbAdapter" |
63 | 74 |
value="edu.ucsb.nceas.dbadapter.SqlserverAdapter"/> |
64 |
<property name="jdbc-base" value="F:\\Program Files\\Microsoft SQL Server 2000 Driver for JDBC\\lib" /> |
|
65 | 75 |
<property name="jdbc" value="${jdbc-base}/msbase.jar" /> |
66 | 76 |
<property name="jdbc-add1" value="${jdbc-base}/msutil.jar" /> |
67 | 77 |
<property name="jdbc-add2" value="${jdbc-base}/mssqlserver.jar" /> |
... | ... | |
69 | 79 |
<property name="MSSQL" value="yes"/> |
70 | 80 |
</target> |
71 | 81 |
|
72 |
<target name="config" depends="oracle"> |
|
73 |
<!-- Change the 'depends' attribute above to 'postgresql' to install |
|
74 |
metacat with postgres instead of oracle --> |
|
75 |
|
|
76 |
<!-- Customize these properties for your system --> |
|
77 |
<property name="tomcat" value="/usr/local/devtools/jakarta-tomcat" /> |
|
78 |
<property name="webapps" value="${tomcat}/webapps" /> |
|
79 |
<property name="context" value="tao" /> |
|
80 |
<property name="user" value="knb"/> |
|
81 |
<property name="password" value="tdataint"/> |
|
82 |
|
|
82 |
<target name="config" depends="check-db,oracle,postgresql,sqlserver"> |
|
83 | 83 |
<!-- usr for client testing, generally you don't need change--> |
84 | 84 |
<property name="mcuser" value="uid=tao,o=NCEAS,dc=ecoinformatics,dc=org"/> |
85 | 85 |
<property name="mcpassword" value=""/> |
86 | 86 |
<property name="mcanotheruser" value="uid=jtao,o=LTER,dc=ecoinformatics,dc=org"/> |
87 | 87 |
<property name="mcanotherpassword" value=""/> |
88 | 88 |
|
89 |
<!-- Tomcat version, if you use tomcat 3, please fill it "tomcat3". If you using tomcat4, please fill it "tomcat4"--> |
|
90 |
<property name="tomcatversion" value="tomcat4"/> |
|
91 |
|
|
92 |
<property name="server" value="pine.nceas.ucsb.edu:8080"/> |
|
93 |
<property name="systemidserver" value="http://${server}" /> |
|
94 |
<property name="datafilepath" value="/usr/local/devtools/jakarta-tomcat/data/tao/data" /> |
|
95 |
<property name="inlinedatafilepath" value="/usr/local/devtools/jakarta-tomcat/data/tao/inlinedata" /> |
|
96 | 89 |
<property name="debug" value="on" /> |
97 | 90 |
<property name="debuglevel" value="55" /> |
98 | 91 |
|
99 |
<property name="forcereplicationwaitingtime" value="30000"/> |
|
100 |
<property name="cvsroot" |
|
101 |
value=":ext:tao@cvs.ecoinformatics.org:/cvs" /> |
|
102 |
<property name="web-base-url" |
|
103 |
value="http://knb.ecoinformatics.org"/> |
|
104 |
<property name="default-style" value="knb" /> |
|
105 | 92 |
<property name="morphosourcedir" value="../morpho" /> |
106 | 93 |
<property name="defaultcontenttype" value="application/octet-stream" /> |
107 | 94 |
<property name="utilitiesdir" value="../utilities" /> |
... | ... | |
139 | 126 |
<target name="init" depends="config"> |
140 | 127 |
<!-- It is less likely you'll need to make any changes from here down, |
141 | 128 |
but customization is possible --> |
142 |
<property name="installdir" value="${webapps}/${context}" /> |
|
143 |
<property name="name" value="metacat"/> |
|
144 |
<property name="Name" value="MetaCat"/> |
|
145 |
<property name="debugprefix" value="${Name}:"/> |
|
146 |
<property name="release" value="1.2.1"/> |
|
147 |
<property name="replication-path" |
|
148 |
value="/${context}/servlet/replication"/> |
|
149 |
<property name="servlet-path" value="/${context}/servlet/metacat"/> |
|
150 |
<property name="html-path" value="/${context}"/> |
|
151 |
<property name="image-path" value="/${context}" /> |
|
152 |
<property name="style-path" value="/${context}/style"/> |
|
153 |
<property name="replication-log" value="/tmp/metacatreplication.log"/> |
|
129 |
<property name="installdir" value="${webapps}/${context}" /> |
|
130 |
<property name="temp-dir" value="/tmp/${context}" /> |
|
131 |
<property name="name" value="metacat"/> |
|
132 |
<property name="Name" value="MetaCat"/> |
|
133 |
<property name="debugprefix" value="${Name}:"/> |
|
134 |
<property name="release" value="1.2.1"/> |
|
135 |
<property name="replication-path" value="/${context}/servlet/replication"/> |
|
136 |
<property name="servlet-path" value="/${context}/servlet/metacat"/> |
|
137 |
<property name="html-path" value="/${context}"/> |
|
138 |
<property name="systemidserver" value="http://${server}"/> |
|
139 |
|
|
140 |
<property name="style-common-relpath" value="/style/common"/> |
|
141 |
<property name="style-common-fullpath" |
|
142 |
value="/${installdir}${style-common-relpath}"/> |
|
143 |
<property name="style-common-path" |
|
144 |
value="/${context}${style-common-relpath}"/> |
|
145 |
<property name="style-skins-relpath" value="/style/skins"/> |
|
146 |
<property name="style-skins-path" value="/${context}${style-skins-relpath}"/> |
|
147 |
<property name="replication-log" value="/tmp/metacatreplication.log"/> |
|
154 | 148 |
<property name="replicationerrorlog" value="/tmp/metacatreplication.err"/> |
155 |
<property name="config-dir" value="${installdir}" /> |
|
156 |
<property name="eml-module" value="eml" /> |
|
157 |
<property name="eml-version" value="2.0.0beta6" /> |
|
158 |
<property name="eml-tag" value="RELEASE_EML_2_0_0_BETA_6_REV1" /> |
|
159 |
<property name="eml2-tag" value="STMML_SCHEMA_UPDATE" /> |
|
160 |
<property name="eml2namespace" value="eml://ecoinformatics.org/eml-2.0.0" /> |
|
161 |
<property name="stmmlnamespace" value="http://www.xml-cml.org/schema/stmml" /> |
|
149 |
<property name="config-dir" value="${webapps}/${style-skins-path}" /> |
|
150 |
<property name="eml-module" value="eml" /> |
|
151 |
<property name="eml-version" value="2.0.0beta6" /> |
|
152 |
<property name="eml-tag" value="EML_2_0_0_BETA_6_FOR_METACAT" /> |
|
153 |
<property name="eml2-tag" value="EML_2_0_0_FOR_METACAT" /> |
|
154 |
<property name="eml2namespace" value="eml://ecoinformatics.org/eml-2.0.0" /> |
|
155 |
<property name="stmmlnamespace" value="http://www.xml-cml.org/schema/stmml" /> |
|
156 |
<property name="conversion-module" value="webmdentry" /> |
|
162 | 157 |
|
158 |
<!-- Config for registry variables --> |
|
159 |
<property name="scope" value="obfs"/> |
|
160 |
<property name="responseForm" value="genericResponse.tmpl"/> |
|
161 |
<property name="entryForm" value="entryForm.tmpl"/> |
|
162 |
<property name="guide" value="genericGuide.tmpl"/> |
|
163 |
<property name="confirmData" value="confirmData.tmpl"/> |
|
164 |
<property name="deleteData" value="deleteData.tmpl"/> |
|
165 |
<property name="genericHeader" value="genericHeader.tmpl"/> |
|
166 |
<property name="genericFooter" value="genericFooter.tmpl"/> |
|
167 |
<property name="adminname" value="KNB Support"/> |
|
168 |
<property name="recipient" value="knb-software\@nceas.ucsb.edu"/> |
|
169 |
<filter token="scope" value="${scope}"/> |
|
170 |
<filter token="responseForm" value="${responseForm}"/> |
|
171 |
<filter token="entryForm" value="${entryForm}"/> |
|
172 |
<filter token="guide" value="${guide}"/> |
|
173 |
<filter token="confirmData" value="${confirmData}"/> |
|
174 |
<filter token="deleteData" value="${deleteData}"/> |
|
175 |
<filter token="genericHeader" value="${genericHeader}"/> |
|
176 |
<filter token="genericFooter" value="${genericFooter}"/> |
|
177 |
<filter token="adminname" value="${adminname}"/> |
|
178 |
<filter token="recipient" value="${recipient}"/> |
|
179 |
|
|
163 | 180 |
<property name="cpath" |
164 | 181 |
value="${xmlp}:${xalan}:${apis}:${jdbc}:${jsdk}:${srb}:${cos}:${morpho}:${emlparser}:${jdbc-add1}:${jdbc-add2}:${util}:${httpclient}"/> |
165 | 182 |
|
... | ... | |
168 | 185 |
<filter token="dbDriver" value="${dbDriver}"/> |
169 | 186 |
<filter token="dbAdapter" value="${dbAdapter}"/> |
170 | 187 |
<filter token="install-dir" value="${installdir}"/> |
188 |
<filter token="temp-dir" value="${temp-dir}"/> |
|
171 | 189 |
<filter token="server" value="${server}"/> |
172 | 190 |
<filter token="systemidserver" value="${systemidserver}"/> |
191 |
<filter token="cgi-prefix" value="${cgi-prefix}"/> |
|
192 |
<filter token="ldapUrl" value="${ldapUrl}"/> |
|
173 | 193 |
<filter token="replication-log" value="${replication-log}"/> |
174 | 194 |
<filter token="replicationerrorlog" value="${replicationerrorlog}"/> |
175 | 195 |
<filter token="release" value="${release}"/> |
... | ... | |
181 | 201 |
<filter token="mcpassword" value="${mcpassword}"/> |
182 | 202 |
<filter token="mcanotheruser" value="${mcanotheruser}"/> |
183 | 203 |
<filter token="mcanotherpassword" value="${mcanotherpassword}"/> |
184 |
<filter token="image-path" value="${image-path}"/> |
|
185 |
<filter token="style-path" value="${style-path}"/> |
|
186 |
<filter token="web-base-url" value="${web-base-url}"/> |
|
204 |
<filter token="knb-site-url" value="${knb-site-url}"/> |
|
205 |
<filter token="style-skins-relpath" value="${style-skins-relpath}"/> |
|
206 |
<filter token="style-skins-path" value="${style-skins-path}"/> |
|
207 |
<filter token="style-common-relpath" value="${style-common-relpath}"/> |
|
208 |
<filter token="style-common-fullpath" value="${style-common-fullpath}"/> |
|
209 |
<filter token="style-common-path" value="${style-common-path}"/> |
|
210 |
<!-- The "style-path" filter is used by the eml xsl stylesheets!! --> |
|
211 |
<filter token="style-path" value="${style-skins-path}"/> |
|
187 | 212 |
<filter token="replication-path" value="${replication-path}"/> |
188 | 213 |
<filter token="config-dir" value="${config-dir}"/> |
189 | 214 |
<filter token="default-style" value="${default-style}"/> |
... | ... | |
214 | 239 |
<property name="build.metacatnettest" value="${build.tests}/metacatnettest"/> |
215 | 240 |
<property name="build.data" value="${build.dir}/data"/> |
216 | 241 |
<property name="build.javadocs" value="${build.dir}/docs/api"/> |
217 |
<property name="build.img" value="${installdir}"/> |
|
218 | 242 |
|
219 | 243 |
<property name="dist.dir" value="dist"/> |
220 | 244 |
<property name="ver.dir" value="${dist.dir}/${name}-${release}"/> |
... | ... | |
303 | 327 |
</fileset> |
304 | 328 |
<mapper type="glob" from="eml-*.dtd" to="eml-*-${eml-version}.dtd" /> |
305 | 329 |
</copy> |
306 |
<echo>Enter CVS password: </echo> |
|
330 |
<copy todir="lib/style/common" filtering="yes"> |
|
331 |
<fileset dir="${build.tmp}/${eml-module}/style"> |
|
332 |
<include name="**/*.xsl"/> |
|
333 |
</fileset> |
|
334 |
</copy> <echo>Enter CVS password: </echo> |
|
307 | 335 |
<cvs cvsRoot="${cvsroot}" |
308 | 336 |
package="${eml-module}" |
309 | 337 |
tag="${eml2-tag}" |
... | ... | |
314 | 342 |
<include name="*.xsd"/> |
315 | 343 |
</fileset> |
316 | 344 |
</copy> |
317 |
<copy todir="lib/style"> |
|
345 |
<copy todir="lib/style/common" filtering="yes">
|
|
318 | 346 |
<fileset dir="${build.tmp}/${eml-module}/style"> |
319 |
<include name="*.xsl"/> |
|
347 |
<include name="**/*.xsl"/>
|
|
320 | 348 |
</fileset> |
321 | 349 |
</copy> |
322 | 350 |
</target> |
... | ... | |
348 | 376 |
<include name="*.xsd"/> |
349 | 377 |
</fileset> |
350 | 378 |
</copy> |
351 |
<copy todir="lib/style"> |
|
379 |
<copy todir="lib/style/common">
|
|
352 | 380 |
<fileset dir="${build.tmp}/${eml-module}/style"> |
353 |
<include name="*.xsl"/> |
|
381 |
<include name="**/*.xsl"/>
|
|
354 | 382 |
</fileset> |
355 | 383 |
</copy> |
356 | 384 |
</target> |
... | ... | |
414 | 442 |
<mkdir dir="${datafilepath}" /> |
415 | 443 |
<mkdir dir="${inlinedatafilepath}" /> |
416 | 444 |
<chmod dir="${datafilepath}" perm="ug+w" /> |
445 |
<mkdir dir="${temp-dir}"/> |
|
446 |
<chmod dir="${temp-dir}" perm="ug+w" /> |
|
417 | 447 |
<mkdir dir="${installdir}/WEB-INF/lib" /> |
418 | 448 |
<copy file="${build.dir}/${name}.jar" |
419 | 449 |
tofile="${installdir}/WEB-INF/lib/${name}.jar" /> |
... | ... | |
428 | 458 |
<copy file="${jdbc}" tofile="${installdir}/WEB-INF/lib/jdbc.jar" /> |
429 | 459 |
<copy file="lib/web.xml.${tomcatversion}" |
430 | 460 |
tofile="${installdir}/WEB-INF/web.xml" /> |
431 |
<copy todir="${build.img}" filtering="no">
|
|
461 |
<copy todir="${installdir}" filtering="no">
|
|
432 | 462 |
<fileset dir="lib"> |
433 | 463 |
<include name="**/*.jpg"/> |
434 | 464 |
<include name="**/*.png"/> |
... | ... | |
446 | 476 |
<exclude name="**/*.gif"/> |
447 | 477 |
</fileset> |
448 | 478 |
</copy> |
479 |
<copy todir="${installdir}" filtering="no"> |
|
480 |
<fileset dir="lib"> |
|
481 |
<include name="**/*.jpg"/> |
|
482 |
<include name="**/*.png"/> |
|
483 |
<include name="**/*.gif"/> |
|
484 |
</fileset> |
|
485 |
</copy> |
|
449 | 486 |
<echo> |
450 | 487 |
*********************************************************** |
451 | 488 |
Remember to register the default DTDs by running the |
... | ... | |
471 | 508 |
|
472 | 509 |
</target> |
473 | 510 |
|
511 |
<target name="install-registry" depends="init"> |
|
512 |
<copy file="${srcdir}/perl/register-dataset.cgi" |
|
513 |
todir="${inst.cgi.dir}" filtering="yes"/> |
|
514 |
<chmod file="${inst.cgi.dir}/register-dataset.cgi" perm="ugo+x" /> |
|
515 |
|
|
516 |
<mkdir dir="${temp-dir}" /> |
|
517 |
<copy todir="${temp-dir}" filtering="yes"> |
|
518 |
<fileset dir="${build.tmp}/${conversion-module}/lib/style"> |
|
519 |
<include name="*.xsl"/> |
|
520 |
<include name="*.xml"/> |
|
521 |
</fileset> |
|
522 |
</copy> |
|
523 |
|
|
524 |
<echo message="Install Registry completed." /> |
|
525 |
</target> |
|
526 |
|
|
527 |
<target name="getBeta6ConversionStyles" depends="prepare"> |
|
528 |
<echo>Enter CVS password: </echo> |
|
529 |
<cvs cvsRoot="${cvsroot-alternate}" |
|
530 |
package="${conversion-module}" |
|
531 |
dest="${build.tmp}" /> |
|
532 |
</target> |
|
533 |
|
|
474 | 534 |
<target name="testprep" depends="jar,clientjar"> |
475 | 535 |
<mkdir dir="${build.tests}"/> |
476 | 536 |
<copy todir="${build.tests}" filtering="yes"> |
... | ... | |
651 | 711 |
</target> |
652 | 712 |
|
653 | 713 |
<target name="stylesheettest"> |
654 |
<xslt in="${input}" out="eml.html" style="lib/style/eml2/eml-2.0.0.xsl">
|
|
714 |
<xslt in="${input}" out="eml.html" style="lib/style/common/eml-2.0.0/eml-2.0.0.xsl">
|
|
655 | 715 |
<param name="displaymodule" expression="${displaymodule}"/> |
656 | 716 |
<param name="docid" expression="${input}"/> |
657 | 717 |
<param name="entitytype" expression="${entitytype}"/> |
Also available in: Unified diff
This is the merge from the branch WEB_UI_REDESIGN_BRANCH back into the head.
The only files that have been removed are those in lib/style/eml2; other files
that have been cvs removed (only from lib/ and lib/style) have been re-added
elsewhere (i.e. moved from one directory to another).
New files have also been added as follows:
/lib/style/common - this contains common xsl stylesheets and any other files
which are common to the web interface, no matter what "skin" is chosen.
/lib/style/skins - this contains a subdirectory for each of the available skins.
The names of the subdirectories contained within this "skins" directory
correspond directly with the values of the "qformat" parameter sent as part of
the user request. The system will automatically look in the correct folder under
style/skins/ based on this value. In there, it expects to find the following
(substitute the real value for {qformat}):
subdirectory is style/skins/{qformat}
it contains:
{qformat}.js
- contains url settings for the globally-included header/left sidebar/right
sidebar/footer, where applicable
{qformat}.css
- contains the css styles for customizing the presentation of the HTML sent
back to the client. Also contains the size settings for the
globally-included header/left sidebar/right sidebar/footer, where
applicable.
{qformat}.xml
- contains the mappings from doctype-> xsl stylesheet, so the system knows
which stylesheet to use for styling any particular requested document.
- any other content referenced in any of these files (for example, it may
contain the html for the header, footer etc, and their associated
images, if these are not pulled from a separate site)
The build.xml file has had the main user-configurable parameters pulled out into
the new build.properties file, making it easier to find and edit these values.