Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Greenplum
Gpdb
提交
178961ad
G
Gpdb
项目概览
Greenplum
/
Gpdb
通知
7
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
Gpdb
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
178961ad
编写于
2月 22, 2002
作者:
D
Dave Cramer
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
now compiles clean with jdk 1.4
上级
2ea01da5
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
234 addition
and
207 deletion
+234
-207
src/interfaces/jdbc/build.xml
src/interfaces/jdbc/build.xml
+234
-207
未找到文件。
src/interfaces/jdbc/build.xml
浏览文件 @
178961ad
<?xml version="1.0"?>
<!--
build file to allow ant (http://jakarta.apache.org/ant/) to be used
to build the PostgreSQL JDBC Driver
$Header: /cvsroot/pgsql/src/interfaces/jdbc/Attic/build.xml,v 1.18 2001/09/23 04:11:14 momjian Exp $
-->
<!DOCTYPE project [
<!ENTITY jarfiles "postgresql.jar,postgresql-examples.jar">
]>
<project
name=
"postgresqlJDBC"
default=
"all"
basedir=
"."
>
<!-- set global properties for this build -->
<property
name=
"srcdir"
value=
"."
/>
<property
name=
"jardir"
value=
"jars"
/>
<property
name=
"builddir"
value=
"build"
/>
<property
name=
"package"
value=
"org/postgresql"
/>
<!--
This is a simpler method than utils.CheckVersion
It defaults to jdbc1, but builds jdbc2 if the java.lang.Byte class is
in the CLASSPATH (ie JDK1.2 or later), and then enterprise if the
javax.sql.DataSource class is present.
Important: This must have the following order: jdbc1, jdbc2, enterprise
-->
<target
name=
"check_versions"
>
<available
property=
"jdk1.2+"
classname=
"java.lang.ThreadLocal"
/>
<available
property=
"jdk1.2e+"
classname=
"javax.sql.DataSource"
/>
<available
property=
"junit"
classname=
"junit.framework.Test"
/>
</target>
<!-- default target -->
<target
name=
"all"
>
<antcall
target=
"jar"
/>
</target>
<!-- create the jar file -->
<target
name=
"jar"
depends=
"compile,examples"
>
<jar
jarfile=
"${jardir}/postgresql.jar"
whenempty=
"fail"
>
<fileset
dir=
"${builddir}"
>
<include
name=
"${package}/**/*.class"
/>
<exclude
name=
"${package}/test/**"
/>
</fileset>
<fileset
dir=
"${srcdir}"
>
<include
name=
"${package}/*.properties"
/>
</fileset>
</jar>
<jar
jarfile=
"${jardir}/postgresql-examples.jar"
whenempty=
"fail"
>
<fileset
dir=
"${builddir}"
>
<include
name=
"example/**/*.class"
/>
</fileset>
<fileset
dir=
"${srcdir}"
>
<include
name=
"example/*.properties"
/>
</fileset>
</jar>
</target>
<!-- This is the core of the driver. It is common for all three versions. -->
<target
name=
"compile"
depends=
"prepare,check_versions,driver"
>
<javac
srcdir=
"${srcdir}"
destdir=
"${builddir}"
>
<include
name=
"${package}/**"
/>
<exclude
name=
"${package}/jdbc1/**"
if=
"jdk1.2+"
/>
<exclude
name=
"${package}/jdbc2/**"
unless=
"jdk1.2+"
/>
<exclude
name=
"${package}/largeobject/PGblob.java"
unless=
"jdk1.2+"
/>
<exclude
name=
"${package}/largeobject/PGclob.java"
unless=
"jdk1.2+"
/>
<exclude
name=
"${package}/PostgresqlDataSource.java"
unless=
"jdk1.2e+"
/>
<exclude
name=
"${package}/xa/**"
unless=
"jdk1.2e+"
/>
<exclude
name=
"${package}/test/**"
unless=
"junit"
/>
</javac>
</target>
<!--
This generates Driver.java from Driver.java.in
It's required for importing the driver version properties
-->
<target
name=
"driver"
depends=
"prepare,check_versions"
>
<!-- determine the edition text -->
<property
name=
"edition"
value=
"JDBC1"
/>
<available
property=
"edition"
value=
"JDBC2"
classname=
"java.lang.ThreadLocal"
/>
<available
property=
"edition"
value=
"JDBC2"
classname=
"java.lang.StrictMath"
/>
<available
property=
"edition"
value=
"JDBC2 Enterprise"
classname=
"javax.sql.DataSource"
/>
<!-- determine the connection class -->
<property
name=
"connectclass"
value=
"org.postgresql.jdbc1.Connection"
/>
<available
property=
"connectclass"
value=
"org.postgresql.jdbc2.Connection"
classname=
"java.lang.ThreadLocal"
/>
<!-- Some defaults -->
<filter
token=
"MAJORVERSION"
value=
"${major}"
/>
<filter
token=
"MINORVERSION"
value=
"${minor}"
/>
<filter
token=
"VERSION"
value=
"PostgreSQL ${fullversion} ${edition}"
/>
<filter
token=
"JDBCCONNECTCLASS"
value=
"${connectclass}"
/>
<filter
token=
"DEF_PGPORT"
value=
"${def_pgport}"
/>
<!-- Put a check for the current version here -->
<!-- now copy and filter the file -->
<copy
file=
"${package}/Driver.java.in"
tofile=
"${package}/Driver.java"
filtering=
"yes"
/>
<echo
message=
"Configured build for the ${edition} edition driver"
/>
</target>
<!-- Prepares the build directory -->
<target
name=
"prepare"
>
<mkdir
dir=
"${builddir}"
/>
<mkdir
dir=
"${jardir}"
/>
</target>
<!-- This builds the examples -->
<target
name=
"examples"
depends=
"compile"
>
<javac
srcdir=
"${srcdir}"
destdir=
"${builddir}"
>
<include
name=
"example/**"
/>
<exclude
name=
"example/corba/**"
/>
<exclude
name=
"example/blobtest.java"
unless=
"jdk1.2+"
/>
</javac>
</target>
<!-- Builds the corba example -->
<target
name=
"corba"
if=
"jdk1.2+"
>
<exec
dir=
"${srcdir}/example/corba"
executable=
"idl2java"
>
<arg
value=
"stock.idl"
/>
</exec>
<javac
srcdir=
"${srcdir}"
destdir=
"${builddir}"
>
<include
name=
"example/corba/**"
/>
</javac>
</target>
<!-- Install the jar files -->
<target
name=
"install"
depends=
"all"
if=
"install.directory"
>
<copy
todir=
"${install.directory}"
overwrite=
"true"
>
<fileset
dir=
"${jardir}"
includes=
"&jarfiles;"
/>
</copy>
</target>
<!-- Uninstall the jar file -->
<target
name=
"uninstall"
if=
"install.directory"
>
<delete>
<fileset
dir=
"${install.directory}"
includes=
"&jarfiles;"
/>
</delete>
</target>
<!-- This target removes any class files from the build directory -->
<target
name=
"clean"
>
<delete
quiet=
"true"
dir=
"${builddir}"
/>
<delete
quiet=
"true"
dir=
"${jardir}"
/>
<delete
quiet=
"true"
file=
"${package}/Driver.java"
/>
</target>
<!-- This compiles and executes the JUnit tests -->
<!-- defaults for the tests - override these if required -->
<property
name=
"database"
value=
"jdbc:postgresql:test"
/>
<property
name=
"username"
value=
"test"
/>
<!-- Password must be something. Doesn't matter if trust is used! -->
<property
name=
"password"
value=
"password"
/>
<!-- junit.ui is one of textui, awtui, or swingui -->
<property
name=
"junit.ui"
value=
"textui"
/>
<target
name=
"test"
depends=
"jar"
if=
"junit"
>
<javac
srcdir=
"${srcdir}"
destdir=
"${builddir}"
>
<include
name=
"${package}/test/jdbc2/**"
if=
"jdk1.2+"
/>
<include
name=
"${package}/test/java2ee/**"
if=
"jdk1.2e+"
/>
</javac>
<java
fork=
"yes"
classname=
"junit.${junit.ui}.TestRunner"
taskname=
"junit"
failonerror=
"true"
>
<arg
value=
"org.postgresql.test.JDBC2Tests"
/>
<sysproperty
key=
"database"
value=
"${database}"
/>
<sysproperty
key=
"username"
value=
"${username}"
/>
<sysproperty
key=
"password"
value=
"${password}"
/>
<classpath>
<pathelement
location=
"${builddir}"
/>
<pathelement
path=
"${java.class.path}"
/>
</classpath>
</java>
</target>
</project>
<?xml version="1.0"?>
<!--
build file to allow ant (http://jakarta.apache.org/ant/) to be used
to build the PostgreSQL JDBC Driver
$Header: /cvsroot/pgsql/src/interfaces/jdbc/Attic/build.xml,v 1.19 2002/02/22 02:07:30 davec Exp $
-->
<!DOCTYPE project [
<!ENTITY jarfiles "postgresql.jar,postgresql-examples.jar">
]>
<project
name=
"postgresqlJDBC"
default=
"all"
basedir=
"."
>
<!-- set global properties for this build -->
<property
name=
"srcdir"
value=
"."
/>
<property
name=
"jardir"
value=
"jars"
/>
<property
name=
"builddir"
value=
"build"
/>
<property
name=
"package"
value=
"org/postgresql"
/>
<property
name=
"debug"
value=
"yes"
/>
<!--
This is a simpler method than utils.CheckVersion
It defaults to jdbc1, but builds jdbc2 if the java.lang.Byte class is
in the CLASSPATH (ie JDK1.2 or later), and then enterprise if the
javax.sql.DataSource class is present.
Important: This must have the following order: jdbc1, jdbc2, enterprise
-->
<target
name=
"check_versions"
>
<condition
property=
"jdbc1"
>
<equals
arg1=
"${ant.java.version}"
arg2=
"1.1"
/>
</condition>
<condition
property=
"jdbc2"
>
<or>
<equals
arg1=
"${ant.java.version}"
arg2=
"1.2"
/>
<equals
arg1=
"${ant.java.version}"
arg2=
"1.3"
/>
</or>
</condition>
<condition
property=
"jdbc3"
>
<equals
arg1=
"${ant.java.version}"
arg2=
"1.4"
/>
</condition>
<condition
property=
"datasource"
>
<and>
<equals
arg1=
"${jdbc2}"
arg2=
"true"
/>
<available
classname=
"javax.sql.DataSource"
/>
</and>
</condition>
<available
property=
"junit"
classname=
"junit.framework.Test"
/>
</target>
<!-- default target -->
<target
name=
"all"
>
<antcall
target=
"jar"
/>
</target>
<!-- create the jar file -->
<target
name=
"jar"
depends=
"compile,examples"
>
<jar
jarfile=
"${jardir}/postgresql.jar"
whenempty=
"fail"
>
<fileset
dir=
"${builddir}"
>
<include
name=
"${package}/**/*.class"
/>
<exclude
name=
"${package}/test/**"
/>
</fileset>
<fileset
dir=
"${srcdir}"
>
<include
name=
"${package}/*.properties"
/>
</fileset>
</jar>
<jar
jarfile=
"${jardir}/postgresql-examples.jar"
whenempty=
"fail"
>
<fileset
dir=
"${builddir}"
>
<include
name=
"example/**/*.class"
/>
</fileset>
<fileset
dir=
"${srcdir}"
>
<include
name=
"example/*.properties"
/>
</fileset>
</jar>
</target>
<!-- This is the core of the driver. It is common for all three versions. -->
<target
name=
"compile"
depends=
"prepare,check_versions,driver"
>
<javac
srcdir=
"${srcdir}"
destdir=
"${builddir}"
debug=
"${debug}"
>
<include
name=
"${package}/**"
/>
<exclude
name=
"${package}/jdbc1/**"
unless=
"jdbc1"
/>
<exclude
name=
"${package}/jdbc2/**"
unless=
"jdbc2"
/>
<exclude
name=
"${package}/largeobject/PGblob.java"
unless=
"jdbc2"
/>
<exclude
name=
"${package}/largeobject/PGclob.java"
unless=
"jdbc2"
/>
<exclude
name=
"${package}/PostgresqlDataSource.java"
unless=
"datasource"
/>
<exclude
name=
"${package}/xa/**"
unless=
"datasource"
/>
<exclude
name=
"${package}/test/**"
unless=
"junit"
/>
</javac>
</target>
<!--
This generates Driver.java from Driver.java.in
It's required for importing the driver version properties
-->
<target
name=
"driver"
depends=
"prepare,check_versions"
>
<!-- determine the edition text -->
<property
name=
"edition"
value=
"JDBC1"
/>
<condition
property=
"edition"
value=
"JDBC2"
>
<or>
<equals
arg1=
"${jdbc2}"
arg2=
"true"
/>
<equals
arg1=
"${jdbc3}"
arg2=
"true"
/>
<!-- fake it for now -->
</or>
</condition>
<condition
property=
"edition"
value=
"JDBC2 Enterprise"
>
<and>
<available
classname=
"javax.sql.DataSource"
/>
<equals
arg1=
"${jdbc2}"
arg2=
"true"
/>
</and>
</condition>
<!-- determine the connection class -->
<property
name=
"connectclass"
value=
"org.postgresql.jdbc1.Connection"
/>
<available
property=
"connectclass"
value=
"org.postgresql.jdbc2.Connection"
classname=
"java.lang.ThreadLocal"
/>
<!-- Some defaults -->
<filter
token=
"MAJORVERSION"
value=
"${major}"
/>
<filter
token=
"MINORVERSION"
value=
"${minor}"
/>
<filter
token=
"VERSION"
value=
"PostgreSQL ${fullversion} ${edition}"
/>
<filter
token=
"JDBCCONNECTCLASS"
value=
"${connectclass}"
/>
<filter
token=
"DEF_PGPORT"
value=
"${def_pgport}"
/>
<!-- Put a check for the current version here -->
<!-- now copy and filter the file -->
<copy
file=
"${package}/Driver.java.in"
tofile=
"${package}/Driver.java"
filtering=
"yes"
/>
<echo
message=
"Configured build for the ${edition} edition driver"
/>
</target>
<!-- Prepares the build directory -->
<target
name=
"prepare"
>
<mkdir
dir=
"${builddir}"
/>
<mkdir
dir=
"${jardir}"
/>
</target>
<!-- This builds the examples -->
<target
name=
"examples"
depends=
"compile"
>
<javac
srcdir=
"${srcdir}"
destdir=
"${builddir}"
>
<include
name=
"example/**"
/>
<exclude
name=
"example/corba/**"
/>
<exclude
name=
"example/blobtest.java"
unless=
"jdk1.2+"
/>
</javac>
</target>
<!-- Builds the corba example -->
<target
name=
"corba"
if=
"jdk1.2+"
>
<exec
dir=
"${srcdir}/example/corba"
executable=
"idl2java"
>
<arg
value=
"stock.idl"
/>
</exec>
<javac
srcdir=
"${srcdir}"
destdir=
"${builddir}"
>
<include
name=
"example/corba/**"
/>
</javac>
</target>
<!-- Install the jar files -->
<target
name=
"install"
depends=
"all"
if=
"install.directory"
>
<copy
todir=
"${install.directory}"
overwrite=
"true"
>
<fileset
dir=
"${jardir}"
includes=
"&jarfiles;"
/>
</copy>
</target>
<!-- Uninstall the jar file -->
<target
name=
"uninstall"
if=
"install.directory"
>
<delete>
<fileset
dir=
"${install.directory}"
includes=
"&jarfiles;"
/>
</delete>
</target>
<!-- This target removes any class files from the build directory -->
<target
name=
"clean"
>
<delete
quiet=
"true"
dir=
"${builddir}"
/>
<delete
quiet=
"true"
dir=
"${jardir}"
/>
<delete
quiet=
"true"
file=
"${package}/Driver.java"
/>
</target>
<!-- This compiles and executes the JUnit tests -->
<!-- defaults for the tests - override these if required -->
<property
name=
"database"
value=
"jdbc:postgresql:test"
/>
<property
name=
"username"
value=
"test"
/>
<!-- Password must be something. Doesn't matter if trust is used! -->
<property
name=
"password"
value=
"password"
/>
<!-- junit.ui is one of textui, awtui, or swingui -->
<property
name=
"junit.ui"
value=
"textui"
/>
<target
name=
"test"
depends=
"jar"
if=
"junit"
>
<javac
srcdir=
"${srcdir}"
destdir=
"${builddir}"
>
<include
name=
"${package}/test/jdbc2/**"
if=
"jdk1.2+"
/>
<include
name=
"${package}/test/java2ee/**"
if=
"jdk1.2e+"
/>
</javac>
<java
fork=
"yes"
classname=
"junit.${junit.ui}.TestRunner"
taskname=
"junit"
failonerror=
"true"
>
<arg
value=
"org.postgresql.test.JDBC2Tests"
/>
<sysproperty
key=
"database"
value=
"${database}"
/>
<sysproperty
key=
"username"
value=
"${username}"
/>
<sysproperty
key=
"password"
value=
"${password}"
/>
<classpath>
<pathelement
location=
"${builddir}"
/>
<pathelement
path=
"${java.class.path}"
/>
</classpath>
</java>
</target>
</project>
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录