44# Makefile for Java JDBC interface
55#
66# IDENTIFICATION
7- # $Header: /cvsroot/pgsql/src/interfaces/jdbc/Attic/Makefile,v 1.2 1997/09/29 20:11:42 scrappy Exp $
7+ # $Header: /cvsroot/pgsql/src/interfaces/jdbc/Attic/Makefile,v 1.3 1998/01/11 21:14:29 scrappy Exp $
88#
99# -------------------------------------------------------------------------
1010
@@ -22,41 +22,70 @@ RM= rm -f
2222$(JAVAC ) $<
2323
2424.SUFFIXES :.class .java
25- .PHONY :all clean doc
25+ .PHONY :all clean doc examples
2626
2727all : postgresql.jar
28+ @echo ------------------------------------------------------------
29+ @echo The JDBC driver has now been built. To make it available to
30+ @echo other applications, copy the postgresql.jar file to a public
31+ @echo" place (under unix this could be /usr/local/lib) and add it"
32+ @echo to the class path.
33+ @echo
34+ @echo Then either add -Djdbc.drivers=postgresql.Driver to the
35+ @echo commandline when running your application, or edit the
36+ @echo" properties file (~/.hotjava/properties under unix), and"
37+ @echo add a line containing jdbc.drivers=postgresql.Driver
38+ @echo
39+ @echo More details arein the README file.
40+ @echo ------------------------------------------------------------
41+ @echo To build the examples, type:
42+ @echo" make examples"
43+ @echo ------------------------------------------------------------
44+ @echo
2845
46+ # This rule builds the javadoc documentation
2947doc :
30- $(JAVADOC ) -public postgresql
48+ export CLASSPATH=.; \
49+ $(JAVADOC ) -public\
50+ postgresql\
51+ postgresql.fastpath\
52+ postgresql.largeobject
3153
54+ # These classes form the driver. These, and only these are placed into
55+ # the jar file.
3256OBJS =postgresql/CallableStatement.class\
3357postgresql/Connection.class\
3458postgresql/DatabaseMetaData.class\
3559postgresql/Driver.class\
3660postgresql/Field.class\
37- postgresql/PG_Object.class\
3861postgresql/PG_Stream.class\
39- postgresql/PGbox.class\
40- postgresql/PGcircle.class\
41- postgresql/PGlobj.class\
42- postgresql/PGlseg.class\
43- postgresql/PGpath.class\
44- postgresql/PGpoint.class\
45- postgresql/PGpolygon.class\
46- postgresql/PGtokenizer.class\
4762postgresql/PreparedStatement.class\
4863postgresql/ResultSet.class\
4964postgresql/ResultSetMetaData.class\
50- postgresql/Statement.class
65+ postgresql/Statement.class\
66+ postgresql/fastpath/Fastpath.class\
67+ postgresql/fastpath/FastpathArg.class\
68+ postgresql/geometric/PGbox.class\
69+ postgresql/geometric/PGcircle.class\
70+ postgresql/geometric/PGlseg.class\
71+ postgresql/geometric/PGpath.class\
72+ postgresql/geometric/PGpoint.class\
73+ postgresql/geometric/PGpolygon.class\
74+ postgresql/largeobject/LargeObject.class\
75+ postgresql/largeobject/LargeObjectManager.class\
76+ postgresql/util/PGobject.class\
77+ postgresql/util/PGtokenizer.class
5178
5279postgresql.jar :$(OBJS )
53- $(JAR ) -c0vf$@ $^
80+ $(JAR ) -c0vf$@ $$( $( FIND ) postgresql -name "*.class" -print)
5481
5582# This rule removes any temporary and compiled files from the source tree.
5683clean :
5784$(FIND ) . -name" *~" -exec$(RM ) {}\;
5885$(FIND ) . -name" *.class" -exec$(RM ) {}\;
86+ $(FIND ) . -name" *.html" -exec$(RM ) {}\;
5987$(RM ) postgresql.jar
88+ -$(RM ) -rf Package-postgresql* output
6089
6190# ######################################################################
6291# This helps make workout what classes are from what source files
@@ -69,21 +98,56 @@ postgresql/Connection.class:postgresql/Connection.java
6998postgresql/DatabaseMetaData.class :postgresql/DatabaseMetaData.java
7099postgresql/Driver.class :postgresql/Driver.java
71100postgresql/Field.class :postgresql/Field.java
72- postgresql/PG_Object.class :postgresql/PG_Object.java
73101postgresql/PG_Stream.class :postgresql/PG_Stream.java
74- postgresql/PGbox.class :postgresql/PGbox.java
75- postgresql/PGcircle.class :postgresql/PGcircle.java
76- postgresql/PGlobj.class :postgresql/PGlobj.java
77- postgresql/PGlseg.class :postgresql/PGlseg.java
78- postgresql/PGpath.class :postgresql/PGpath.java
79- postgresql/PGpoint.class :postgresql/PGpoint.java
80- postgresql/PGpolygon.class :postgresql/PGpolygon.java
81- postgresql/PGtokenizer.class :postgresql/PGtokenizer.java
82102postgresql/PreparedStatement.class :postgresql/PreparedStatement.java
83103postgresql/ResultSet.class :postgresql/ResultSet.java
84104postgresql/ResultSetMetaData.class :postgresql/ResultSetMetaData.java
85105postgresql/Statement.class :postgresql/Statement.java
106+ postgresql/fastpath/Fastpath.class :postgresql/fastpath/Fastpath.java
107+ postgresql/fastpath/FastpathArg.class :postgresql/fastpath/FastpathArg.java
108+ postgresql/geometric/PGbox.class :postgresql/geometric/PGbox.java
109+ postgresql/geometric/PGcircle.class :postgresql/geometric/PGcircle.java
110+ postgresql/geometric/PGlseg.class :postgresql/geometric/PGlseg.java
111+ postgresql/geometric/PGpath.class :postgresql/geometric/PGpath.java
112+ postgresql/geometric/PGpoint.class :postgresql/geometric/PGpoint.java
113+ postgresql/geometric/PGpolygon.class :postgresql/geometric/PGpolygon.java
114+ postgresql/largeobject/LargeObject.class : postgresql/largeobject/LargeObject.java
115+ postgresql/largeobject/LargeObjectManager.class : postgresql/largeobject/LargeObjectManager.java
116+ postgresql/util/PGobject.class :postgresql/util/PGobject.java
117+ postgresql/util/PGtokenizer.class :postgresql/util/PGtokenizer.java
86118
119+ # ######################################################################
120+ # These classes are in the example directory, and form the examples
121+ EX =example/basic.class\
122+ example/blobtest.class\
123+ example/datestyle.class\
124+ example/psql.class\
125+ example/ImageViewer.class
87126
127+ # This rule builds the examples
128+ examples :postgresql.jar$(EX )
129+ @echo ------------------------------------------------------------
130+ @echo The examples have been built.
131+ @echo
132+ @echo For instructions on how to use them, simply run them. For example:
133+ @echo
134+ @echo" java example.blobtest"
135+ @echo
136+ @echo This would display instructions on how to run the example.
137+ @echo ------------------------------------------------------------
138+ @echo Available examples:
139+ @echo
140+ @echo" example.basic Basic JDBC useage"
141+ @echo" example.blobtest Binary Large Object tests"
142+ @echo" example.datestyle Shows how datestyles are handled"
143+ @echo" example.ImageViewer Example application storing images"
144+ @echo" example.psql Simple java implementation of psql"
145+ @echo ------------------------------------------------------------
146+ @echo
88147
89-
148+ example/basic.class :example/basic.java
149+ example/blobtest.class :example/blobtest.java
150+ example/datestyle.class :example/datestyle.java
151+ example/psql.class :example/psql.java
152+ example/ImageViewer.class :example/ImageViewer.java
153+ # ######################################################################