2014-08-01 07:47:39 -04:00
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2019-05-31 11:07:05 -04:00
<project name= "filebot" default= "jar" xmlns:if= "ant:if" xmlns:unless= "ant:unless" >
2014-08-01 07:47:39 -04:00
<!-- define source dirs -->
<property name= "dir.source" location= "${basedir}/source" />
<property name= "dir.build" location= "${basedir}/build" />
<property name= "dir.dist" location= "${basedir}/dist" />
<property name= "dir.installer" location= "${basedir}/installer" />
2019-05-29 08:07:32 -04:00
<!-- external projects -->
<property name= "dir.lib" location= "${basedir}/lib" />
2018-06-26 12:48:56 -04:00
<property name= "dir.cache" location= "${basedir}/cache" />
2014-08-01 07:47:39 -04:00
2016-11-04 16:19:30 -04:00
<!-- import property files -->
<property file= "${basedir}/profile.properties" />
2018-01-19 15:55:19 -05:00
<property file= "${basedir}/app.properties" />
2016-11-04 16:19:30 -04:00
2018-06-26 12:48:56 -04:00
<!-- define release files -->
2016-11-04 16:19:30 -04:00
<property name= "release" value= "${application.name}_${application.version}" />
2018-06-26 12:48:56 -04:00
<property name= "dir.release.index" location= "${basedir}/release" />
<property name= "dir.release" location= "${dir.release.index}/${release}" />
2014-08-01 07:47:39 -04:00
2016-11-04 16:19:30 -04:00
<!-- timestamp variables -->
<tstamp prefix= "tstamp" >
<format property= "date" pattern= "yyyy-MM-dd" />
<format property= "year" pattern= "yyyy" />
</tstamp>
2016-09-17 02:53:14 -04:00
2014-08-01 07:47:39 -04:00
2018-06-23 09:34:55 -04:00
<macrodef name= "copy-replace" description= "Copy text files and replace ant variables" >
2016-11-04 10:39:19 -04:00
<attribute name= "todir" />
<element name= "filesets" implicit= "yes" />
<sequential >
2016-11-04 16:19:30 -04:00
<copy todir= "@{todir}" encoding= "utf-8" overwrite= "yes" verbose= "yes" >
2016-11-04 10:39:19 -04:00
<filesets />
<filterset begintoken= "@{" endtoken= "}" >
<propertyset >
<propertyref builtin= "all" />
</propertyset>
</filterset>
2018-07-27 03:09:45 -04:00
<filtermapper >
<replacetokens begintoken= "@{" endtoken= "}" propertiesResource= "app.properties" />
</filtermapper>
2016-11-04 10:39:19 -04:00
</copy>
</sequential>
</macrodef>
2018-06-23 09:34:55 -04:00
<macrodef name= "release-sign" description= "Sign files with GnuPG" >
2017-04-16 08:11:48 -04:00
<element name= "filesets" implicit= "yes" />
<sequential >
2018-06-22 11:28:16 -04:00
<apply executable= "gpg" verbose= "yes" failonerror= "yes" >
2018-06-21 15:05:21 -04:00
<arg line= "--verbose --batch --yes --local-user ${package.maintainer}" />
<arg line= "--armor --detach-sign" />
2017-04-16 08:11:48 -04:00
<srcfile />
<filesets />
</apply>
</sequential>
</macrodef>
2018-06-23 09:34:55 -04:00
<macrodef name= "release-deploy" description= "Upload files" >
2018-06-22 10:44:23 -04:00
<attribute name= "dir" />
2017-04-16 13:08:09 -04:00
<attribute name= "todir" />
2018-06-22 11:30:51 -04:00
<element name= "includes" implicit= "yes" optional= "yes" />
2017-04-16 13:08:09 -04:00
<sequential >
2018-06-26 12:48:56 -04:00
<scp todir= "@{todir}" trust= "yes" verbose= "true" sftp= "true" keyfile= "${scp.keyfile}" >
2018-06-22 10:44:23 -04:00
<fileset dir= "@{dir}" >
<includes />
<modified >
<param name= "cache.cachefile" value= "${dir.cache}/scp.cache" />
</modified>
</fileset>
2017-04-16 13:08:09 -04:00
</scp>
</sequential>
</macrodef>
2018-06-23 09:34:55 -04:00
<macrodef name= "create-app-bundle" description= "Create macOS app bundle folder structure" >
<attribute name= "dir" />
2018-06-23 09:50:33 -04:00
<attribute name= "deployment" />
<attribute name= "license" />
2018-07-12 15:10:40 -04:00
<attribute name= "identifier" />
2018-06-23 09:50:33 -04:00
<element name= "options" implicit= "yes" optional= "yes" />
2018-06-23 09:34:55 -04:00
<sequential >
2019-05-07 16:34:00 -04:00
<bundleapp jvmrequired= "${jvm.version}" minimumsystemversion= "${mac.version}" outputdirectory= "@{dir}" executablename= "${package.name}.launcher" name= "${application.name}" displayname= "${application.name}.launcher" version= "${revision}" shortversion= "${application.version}" identifier= "@{identifier}" mainclassname= "${main.class}" icon= "${dir.installer}/icons/${package.name}.icns" copyright= "${tstamp.year} ${package.company}" applicationcategory= "${mac.application.category}" highresolutioncapable= "true" supportsautomaticgraphicsswitching= "true" >
2018-06-23 09:34:55 -04:00
<arch name= "x86_64" />
2018-06-23 15:43:20 -04:00
2019-05-31 11:00:32 -04:00
<runtime dir= "${dir.lib}/jre/Darwin-x86_64/openjdk.jre/Contents/Home" >
2018-06-23 15:43:20 -04:00
<include name= "**/*" />
</runtime>
2018-06-23 09:34:55 -04:00
<classpath dir= "${dir.dist}/lib" />
<librarypath dir= "${dir.lib}/native/mac-x86_64" />
2018-11-18 07:39:23 -05:00
<option value= "--module-path" />
2019-05-31 10:25:14 -04:00
<option value= "$APP_ROOT/Contents/PlugIns/openjdk.jre/Contents/Home/ext/modules/lib" />
2018-11-18 07:39:23 -05:00
<option value= "--add-modules" />
<option value= "ALL-MODULE-PATH" />
2018-06-23 09:50:33 -04:00
<!-- include command - line tools -->
2018-06-23 15:03:53 -04:00
<librarypath dir= "@{dir}" >
<include name= "*.sh" />
</librarypath>
2018-06-23 09:50:33 -04:00
2018-06-23 09:34:55 -04:00
<bundledocument role= "viewer" handlerRank= "none" contentTypes= "public.movie" name= "Video file" />
<bundledocument role= "viewer" handlerRank= "none" contentTypes= "public.audio" name= "Audio file" />
<bundledocument role= "viewer" handlerRank= "none" contentTypes= "public.folder" name= "Media folder" />
<option value= "-Dunixfs=false" />
<option value= "-DuseExtendedFileAttributes=true" />
<option value= "-DuseCreationDate=false" />
<option value= "-Djava.net.useSystemProxies=true" />
2018-06-23 14:53:34 -04:00
2018-06-23 09:34:55 -04:00
<option value= "-Djna.nosys=true" />
<option value= "-Djna.nounpack=true" />
<option value= "-Djna.boot.library.name=jnidispatch" />
<option value= "-Djna.boot.library.path=$APP_ROOT/Contents/MacOS" />
<option value= "-Djna.library.path=$APP_ROOT/Contents/MacOS" />
<option value= "-Djava.library.path=$APP_ROOT/Contents/MacOS" />
<option value= "-Dnet.filebot.AcoustID.fpcalc=$APP_ROOT/Contents/MacOS/fpcalc" />
2018-06-23 14:53:34 -04:00
<option value= "-Dnet.filebot.UserFiles.fileChooser=COCOA" />
2018-06-23 09:34:55 -04:00
<option value= "-Dapple.awt.application.name=${application.name}" />
2018-06-23 14:53:34 -04:00
<option value= "-Dapple.laf.useScreenMenuBar=true" />
<option value= "-Dfile.encoding=UTF-8" />
2018-06-23 09:34:55 -04:00
2018-12-17 04:43:02 -05:00
<!-- MAS does not support or allow command - line applications and may run executables with strange arguments for no apparent reason (e.g. filebot.launcher - psn_0_774333) so we ignore arguments completely in this case -->
<option value= "-Dapple.app.launcher=true" />
2019-02-20 13:07:09 -05:00
<option value= "-Dapple.app.workflows=$APP_ROOT/Contents/Workflows" />
2018-12-17 04:43:02 -05:00
2018-06-23 14:53:34 -04:00
<!-- libjfxwebkit.dylib cannot be deployed on the MAS due to deprecated dependencies -->
2018-06-23 09:50:33 -04:00
<option value= "-Dapplication.deployment=@{deployment}" />
<!-- associate with *.psm files -->
<bundledocument extensions= "${license.extension}" icon= "${dir.installer}/icons/filebot.icns" name= "${license.description}" role= "viewer" handlerRank= "owner" contentTypes= "net.filebot.license" if:true= "@{license}" />
<typedeclaration extensions= "${license.extension}" icon= "${dir.installer}/icons/filebot.icns" description= "${license.description}" conformsTo= "public.plain-text" identifier= "net.filebot.license" mimeTypes= "${license.mimetype}" if:true= "@{license}" />
2018-06-23 09:34:55 -04:00
<!-- include custom macro options -->
<options />
</bundleapp>
2019-02-20 10:57:57 -05:00
<!-- include workflows -->
2019-02-20 11:04:38 -05:00
<copy todir= "${dir.staging}/${application.name}.app/Contents/Workflows" >
2019-02-20 10:57:57 -05:00
<fileset dir= "${dir.installer}/workflows" />
</copy>
2018-06-23 09:34:55 -04:00
<!-- fix permissions -->
<chmod perm= "+x" verbose= "yes" >
2019-02-20 10:57:57 -05:00
<fileset dir= "${dir.staging}/${application.name}.app" >
2019-02-20 11:01:15 -05:00
<include name= "**/*.launcher" />
<include name= "**/*.sh" />
<include name= "**/jspawnhelper" />
<include name= "**/java" />
2018-06-23 09:34:55 -04:00
</fileset>
</chmod>
</sequential>
</macrodef>
2018-06-27 09:13:10 -04:00
<target name= "jar" depends= "revision" >
2018-06-26 14:26:12 -04:00
<!-- select jar dependencies -->
<fileset id= "jar.classpath" dir= "${dir.lib}" includesfile= "${dir.lib}/jar.includes" />
2018-06-27 09:13:10 -04:00
<!-- rebuild each dependency jar with zero compression and remove signatures -->
2018-06-27 12:11:20 -04:00
<groovy src= "${dir.lib}/jar.groovy" />
2018-06-27 12:07:32 -04:00
<path id= "jar.classpath" >
<fileset dir= "${dir.dist}/lib" >
<include name= "*.jar" />
</fileset>
</path>
<manifestclasspath property= "jar.classpath" jarfile= "${dir.dist}/lib/${package.name}.jar" >
<classpath refid= "jar.classpath" />
</manifestclasspath>
2018-06-22 10:44:23 -04:00
<!-- compile -->
2018-06-27 12:07:32 -04:00
<javac srcdir= "${dir.source}" destdir= "${dir.build}" release= "${jvm.version}" encoding= "utf-8" debug= "yes" includeAntRuntime= "no" >
<classpath refid= "jar.classpath" />
2018-11-18 06:04:43 -05:00
<modulepath path= "${jfx.path}" />
<compilerarg line= "--add-modules ALL-MODULE-PATH" />
2018-06-22 10:44:23 -04:00
</javac>
<!-- copy resources -->
2018-07-11 10:35:33 -04:00
<copy todir= "${dir.build}" includeemptydirs= "no" >
2018-06-22 10:44:23 -04:00
<fileset dir= "${dir.source}" >
<exclude name= "**/*.java" />
<exclude name= "**/*.properties" />
</fileset>
</copy>
2018-06-27 12:07:32 -04:00
<!-- copy property files -->
<copy-replace todir= "${dir.build}" >
<fileset dir= "${dir.source}" includes= "**/*.properties" />
</copy-replace>
2018-06-22 10:44:23 -04:00
2019-05-12 06:56:30 -04:00
<jar destfile= "${dir.dist}/lib/${package.name}.jar" compress= "no" >
2016-05-12 10:15:19 -04:00
<fileset dir= "${dir.build}" />
2014-08-01 07:47:39 -04:00
<manifest >
2018-06-27 09:13:10 -04:00
<attribute name= "Main-Class" value= "${main.class}" />
<attribute name= "Class-Path" value= "${jar.classpath}" />
2016-04-21 07:57:01 -04:00
<attribute name= "Build-Date" value= "${tstamp.date}" />
<attribute name= "Build-Revision" value= "${revision}" />
2014-08-01 07:47:39 -04:00
</manifest>
2018-06-27 12:07:32 -04:00
<indexjars refid= "jar.classpath" />
2014-08-01 07:47:39 -04:00
</jar>
</target>
2018-06-23 14:35:47 -04:00
<target name= "appx" depends= "revision" description= "Build Windows 10 package" >
2018-08-11 05:48:24 -04:00
<property name= "appx.arch" value= "x64" />
2018-08-12 01:32:38 -04:00
<property name= "dir.staging" location= "${dir.dist}/appx/${appx.arch}" />
2018-06-23 14:35:47 -04:00
<copy todir= "${dir.staging}" >
2018-11-25 10:45:12 -05:00
<fileset dir= "${dir.installer}/msi/${appx.arch}" includes= "*.exe" />
2018-06-23 14:35:47 -04:00
</copy>
<copy todir= "${dir.staging}/lib" >
2018-08-11 05:07:39 -04:00
<fileset dir= "${dir.lib}/native/win32-${appx.arch}" />
2018-06-23 14:35:47 -04:00
</copy>
<copy todir= "${dir.staging}/jar" >
<fileset dir= "${dir.dist}/lib" includes= "*.jar" />
</copy>
2018-06-28 16:37:14 -04:00
<copy todir= "${dir.staging}" >
<fileset dir= "${dir.installer}/appx" includes= "**/*.png" />
</copy>
2018-06-23 14:35:47 -04:00
<!-- copy files and resolve ant variables -->
<copy-replace todir= "${dir.staging}" >
2018-08-12 01:32:38 -04:00
<fileset dir= "${dir.installer}/appx" includes= "*.xml, *.ini" />
2018-06-23 14:35:47 -04:00
</copy-replace>
<!-- fetch latest JRE -->
2019-05-31 11:00:32 -04:00
<copy todir= "${dir.staging}/jre" >
2019-05-31 13:44:37 -04:00
<fileset dir= "${dir.lib}/jre/Windows-${appx.arch}" />
2019-05-31 11:00:32 -04:00
</copy>
2018-06-23 14:35:47 -04:00
<!-- package APPX -->
<exec executable= "makepri" dir= "${dir.staging}" failonerror= "yes" >
<arg line= "createconfig /o /pv 10.0.0 /cf priconfig.xml /dq en-US" />
</exec>
<exec executable= "makepri" dir= "${dir.staging}" failonerror= "yes" >
<arg line= "new /o /pr . /cf priconfig.xml /in ${microsoft.application.name}" />
</exec>
<exec executable= "makeappx" dir= "${dir.dist}" failonerror= "yes" >
2018-08-11 05:07:39 -04:00
<arg line= "pack /v /o /d ${dir.staging} /p ${release}_r${revision}_${appx.arch}.appx" />
2018-06-23 14:35:47 -04:00
</exec>
</target>
<target name= "msi" depends= "revision" description= "Build Windows Installer package" >
2018-08-12 01:22:03 -04:00
<property name= "msi.package.platform" value= "x64" />
<property name= "msi.directory.id" value= "ProgramFiles64Folder" />
<property name= "msi.component.win64" value= "yes" />
<property name= "dir.staging" location= "${dir.dist}/msi/${msi.package.platform}" />
2018-06-23 14:35:47 -04:00
<!-- 1. prepare application files for heat harvest -->
2019-05-31 11:00:32 -04:00
<copy todir= "${dir.staging}/base/jre" >
<fileset dir= "${dir.lib}/jre/Windows-${msi.package.platform}" />
</copy>
2018-06-23 14:35:47 -04:00
<copy todir= "${dir.staging}/base/jar" >
<fileset dir= "${dir.dist}/lib" includes= "*.jar" />
</copy>
<copy todir= "${dir.staging}/base/lib" >
2018-08-12 01:22:03 -04:00
<fileset dir= "${dir.lib}/native/win32-${msi.package.platform}" />
2018-06-23 14:35:47 -04:00
</copy>
2019-02-26 10:55:43 -05:00
<copy todir= "${dir.staging}/base/menu" >
<fileset dir= "${dir.installer}/msi/menu" />
</copy>
2018-06-23 14:35:47 -04:00
<exec executable= "heat" dir= "${dir.staging}" failonerror= "true" >
<arg line= "dir base -v -srd -gg -dr ApplicationBase -cg ApplicationBase -template fragment -sreg -sfrag -scom -out base.wxs" />
</exec>
<exec executable= "candle" dir= "${dir.staging}" failonerror= "true" >
<arg line= "base.wxs -out base.wixobj" />
</exec>
<!-- 2. prepare installer files and application stub for candle light -->
<copy-replace todir= "${dir.staging}" >
<fileset dir= "${dir.installer}/msi" includes= "*.wix, *.ini" />
</copy-replace>
<exec executable= "candle" dir= "${dir.staging}" failonerror= "true" >
<arg line= "filebot.wix -out filebot.wixobj" />
</exec>
<!-- 3. compile MSI package (use - b to add additional resource folders) -->
<exec executable= "light" dir= "${dir.staging}" failonerror= "true" >
2018-08-12 02:02:57 -04:00
<arg line= "filebot.wixobj base.wixobj -b base -b ${dir.installer}/msi/${msi.package.platform} -b ${dir.installer}/msi -sval -ext WixUIExtension -out ${dir.dist}/${release}_${msi.package.platform}.msi" />
2018-06-23 14:35:47 -04:00
</exec>
</target>
2018-06-29 14:36:26 -04:00
<target name= "zip" depends= "revision" description= "Build Windows Portable ZIP package" >
<property name= "dir.staging" location= "${dir.dist}/zip" />
2019-05-31 11:00:32 -04:00
<copy todir= "${dir.staging}/jre" >
2019-05-31 14:34:14 -04:00
<fileset dir= "${dir.lib}/jre/Windows-x64" />
2019-05-31 11:00:32 -04:00
</copy>
2018-11-20 11:54:55 -05:00
2018-11-25 09:58:03 -05:00
<copy todir= "${dir.staging}" >
2018-11-25 10:45:12 -05:00
<fileset dir= "${dir.installer}/msi/x64" includes= "*.exe" />
2018-11-25 09:58:03 -05:00
</copy>
2018-06-29 14:36:26 -04:00
<copy-replace todir= "${dir.staging}" >
<fileset dir= "${dir.installer}/zip" includes= "*.ini" />
</copy-replace>
2019-05-18 00:09:02 -04:00
<zip destfile= "${dir.dist}/${release}-portable.zip" encoding= "utf-8" compress= "yes" level= "9" >
2018-11-25 09:58:03 -05:00
<zipfileset dir= "${dir.staging}" />
2018-06-29 14:36:26 -04:00
<zipfileset prefix= "jar" dir= "${dir.dist}/lib" />
<zipfileset prefix= "lib" dir= "${dir.lib}/native/win32-x64" />
</zip>
</target>
2018-07-01 12:36:32 -04:00
<target name= "mas" depends= "revision" description= "Build MAS package" >
2018-06-15 05:05:42 -04:00
<property name= "dir.staging" location= "${dir.dist}/mas" />
2016-11-13 15:17:52 -05:00
2018-06-15 05:05:42 -04:00
<property name= "path.app" location= "${dir.staging}/${application.name}.app" />
<property name= "path.pkg" location= "${dir.staging}/${application.name}_${application.version}_r${revision}.pkg" />
2016-11-13 16:41:07 -05:00
2019-05-31 10:25:14 -04:00
<create-app-bundle dir= "${dir.staging}" deployment= "mas" license= "no" identifier= "${package.identifier}" >
2018-06-23 14:53:34 -04:00
<option value= "-Dapplication.update=skip" />
2015-12-12 07:06:13 -05:00
<!-- WORKING_DIR is sandbox data folder -->
2016-11-13 17:32:28 -05:00
<option value= "-Dapplication.dir=Library/Application Support/User Data" />
<option value= "-Dapplication.cache=Library/Caches/ehcache.disk.store" />
<option value= "-Djava.io.tmpdir=Library/Caches/java.io.tmpdir" />
2018-06-23 14:53:34 -04:00
</create-app-bundle>
2015-12-12 07:06:13 -05:00
2018-08-08 09:33:52 -04:00
<!-- strip bundle from unused resources -->
2016-11-13 15:17:52 -05:00
<delete verbose= "yes" includeEmptyDirs= "yes" >
2019-02-20 13:07:09 -05:00
<fileset dir= "${path.app}" >
<include name= "**/Workflows/**" />
2018-08-08 11:48:58 -04:00
<include name= "**/bin/**" />
2019-02-20 13:07:09 -05:00
<include name= "**/*.lproj/**" />
<exclude name= "**/en.lproj/**" />
2018-08-08 09:33:52 -04:00
</fileset>
2016-11-13 15:17:52 -05:00
</delete>
2016-11-11 17:12:11 -05:00
2019-05-31 10:25:14 -04:00
<property name= "path.app.jre" location= "${path.app}/Contents/PlugIns/openjdk.jre" />
2018-06-15 05:05:42 -04:00
<!-- MAS validation is a bit buggy and requires even libraries and frameworks to have a unique CFBundleIdentifier Collision -->
2019-05-31 11:18:19 -04:00
<replace file= "${path.app.jre}/Contents/Info.plist" token= "net.java.openjdk" value= "${package.identifier}.openjdk" encoding= "UTF-8" summary= "true" />
2018-06-15 05:05:42 -04:00
2016-11-13 17:32:28 -05:00
<!-- fix broken symlink -->
2019-05-31 10:25:14 -04:00
<copy file= "${dir.staging}/openjdk.jre/Contents/Home/lib/jli/libjli.dylib" tofile= "${path.app.jre}/Contents/MacOS/libjli.dylib" overwrite= "yes" verbose= "yes" failonerror= "yes" />
2016-11-13 17:32:28 -05:00
<!-- fix permissions (fpcalc and jspawnhelper be executable and signed with inherit entitlements) -->
<chmod perm= "+x" >
<fileset dir= "${path.app}" >
<include name= "**/jspawnhelper" />
<include name= "**/fpcalc" />
<include name= "**/*.sh" />
</fileset>
</chmod>
2016-11-11 17:12:11 -05:00
2015-12-12 07:06:13 -05:00
<!-- JRE sign all jars, dylibs and executables -->
2018-06-23 14:53:34 -04:00
<property name= "sign" value= "--verbose --force --sign '3rd Party Mac Developer Application: ${package.company}'" />
2018-07-01 13:43:03 -04:00
<property name= "entitlements" value= "--entitlements '${dir.installer}/mas/FileBot.entitlements'" />
<property name= "entitlements.inherit" value= "--entitlements '${dir.installer}/mas/inherit.entitlements'" />
2016-11-13 17:32:28 -05:00
<!-- sign helper tools with inherit entitlements -->
<apply executable= "codesign" parallel= "yes" failonerror= "yes" >
<arg line= "${sign} ${entitlements.inherit}" />
<fileset dir= "${path.app}" >
2016-11-13 15:34:35 -05:00
<include name= "**/jspawnhelper" />
2016-11-13 17:32:28 -05:00
<include name= "**/fpcalc" />
2016-11-13 16:00:02 -05:00
<include name= "**/*.dylib" />
<include name= "**/*.jar" />
2016-11-13 17:32:28 -05:00
<include name= "**/*.sh" />
2016-11-11 17:12:11 -05:00
</fileset>
</apply>
2016-11-13 17:32:28 -05:00
<!-- sign frameworks -->
<exec executable= "codesign" failonerror= "yes" >
<arg line= "${sign} ${entitlements.inherit} '${path.app.jre}'" />
2016-11-13 16:00:02 -05:00
</exec>
2016-11-13 17:32:28 -05:00
<!-- sign app -->
<exec executable= "codesign" failonerror= "yes" >
<arg line= "${sign} ${entitlements} '${path.app}'" />
2015-12-12 07:06:13 -05:00
</exec>
2016-11-13 17:32:28 -05:00
<!-- verify signature -->
<exec executable= "codesign" failonerror= "yes" >
<arg line= "--verbose --deep --verify '${path.app}'" />
2016-11-13 16:00:02 -05:00
</exec>
2016-11-13 17:32:28 -05:00
<!-- build package -->
<exec executable= "productbuild" failonerror= "yes" >
2018-06-23 14:53:34 -04:00
<arg line= "--component '${path.app}' /Applications '${path.pkg}' --sign '3rd Party Mac Developer Installer: ${package.company}'" />
2015-12-12 07:06:13 -05:00
</exec>
2016-09-19 05:09:47 -04:00
<!-- store as release build -->
2016-11-13 17:32:28 -05:00
<copy todir= "${dir.release}" file= "${path.pkg}" verbose= "yes" />
2015-12-12 07:06:13 -05:00
</target>
2018-07-01 12:36:32 -04:00
<target name= "app" depends= "revision" description= "Build macOS app bundle" >
2018-06-11 15:20:20 -04:00
<property name= "dir.staging" location= "${dir.dist}/app" />
2018-06-23 15:03:53 -04:00
<copy-replace todir= "${dir.staging}" >
<fileset dir= "${dir.installer}/app" />
2018-06-11 15:20:20 -04:00
</copy-replace>
2019-05-31 10:25:14 -04:00
<create-app-bundle dir= "${dir.staging}" deployment= "app" license= "yes" identifier= "${package.identifier}.app" />
2018-06-11 15:20:20 -04:00
2018-06-12 09:34:10 -04:00
<tar destfile= "${dir.dist}/${release}.app.tar.xz" compression= "${tar.compression}" longfile= "posix" encoding= "utf-8" >
2018-06-11 15:20:20 -04:00
<tarfileset dir= "${dir.staging}" >
<include name= "*.app/**" />
2018-06-11 16:33:10 -04:00
<exclude name= "*.app/**/MacOS/filebot.*" />
<exclude name= "*.app/**/MacOS/fpcalc" />
<exclude name= "*.app/**/lib/jspawnhelper" />
<exclude name= "*.app/**/bin/*" />
2018-06-11 15:20:20 -04:00
</tarfileset>
<tarfileset dir= "${dir.staging}" filemode= "755" >
<include name= "*.app/**/MacOS/filebot.*" />
<include name= "*.app/**/MacOS/fpcalc" />
<include name= "*.app/**/lib/jspawnhelper" />
<include name= "*.app/**/bin/*" />
</tarfileset>
</tar>
</target>
2018-06-15 08:30:02 -04:00
2018-07-01 12:36:32 -04:00
<target name= "pkg" depends= "revision" description= "Build macOS installer package" >
2018-06-15 08:30:02 -04:00
<property name= "dir.staging" location= "${dir.dist}/pkg" />
<copy-replace todir= "${dir.staging}" >
<fileset dir= "${dir.installer}/pkg" />
</copy-replace>
2019-05-31 10:25:14 -04:00
<create-app-bundle dir= "${dir.staging}" deployment= "pkg" license= "yes" identifier= "${package.identifier}.pkg" />
2018-06-23 09:34:55 -04:00
2018-06-15 09:09:22 -04:00
<!-- fix permissions -->
<chmod perm= "+x" verbose= "yes" >
<fileset dir= "${dir.staging}/scripts" />
</chmod>
2018-06-15 08:30:02 -04:00
<exec executable= "pkgbuild" dir= "${dir.staging}" failonerror= "yes" >
2018-06-29 16:04:47 -04:00
<arg line= "${package.name}.pkg --install-location /Applications --component ${dir.dist}/pkg/${application.name}.app --scripts scripts" />
2018-06-15 08:30:02 -04:00
</exec>
<exec executable= "productbuild" dir= "${dir.staging}" failonerror= "yes" >
2018-06-15 08:44:33 -04:00
<arg line= "${dir.dist}/${release}.pkg --distribution distribution.xml --package-path . --sign 'Developer ID Installer: ${package.company}'" />
2018-06-15 08:30:02 -04:00
</exec>
</target>
2018-06-22 10:44:23 -04:00
<target name= "deb" depends= "revision" description= "Build Debian package" >
2018-06-20 12:30:46 -04:00
<property name= "dir.staging" location= "${dir.dist}/deb" />
2016-11-03 18:46:00 -04:00
2019-05-31 11:00:32 -04:00
<copy todir= "${dir.staging}/jre" >
<fileset dir= "${dir.lib}/jre/Linux-x86_64" />
</copy>
2018-11-28 11:15:37 -05:00
2016-11-04 10:39:19 -04:00
<copy-replace todir= "${dir.staging}" >
2017-02-07 08:50:37 -05:00
<fileset dir= "${dir.installer}/deb" />
2016-11-04 10:39:19 -04:00
</copy-replace>
2016-11-03 18:46:00 -04:00
2018-11-28 11:50:23 -05:00
<jdeb destfile= "${dir.dist}/${application.name}_${application.version}_amd64.deb" control= "${dir.staging}/control" compression= "${tar.compression}" verbose= "true" >
2018-04-03 02:31:46 -04:00
<tarfileset prefix= "/usr/share/filebot/bin" dir= "${dir.staging}" includes= "*.sh" filemode= "755" />
2018-11-28 11:15:37 -05:00
<tarfileset prefix= "/usr/share/filebot/mod" dir= "${dir.staging}/jre/ext/modules/lib" />
2018-06-12 14:23:00 -04:00
<tarfileset prefix= "/usr/share/filebot/jar" dir= "${dir.dist}/lib" />
2018-11-29 10:23:56 -05:00
<tarfileset prefix= "/usr/share/filebot/lib" dir= "${dir.lib}/native/linux-amd64" />
2018-06-12 14:23:00 -04:00
2017-02-14 10:48:04 -05:00
<tarfileset prefix= "/usr/share/icons/hicolor/scalable/apps" dir= "${dir.installer}/icons" includes= "filebot.svg" />
2018-06-13 06:10:04 -04:00
<tarfileset prefix= "/usr/share" dir= "${dir.staging}/share" />
2016-11-03 18:46:00 -04:00
</jdeb>
2014-08-01 07:47:39 -04:00
</target>
2018-11-28 15:34:26 -05:00
<target name= "deb-universal" depends= "revision" description= "Build Universal Debian package" >
<property name= "dir.staging" location= "${dir.dist}/deb-universal" />
<!-- use Debian package structure -->
2019-03-07 06:53:54 -05:00
<copy-replace todir= "${dir.staging}/share" >
<fileset dir= "${dir.installer}/deb/share" />
2018-11-28 15:34:26 -05:00
</copy-replace>
<copy-replace todir= "${dir.staging}" >
<fileset dir= "${dir.installer}/deb-universal" />
</copy-replace>
<jdeb destfile= "${dir.dist}/${application.name}_${application.version}_universal.deb" control= "${dir.staging}/control" compression= "${tar.compression}" verbose= "true" >
<tarfileset prefix= "/usr/share/filebot/bin" dir= "${dir.staging}" includes= "*.sh" filemode= "755" />
2019-03-07 06:53:54 -05:00
<tarfileset prefix= "/usr/share/filebot/jar" dir= "${dir.dist}/lib" excludes= "${deb.jna.depends}" />
2018-11-28 15:34:26 -05:00
<tarfileset prefix= "/usr/share/icons/hicolor/scalable/apps" dir= "${dir.installer}/icons" includes= "filebot.svg" />
<tarfileset prefix= "/usr/share" dir= "${dir.staging}/share" />
</jdeb>
</target>
2018-07-01 12:36:32 -04:00
<target name= "snap" depends= "revision" description= "Build Ubuntu SNAP package" >
2018-06-23 14:35:47 -04:00
<property name= "dir.staging" location= "${dir.dist}/snap" />
<property name= "dir.base" location= "${dir.staging}/base" />
2017-08-23 06:03:29 -04:00
2017-03-12 05:21:11 -04:00
<!-- copy files and resolve ant variables -->
2017-08-23 06:03:29 -04:00
<copy-replace todir= "${dir.staging}" >
2018-06-23 14:35:47 -04:00
<fileset dir= "${dir.installer}/snap" />
2017-03-12 05:21:11 -04:00
</copy-replace>
2016-11-02 15:50:39 -04:00
2018-06-23 14:35:47 -04:00
<copy todir= "${dir.base}/filebot/jar" >
2018-06-09 01:35:57 -04:00
<fileset dir= "${dir.dist}/lib" includes= "*.jar" />
2016-11-04 16:19:30 -04:00
</copy>
2018-06-23 14:35:47 -04:00
<copy todir= "${dir.base}/filebot/lib" >
2018-11-25 09:50:50 -05:00
<fileset dir= "${dir.lib}/native/linux-amd64" includes= "${deb.jna.depends}" />
2016-11-04 16:19:30 -04:00
</copy>
2018-06-23 14:35:47 -04:00
<chmod perm= "+x" verbose= "yes" >
<fileset dir= "${dir.base}" includes= "**/bin/**" />
</chmod>
2018-06-09 01:35:57 -04:00
2019-02-04 05:10:31 -05:00
<exec executable= "snapcraft" dir= "${dir.staging}" failonerror= "yes" />
2014-08-01 07:47:39 -04:00
</target>
2018-07-01 12:36:32 -04:00
<target name= "tar" depends= "revision" description= "Build Linux Portable TAR package" >
<property name= "dir.staging" location= "${dir.dist}/tar" />
2018-06-12 15:25:10 -04:00
<copy-replace todir= "${dir.staging}" >
2018-07-01 12:36:32 -04:00
<fileset dir= "${dir.installer}/tar" includes= "*.sh" />
2018-06-12 15:25:10 -04:00
</copy-replace>
2018-06-12 09:34:10 -04:00
<tar destfile= "${dir.dist}/${release}-portable.tar.xz" compression= "${tar.compression}" longfile= "posix" encoding= "utf-8" >
2018-06-12 15:25:10 -04:00
<tarfileset dir= "${dir.staging}" includes= "*.sh" filemode= "755" />
<tarfileset prefix= "jar" dir= "${dir.dist}/lib" />
2017-02-09 11:18:24 -05:00
<!-- include native libraries for all supported platforms -->
2018-07-23 06:40:32 -04:00
<tarfileset prefix= "lib/Linux-armv7l" dir= "${dir.lib}/native/linux-armv7l" includes= "*.so" />
2019-05-23 08:55:27 -04:00
<tarfileset prefix= "lib/Linux-aarch64" dir= "${dir.lib}/native/linux-aarch64" includes= "*.so" />
2018-07-23 06:40:32 -04:00
<tarfileset prefix= "lib/Linux-i686" dir= "${dir.lib}/native/linux-i686" includes= "*.so" />
<tarfileset prefix= "lib/Linux-x86_64" dir= "${dir.lib}/native/linux-amd64" includes= "*.so" />
2018-07-30 00:50:23 -04:00
<tarfileset prefix= "lib/FreeBSD-amd64" dir= "${dir.lib}/native/freebsd-amd64" includes= "*.so" />
2017-04-16 08:11:48 -04:00
<!-- include maintainer public key -->
2018-06-28 12:55:51 -04:00
<tarfileset dir= "${dir.installer}/gpg" includes= "maintainer.gpg" />
2017-02-09 11:18:24 -05:00
</tar>
2014-08-01 07:47:39 -04:00
</target>
2018-11-22 06:08:37 -05:00
<target name= "aur" depends= "revision" description= "Build Arch Linux TAR package for AUR" >
<property name= "dir.staging" location= "${dir.dist}/aur" />
<!-- use Debian package structure -->
<copy-replace todir= "${dir.staging}" >
<fileset dir= "${dir.installer}/deb" />
</copy-replace>
2018-11-25 16:05:12 -05:00
<copy-replace todir= "${dir.staging}" >
<fileset dir= "${dir.installer}/aur" />
</copy-replace>
2018-11-22 06:08:37 -05:00
<tar destfile= "${dir.dist}/${application.name}_${application.version}-aur.tar.xz" compression= "${tar.compression}" longfile= "posix" encoding= "utf-8" >
<tarfileset prefix= "/usr/share/filebot/bin" dir= "${dir.staging}" includes= "*.sh" filemode= "755" />
<tarfileset prefix= "/usr/share/filebot/jar" dir= "${dir.dist}/lib" />
2018-11-28 15:14:37 -05:00
<tarfileset prefix= "/usr/share/filebot/lib/x86_64" dir= "${dir.lib}/native/linux-amd64" includes= "${deb.jna.depends}" />
<tarfileset prefix= "/usr/share/filebot/lib/i686" dir= "${dir.lib}/native/linux-i686" includes= "${deb.jna.depends}" />
2019-05-23 08:55:27 -04:00
<tarfileset prefix= "/usr/share/filebot/lib/aarch64" dir= "${dir.lib}/native/linux-aarch64" includes= "${deb.jna.depends}" />
2018-11-28 15:14:37 -05:00
<tarfileset prefix= "/usr/share/filebot/lib/armv7l" dir= "${dir.lib}/native/linux-armv7l" includes= "${deb.jna.depends}" />
2018-11-22 06:08:37 -05:00
<tarfileset prefix= "/usr/share/icons/hicolor/scalable/apps" dir= "${dir.installer}/icons" includes= "filebot.svg" />
<tarfileset prefix= "/usr/share" dir= "${dir.staging}/share" />
</tar>
</target>
2019-03-02 13:10:49 -05:00
<target name= "rpm" depends= "revision" description= "Build RPM package" >
<property name= "dir.staging" location= "${dir.dist}/rpm" />
<copy-replace todir= "${dir.staging}" >
<fileset dir= "${dir.installer}/rpm" />
</copy-replace>
<copy todir= "${dir.staging}/usr/share/filebot/jar" >
2019-03-07 07:27:45 -05:00
<fileset dir= "${dir.dist}/lib" excludes= "${deb.jna.depends}" />
2019-03-02 13:10:49 -05:00
</copy>
<!-- use Debian package structure -->
<copy-replace todir= "${dir.staging}/usr/share" >
<fileset dir= "${dir.installer}/deb/share" />
</copy-replace>
<copy todir= "${dir.staging}/usr/share/icons/hicolor/scalable/apps" >
<fileset dir= "${dir.installer}/icons" includes= "filebot.svg" />
</copy>
<!-- fix execute permissions -->
<chmod verbose= "yes" perm= "+x" >
<fileset dir= "${dir.staging}" includes= "**/*.sh" />
</chmod>
<exec executable= "docker" failonerror= "yes" >
<arg line= "run -v ${dir.staging}:/src -v ${dir.staging}/build:/rpm --rm rednoah/rpm-build -bb filebot.spec" />
</exec>
2019-03-08 05:03:04 -05:00
<copy file= "${dir.staging}/build/RPMS/noarch/${package.name}-${application.version}-universal.jdk8.noarch.rpm" tofile= "${dir.dist}/${release}_universal-jdk8.rpm" />
2019-03-02 13:10:49 -05:00
</target>
2018-11-22 06:08:37 -05:00
2018-06-22 10:44:23 -04:00
<target name= "spk" depends= "revision" description= "Build Synology NAS package" >
2018-07-01 06:21:57 -04:00
<property name= "dir.staging" location= "${dir.dist}/spk" />
<copy-replace todir= "${dir.staging}" >
<fileset dir= "${dir.installer}/spk" />
</copy-replace>
2018-06-12 09:34:10 -04:00
<spk destdir= "${dir.dist}" name= "${package.name}" version= "${application.version}" arch= "noarch" compression= "${tar.compression}" >
2016-11-04 16:19:30 -04:00
<info name= "displayname" value= "${application.name}" />
<info name= "description" value= "${package.description}" />
<info name= "maintainer" value= "${package.project}" />
<info name= "maintainer_url" value= "${package.homepage}" />
<info name= "distributor" value= "${package.project}" />
<info name= "distributor_url" value= "${package.homepage}" />
<info name= "support_url" value= "${link.help.synology}" />
<info name= "helpurl" value= "${link.help.manpage}" />
2016-10-25 15:55:57 -04:00
<info name= "firmware" value= "6.0" />
2015-05-16 00:52:25 -04:00
<info name= "startable" value= "no" />
<info name= "silent_install" value= "yes" />
<info name= "silent_uninstall" value= "yes" />
<info name= "silent_upgrade" value= "yes" />
<info name= "thirdparty" value= "yes" />
2016-09-29 07:00:58 -04:00
2016-09-29 07:37:23 -04:00
<!-- Dependencies are troublesome for some users because they cannot be skipped or ignored (i.e. DSM does not support optional or recommended dependencies) -->
2016-09-29 07:00:58 -04:00
<!-- <info name="start_dep_services" value="ssh" /> -->
<!-- <info name="install_dep_packages" value="oracle - java" /> -->
2014-08-01 07:47:39 -04:00
<icon size= "72" file= "${dir.installer}/icons/icon72.png" />
2015-05-03 11:57:56 -04:00
<icon size= "256" file= "${dir.installer}/icons/icon256.png" />
2015-05-05 09:48:16 -04:00
2018-07-01 06:21:57 -04:00
<scripts dir= "${dir.staging}/scripts" filemode= "755" />
<package dir= "${dir.staging}/package" includes= "*.sh" filemode= "755" />
2018-06-23 08:19:10 -04:00
<package prefix= "jar" dir= "${dir.dist}/lib" includes= "*.jar" />
2015-05-16 01:35:51 -04:00
2016-12-16 03:26:34 -05:00
<!-- include native libraries for all supported platforms -->
2016-12-16 06:32:05 -05:00
<package prefix= "lib/armv7l" dir= "${dir.lib}/native/linux-armv7l" includes= "*.so" />
2019-05-23 08:55:27 -04:00
<package prefix= "lib/aarch64" dir= "${dir.lib}/native/linux-aarch64" includes= "*.so" />
2016-12-16 06:32:05 -05:00
<package prefix= "lib/i686" dir= "${dir.lib}/native/linux-i686" includes= "*.so" />
<package prefix= "lib/x86_64" dir= "${dir.lib}/native/linux-amd64" includes= "*.so" />
2016-12-16 03:26:34 -05:00
2018-06-26 06:34:51 -04:00
<codesign secring= "${dir.installer}/gpg/syno.gpg" keyid= "${gpg.key}" password= "${gpg.pwd}" />
2014-08-01 07:47:39 -04:00
</spk>
2017-03-04 05:14:14 -05:00
2018-11-27 13:16:30 -05:00
<move file= "${dir.dist}/${package.name}-${application.version}-noarch.spk" tofile= "${dir.dist}/${release}.spk" />
2014-08-01 07:47:39 -04:00
</target>
2019-03-02 13:10:49 -05:00
<target name= "qpkg" depends= "revision" description= "Build QNAP NAS package" >
2018-07-04 11:15:07 -04:00
<property name= "dir.staging" location= "${dir.dist}/qpkg" />
2018-07-04 11:27:08 -04:00
<property name= "dir.base" location= "${dir.dist}/qpkg/shared" />
2018-07-04 11:15:07 -04:00
<copy-replace todir= "${dir.staging}" >
2018-08-15 15:37:00 -04:00
<fileset dir= "${dir.installer}/qpkg" >
<include name= "**/*.sh" />
<include name= "**/*.cfg" />
2018-08-15 15:37:49 -04:00
<include name= "**/package_routines" />
2018-08-15 15:37:00 -04:00
</fileset>
2018-07-04 11:15:07 -04:00
</copy-replace>
<copy todir= "${dir.staging}" >
2018-08-15 15:37:00 -04:00
<fileset dir= "${dir.installer}/qpkg" >
<include name= "**/*.png" />
</fileset>
2018-07-04 11:15:07 -04:00
</copy>
2018-07-04 11:27:08 -04:00
<copy todir= "${dir.base}/jar" >
2018-07-04 11:15:07 -04:00
<fileset dir= "${dir.dist}/lib" includes= "*.jar" />
</copy>
<!-- include native libraries for all supported platforms -->
2018-07-04 11:27:08 -04:00
<copy todir= "${dir.base}/lib/armv7l" >
2018-07-04 11:15:07 -04:00
<fileset dir= "${dir.lib}/native/linux-armv7l" />
</copy>
2018-07-04 11:46:20 -04:00
<copy todir= "${dir.base}/lib/aarch64" >
2019-05-23 08:55:27 -04:00
<fileset dir= "${dir.lib}/native/linux-aarch64" />
2018-07-04 11:15:07 -04:00
</copy>
2018-07-04 11:27:08 -04:00
<copy todir= "${dir.base}/lib/i686" >
2018-07-04 11:15:07 -04:00
<fileset dir= "${dir.lib}/native/linux-i686" />
</copy>
2018-07-04 11:27:08 -04:00
<copy todir= "${dir.base}/lib/x86_64" >
2018-07-04 11:15:07 -04:00
<fileset dir= "${dir.lib}/native/linux-amd64" />
</copy>
2018-08-15 16:00:48 -04:00
<!-- overwrite native libraries with QNAP compatible ones -->
<copy todir= "${dir.staging}" overwrite= "yes" >
<fileset dir= "${dir.installer}/qpkg" >
<include name= "**/*.so" />
</fileset>
</copy>
2018-07-04 11:15:07 -04:00
<!-- fix execute permissions -->
<chmod verbose= "yes" perm= "+x" >
2018-07-04 11:27:08 -04:00
<fileset dir= "${dir.base}" includes= "**/*.sh" />
<fileset dir= "${dir.base}" includes= "**/fpcalc" />
2018-07-04 11:15:07 -04:00
</chmod>
2019-01-16 08:57:57 -05:00
<exec executable= "docker" failonerror= "yes" >
2019-01-16 09:52:41 -05:00
<arg line= "run --rm -v ${dir.staging}:/src rednoah/qpkg-build --7zip" />
2018-07-04 11:15:07 -04:00
</exec>
2019-01-16 08:57:57 -05:00
<copy file= "${dir.staging}/build/${package.name}_${application.version}.qpkg" tofile= "${dir.dist}/${release}.qpkg" />
2018-07-04 11:15:07 -04:00
</target>
2018-06-14 02:55:07 -04:00
<target name= "clean" description= "Delete build artifacts" >
2014-08-01 07:47:39 -04:00
<delete dir= "${dir.dist}" />
<delete dir= "${dir.build}" />
</target>
2016-09-19 05:09:47 -04:00
<target name= "revision" depends= "init" >
2016-04-20 12:57:03 -04:00
<exec executable= "git" outputproperty= "revision" failonerror= "true" >
<arg line= "rev-list --count master" />
</exec>
<echo > Revision: ${revision}</echo>
2014-08-01 07:47:39 -04:00
</target>
2016-09-19 05:09:47 -04:00
<target name= "init" >
<mkdir dir= "${dir.build}" />
<mkdir dir= "${dir.dist}" />
<mkdir dir= "${dir.release}" />
2016-09-20 02:40:38 -04:00
<mkdir dir= "${dir.cache}" />
2016-09-19 05:09:47 -04:00
2016-09-19 04:32:49 -04:00
<path id= "lib.classpath" >
<fileset dir= "${dir.lib}" includes= "**/*.jar" excludes= "**/*-jdk14.jar" />
</path>
2018-06-26 14:26:12 -04:00
<taskdef resource= "org/codehaus/groovy/antlib.xml" classpathref= "lib.classpath" />
2016-09-19 04:32:49 -04:00
<taskdef resource= "net/filebot/ant/spk/antlib.xml" classpathref= "lib.classpath" />
2016-11-03 18:46:00 -04:00
<taskdef resource= "org/vafer/jdeb/ant/antlib.xml" classpathref= "lib.classpath" />
2016-09-19 04:32:49 -04:00
<taskdef name= "bundleapp" classname= "com.oracle.appbundler.AppBundlerTask" classpathref= "lib.classpath" />
</target>
2018-06-24 13:42:05 -04:00
<target name= "stage" description= "Stage release files" >
2014-08-01 07:47:39 -04:00
<mkdir dir= "${dir.release}" />
2018-06-24 13:42:05 -04:00
<patternset id= "release.files" >
<include name= "*.msi" />
2018-07-04 11:15:07 -04:00
<include name= "*.zip" />
2018-06-24 13:42:05 -04:00
<include name= "*.pkg" />
<include name= "*.deb" />
2019-03-02 14:05:43 -05:00
<include name= "*.rpm" />
2018-06-24 13:42:05 -04:00
<include name= "*.tar.xz" />
<include name= "*.spk" />
2018-07-04 11:15:07 -04:00
<include name= "*.qpkg" />
2018-06-24 13:42:05 -04:00
</patternset>
<patternset id= "verification.files" >
<include name= "*.asc" />
<include name= "*.sha256" />
</patternset>
2015-06-15 15:25:17 -04:00
2018-06-21 15:05:21 -04:00
<!-- add *.asc files -->
2018-06-22 10:44:23 -04:00
<release-sign >
2018-06-24 13:42:05 -04:00
<fileset dir= "${dir.dist}" >
<patternset refid= "release.files" />
2018-06-22 10:44:23 -04:00
</fileset>
</release-sign>
2017-04-16 13:08:09 -04:00
2018-06-21 15:05:21 -04:00
<!-- add *.sha256 files -->
<checksum algorithm= "SHA-256" pattern= "{0}" fileext= ".sha256" >
2018-06-24 13:42:05 -04:00
<fileset dir= "${dir.dist}" >
<patternset refid= "release.files" />
2017-04-16 13:08:09 -04:00
</fileset>
2015-06-15 15:25:17 -04:00
</checksum>
2014-08-01 07:47:39 -04:00
2018-06-26 15:03:12 -04:00
<!-- normalize Windows / Linux EOL -->
<fixcrlf srcdir= "${dir.dist}" eol= "unix" eof= "remove" encoding= "utf-8" >
<patternset refid= "verification.files" />
</fixcrlf>
2018-06-24 13:42:05 -04:00
<!-- move to release folder -->
2018-06-24 15:11:19 -04:00
<touch datetime= "now" >
<fileset dir= "${dir.dist}" >
<patternset refid= "release.files" />
<patternset refid= "verification.files" />
</fileset>
</touch>
<move todir= "${dir.release}" verbose= "yes" flatten= "yes" overwrite= "yes" preservelastmodified= "yes" >
2018-06-24 13:42:05 -04:00
<fileset dir= "${dir.dist}" >
<patternset refid= "release.files" />
<patternset refid= "verification.files" />
</fileset>
</move>
</target>
2018-06-30 12:34:26 -04:00
<target name= "stage-update" description= "Upload incremental update archive" >
2018-08-02 01:22:55 -04:00
<tar destfile= "${dir.dist}/HEAD/CHANGES.tar.xz" compression= "${tar.compression}" longfile= "posix" encoding= "utf-8" >
2018-08-02 01:10:33 -04:00
<tarfileset src= "${dir.dist}/${release}-portable.tar.xz" includesfile= "${dir.installer}/tar/CHANGES.includes" />
2018-06-26 08:28:39 -04:00
</tar>
<antcall target= "stage" >
2018-08-02 01:22:55 -04:00
<param name= "dir.dist" value= "${dir.dist}/HEAD" />
2018-06-26 12:48:56 -04:00
<param name= "dir.release" value= "${dir.release.index}/HEAD" />
2018-06-26 08:28:39 -04:00
</antcall>
2014-08-01 07:47:39 -04:00
</target>
2018-06-26 08:28:39 -04:00
<target name= "deploy-release" description= "Upload release files" >
2018-06-26 12:48:56 -04:00
<release-deploy dir= "${dir.release.index}" todir= "${scp.release}" />
2017-06-13 08:27:31 -04:00
</target>
2018-06-22 11:24:06 -04:00
<target name= "deploy-chocolatey" description= "Update Chocolatey Package Source" >
2019-05-21 07:37:46 -04:00
<loadresource property= "x64.msi.sha256" >
2019-05-21 07:39:57 -04:00
<url url= "${link.release.index}/${release}/${release}_x64.msi.sha256" />
2019-05-21 08:24:05 -04:00
<filterchain >
<striplinebreaks />
</filterchain>
2019-05-21 07:37:46 -04:00
</loadresource>
2018-06-22 11:24:06 -04:00
<!-- replace variables for new release -->
2018-08-09 05:20:36 -04:00
<copy-replace todir= "${dir.dist}/choco" >
<fileset dir= "${dir.installer}/choco" >
2018-06-22 11:24:06 -04:00
<include name= "**/*.ps1" />
<include name= "**/*.nuspec" />
</fileset>
</copy-replace>
<!-- chocolatey pack and push -->
2018-08-09 05:20:36 -04:00
<exec executable= "choco" dir= "${dir.dist}/choco" failonerror= "yes" >
2018-06-22 11:24:06 -04:00
<arg line= "pack" />
</exec>
2018-08-09 05:20:36 -04:00
<exec executable= "choco" dir= "${dir.dist}/choco" failonerror= "yes" >
<arg line= "push ${package.name}.${application.version}.nupkg" />
2018-06-22 11:24:06 -04:00
</exec>
</target>
2019-03-12 03:33:35 -04:00
<target name= "docs" depends= "revision" >
2019-03-11 13:42:03 -04:00
<path id= "jar.classpath" >
<fileset dir= "${dir.dist}/lib" >
<include name= "*.jar" />
</fileset>
<fileset dir= "${jfx.path}" >
<include name= "*.jar" />
</fileset>
</path>
<javadoc destdir= "${dir.dist}/docs/api" windowtitle= "${application.name} ${application.version}" linksource= "yes" public= "yes" encoding= "UTF-8" >
<fileset dir= "${dir.source}" includesfile= "${dir.lib}/doc.includes" />
<classpath refid= "jar.classpath" />
2019-03-12 03:33:35 -04:00
<doctitle > ${application.name} ${application.version}</doctitle>
<header > ${application.name} ${application.version} (r${revision})</header>
<bottom > < i> Copyright © ${tstamp.year} ${package.company}. All Rights Reserved.< /i> </bottom>
2019-03-11 13:42:03 -04:00
<link href= "https://docs.oracle.com/en/java/javase/11/docs/api/" />
2019-03-12 03:33:35 -04:00
<link href= "http://docs.groovy-lang.org/latest/html/api/" />
2019-03-11 13:42:03 -04:00
</javadoc>
</target>
2018-01-19 15:55:19 -05:00
<target name= "eclipse-properties-builder" >
<copy-replace todir= "bin" >
<fileset dir= "source" includes= "**/*.properties" />
</copy-replace>
</target>
2014-08-01 07:47:39 -04:00
</project>