2006-12-29 20:20:57 +07:00
|
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
2006-11-17 10:09:16 +07:00
|
|
|
<!-- ============================================= -->
|
|
|
|
<!-- Adempiere Installer build file -->
|
|
|
|
<!-- ============================================= -->
|
|
|
|
<!-- $Header: /cvs/adempiere/install/build.xml,v 1.7 2006/07/24 08:20:55 comdivision Exp $-->
|
|
|
|
|
|
|
|
<project name="install" default="installDistribution" basedir=".">
|
|
|
|
|
|
|
|
<description>
|
|
|
|
This buildfile is used to create the Adempiere installer.
|
|
|
|
</description>
|
|
|
|
|
2007-01-30 16:06:53 +07:00
|
|
|
<!--<property environment="env"/>-->
|
2007-01-30 17:13:17 +07:00
|
|
|
<import file="../utils_dev/properties.xml"/>
|
2006-11-17 10:09:16 +07:00
|
|
|
<property name="adempiere.dir" value="../"/>
|
|
|
|
<property name="web.dir" value="../../adempiereWeb"/>
|
|
|
|
<property name="dbStartup.dir" value="../db/database/Startup"/>
|
|
|
|
<property name="lib.dir" value="../lib"/>
|
2010-04-29 03:59:00 +07:00
|
|
|
<property name="dist.dir" value="../lib"/>
|
2006-11-17 10:09:16 +07:00
|
|
|
<property name="utils.dir" value="../utils"/>
|
|
|
|
<property name="launch.dir" value="../launch"/>
|
|
|
|
<property name="keystore.dir" value="../keystore"/>
|
|
|
|
<property name="data.dir" value="../data"/>
|
|
|
|
<property name="jboss.dir" value="../jboss"/>
|
|
|
|
|
|
|
|
<property name="src" value="src"/>
|
|
|
|
<property name="compile.dir" value="lib"/>
|
|
|
|
|
|
|
|
<property name="src.dir" value="${basedir}/Adempiere"/>
|
|
|
|
<property name="build.dir" value="${basedir}/build"/>
|
|
|
|
|
|
|
|
<path id="project.class.path">
|
|
|
|
<pathelement path="${classpath}"/>
|
|
|
|
<pathelement path="${lib.dir}/CCTools.jar"/>
|
|
|
|
<pathelement path="${lib.dir}/Adempiere.jar"/>
|
|
|
|
<pathelement path="${lib.dir}/oracle.jar"/>
|
2006-12-02 00:14:01 +07:00
|
|
|
<pathelement path="${lib.dir}/postgresql.jar"/>
|
2006-11-17 10:09:16 +07:00
|
|
|
<pathelement path="../tools/lib/ant.jar"/>
|
|
|
|
<pathelement path="../tools/lib/ant-launcher.jar"/>
|
|
|
|
</path>
|
|
|
|
|
2007-06-04 23:26:14 +07:00
|
|
|
<patternset id="manifest.exclude">
|
|
|
|
<exclude name="META-INF/*.DSA"/>
|
|
|
|
<exclude name="META-INF/*.RSA"/>
|
|
|
|
<exclude name="META-INF/*.SF"/>
|
|
|
|
<exclude name="META-INF/MANIFEST.MF"/>
|
|
|
|
<exclude name="META-INF/INDEX.LIST"/>
|
|
|
|
</patternset>
|
2006-11-17 10:09:16 +07:00
|
|
|
<!-- ======================================================= -->
|
|
|
|
<!-- Init -->
|
|
|
|
<!-- ======================================================= -->
|
|
|
|
<target name="installInit" description="initialization target">
|
|
|
|
<echo message="=========== Build Install - ${env.ENCODING}"/>
|
|
|
|
<!-- create the time stamp -->
|
|
|
|
<tstamp/>
|
|
|
|
<mkdir dir="${build.dir}"/>
|
|
|
|
<mkdir dir="${compile.dir}"/>
|
|
|
|
</target>
|
|
|
|
|
|
|
|
<!-- ======================================================= -->
|
|
|
|
<!-- Compile & Jar -->
|
|
|
|
<!-- ======================================================= -->
|
|
|
|
<target name="installCompile" depends="installInit">
|
|
|
|
<!-- compile the java code from ${src} into ${build.dir} -->
|
2009-10-05 11:56:48 +07:00
|
|
|
<javac target="1.6" srcdir="${src}" destdir="${compile.dir}" deprecation="on" debug="on">
|
2006-11-17 10:09:16 +07:00
|
|
|
<classpath refid="project.class.path"/>
|
|
|
|
</javac>
|
|
|
|
<!-- copy all image & sound files from src to the build directory -->
|
|
|
|
<copy todir="${compile.dir}">
|
|
|
|
<fileset dir="${src}">
|
|
|
|
<include name="**/images/*"/>
|
|
|
|
<include name="**/*.gif"/>
|
|
|
|
<include name="**/*.jpg"/>
|
|
|
|
<include name="**/*.wav"/>
|
|
|
|
<include name="**/*.htm"/>
|
|
|
|
<include name="**/*.html"/>
|
|
|
|
<include name="**/*.properties"/>
|
|
|
|
<exclude name="**/package.html"/>
|
|
|
|
</fileset>
|
|
|
|
</copy>
|
|
|
|
|
2007-06-04 23:26:14 +07:00
|
|
|
<!-- put everything into the $CInstall.jar file -->
|
2006-11-17 10:09:16 +07:00
|
|
|
<jar
|
|
|
|
jarfile="CInstall.jar"
|
2007-06-04 23:26:14 +07:00
|
|
|
index="yes"
|
|
|
|
duplicate="preserve">
|
|
|
|
<fileset dir="${compile.dir}"/>
|
|
|
|
<!-- Ant (with ftp) files -->
|
|
|
|
<zipfileset src="../tools/lib/ant.jar" >
|
|
|
|
<patternset refid="manifest.exclude"/>
|
|
|
|
</zipfileset>
|
|
|
|
<zipfileset src="../tools/lib/ant-launcher.jar" >
|
|
|
|
<patternset refid="manifest.exclude"/>
|
|
|
|
</zipfileset>
|
|
|
|
<zipfileset src="../tools/lib/ant-commons-net.jar" >
|
|
|
|
<patternset refid="manifest.exclude"/>
|
|
|
|
</zipfileset>
|
|
|
|
<zipfileset src="../tools/lib/commons-net-1.4.0.jar" >
|
|
|
|
<patternset refid="manifest.exclude"/>
|
|
|
|
</zipfileset>
|
|
|
|
|
2006-11-17 10:09:16 +07:00
|
|
|
<manifest>
|
|
|
|
<attribute name="Specification-Title" value="CInstall"/>
|
|
|
|
<attribute name="Specification-Version" value="${env.ADEMPIERE_VERSION}"/>
|
|
|
|
<attribute name="Specification-Vendor" value="Adempiere.org"/>
|
|
|
|
<attribute name="Implementation-Title" value="CInstall ${env.ADEMPIERE_VERSION}"/>
|
|
|
|
<attribute name="Implementation-Version" value="${env.ADEMPIERE_VERSION} ${DSTAMP}-${TSTAMP}"/>
|
|
|
|
<attribute name="Implementation-Vendor" value="${env.ADEMPIERE_VENDOR}"/>
|
|
|
|
<attribute name="Implementation-URL" value="http://www.adempiere.org"/>
|
|
|
|
<attribute name="Main-Class" value="org.compiere.install.Setup"/>
|
|
|
|
<attribute name="Class-Path" value="CTools.jar CClient.jar oracle.jar"/>
|
|
|
|
</manifest>
|
|
|
|
</jar>
|
|
|
|
|
|
|
|
</target>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ======================================================= -->
|
|
|
|
<!-- Update from Web Site + Clean .sh -->
|
|
|
|
<!-- ======================================================= -->
|
2010-04-29 03:59:00 +07:00
|
|
|
<target name="installUpdate" depends=""
|
2006-11-17 10:09:16 +07:00
|
|
|
description="Update install directory with copies of web site">
|
|
|
|
|
|
|
|
<fixcrlf srcdir="${src.dir}"
|
|
|
|
eol="lf" eof="remove"
|
|
|
|
includes="**/*.sh"/>
|
|
|
|
<fixcrlf srcdir="${utils.dir}"
|
|
|
|
eol="lf" eof="remove"
|
|
|
|
includes="**/*.sh"/>
|
|
|
|
<fixcrlf srcdir="${utils.dir}/unix"
|
|
|
|
eol="lf" eof="remove"
|
|
|
|
includes="*"/>
|
|
|
|
<fixcrlf srcdir="../sqlj/oracle"
|
|
|
|
eol="lf" eof="remove"
|
|
|
|
includes="*.sh"/>
|
|
|
|
</target>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- ======================================================= -->
|
|
|
|
<!-- Create Distribution -->
|
|
|
|
<!-- ======================================================= -->
|
|
|
|
<target name="installDistribution" depends="installUpdate">
|
|
|
|
<mkdir dir="${build.dir}"/>
|
|
|
|
<mkdir dir="${build.dir}/Adempiere"/>
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/images"/>
|
2007-08-24 09:19:02 +07:00
|
|
|
<mkdir dir="${build.dir}/Adempiere/packages"/>
|
2008-12-10 10:09:42 +07:00
|
|
|
<mkdir dir="${build.dir}/Adempiere/zkpackages"/>
|
2009-09-14 06:20:53 +07:00
|
|
|
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/packages/liberoMFG"/>
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/packages/liberoMFG/lib"/>
|
2009-09-16 08:53:40 +07:00
|
|
|
<copy file="../packages/liberoMFG.jar" tofile="${build.dir}/Adempiere/packages/liberoMFG/lib/liberoMFG.jar"/>
|
2009-09-14 06:20:53 +07:00
|
|
|
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/packages/liberoHR"/>
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/packages/liberoHR/lib"/>
|
2009-09-16 08:53:40 +07:00
|
|
|
<copy file="../packages/liberoHR.jar" tofile="${build.dir}/Adempiere/packages/liberoHR/lib/liberoHR.jar"/>
|
2009-09-16 09:21:01 +07:00
|
|
|
|
2009-09-16 10:02:52 +07:00
|
|
|
<copy file="../lib/CheckConflicts.sh" tofile="${build.dir}/Adempiere/lib/CheckConflicts.sh"/>
|
2006-11-17 10:09:16 +07:00
|
|
|
|
|
|
|
<!-- Base Directory -->
|
|
|
|
<copy todir="${build.dir}/Adempiere">
|
|
|
|
<fileset dir="${src.dir}"/>
|
|
|
|
</copy>
|
|
|
|
<copy todir="${build.dir}/Adempiere/images">
|
|
|
|
<fileset dir="${src.dir}/images"/>
|
|
|
|
</copy>
|
|
|
|
<copy file="${utils.dir}/RUN_Adempiere.bat" todir="${build.dir}/Adempiere/"/>
|
|
|
|
<copy file="${utils.dir}/RUN_Adempiere.sh" todir="${build.dir}/Adempiere/"/>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- Lib Directory -->
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/lib"/>
|
2006-12-23 22:30:41 +07:00
|
|
|
<copy file="${launch.dir}/Adempiere.ico" tofile="${build.dir}/Adempiere/lib/Adempiere.ico"/>
|
|
|
|
<!-- copy file="${launch.dir}/jlaunchs.ico" tofile="${build.dir}/Adempiere/lib/Adempieres.ico"/-->
|
2006-11-17 10:09:16 +07:00
|
|
|
<copy todir="${build.dir}/Adempiere/lib">
|
|
|
|
<fileset dir="${lib.dir}">
|
|
|
|
<include name="**/*ar"/>
|
|
|
|
<include name="**/*xml"/>
|
|
|
|
<include name="**/*0"/>
|
|
|
|
</fileset>
|
|
|
|
</copy>
|
|
|
|
<copy file="${launch.dir}/Release/Adempiere.exe" todir="${build.dir}/Adempiere/lib"/>
|
|
|
|
<copy file="CInstall.jar" todir="${build.dir}/Adempiere/lib"/>
|
2010-04-29 03:59:00 +07:00
|
|
|
<!-- <copy file="../sqlj/sqlj.jar" todir="${build.dir}/Adempiere/lib"/>
|
|
|
|
<copy file="../JasperReports/CompiereJasperReqs.jar" todir="${build.dir}/Adempiere/lib"/> -->
|
2006-11-17 10:09:16 +07:00
|
|
|
<concat destfile="${build.dir}/Adempiere/lib/index.html">AdempiereHome</concat>
|
|
|
|
|
2010-04-29 03:59:00 +07:00
|
|
|
<!-- OSGi Container -->
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/osgi"/>
|
|
|
|
<copy overwrite="true" todir="${build.dir}/Adempiere/osgi" >
|
|
|
|
<fileset dir="../equinox-target">
|
|
|
|
<include name="configuration/**/*"/>
|
|
|
|
<include name="plugins/**/*"/>
|
|
|
|
<include name="org.eclipse.*.jar"/>
|
|
|
|
</fileset>
|
|
|
|
<fileset dir="../lib">
|
|
|
|
<include name="plugins/**/*"/>
|
|
|
|
</fileset>
|
|
|
|
</copy>
|
|
|
|
|
2006-11-17 10:09:16 +07:00
|
|
|
<!-- Utils Directory -->
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/utils"/>
|
|
|
|
<copy todir="${build.dir}/Adempiere/utils">
|
|
|
|
<fileset dir="${utils.dir}" excludes="**/pg/**,.project"/>
|
|
|
|
</copy>
|
|
|
|
<copy todir="${build.dir}/Adempiere/utils/oracle">
|
|
|
|
<fileset dir="${dbStartup.dir}/oracle" includes="*.sql"/>
|
|
|
|
<fileset dir="../sqlj/oracle/"/>
|
|
|
|
</copy>
|
2006-12-28 15:33:33 +07:00
|
|
|
<copy todir="${build.dir}/Adempiere/utils/postgresql">
|
|
|
|
<fileset dir="${dbStartup.dir}/postgresql" includes="*.sql"/>
|
|
|
|
<fileset dir="../sqlj/postgresql/"/>
|
|
|
|
</copy>
|
|
|
|
<copy todir="${build.dir}/Adempiere/utils/oracleXE">
|
|
|
|
<fileset dir="${dbStartup.dir}/oracleXE" includes="*.sql"/>
|
|
|
|
</copy>
|
2006-11-17 10:09:16 +07:00
|
|
|
|
|
|
|
|
|
|
|
<!-- Data Directory -->
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/data"/>
|
|
|
|
<unjar src="${data.dir}/seed/Adempiere.jar" dest="${build.dir}/Adempiere/data"/>
|
2006-12-28 02:36:39 +07:00
|
|
|
<unjar src="${data.dir}/seed/Adempiere_pg.jar" dest="${build.dir}/Adempiere/data"/>
|
2006-11-17 10:09:16 +07:00
|
|
|
<mkdir dir="${build.dir}/Adempiere/data/import"/>
|
|
|
|
<copy todir="${build.dir}/Adempiere/data/import">
|
|
|
|
<fileset dir="${data.dir}/import">
|
|
|
|
<include name="**/Accounting*.*"/>
|
|
|
|
<include name="Example*.csv"/>
|
|
|
|
</fileset>
|
|
|
|
</copy>
|
2007-01-12 20:53:44 +07:00
|
|
|
<copy todir="${build.dir}/Adempiere/data/">
|
2006-11-17 10:09:16 +07:00
|
|
|
<fileset dir="${data.dir}/seed/">
|
2007-01-12 20:53:44 +07:00
|
|
|
<include name="**/*.jar"/>
|
|
|
|
</fileset>
|
2006-11-17 10:09:16 +07:00
|
|
|
</copy>
|
|
|
|
|
|
|
|
|
|
|
|
<!-- JBoss Directory -->
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/jboss"/>
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/jboss/bin"/>
|
|
|
|
<copy todir="${build.dir}/Adempiere/jboss/bin">
|
|
|
|
<fileset dir="${jboss.dir}/bin" excludes="**/CVS/**"/>
|
|
|
|
</copy>
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/jboss/lib"/>
|
|
|
|
<copy todir="${build.dir}/Adempiere/jboss/lib">
|
|
|
|
<fileset dir="${jboss.dir}/lib" excludes="**/CVS/**"/>
|
|
|
|
</copy>
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/jboss/server"/>
|
|
|
|
<copy todir="${build.dir}/Adempiere/jboss/server">
|
|
|
|
<fileset dir="${jboss.dir}/server"
|
|
|
|
excludes="**/CVS/**"/>
|
|
|
|
</copy>
|
2008-11-11 06:54:09 +07:00
|
|
|
|
|
|
|
<!-- GlassFish -->
|
|
|
|
<mkdir dir="${build.dir}/Adempiere/glassfish"/>
|
|
|
|
<copy todir="${build.dir}/Adempiere/glassfish">
|
|
|
|
<fileset dir="../glassfishfacet/config"/>
|
|
|
|
</copy>
|
2006-11-17 10:09:16 +07:00
|
|
|
|
|
|
|
|
|
|
|
<!-- Create Install ZIP -->
|
|
|
|
<zip zipfile="${build.dir}/Adempiere_${env.ADEMPIERE_VERSION_FILE}.zip"
|
|
|
|
basedir="${build.dir}"
|
|
|
|
includes="Adempiere/**" />
|
|
|
|
|
|
|
|
<!-- Create Install TAR -->
|
2007-03-10 04:34:38 +07:00
|
|
|
<tar longfile="gnu" tarfile="${build.dir}/Adempiere_${env.ADEMPIERE_VERSION_FILE}.tar.gz"
|
2006-11-17 10:09:16 +07:00
|
|
|
basedir="${build.dir}"
|
2007-03-10 04:34:38 +07:00
|
|
|
includes="Adempiere/**"
|
|
|
|
compression="gzip" />
|
2006-11-17 10:09:16 +07:00
|
|
|
|
|
|
|
|
|
|
|
<!-- Create Checksums -->
|
|
|
|
<checksum file="${build.dir}/Adempiere_${env.ADEMPIERE_VERSION_FILE}.tar.gz"/>
|
|
|
|
<concat destfile="${build.dir}/Adempiere_${env.ADEMPIERE_VERSION_FILE}.tar.gz.MD5" append="yes"> *Adempiere_${env.ADEMPIERE_VERSION_FILE}.tar.gz</concat>
|
|
|
|
<!-- Test with md5sum -c Adempiere_251.zip.MD5 -->
|
|
|
|
<checksum file="${build.dir}/Adempiere_${env.ADEMPIERE_VERSION_FILE}.zip"/>
|
|
|
|
<concat destfile="${build.dir}/Adempiere_${env.ADEMPIERE_VERSION_FILE}.zip.MD5" append="yes"> *Adempiere_${env.ADEMPIERE_VERSION_FILE}.zip</concat>
|
|
|
|
|
|
|
|
</target>
|
|
|
|
|
2010-04-29 03:59:00 +07:00
|
|
|
<target name="plugin">
|
|
|
|
<buildPlugin workspaceDirectory=".."
|
|
|
|
projectName="install"
|
|
|
|
targetPlatformId="target.platform"
|
|
|
|
destination="${dist.dir}"
|
|
|
|
buildSourceJar="false" />
|
|
|
|
</target>
|
2006-11-17 10:09:16 +07:00
|
|
|
|
|
|
|
<target name="clean" description="deletes build">
|
|
|
|
<delete dir="${build.dir}"/>
|
|
|
|
<delete dir="${compile.dir}"/>
|
|
|
|
</target>
|
|
|
|
|
|
|
|
</project>
|