Skip to content

Commit

Permalink
java 5 compatible now
Browse files Browse the repository at this point in the history
  • Loading branch information
jeichar committed Nov 6, 2008
1 parent 9980956 commit f2d0d22
Show file tree
Hide file tree
Showing 15 changed files with 281 additions and 230 deletions.
3 changes: 2 additions & 1 deletion owsproxyclient/.classpath
Expand Up @@ -2,6 +2,7 @@
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="src" path="test"/>
<classpathentry kind="src" path="netbeans/owsproxyclient/src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="lib" path="lib/jetty-6.0.1.jar" sourcepath="/home/sypasche/c2c/projects/wms/jetty/jetty-6.0.1"/>
<classpathentry kind="lib" path="lib/jetty-util-6.0.1.jar" sourcepath="/home/jeichar/dev/src/jetty-6.0.2/modules/util"/>
Expand All @@ -12,7 +13,7 @@
<classpathentry kind="lib" path="lib/commons-logging-api-1.1.jar"/>
<classpathentry kind="lib" path="lib/commons-codec-1.3.jar"/>
<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/3.8.1"/>
<classpathentry kind="lib" path="netbeans/owsproxyclient/dist/owsproxyclient.jar" sourcepath="netbeans/owsproxyclient/src"/>
<classpathentry kind="lib" path="netbeans/owsproxyclient/dist/lib/swing-layout-1.0.3.jar"/>
<classpathentry kind="lib" path="netbeans/owsproxyclient/dist/owsproxyclient.jar"/>
<classpathentry kind="output" path="bin"/>
</classpath>
2 changes: 1 addition & 1 deletion owsproxyclient/make_jar.sh
Expand Up @@ -3,7 +3,7 @@
# Script to create a standalone .jar file of the project

# WARNING: keep in sync with ~/c2c/projects/wms/project_public_files/Makefile
VERSION=0.5
VERSION=0.6
SWING_LAYOUT_VERSION=1.0.3

