12 Star 17 Fork 6

Solo / SocketProxy

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
build.xml 6.82 KB
一键复制 编辑 原始数据 按行查看 历史
Solo 提交于 2014-08-23 17:25 . init
<?xml version="1.0" encoding="utf-8"?>
<!--
! This is the ANT build file for JSocksProxy
!
! JSocksProxy Copyright (c) 2006-2008 Kenny Colliander Nordin
!
! Licensed under the Apache License, Version 2.0 (the "License");
! you may not use this file except in compliance with the License.
! You may obtain a copy of the License at
!
! http://www.apache.org/licenses/LICENSE-2.0
!
! Unless required by applicable law or agreed to in writing, software
! distributed under the License is distributed on an "AS IS" BASIS,
! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
! See the License for the specific language governing permissions and
! limitations under the License.
-->
<project name="JSocksProxy" default="usage">
<property file="build.properties" />
<description>JSocksProxy build file</description>
<!-- Set global properties for this build -->
<property name="src" location="src/main/java" />
<property name="binDir" location="bin" />
<property name="libDir" location="lib" />
<property name="docDir" location="doc" />
<property name="sarDir" location="sar" />
<property name="javadocDir" location="javadoc" />
<property name="distDir" location="dist" />
<property name="distConfDir" location="${distDir}/conf" />
<property name="distLibDir" location="${distDir}/lib" />
<property name="distOutput" location="${distDir}/jsocksproxy.zip" />
<property name="distSarOutput" location="${distDir}/jsocksproxy.sar" />
<property name="confDir" location="conf" />
<property name="jsocksproxyXml" location="${confDir}/jsocksproxy.xml" />
<property name="jarFile" location="${libDir}/jsocksproxy.jar" />
<!-- BUILD ALL TARGET -->
<target name="buildAll" depends="compile,jar" description="Compiles and builds the application" />
<!-- CLEAN TARGET -->
<target name="clean" description="Remove all compiled and dist files">
<delete dir="${binDir}" failonerror="false" />
<delete dir="${distDir}" failonerror="false" />
<delete dir="${javadocDir}" failonerror="false" />
<delete dir="${distSarOutput}" failonerror="false" />
<delete file="${sarDir}/jsocksproxy.jar" failonerror="false"/>
</target>
<!-- COMPILE TARGET-->
<target name="compile" description="Compile the source">
<mkdir dir="${binDir}" />
<!-- Setup classpath -->
<path id="class.path">
<pathelement path="${java.class.path}/" />
</path>
<!-- Compile the java code -->
<javac srcdir="${src}" destdir="${binDir}" debug="${app.debug}" target="1.6" source="1.6" includeantruntime="true">
<classpath refid="class.path" />
</javac>
</target>
<!-- JAR TARGET -->
<target name="jar" description="Make jar file from compiled binaries">
<mkdir dir="${libDir}" />
<!-- Create the time stamp -->
<tstamp>
<format property="jarTime" pattern="yyyy-MM-dd HH:mm" />
</tstamp>
<!-- Make .jar and place in dist lib. This is to enable the use of the methods in
java.lang.Package, such as getImplementationVersion() -->
<jar jarfile="${jarFile}" excludes="**/CVS/**">
<fileset dir="${binDir}" />
<fileset dir="${src}" includes="**/*.properties" />
<manifest>
<attribute name="Built-By" value="${user.name}" />
<attribute name="Compiled-With" value="${java.version}" />
<attribute name="Build-Date" value="${jarTime}" />
<attribute name="Implementation-Title" value="JSocksProxy" />
<attribute name="Implementation-Version" value="${app.version}-${DSTAMP}${TSTAMP}" />
<attribute name="Implementation-Vendor" value="Kenny Colliander Nordin, kecon.najt.nu" />
<attribute name="Implementation-URL" value="http://kecon.najt.nu/jsocksproxy/" />
<attribute name="Main-Class" value="nu.najt.kecon.jsocksproxy.admin.JSocksProxyAdmin" />
</manifest>
</jar>
</target>
<!-- MAKE DIST TARGET -->
<target name="dist" depends="compile,jar" description="Builds a zip package">
<mkdir dir="${distDir}" />
<mkdir dir="${distLibDir}" />
<mkdir dir="${distConfDir}" />
<mkdir dir="${distConfDir}/example" />
<delete file="${distOutput}" failonerror="false" />
<delete file="${distSarOutput}" failonerror="false" />
<copy tofile="${distConfDir}/example/jsocksproxy.xml" file="${jsocksproxyXml}" overwrite="true" preservelastmodified="true" />
<copy tofile="${distDir}/run.bat" file="${confDir}/run.bat" overwrite="true" preservelastmodified="true" />
<copy tofile="${distDir}/LICENSE-2.0.txt" file="${docDir}/LICENSE-2.0.txt" overwrite="true" preservelastmodified="true" />
<copy tofile="${distLibDir}/jsocksproxy.jar" file="${jarFile}" overwrite="true" preservelastmodified="true" />
<zip destfile="${distOutput}" basedir="${distDir}" />
<!-- Create .sar -->
<copy tofile="${sarDir}/jsocksproxy.jar" file="${jarFile}" overwrite="true" preservelastmodified="true" />
<!-- Make .sar and place in dist. This is to enable the use of the methods in
java.lang.Package, such as getImplementationVersion() -->
<jar jarfile="${distSarOutput}" excludes="**/CVS/**">
<fileset dir="${sarDir}" />
<manifest>
<attribute name="Built-By" value="${user.name}" />
<attribute name="Compiled-With" value="${java.version}" />
<attribute name="Build-Date" value="${jarTime}" />
<attribute name="Implementation-Title" value="JSocksProxy" />
<attribute name="Implementation-Version" value="${app.version}-${DSTAMP}${TSTAMP}" />
<attribute name="Implementation-Vendor" value="Kenny Colliander Nordin, kecon.najt.nu" />
<attribute name="Implementation-URL" value="http://kecon.najt.nu/jsocksproxy/" />
</manifest>
</jar>
</target>
<target name="javadoc" description="Make javadoc" depends="compile">
<javadoc destdir="${javadocDir}" sourcepath="${src}" doctitle="JSocksProxy ${app.version}" windowtitle="JSocksProxy ${app.version}">
<classpath refid="class.path" />
<package name="nu.najt.kecon.jsocksproxy" />
<package name="nu.najt.kecon.jsocksproxy.configuration" />
<package name="nu.najt.kecon.jsocksproxy.admin" />
<package name="nu.najt.kecon.jsocksproxy.socks4" />
<package name="nu.najt.kecon.jsocksproxy.socks5" />
</javadoc>
</target>
<!-- PRINT USAGE TARGET -->
<target name="usage">
<echo message="" />
<echo message="JSocksProxy build file" />
<echo message="-----------------------------------" />
<echo message="" />
<echo message="Available targets are:" />
<echo message="" />
<echo message="buildAll --> Compiles and make jar" />
<echo message="compile --> Compiles" />
<echo message="jar --> Make jar" />
<echo message="dist --> Compiles, make jar, zip and sar" />
<echo message="javadoc --> Compiles make javadoc" />
<echo message="clean --> Remove all compiled an dist files" />
<echo message="" />
</target>
</project>
Java
1
https://gitee.com/geliang/SocketProxy.git
git@gitee.com:geliang/SocketProxy.git
geliang
SocketProxy
SocketProxy
master

搜索帮助