Skip to content
Permalink
Browse files

Updates for Mac Build

  • Loading branch information
davidzof committed Aug 21, 2015
1 parent 18f418e commit 80af468b0012820dd79d26c53c2af7bfaeb1fe43
@@ -0,0 +1,98 @@
<project name="wattzap" default="mac" basedir=".">
<description>
Wattzap Ant OSX Build File
</description>
<!-- set global properties for this build -->
<property name="src" location="src"/>
<property name="build" location="dist-mac/bin"/>
<property name="dist" location="dist-mac"/>
<!-- ***** Change this to point to your JDK ***** -->
<property name="javadir" location="/home/david/bin/jdk1.6.0_45"/>

<path id="master-classpath">
<fileset dir="lib">
<include name="*.jar"/>
</fileset>
<fileset dir="lib/java1.6libs">
<include name="*.jar"/>
</fileset>
</path>
<property name="classpath" refid="master-classpath"/>


<target name="init">
<!-- Create the time stamp -->
<tstamp/>
<!-- Create the build directory structure used by compile -->
<mkdir dir="${build}"/>
</target>

<target name="compile" depends="init" description="compile the source " >
<!-- Compile the java code from ${src} into ${build} -->
<javac srcdir="${src}" destdir="${build}" debug="true" debuglevel="lines,vars,source" fork="yes" executable="${javadir}/bin/javac">
<classpath refid="master-classpath"/>
</javac>
</target>

<target name="dist" depends="compile" description="generate the distribution" >
<!-- Create the distribution directory -->
<mkdir dir="${dist}"/>
<!-- Copy libs -->
<copy todir="${dist}/wattzap/lib">
<fileset dir="lib">
<include name="*.jar"/>
</fileset>
</copy>

<!-- Build WattzAp Jar -->
<jar destfile="wattzap.jar">
<fileset dir="${build}">
<exclude name="**/*Test.class" />
<exclude name="org/**/*.class" />
</fileset>
</jar>

<!-- Update jsr80 jar -->
<zip destfile="tmp.jar" >
<zipfileset src="lib/java1.6libs/jformica-jsr80-1.6.jar" excludes="org/cowboycoders/ant/interfaces/**/*.class" />
<zipfileset dir="${build}" includes="org/cowboycoders/ant/interfaces/**/*.class" />
</zip>
<move file="tmp.jar" tofile="${dist}/wattzap/lib/jformica_jsr80.jar"/>

<!-- Update usb4java jar -->
<zip destfile="tmp.jar" >
<zipfileset src="lib/usb4java-javax-1.2.0.jar" excludes="org/usb4java/javax/AbstractIrp*.class" />
<zipfileset dir="${build}" includes="org/usb4java/javax/AbstractIrp*.class" />
</zip>
<move file="tmp.jar" tofile="${dist}/wattzap/lib/usb4java-javax-1.2.0.jar"/>
</target>

<target name="clean"
description="clean up" >
<!-- Delete the ${build} and ${dist} directory trees -->
<delete dir="${build}"/>
<delete dir="${dist}"/>
</target>

<target name="mac" description="make OSX release" depends="dist">
<copy todir="${dist}/wattzap/lib/org">
<fileset dir="lib/org"/>
</copy>
<copy todir="${dist}/wattzap/properties">
<fileset dir="properties"/>
</copy>
<copy todir="${dist}/wattzap/icons">
<fileset dir="icons"/>
</copy>

<copy file="lib/java1.6libs/jformica-core1.6.jar" tofile="${dist}/wattzap/lib/jformica_core.jar"/>
<copy file="lib/java1.6libs/track-parser.jar" tofile="${dist}/wattzap/lib/track-parser.jar"/>

<copy file="runmac.sh" tofile="${dist}/wattzap/wattzap.sh"/>
<chmod file="${dist}/wattzap/wattzap.sh" perm="755"/>
<copy file="wattzap.jar" todir="${dist}/wattzap/lib/"/>

<tar destfile="${dist}/wattzap.tar" basedir="${dist}/wattzap"/>
<gzip destfile="${dist}/wattzap-mac.tgz" src="${dist}/wattzap.tar"/>
</target>
</project>
File renamed without changes.
@@ -366,7 +366,6 @@ public String getSerial() {

public boolean isRegistered() {
if (get("", "rsnn", null) == null) {
// return false;
return false;
}
return true;
@@ -68,7 +68,7 @@ public AboutPanel() {
if (key == null || key.length() == 0) {
userPrefs.setRegistrationKey("Community Edition");
}
about.setText("<html>WattzAp Community Edition<br/><br/>Version 2.5 beta2<br/>10th August 2015");
about.setText("<html>WattzAp Community Edition<br/><br/>Version 2.5.1<br/>19th August 2015");
add(about,"alignx right, span");

debug = new JCheckBox("Enable Debugging");

0 comments on commit 80af468

Please sign in to comment.
You can’t perform that action at this time.