Never mind, I figured it out.
Ant's build.xml (src/interfaces/jdbc/build.xml) decides whether
to build the 'enterprise' version of postgresql.jar by
checking whether the class javax.sql.DataSource is present.
The solution is to install the J2EE SDK, then make sure
j2ee.jar is in the classpath when ant builds the JDBC driver.
Example, my build script for all of PostgreSQL is now:
CC=gcc CXX=g++ CFLAGS=-O2 CXXFLAGS=-O2 \
make -j 2
Larry Mulcahy wrote:
> Referring back to
> I tried to use [org.]postgresql.PostgresqlDataSource
> but could not find it in
> /usr/local/pgsql/share/java/postgresql.jar, created
> today by compiling PostgreSQL 7.1.1 from the sources.
> When I list postgresql.jar with
> jar tvf /usr/local/pgsql/share/java/postgresql.jar,
> it has the other classes that are supposed to be
> under org.postgresql:
> 12171 Tue May 08 15:48:50 MDT 2001 org/postgresql/Connection.class
> 4332 Tue May 08 15:48:50 MDT 2001 org/postgresql/PG_Stream.class
> 4204 Tue May 08 15:48:50 MDT 2001 org/postgresql/Driver.class
> 2836 Tue May 08 15:48:50 MDT 2001 org/postgresql/Field.class
> 2440 Tue May 08 15:48:50 MDT 2001 org/postgresql/ResultSet.class
> 347 Tue May 08 15:48:52 MDT 2001 org/postgresql/Statement.class
> but not PostgresqlDataSource.
> I can see PostgresqlDataSource.java
> sitting there in src/interfaces/jdbc/org/postgresql,
> but it's not being compiled and finding its way into the
> .jar file.
> I see in postgresql-7.1.1/src/interfaces/jdbc/Implementation
> this provocative hint:
> Exists in the Java2 Enterprise edition driver only and
> is the
> enterprise equivalent to Driver
> What do I need to do to get the DataSource class? Build
> with some J2EE stuff?
Larry Mulcahy [EMAIL PROTECTED]
PGP public key at:
---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])