2010-02-08 00:15:50 +01:00
|
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
|
|
|
|
|
|
<!--+
|
|
|
|
|
|
2012-10-19 01:40:31 +02:00
|
|
|
| OpenRefine Build File
|
2010-09-22 23:47:35 +02:00
|
|
|
|
|
2010-02-08 00:15:50 +01:00
|
|
|
+-->
|
2010-02-10 19:47:32 +01:00
|
|
|
|
2017-08-03 12:07:14 +02:00
|
|
|
<project name="openrefine" default="build" basedir="." xmlns:jacoco="antlib:org.jacoco.ant">
|
2010-02-08 00:15:50 +01:00
|
|
|
|
2011-10-07 21:33:28 +02:00
|
|
|
<!-- Properties are immutable, so anything set in this file takes priority-->
|
|
|
|
<property file="build.properties"/>
|
|
|
|
|
2010-02-08 00:15:50 +01:00
|
|
|
<property environment="env"/>
|
|
|
|
|
2011-06-06 22:22:14 +02:00
|
|
|
<property name="version" value="trunk"/>
|
|
|
|
<property name="full_version" value="0.0.0.0"/>
|
|
|
|
<property name="build.dir" value="build"/>
|
|
|
|
<property name="dist.dir" value="dist"/>
|
2010-06-09 00:27:59 +02:00
|
|
|
|
2017-11-29 23:42:02 +01:00
|
|
|
<property name="java_version" value="1.8"/>
|
2013-03-26 22:05:17 +01:00
|
|
|
|
2012-10-19 01:40:31 +02:00
|
|
|
<property name="appengine.app_id" value="openrefine-broker"/>
|
2011-06-06 22:22:14 +02:00
|
|
|
<property name="appengine.version" value="1"/>
|
|
|
|
<property name="appengine.sdk.dir" value="/opt/appengine"/>
|
2011-10-07 21:33:28 +02:00
|
|
|
|
2013-07-29 23:59:00 +02:00
|
|
|
<property name="fullname" value="openrefine-${version}" />
|
2010-05-30 19:13:37 +02:00
|
|
|
|
|
|
|
<property name="main.dir" value="${basedir}/main" />
|
|
|
|
|
|
|
|
<property name="webapp.dir" value="${main.dir}/webapp" />
|
|
|
|
<property name="webapp.src.dir" value="${main.dir}/src" />
|
|
|
|
<property name="webapp.lib.dir" value="${webapp.dir}/WEB-INF/lib" />
|
|
|
|
<property name="webapp.classes.dir" value="${webapp.dir}/WEB-INF/classes" />
|
|
|
|
|
|
|
|
<property name="server.dir" value="${basedir}/server" />
|
|
|
|
<property name="server.src.dir" value="${server.dir}/src" />
|
|
|
|
<property name="server.lib.dir" value="${server.dir}/lib" />
|
|
|
|
<property name="server.classes.dir" value="${server.dir}/classes" />
|
|
|
|
|
2010-06-25 08:52:12 +02:00
|
|
|
<property name="broker.dir" value="${basedir}/broker" />
|
|
|
|
<property name="broker.core.dir" value="${broker.dir}/core" />
|
|
|
|
<property name="broker.appengine.dir" value="${broker.dir}/appengine" />
|
2010-08-24 21:25:10 +02:00
|
|
|
|
|
|
|
<property name="extensions.dir" value="${basedir}/extensions" />
|
2010-06-25 08:52:12 +02:00
|
|
|
|
2010-05-30 19:13:37 +02:00
|
|
|
<property name="tests.dir" value="${main.dir}/tests" />
|
|
|
|
<property name="server.tests.dir" value="${tests.dir}/server" />
|
|
|
|
<property name="server.tests.lib.dir" value="${server.tests.dir}/lib" />
|
|
|
|
<property name="server.tests.src.dir" value="${server.tests.dir}/src" />
|
|
|
|
<property name="server.tests.classes.dir" value="${server.tests.dir}/classes" />
|
2017-08-03 12:07:14 +02:00
|
|
|
<property name="server.tests.report.dir" value="${build.dir}/report"/>
|
|
|
|
<property name="server.tests.report.html.dir" value="${server.tests.report.dir}/html"/>
|
2017-08-03 12:20:21 +02:00
|
|
|
<property name="server.tests.report.xml.path" value="${server.tests.report.dir}/jacoco.xml"/>
|
2010-05-30 19:13:37 +02:00
|
|
|
|
|
|
|
<property name="graphics.dir" value="${basedir}/graphics" />
|
|
|
|
<property name="conf.dir" value="${basedir}/conf" />
|
2010-04-07 02:12:40 +02:00
|
|
|
<property name="tools.dir" value="${basedir}/tools" />
|
2010-02-10 19:47:32 +01:00
|
|
|
|
2010-04-07 19:31:25 +02:00
|
|
|
<property name="reports.dir" value="${build.dir}/reports" />
|
2010-05-30 19:13:37 +02:00
|
|
|
|
|
|
|
<property name="built.webapp.name" value="webapp" />
|
|
|
|
<property name="built.webapp.dir" value="${build.dir}/${built.webapp.name}" />
|
2010-06-25 08:52:12 +02:00
|
|
|
|
|
|
|
<property name="built.broker.webapp.dir" value="${build.dir}/broker" />
|
2010-05-30 19:13:37 +02:00
|
|
|
|
2010-03-31 04:11:53 +02:00
|
|
|
<property name="mac.dir" value="${build.dir}/mac" />
|
2012-10-19 01:40:31 +02:00
|
|
|
<property name="release.name" value="openrefine-${version}" />
|
2012-01-27 22:27:35 +01:00
|
|
|
<property name="windows.dir" value="${build.dir}/windows/${release.name}" />
|
|
|
|
<property name="linux.dir" value="${build.dir}/linux/${release.name}" />
|
2010-02-09 21:21:10 +01:00
|
|
|
|
2010-06-09 00:27:59 +02:00
|
|
|
<!-- ================================================================== -->
|
|
|
|
|
2010-05-30 19:13:37 +02:00
|
|
|
<path id="server.class.path">
|
|
|
|
<fileset dir="${server.lib.dir}">
|
|
|
|
<include name="**/*.jar" />
|
|
|
|
</fileset>
|
|
|
|
<pathelement location="${server.classes.dir}"/>
|
|
|
|
</path>
|
|
|
|
|
|
|
|
<path id="webapp.class.path">
|
|
|
|
<fileset dir="${server.lib.dir}">
|
|
|
|
<include name="**/servlet-api*.jar" />
|
|
|
|
</fileset>
|
|
|
|
<fileset dir="${webapp.lib.dir}">
|
2010-02-08 00:15:50 +01:00
|
|
|
<include name="**/*.jar" />
|
|
|
|
</fileset>
|
2010-05-30 19:13:37 +02:00
|
|
|
<pathelement location="${webapp.classes.dir}"/>
|
2010-02-08 00:15:50 +01:00
|
|
|
</path>
|
2010-03-09 09:08:35 +01:00
|
|
|
|
2010-06-25 08:52:12 +02:00
|
|
|
<path id="tests.class.path">
|
2010-06-09 00:27:59 +02:00
|
|
|
<path refid="webapp.class.path"/>
|
2013-06-12 01:44:58 +02:00
|
|
|
<path refid="server.class.path"/>
|
|
|
|
<pathelement location="${server.tests.classes.dir}"/>
|
|
|
|
<pathelement location="${server.tests.lib.dir}/testng-6.8.jar"/>
|
2017-08-13 20:03:19 +02:00
|
|
|
<pathelement location="${tests.dir}/data" />
|
2010-06-25 08:52:12 +02:00
|
|
|
<fileset dir="${server.tests.lib.dir}">
|
|
|
|
<include name="**/*.jar" />
|
2010-06-09 00:27:59 +02:00
|
|
|
</fileset>
|
|
|
|
</path>
|
|
|
|
|
2010-06-25 08:52:12 +02:00
|
|
|
<path id="broker.class.path">
|
|
|
|
<fileset dir="${server.lib.dir}">
|
|
|
|
<include name="**/servlet-api*.jar" />
|
|
|
|
</fileset>
|
|
|
|
<fileset dir="${webapp.lib.dir}">
|
|
|
|
<include name="**/butterfly*.jar" />
|
|
|
|
<include name="**/json*.jar" />
|
|
|
|
<include name="**/http*.jar" />
|
|
|
|
<include name="**/slf4j-api*.jar" />
|
|
|
|
</fileset>
|
|
|
|
<fileset dir="${broker.core.dir}/module/MOD-INF/lib">
|
2010-03-09 09:08:35 +01:00
|
|
|
<include name="**/*.jar" />
|
|
|
|
</fileset>
|
|
|
|
</path>
|
2010-04-03 03:01:11 +02:00
|
|
|
|
2010-06-25 08:52:12 +02:00
|
|
|
<path id="broker.appengine.class.path">
|
|
|
|
<pathelement location="${broker.core.dir}/module/MOD-INF/classes"/>
|
|
|
|
<path refid="broker.class.path"/>
|
|
|
|
<fileset dir="${appengine.sdk.dir}/lib">
|
|
|
|
<include name="shared/**/*.jar" />
|
|
|
|
<include name="user/**/*.jar" />
|
|
|
|
</fileset>
|
|
|
|
</path>
|
|
|
|
|
2010-06-09 00:27:59 +02:00
|
|
|
<!-- ================================================================== -->
|
|
|
|
|
2010-04-03 03:01:11 +02:00
|
|
|
<target name="build_server">
|
2010-05-30 19:13:37 +02:00
|
|
|
<mkdir dir="${server.classes.dir}" />
|
2013-03-26 22:05:17 +01:00
|
|
|
<javac source="${java_version}" target="${java_version}" encoding="utf-8" srcdir="${server.src.dir}" destdir="${server.classes.dir}" debug="true" includeAntRuntime="no">
|
2010-05-30 19:13:37 +02:00
|
|
|
<classpath refid="server.class.path" />
|
2010-02-08 00:15:50 +01:00
|
|
|
</javac>
|
2010-05-30 19:13:37 +02:00
|
|
|
<copy file="${server.src.dir}/log4j.properties" tofile="${server.classes.dir}/log4j.properties"/>
|
2010-02-08 00:15:50 +01:00
|
|
|
</target>
|
2010-04-03 03:01:11 +02:00
|
|
|
|
2010-05-30 19:13:37 +02:00
|
|
|
<target name="build_webapp">
|
|
|
|
<mkdir dir="${webapp.classes.dir}" />
|
2013-03-26 22:05:17 +01:00
|
|
|
<javac source="${java_version}" target="${java_version}" encoding="utf-8" destdir="${webapp.classes.dir}" debug="true" includeAntRuntime="no">
|
2010-05-30 19:13:37 +02:00
|
|
|
<src path="${webapp.src.dir}"/>
|
|
|
|
<classpath refid="webapp.class.path" />
|
2010-04-03 03:01:11 +02:00
|
|
|
</javac>
|
2010-05-30 20:18:59 +02:00
|
|
|
<copy file="${webapp.src.dir}/log4j.properties" tofile="${webapp.classes.dir}/log4j.properties"/>
|
2010-04-03 03:01:11 +02:00
|
|
|
</target>
|
2010-02-08 00:15:50 +01:00
|
|
|
|
2013-07-10 22:03:41 +02:00
|
|
|
<target name="build_tests" depends="build">
|
2010-05-30 19:13:37 +02:00
|
|
|
<mkdir dir="${server.tests.classes.dir}" />
|
2013-03-26 22:05:17 +01:00
|
|
|
<javac source="${java_version}" target="${java_version}" encoding="utf-8" srcdir="${server.tests.src.dir}" destdir="${server.tests.classes.dir}" debug="true" includeAntRuntime="no">
|
2010-03-09 09:08:35 +01:00
|
|
|
<classpath refid="tests.class.path" />
|
|
|
|
</javac>
|
2010-05-31 10:51:51 +02:00
|
|
|
<copy file="${server.tests.src.dir}/tests.log4j.properties" tofile="${server.tests.classes.dir}/tests.log4j.properties"/>
|
2010-03-09 09:08:35 +01:00
|
|
|
</target>
|
2010-06-20 02:44:06 +02:00
|
|
|
|
|
|
|
<target name="build_extensions">
|
|
|
|
<ant dir="extensions/" target="build" />
|
|
|
|
</target>
|
2010-03-09 09:08:35 +01:00
|
|
|
|
2010-06-20 02:44:06 +02:00
|
|
|
<target name="build" depends="build_server, build_webapp, build_extensions"/>
|
2010-05-30 19:13:37 +02:00
|
|
|
|
2010-06-25 08:52:12 +02:00
|
|
|
<target name="build_broker_core">
|
|
|
|
<mkdir dir="${broker.core.dir}/module/MOD-INF/classes" />
|
2013-03-26 22:05:17 +01:00
|
|
|
<javac source="${java_version}" target="${java_version}" encoding="utf-8" destdir="${broker.core.dir}/module/MOD-INF/classes" debug="true" includeAntRuntime="no">
|
2010-06-25 08:52:12 +02:00
|
|
|
<src path="${broker.core.dir}/src/"/>
|
|
|
|
<classpath refid="broker.class.path" />
|
|
|
|
</javac>
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="build_broker_appengine" depends="build_broker_core">
|
|
|
|
<mkdir dir="${broker.appengine.dir}/module/MOD-INF/classes" />
|
2013-03-26 22:05:17 +01:00
|
|
|
<javac source="${java_version}" target="${java_version}" encoding="utf-8" destdir="${broker.appengine.dir}/module/MOD-INF/classes" debug="true" includeAntRuntime="no">
|
2010-06-25 08:52:12 +02:00
|
|
|
<src path="${broker.appengine.dir}/src/"/>
|
|
|
|
<classpath refid="broker.appengine.class.path" />
|
|
|
|
</javac>
|
|
|
|
</target>
|
|
|
|
|
2010-06-25 09:03:41 +02:00
|
|
|
<target name="build_broker" depends="build_broker_core, build_broker_appengine"/>
|
2010-06-25 08:52:12 +02:00
|
|
|
|
2013-06-12 01:44:58 +02:00
|
|
|
<taskdef resource="testngtasks" classpath="${server.tests.lib.dir}/testng-6.8.jar"/>
|
2017-08-03 12:07:14 +02:00
|
|
|
<taskdef uri="antlib:org.jacoco.ant" resource="org/jacoco/ant/antlib.xml">
|
|
|
|
<classpath path="${server.tests.lib.dir}/jacocoant.jar"/>
|
|
|
|
</taskdef>
|
|
|
|
|
2013-06-12 01:44:58 +02:00
|
|
|
<mkdir dir="${build.dir}/server_tests"/>
|
|
|
|
<target name="server_test" depends="build_tests">
|
2017-08-03 12:07:14 +02:00
|
|
|
<jacoco:coverage destfile="${server.tests.report.dir}/jacoco.exec">
|
|
|
|
<testng verbose="2" haltOnFailure="true" workingdir="${build.dir}/server_tests"
|
|
|
|
listener="org.testng.reporters.DotTestListener" excludedgroups="broken"
|
|
|
|
classpathref="tests.class.path">
|
|
|
|
<xmlfileset file="${server.tests.dir}/conf/tests.xml"/>
|
|
|
|
</testng>
|
|
|
|
</jacoco:coverage>
|
|
|
|
<jacoco:report>
|
|
|
|
<executiondata>
|
|
|
|
<file file="${server.tests.report.dir}/jacoco.exec"/>
|
|
|
|
</executiondata>
|
|
|
|
|
|
|
|
<structure name="OpenRefine server">
|
|
|
|
<classfiles>
|
|
|
|
<fileset dir="${webapp.classes.dir}"/>
|
|
|
|
</classfiles>
|
|
|
|
<sourcefiles encoding="UTF-8">
|
|
|
|
<fileset dir="${server.src.dir}"/>
|
|
|
|
</sourcefiles>
|
|
|
|
</structure>
|
|
|
|
<html destdir="${server.tests.report.html.dir}"/>
|
|
|
|
<xml destfile="${server.tests.report.xml.path}"/>
|
|
|
|
</jacoco:report>
|
2013-06-12 01:44:58 +02:00
|
|
|
</target>
|
|
|
|
|
2018-01-03 19:32:22 +01:00
|
|
|
<!-- runs the tests for the extensions -->
|
2018-01-03 18:37:16 +01:00
|
|
|
<target name="extensions_test" depends="build">
|
|
|
|
<ant dir="extensions/" target="test" />
|
|
|
|
</target>
|
|
|
|
|
2010-06-09 00:27:59 +02:00
|
|
|
<!-- ================================================================== -->
|
|
|
|
|
2010-09-19 19:08:39 +02:00
|
|
|
<target name="prepare_jar">
|
|
|
|
<mkdir dir="${build.dir}"/>
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="jar_server" depends="prepare_jar, build_server">
|
2010-05-30 21:27:41 +02:00
|
|
|
<jar destfile="${build.dir}/${fullname}-server.jar" basedir="${server.classes.dir}"/>
|
2010-05-30 19:13:37 +02:00
|
|
|
</target>
|
|
|
|
|
2010-09-19 19:08:39 +02:00
|
|
|
<target name="jar_webapp" depends="prepare_jar, build_webapp">
|
2010-05-30 19:13:37 +02:00
|
|
|
<jar destfile="${build.dir}/${fullname}.jar" basedir="${webapp.classes.dir}"/>
|
2010-02-09 21:21:10 +01:00
|
|
|
</target>
|
2010-03-31 02:17:40 +02:00
|
|
|
|
2010-05-30 19:13:37 +02:00
|
|
|
<target name="jar" depends="jar_server, jar_webapp"/>
|
|
|
|
|
2010-06-09 00:27:59 +02:00
|
|
|
<!-- ================================================================== -->
|
|
|
|
|
2010-08-24 23:04:59 +02:00
|
|
|
<target name="prepare_webapp" depends="jar_webapp, build">
|
2010-05-30 19:13:37 +02:00
|
|
|
<mkdir dir="${built.webapp.dir}" />
|
2010-03-31 02:17:40 +02:00
|
|
|
|
2010-05-30 19:13:37 +02:00
|
|
|
<copy todir="${built.webapp.dir}">
|
|
|
|
<fileset dir="${webapp.dir}">
|
2010-03-31 02:17:40 +02:00
|
|
|
<include name="**/*"/>
|
2010-04-03 03:01:11 +02:00
|
|
|
<exclude name="WEB-INF/classes/**"/>
|
2010-05-30 19:13:37 +02:00
|
|
|
<exclude name="WEB-INF/lib-src/**"/>
|
2013-08-26 22:43:22 +02:00
|
|
|
<exclude name="WEB-INF/lib/icu4j*.jar"/>
|
2010-03-31 02:17:40 +02:00
|
|
|
</fileset>
|
|
|
|
</copy>
|
|
|
|
|
2010-05-30 19:13:37 +02:00
|
|
|
<copy file="${build.dir}/${fullname}.jar" tofile="${built.webapp.dir}/WEB-INF/lib/${fullname}.jar"/>
|
2010-08-24 21:25:10 +02:00
|
|
|
|
|
|
|
<copy todir="${built.webapp.dir}/extensions">
|
|
|
|
<fileset dir="${extensions.dir}">
|
|
|
|
<include name="**/*"/>
|
|
|
|
<exclude name="**/build.xml"/>
|
|
|
|
<exclude name="**/src/**"/>
|
2013-08-26 21:36:53 +02:00
|
|
|
<exclude name="**/lib-src/**"/>
|
2013-08-26 22:43:22 +02:00
|
|
|
<exclude name="**/libsrc/**"/>
|
2010-08-24 21:25:10 +02:00
|
|
|
</fileset>
|
|
|
|
</copy>
|
2010-05-30 19:13:37 +02:00
|
|
|
|
2010-09-29 03:50:57 +02:00
|
|
|
<replace file="${built.webapp.dir}/WEB-INF/web.xml">
|
|
|
|
<replacefilter token="$VERSION" value="${version}"/>
|
|
|
|
</replace>
|
|
|
|
|
2010-08-24 21:25:10 +02:00
|
|
|
<replace file="${built.webapp.dir}/WEB-INF/butterfly.properties">
|
2013-08-10 12:34:14 +02:00
|
|
|
<replacefilter token="../../extensions" value="extensions"/>
|
2010-08-24 21:25:10 +02:00
|
|
|
</replace>
|
|
|
|
|
2010-03-31 02:17:40 +02:00
|
|
|
</target>
|
2010-02-09 21:21:10 +01:00
|
|
|
|
2010-03-31 04:11:53 +02:00
|
|
|
<target name="mac" depends="jar, prepare_webapp">
|
2013-03-26 17:52:55 +01:00
|
|
|
<mkdir dir="${mac.dir}"/>
|
|
|
|
|
|
|
|
<taskdef name="bundleapp"
|
|
|
|
classname="com.oracle.appbundler.AppBundlerTask"
|
2013-03-26 22:05:17 +01:00
|
|
|
classpath="${appbundler.dir}/appbundler-1.0.jar" />
|
2013-03-26 17:52:55 +01:00
|
|
|
|
|
|
|
<bundleapp outputdirectory="${mac.dir}"
|
|
|
|
name="OpenRefine"
|
|
|
|
displayname="OpenRefine ${version}"
|
2013-03-26 22:05:17 +01:00
|
|
|
icon="${graphics.dir}/icon/openrefine.icns"
|
2013-06-11 21:53:45 +02:00
|
|
|
identifier="com.google.refine.Refine"
|
2013-03-26 17:52:55 +01:00
|
|
|
shortversion="${version}"
|
2013-03-26 22:05:17 +01:00
|
|
|
mainclassname="com/google/refine/Refine">
|
|
|
|
<runtime dir="${env.JAVA_HOME}"/>
|
|
|
|
<classpath dir="${build.dir}">
|
|
|
|
<include name="${fullname}-server.jar" />
|
|
|
|
</classpath>
|
|
|
|
<classpath dir="${server.lib.dir}">
|
|
|
|
<include name="**/*.jar" />
|
|
|
|
</classpath>
|
|
|
|
<option value="-Xms256M"/>
|
|
|
|
<option value="-Xmx1024M"/>
|
2013-07-29 23:59:00 +02:00
|
|
|
<option value="-Drefine.version=${version}"/>
|
2013-03-26 22:05:17 +01:00
|
|
|
<option value="-Drefine.webapp=$APP_ROOT/Contents/Resource/${built.webapp.name}"/>
|
2013-03-26 17:52:55 +01:00
|
|
|
</bundleapp>
|
|
|
|
|
2013-03-26 22:05:17 +01:00
|
|
|
<copy todir="${mac.dir}/OpenRefine.app/Contents/Resource">
|
|
|
|
<fileset dir="${build.dir}" id="librarypathset" >
|
|
|
|
<include name="${built.webapp.name}/**/**" />
|
|
|
|
</fileset>
|
|
|
|
</copy>
|
|
|
|
|
|
|
|
<!--- Options from old jarbundler code not supported by appbundler
|
2012-10-19 01:40:31 +02:00
|
|
|
aboutmenuname="OpenRefine"
|
2010-02-09 21:21:10 +01:00
|
|
|
workingdirectory="$APP_PACKAGE/Contents/Resources"
|
|
|
|
antialiasedgraphics="true"
|
|
|
|
antialiasedtext="true"
|
|
|
|
liveresize="true"
|
|
|
|
growboxintrudes="true"
|
|
|
|
screenmenu="true">
|
2013-03-26 17:52:55 +01:00
|
|
|
-->
|
2010-02-09 21:21:10 +01:00
|
|
|
</target>
|
|
|
|
|
2010-03-31 04:11:53 +02:00
|
|
|
<target name="windows" depends="jar, prepare_webapp">
|
2013-07-30 00:30:23 +02:00
|
|
|
<echo message="Full version ${full_version} and version ${version}"/>
|
2010-03-31 04:11:53 +02:00
|
|
|
<mkdir dir="${windows.dir}"/>
|
2010-03-30 23:24:04 +02:00
|
|
|
<taskdef
|
|
|
|
name="launch4j"
|
|
|
|
classname="net.sf.launch4j.ant.Launch4jTask"
|
2010-04-05 09:15:16 +02:00
|
|
|
classpath="${launch4j.dir}/launch4j.jar:${launch4j.dir}/lib/xstream.jar"
|
2010-03-30 23:24:04 +02:00
|
|
|
/>
|
2010-02-10 08:30:16 +01:00
|
|
|
<launch4j>
|
|
|
|
<config
|
|
|
|
headerType="console"
|
2012-10-19 01:40:31 +02:00
|
|
|
outfile="${windows.dir}/openrefine.exe"
|
2010-05-31 09:06:55 +02:00
|
|
|
jarPath="server/lib/${fullname}-server.jar"
|
2010-02-10 08:30:16 +01:00
|
|
|
dontWrapJar="true"
|
2012-10-19 01:40:31 +02:00
|
|
|
icon="${graphics.dir}/icon/openrefine.ico">
|
2010-09-22 23:47:35 +02:00
|
|
|
<classPath mainClass="com.google.refine.Refine">
|
2010-05-31 09:06:55 +02:00
|
|
|
<cp>server/lib/*.jar</cp>
|
2010-02-10 08:30:16 +01:00
|
|
|
</classPath>
|
2017-11-29 23:50:13 +01:00
|
|
|
<jre minVersion="1.8.0" jdkPreference="preferJre" initialHeapSize="256" maxHeapSize="1024">
|
2013-07-29 23:59:00 +02:00
|
|
|
<opt>-Djava.library.path=server/lib/native/windows </opt>
|
2010-02-10 08:30:16 +01:00
|
|
|
</jre>
|
|
|
|
<versionInfo
|
2010-05-13 00:57:31 +02:00
|
|
|
fileVersion="${full_version}"
|
2010-02-10 08:30:16 +01:00
|
|
|
txtFileVersion="${version}"
|
2012-10-19 01:40:31 +02:00
|
|
|
fileDescription="openrefine"
|
2013-03-26 22:05:17 +01:00
|
|
|
copyright="Copyright (c) 2013 OpenRefine contributors, 2010, Google, Inc."
|
2010-05-13 00:57:31 +02:00
|
|
|
productVersion="${full_version}"
|
2013-07-30 00:30:23 +02:00
|
|
|
txtProductVersion="${version}"
|
2012-10-19 01:40:31 +02:00
|
|
|
productName="OpenRefine"
|
|
|
|
companyName="OpenRefine team"
|
|
|
|
internalName="openrefine"
|
|
|
|
originalFilename="openrefine.exe"
|
2010-02-10 08:30:16 +01:00
|
|
|
/>
|
|
|
|
</config>
|
2010-05-05 01:14:36 +02:00
|
|
|
</launch4j>
|
2010-05-31 09:06:55 +02:00
|
|
|
<copy file="${build.dir}/${fullname}-server.jar" tofile="${windows.dir}/server/lib/${fullname}-server.jar"/>
|
|
|
|
<copy todir="${windows.dir}/server/lib">
|
2010-05-30 19:13:37 +02:00
|
|
|
<fileset dir="${server.lib.dir}">
|
2010-02-10 08:30:16 +01:00
|
|
|
<include name="**/*.jar"/>
|
|
|
|
</fileset>
|
|
|
|
</copy>
|
2010-05-31 09:06:55 +02:00
|
|
|
<copy todir="${windows.dir}/server/lib/native/windows">
|
2010-05-30 19:13:37 +02:00
|
|
|
<fileset dir="${server.lib.dir}/native/windows">
|
2010-03-03 03:53:07 +01:00
|
|
|
<include name="*.dll"/>
|
|
|
|
</fileset>
|
|
|
|
</copy>
|
2010-05-30 21:27:41 +02:00
|
|
|
|
2010-03-31 04:11:53 +02:00
|
|
|
<copy todir="${windows.dir}/webapp">
|
2010-05-30 21:27:41 +02:00
|
|
|
<fileset dir="${built.webapp.dir}">
|
2010-03-31 02:17:40 +02:00
|
|
|
<include name="**"/>
|
2010-02-10 19:47:32 +01:00
|
|
|
</fileset>
|
|
|
|
</copy>
|
2010-03-31 02:17:40 +02:00
|
|
|
|
2015-01-23 14:38:31 +01:00
|
|
|
<mkdir dir="${windows.dir}/licenses"/>
|
|
|
|
<fixcrlf srcDir="${basedir}/licenses" destDir="${windows.dir}/licenses" eol="crlf"/>
|
|
|
|
|
|
|
|
<fixcrlf srcDir="${basedir}" destDir="${windows.dir}" eol="crlf">
|
|
|
|
<include name="refine.bat"/>
|
|
|
|
<include name="refine.ini"/>
|
|
|
|
<include name="README.txt"/>
|
|
|
|
<include name="LICENSE.txt"/>
|
|
|
|
</fixcrlf>
|
|
|
|
<fixcrlf file="${conf.dir}/openrefine.l4j.ini" destDir="${windows.dir}" eol="crlf"/>
|
2010-03-31 02:17:40 +02:00
|
|
|
|
2011-06-06 22:22:14 +02:00
|
|
|
<mkdir dir="${dist.dir}"/>
|
2013-07-29 23:59:00 +02:00
|
|
|
<zip destfile="${dist.dir}/openrefine-win-${version}.zip" basedir="${windows.dir}/.." includes="${release.name}/**"/>
|
2010-03-30 23:24:04 +02:00
|
|
|
</target>
|
|
|
|
|
2010-03-31 04:11:53 +02:00
|
|
|
<target name="linux" depends="jar, prepare_webapp">
|
|
|
|
<mkdir dir="${linux.dir}"/>
|
2010-03-30 23:24:04 +02:00
|
|
|
|
2010-05-30 21:27:41 +02:00
|
|
|
<copy todir="${linux.dir}/server/lib">
|
2010-05-30 19:13:37 +02:00
|
|
|
<fileset dir="${server.lib.dir}">
|
2010-03-30 23:24:04 +02:00
|
|
|
<include name="**/*.jar"/>
|
|
|
|
</fileset>
|
|
|
|
</copy>
|
2010-02-10 08:30:16 +01:00
|
|
|
|
2010-05-30 21:27:41 +02:00
|
|
|
<copy file="${build.dir}/${fullname}-server.jar" tofile="${linux.dir}/server/lib/${fullname}-server.jar"/>
|
2010-04-22 23:36:32 +02:00
|
|
|
|
2010-05-31 09:06:55 +02:00
|
|
|
<copy todir="${linux.dir}/webapp">
|
2010-05-30 21:27:41 +02:00
|
|
|
<fileset dir="${built.webapp.dir}">
|
2010-03-31 02:17:40 +02:00
|
|
|
<include name="**"/>
|
2010-03-30 23:24:04 +02:00
|
|
|
</fileset>
|
|
|
|
</copy>
|
2010-05-30 21:27:41 +02:00
|
|
|
|
2015-01-23 14:38:31 +01:00
|
|
|
<mkdir dir="${linux.dir}/licenses"/>
|
|
|
|
<fixcrlf srcDir="${basedir}/licenses" destDir="${linux.dir}/licenses" eol="lf"/>
|
|
|
|
|
|
|
|
<fixcrlf srcDir="${basedir}" destDir="${linux.dir}" eol="lf">
|
|
|
|
<include name="refine"/>
|
|
|
|
<include name="refine.ini"/>
|
|
|
|
<include name="README.txt"/>
|
|
|
|
<include name="LICENSE.txt"/>
|
|
|
|
</fixcrlf>
|
|
|
|
|
2011-06-06 22:22:14 +02:00
|
|
|
<mkdir dir="${dist.dir}"/>
|
2013-07-29 23:59:00 +02:00
|
|
|
<tar longfile="gnu" compression="gzip" destfile="${dist.dir}/openrefine-linux-${version}.tar.gz">
|
2010-03-31 04:11:53 +02:00
|
|
|
<tarfileset dir="${linux.dir}/.." filemode="755">
|
2012-01-27 22:27:35 +01:00
|
|
|
<include name="${release.name}/refine"/>
|
2010-03-30 23:24:04 +02:00
|
|
|
</tarfileset>
|
2010-03-31 04:11:53 +02:00
|
|
|
<tarfileset dir="${linux.dir}/..">
|
2012-01-27 22:27:35 +01:00
|
|
|
<include name="${release.name}/**"/>
|
|
|
|
<exclude name="${release.name}/refine"/>
|
2010-03-30 23:24:04 +02:00
|
|
|
</tarfileset>
|
|
|
|
</tar>
|
|
|
|
</target>
|
2010-03-17 23:30:16 +01:00
|
|
|
|
2011-10-07 21:33:28 +02:00
|
|
|
<target name="kits" depends="linux,mac,windows"
|
|
|
|
description="Build kits for all supported platforms">
|
|
|
|
</target>
|
|
|
|
|
2010-06-09 00:27:59 +02:00
|
|
|
<!-- ================================================================== -->
|
|
|
|
|
2010-04-07 19:31:25 +02:00
|
|
|
<target name="prepare_reports">
|
|
|
|
<mkdir dir="${reports.dir}" />
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="findbugs" depends="build,prepare_reports">
|
2010-04-05 09:15:16 +02:00
|
|
|
<taskdef
|
|
|
|
name="findbugs"
|
|
|
|
classname="edu.umd.cs.findbugs.anttask.FindBugsTask"
|
|
|
|
classpath="${findbugs.dir}/lib/findbugs-ant.jar"
|
|
|
|
/>
|
2010-04-07 19:31:25 +02:00
|
|
|
<findbugs jvmargs="-Xmx1024m" home="${findbugs.dir}" output="html" outputFile="${reports.dir}/findbugs.html" >
|
2010-05-30 19:13:37 +02:00
|
|
|
<auxClasspath refid="webapp.class.path" />
|
|
|
|
<sourcePath path="${webapp.src.dir}" />
|
|
|
|
<class location="${webapp.classes.dir}" />
|
2010-04-05 09:15:16 +02:00
|
|
|
</findbugs>
|
|
|
|
</target>
|
2010-04-07 19:31:25 +02:00
|
|
|
|
|
|
|
<target name="pmd" depends="prepare_reports">
|
|
|
|
<path id="pmd.path">
|
|
|
|
<fileset dir="${pmd.dir}/lib" includes="*.jar"/>
|
|
|
|
</path>
|
|
|
|
<taskdef
|
|
|
|
name="pmd"
|
|
|
|
classname="net.sourceforge.pmd.ant.PMDTask"
|
|
|
|
classpathref="pmd.path"
|
|
|
|
/>
|
2017-11-29 23:50:13 +01:00
|
|
|
<pmd rulesetfiles="${conf.dir}/pmd.rules.xml" targetjdk="1.8" encoding="UTF-8">
|
2010-04-07 19:31:25 +02:00
|
|
|
<formatter type="html" toFile="${reports.dir}/pmd.html" toConsole="true"/>
|
|
|
|
<fileset dir="${server.src.dir}">
|
|
|
|
<include name="**/*.java"/>
|
|
|
|
</fileset>
|
2010-05-30 19:13:37 +02:00
|
|
|
<fileset dir="${webapp.src.dir}">
|
2010-04-07 19:31:25 +02:00
|
|
|
<include name="**/*.java"/>
|
|
|
|
</fileset>
|
2010-05-30 19:13:37 +02:00
|
|
|
<fileset dir="${server.tests.src.dir}">
|
2010-04-09 02:23:14 +02:00
|
|
|
<include name="**/*.java"/>
|
|
|
|
</fileset>
|
2010-04-07 19:31:25 +02:00
|
|
|
</pmd>
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="cpd" depends="prepare_reports">
|
|
|
|
<path id="pmd.path">
|
|
|
|
<fileset dir="${pmd.dir}/lib" includes="*.jar"/>
|
|
|
|
</path>
|
|
|
|
<taskdef
|
|
|
|
name="cpd"
|
|
|
|
classname="net.sourceforge.pmd.cpd.CPDTask"
|
|
|
|
classpathref="pmd.path"
|
|
|
|
/>
|
|
|
|
<cpd minimumTokenCount="100" outputFile="${reports.dir}/cpd.txt" encoding="UTF-8">
|
|
|
|
<fileset dir="${server.src.dir}">
|
|
|
|
<include name="**/*.java"/>
|
|
|
|
</fileset>
|
2010-05-30 19:13:37 +02:00
|
|
|
<fileset dir="${webapp.src.dir}">
|
2010-04-07 19:31:25 +02:00
|
|
|
<include name="**/*.java"/>
|
|
|
|
</fileset>
|
|
|
|
</cpd>
|
|
|
|
</target>
|
2010-04-05 09:15:16 +02:00
|
|
|
|
2010-04-07 21:05:04 +02:00
|
|
|
<target name="jslint" depends="prepare_reports">
|
|
|
|
<path id="jslint.path">
|
|
|
|
<fileset dir="${jslint.dir}" includes="*.jar"/>
|
|
|
|
</path>
|
|
|
|
<taskdef
|
|
|
|
name="jslint"
|
|
|
|
classname="com.googlecode.jslint4java.ant.JSLintTask"
|
|
|
|
classpathref="jslint.path"
|
|
|
|
/>
|
|
|
|
<jslint>
|
|
|
|
<formatter type="plain" destfile="${reports.dir}/jslint.txt" />
|
2011-10-08 01:44:11 +02:00
|
|
|
<fileset dir="${webapp.dir}/modules/core/scripts">
|
2010-04-07 21:05:04 +02:00
|
|
|
<include name="**/*.js" />
|
|
|
|
</fileset>
|
|
|
|
</jslint>
|
|
|
|
</target>
|
|
|
|
|
2010-06-09 00:27:59 +02:00
|
|
|
<!-- ================================================================== -->
|
|
|
|
|
2010-06-25 09:03:41 +02:00
|
|
|
<target name="prepare_broker" depends="jar_server, build_broker_core">
|
2010-06-25 08:52:12 +02:00
|
|
|
<copy todir="${broker.core.dir}/WEB-INF/lib">
|
|
|
|
<fileset dir="${webapp.lib.dir}">
|
|
|
|
<include name="**/butterfly*.jar" />
|
|
|
|
<include name="**/rhino*.jar" />
|
|
|
|
<include name="**/commons-collections*.jar" />
|
|
|
|
<include name="**/velocity*.jar" />
|
|
|
|
<include name="**/lessen*.jar" />
|
|
|
|
<include name="**/slf4j*.jar" />
|
|
|
|
<include name="**/log4j*.jar" />
|
|
|
|
|
|
|
|
<include name="**/json*.jar" />
|
|
|
|
<include name="**/http*.jar" />
|
|
|
|
<include name="**/jcl*.jar" />
|
2010-06-09 00:27:59 +02:00
|
|
|
</fileset>
|
|
|
|
</copy>
|
2010-06-25 08:52:12 +02:00
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="prepare_broker_appengine" depends="build_broker_appengine">
|
|
|
|
<mkdir dir="${built.broker.webapp.dir}/appengine" />
|
|
|
|
<mkdir dir="${built.broker.webapp.dir}/appengine/modules" />
|
2010-06-09 00:27:59 +02:00
|
|
|
|
2010-06-25 08:52:12 +02:00
|
|
|
<copy todir="${built.broker.webapp.dir}/appengine">
|
|
|
|
<fileset dir="${broker.appengine.dir}">
|
|
|
|
<include name="WEB-INF/**"/>
|
|
|
|
<exclude name="WEB-INF/jdo*"/>
|
2010-06-09 00:27:59 +02:00
|
|
|
</fileset>
|
|
|
|
</copy>
|
|
|
|
|
2010-06-25 08:52:12 +02:00
|
|
|
<copy todir="${built.broker.webapp.dir}/appengine/WEB-INF/classes/META-INF">
|
|
|
|
<fileset dir="${broker.appengine.dir}/WEB-INF">
|
|
|
|
<include name="jdo*"/>
|
|
|
|
</fileset>
|
|
|
|
</copy>
|
|
|
|
|
|
|
|
<copy todir="${built.broker.webapp.dir}/appengine/modules/appengine-broker">
|
|
|
|
<fileset dir="${broker.appengine.dir}/module">
|
|
|
|
<include name="**"/>
|
|
|
|
<exclude name="**/lib-src/**"/>
|
|
|
|
</fileset>
|
|
|
|
</copy>
|
|
|
|
|
|
|
|
<copy todir="${built.broker.webapp.dir}/appengine/modules/broker">
|
|
|
|
<fileset dir="${broker.core.dir}/module">
|
|
|
|
<include name="**"/>
|
|
|
|
<exclude name="**/lib-src/**"/>
|
|
|
|
</fileset>
|
|
|
|
</copy>
|
|
|
|
|
|
|
|
<copy todir="${built.broker.webapp.dir}/appengine/WEB-INF/lib">
|
|
|
|
<fileset dir="${webapp.lib.dir}">
|
|
|
|
<include name="**/butterfly*.jar" />
|
|
|
|
<include name="**/rhino*.jar" />
|
|
|
|
<include name="**/commons-collections*.jar" />
|
|
|
|
<include name="**/velocity*.jar" />
|
|
|
|
<include name="**/lessen*.jar" />
|
|
|
|
|
|
|
|
<include name="**/slf4j-api*.jar" />
|
|
|
|
<include name="**/jcl*.jar" />
|
|
|
|
|
|
|
|
<include name="**/json*.jar" />
|
|
|
|
<include name="**/http*.jar" />
|
|
|
|
</fileset>
|
|
|
|
</copy>
|
|
|
|
|
|
|
|
<copy todir="${built.broker.webapp.dir}/appengine/WEB-INF/lib" flatten="true">
|
|
|
|
<fileset dir="${appengine.sdk.dir}/lib/user">
|
|
|
|
<include name="**/*.jar" />
|
2010-06-09 00:27:59 +02:00
|
|
|
</fileset>
|
|
|
|
</copy>
|
|
|
|
|
2010-06-25 08:52:12 +02:00
|
|
|
<replace file="${built.broker.webapp.dir}/appengine/WEB-INF/appengine-web.xml">
|
2010-06-09 00:27:59 +02:00
|
|
|
<replacefilter token="$APPID" value="${appengine.app_id}"/>
|
|
|
|
<replacefilter token="$VERSION" value="${appengine.version}"/>
|
|
|
|
</replace>
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<!-- ================================================================== -->
|
|
|
|
|
2010-08-31 03:14:37 +02:00
|
|
|
<target name="clean_extensions">
|
|
|
|
<ant dir="extensions/" target="clean" />
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<target name="clean" depends="clean_extensions">
|
2010-05-30 19:13:37 +02:00
|
|
|
<delete file="${build.dir}/${fullname}.jar" />
|
|
|
|
<delete file="${build.dir}/${fullname}-server.jar" />
|
|
|
|
<delete dir="${server.classes.dir}" />
|
|
|
|
<delete dir="${webapp.classes.dir}" />
|
|
|
|
<delete dir="${server.tests.classes.dir}" />
|
2010-06-25 08:52:12 +02:00
|
|
|
<delete dir="${broker.core.dir}/module/MOD-INF/classes" />
|
2010-06-25 09:03:41 +02:00
|
|
|
<delete dir="${broker.core.dir}/WEB-INF/lib" />
|
2010-06-25 08:52:12 +02:00
|
|
|
<delete dir="${broker.appengine.dir}/module/MOD-INF/classes" />
|
2010-02-08 00:15:50 +01:00
|
|
|
</target>
|
|
|
|
|
2010-08-31 03:14:37 +02:00
|
|
|
<target name="distclean" depends="clean">
|
2010-02-08 00:15:50 +01:00
|
|
|
<delete dir="${build.dir}" />
|
2010-02-09 21:21:10 +01:00
|
|
|
<delete dir="${dist.dir}" />
|
2010-04-07 02:12:40 +02:00
|
|
|
<delete dir="${tools.dir}" />
|
2010-02-08 00:15:50 +01:00
|
|
|
</target>
|
|
|
|
|
|
|
|
</project>
|