[ ! -d releases ] && mkdir releases
Expand Down
Binary file modified owsproxyclient/netbeans/owsproxyclient/dist/owsproxyclient.jar
Binary file not shown.
58 changes: 50 additions & 8 deletions owsproxyclient/netbeans/owsproxyclient/nbproject/build-impl.xml
Expand Up @@ -47,6 +47,43 @@ is divided into following sections:
<property file="nbproject/project.properties"/>
</target>
<target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" name="-do-init">
<j2seproject1:property name="platform.home" value="platforms.${platform.active}.home"/>
<j2seproject1:property name="platform.bootcp" value="platforms.${platform.active}.bootclasspath"/>
<j2seproject1:property name="platform.compiler" value="platforms.${platform.active}.compile"/>
<j2seproject1:property name="platform.javac.tmp" value="platforms.${platform.active}.javac"/>
<condition property="platform.javac" value="${platform.home}/bin/javac">
<equals arg1="${platform.javac.tmp}" arg2="$${platforms.${platform.active}.javac}"/>
</condition>
<property name="platform.javac" value="${platform.javac.tmp}"/>
<j2seproject1:property name="platform.java.tmp" value="platforms.${platform.active}.java"/>
<condition property="platform.java" value="${platform.home}/bin/java">
<equals arg1="${platform.java.tmp}" arg2="$${platforms.${platform.active}.java}"/>
</condition>
<property name="platform.java" value="${platform.java.tmp}"/>
<j2seproject1:property name="platform.javadoc.tmp" value="platforms.${platform.active}.javadoc"/>
<condition property="platform.javadoc" value="${platform.home}/bin/javadoc">
<equals arg1="${platform.javadoc.tmp}" arg2="$${platforms.${platform.active}.javadoc}"/>
</condition>
<property name="platform.javadoc" value="${platform.javadoc.tmp}"/>
<condition property="platform.invalid" value="true">
<or>
<contains string="${platform.javac}" substring="$${platforms."/>
<contains string="${platform.java}" substring="$${platforms."/>
<contains string="${platform.javadoc}" substring="$${platforms."/>
</or>
</condition>
<fail unless="platform.home">Must set platform.home</fail>
<fail unless="platform.bootcp">Must set platform.bootcp</fail>
<fail unless="platform.java">Must set platform.java</fail>
<fail unless="platform.javac">Must set platform.javac</fail>
<fail if="platform.invalid">
The J2SE Platform is not correctly set up.
Your active platform is: ${platform.active}, but the corresponding property "platforms.${platform.active}.home" is not found in the project's properties files.
Either open the project in the IDE and setup the Platform with the same name or add it manually.
For example like this:
ant -Duser.properties.file=&lt;path_to_property_file&gt; jar (where you put the property "platforms.${platform.active}.home" in a .properties file)
or ant -Dplatforms.${platform.active}.home=&lt;path_to_JDK_home&gt; jar (where no properties file is used)
</fail>
<available file="${manifest.file}" property="manifest.available"/>
<condition property="manifest.available+main.class">
<and>
Expand Down Expand Up @@ -155,7 +192,7 @@ is divided into following sections:
<attribute default="" name="sourcepath"/>
<element name="customize" optional="true"/>
<sequential>
<javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}">
<javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" executable="${platform.javac}" fork="yes" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">
<classpath>
<path path="@{classpath}"/>
</classpath>
Expand Down Expand Up @@ -198,7 +235,7 @@ is divided into following sections:
<attribute default="${excludes}" name="excludes"/>
<attribute default="**" name="testincludes"/>
<sequential>
<junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true">
<junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" jvm="${platform.java}" showoutput="true">
<batchtest todir="${build.test.results.dir}">
<fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
<filename name="@{testincludes}"/>
Expand Down Expand Up @@ -228,6 +265,9 @@ is divided into following sections:
<classpath>
<path path="@{classpath}"/>
</classpath>
<bootclasspath>
<path path="${platform.bootcp}"/>
</bootclasspath>
</nbjpdastart>
</sequential>
</macrodef>
Expand All @@ -243,7 +283,9 @@ is divided into following sections:
</macrodef>
</target>
<target name="-init-debug-args">
<property name="version-output" value="java version &quot;${ant.java.version}"/>
<exec executable="${platform.java}" outputproperty="version-output">
<arg value="-version"/>
</exec>
<condition property="have-jdk-older-than-1.4">
<or>
<contains string="${version-output}" substring="java version &quot;1.0"/>
Expand All @@ -268,7 +310,7 @@ is divided into following sections:
<attribute default="${debug.classpath}" name="classpath"/>
<element name="customize" optional="true"/>
<sequential>
<java classname="@{classname}" dir="${work.dir}" fork="true">
<java classname="@{classname}" dir="${work.dir}" fork="true" jvm="${platform.java}">
<jvmarg line="${debug-args-line}"/>
<jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>
<jvmarg line="${run.jvmargs}"/>
Expand All @@ -289,7 +331,7 @@ is divided into following sections:
<attribute default="${main.class}" name="classname"/>
<element name="customize" optional="true"/>
<sequential>
<java classname="@{classname}" dir="${work.dir}" fork="true">
<java classname="@{classname}" dir="${work.dir}" fork="true" jvm="${platform.java}">
<jvmarg line="${run.jvmargs}"/>
<classpath>
<path path="${run.classpath}"/>
Expand Down Expand Up @@ -391,7 +433,7 @@ is divided into following sections:
<path path="${run.classpath}"/>
<map from="${build.classes.dir.resolved}" to="${dist.jar.resolved}"/>
</pathconvert>
<echo>java -cp "${run.classpath.with.dist.jar}" ${main.class}</echo>
<echo>${platform.java} -cp "${run.classpath.with.dist.jar}" ${main.class}</echo>
</target>
<target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class+mkdist.available" name="-do-jar-with-libraries">
<property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
Expand All @@ -416,7 +458,7 @@ is divided into following sections:
</copylibs>
<echo>To run this application from the command line without Ant, try:</echo>
<property location="${dist.jar}" name="dist.jar.resolved"/>
<echo>java -jar "${dist.jar.resolved}"</echo>
<echo>${platform.java} -jar "${dist.jar.resolved}"</echo>
</target>
<target name="-post-jar">
<!-- Empty placeholder for easier customization. -->
Expand Down Expand Up @@ -482,7 +524,7 @@ is divided into following sections:
-->
<target depends="init" name="-javadoc-build">
<mkdir dir="${dist.javadoc.dir}"/>
<javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" charset="UTF-8" destdir="${dist.javadoc.dir}" docencoding="UTF-8" encoding="${javadoc.encoding.used}" failonerror="true" noindex="${javadoc.noindex}" nonavbar="${javadoc.nonavbar}" notree="${javadoc.notree}" private="${javadoc.private}" source="${javac.source}" splitindex="${javadoc.splitindex}" use="${javadoc.use}" useexternalfile="true" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}">
<javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" charset="UTF-8" destdir="${dist.javadoc.dir}" docencoding="UTF-8" encoding="${javadoc.encoding.used}" executable="${platform.javadoc}" failonerror="true" noindex="${javadoc.noindex}" nonavbar="${javadoc.nonavbar}" notree="${javadoc.notree}" private="${javadoc.private}" source="${javac.source}" splitindex="${javadoc.splitindex}" use="${javadoc.use}" useexternalfile="true" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}">
<classpath>
<path path="${javac.classpath}"/>
</classpath>
Expand Down
@@ -1,8 +1,8 @@
build.xml.data.CRC32=2b2dc5e6
build.xml.data.CRC32=4a45c297
build.xml.script.CRC32=b5dc8409
build.xml.stylesheet.CRC32=958a1d3e
# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
nbproject/build-impl.xml.data.CRC32=2b2dc5e6
nbproject/build-impl.xml.script.CRC32=7d06fced
nbproject/build-impl.xml.data.CRC32=4a45c297
nbproject/build-impl.xml.script.CRC32=03c5832d
nbproject/build-impl.xml.stylesheet.CRC32=e55b27f5
@@ -1,4 +1,5 @@
application.args=
compile.on.save=false
do.depend=false
do.jar=true
javac.debug=true
Expand Down
Expand Up @@ -22,8 +22,7 @@ excludes=
includes=**
jar.compress=false
javac.classpath=\
${libs.swing-layout.classpath}:\
${libs.beans-binding.classpath}
${libs.swing-layout.classpath}
# Space-separated list of extra javac options
javac.compilerargs=
javac.deprecation=false
Expand All @@ -44,6 +43,12 @@ javadoc.splitindex=true
javadoc.use=true
javadoc.version=false
javadoc.windowtitle=
jnlp.codebase.type=local
jnlp.codebase.url=file:/home/jeichar/dev/project/secureows/src/owsproxyclient/netbeans/owsproxyclient/dist/
jnlp.descriptor=application
jnlp.enabled=false
jnlp.offline-allowed=false
jnlp.signed=false
# Property libs.swing-app-framework.classpath is set here just to make sharing of project simpler.
# The library definition has always preference over this property.
libs.swing-app-framework.classpath=../../../../../../../Applications/netbeans-6.0.1/java1/modules/ext/appframework-1.0.3.jar:../../../../../../../Applications/netbeans-6.0.1/java1/modules/ext/swing-worker-1.1.jar
Expand All @@ -53,7 +58,7 @@ libs.swing-layout.classpath=../../../../../../../Applications/netbeans-6.0.1/pla
main.class=owsproxyclient.Main
manifest.file=manifest.mf
meta.inf.dir=${src.dir}/META-INF
platform.active=default_platform
platform.active=JDK_1.5
run.classpath=\
${javac.classpath}:\
${build.classes.dir}
Expand Down
Expand Up @@ -5,6 +5,7 @@
<data xmlns="http://www.netbeans.org/ns/j2se-project/3">
<name>owsproxyclient</name>
<minimum-ant-version>1.6.5</minimum-ant-version>
<explicit-platform explicit-source-supported="true"/>
<source-roots>
<root id="src.dir"/>
</source-roots>
Expand Down
Expand Up @@ -28,7 +28,7 @@
<Group type="102" alignment="0" attributes="0">
<Component id="jLabel2" min="-2" max="-2" attributes="0"/>
<EmptySpace type="unrelated" max="-2" attributes="0"/>
<Component id="jLabel1" min="-2" max="-2" attributes="0"/>
<Component id="jLabel1" min="-2" pref="271" max="-2" attributes="0"/>
</Group>
<Group type="102" alignment="0" attributes="0">
<EmptySpace min="-2" pref="0" max="-2" attributes="0"/>
Expand All @@ -49,8 +49,8 @@
<Group type="102" alignment="1" attributes="0">
<Group type="103" groupAlignment="0" attributes="0">
<Component id="jLabel2" min="-2" max="-2" attributes="0"/>
<Group type="102" alignment="0" attributes="0">
<EmptySpace min="-2" pref="20" max="-2" attributes="0"/>
<Group type="102" attributes="0">
<EmptySpace min="20" pref="20" max="20" attributes="0"/>
<Component id="jLabel1" min="-2" max="-2" attributes="0"/>
</Group>
</Group>
Expand Down

0 comments on commit f2d0d22

Please sign in to comment.