Project

General

Profile

1
# For Win32, make 'SEP' be a semicolon
2
SEP=:
3
#CPATH=../../xml.jar$(SEP)$(JAVA_HOME)/lib/classes.zip
4
CPATH=/home/httpd/servlets/xsql/lib/xmlparserv2.jar$(SEP)$(ORACLE_HOME)/jdbc/lib/classes111.zip$(SEP)/usr/lib/apache/ApacheJServ.jar$(SEP)/home/httpd/classes/servlet-2.0.jar$(SEP)./classes$(SEP)catalog.jar$(SEP)./classes
5

    
6
USER=jones
7
PW=your-pw-goes-here
8

    
9
JAVAC=javac -d classes
10

    
11
JAVASRC=BasicElement.java \
12
	DBDTDHandler.java \
13
	DBEntityResolver.java \
14
	DBReader.java \
15
	DBSAXDocument.java \
16
	DBSAXElement.java \
17
	DBSAXHandler.java \
18
	DBSAXWriter.java \
19
	DBSimpleQuery.java \
20
	DBTransform.java \
21
	GenericXMLValidate.java \
22
	MetaCatServlet.java \
23
	ReaderElement.java \
24
	XMLValidate.java
25

    
26
default: all
27

    
28
all: orasax reader query servlet xvalid transform
29

    
30
transform:
31
	$(JAVAC) -classpath "$(CPATH)" \
32
		DBTransform.java
33

    
34
xvalid:
35
	$(JAVAC) -classpath "$(CPATH)" \
36
		XMLValidate.java \
37
		GenericXMLValidate.java
38

    
39
orasax: util
40
	$(JAVAC) -classpath "$(CPATH)" \
41
		DBSAXWriter.java \
42
		BasicElement.java \
43
		DBSAXElement.java \
44
		DBSAXHandler.java \
45
		DBEntityResolver.java \
46
		DBDTDHandler.java \
47
		DBSAXDocument.java
48
		
49
sundom:
50
	$(JAVAC) -classpath "$(CPATH)" \
51
		DBWriter.java \
52
		DBElement.java
53
		
54
reader: util
55
	$(JAVAC) -classpath "$(CPATH)" \
56
		DBReader.java \
57
		BasicElement.java \
58
		ReaderElement.java
59

    
60
query: util
61
	$(JAVAC) -classpath "$(CPATH)" \
62
		DBSimpleQuery.java
63

    
64
servlet: query reader orasax xvalid transform
65
	$(JAVAC) -classpath "$(CPATH)" MetaCatServlet.java
66
	cp -r classes/edu /home/httpd/servlets/
67
	cp metacat.properties /home/httpd/servlets/edu/ucsb/nceas/metacat/
68

    
69
util: 
70
	$(JAVAC) -classpath "$(CPATH)" \
71
		MetaCatUtil.java
72

    
73
test:
74
	java -cp $(CPATH) edu.ucsb.nceas.metacat.DBSAXWriter \
75
		test.xml $(USER) $(PW)
76

    
77
test1:
78
	java -cp $(CPATH) edu.ucsb.nceas.metacat.DBSAXWriter \
79
		test.xml $(USER) $(PW) \
80
		jdbc:oracle:thin:@localhost:1521:test
81

    
82
rdtest:
83
	java -cp $(CPATH) edu.ucsb.nceas.metacat.DBReader 1 $(USER) $(PW) 
84

    
85
rdtest1:
86
	java -cp $(CPATH) edu.ucsb.nceas.metacat.DBReader 11 $(USER) $(PW) 
87

    
88
qtest:
89
	java -cp $(CPATH) edu.ucsb.nceas.metacat.DBSimpleQuery \
90
		Value1 $(USER) $(PW) 
91

    
92
qtest1:
93
	java -cp $(CPATH) edu.ucsb.nceas.metacat.DBSimpleQuery \
94
		lakename $(USER) $(PW) 
95

    
96
xvtest:
97
	java -cp $(CPATH) XMLValidate \
98
		test.xml
99

    
100
trantest:
101
	java -cp $(CPATH) edu.ucsb.nceas.metacat.DBTransform \
102
		$(USER) $(PW) 
103

    
104
javadoc:
105
	cp $(JAVASRC) ./classes/edu/ucsb/nceas/metacat
106
	javadoc -classpath $(CPATH) -d docs \
107
		-sourcepath ./classes edu.ucsb.nceas.metacat
108
        #-rm ./classes/edu/ucsb/nceas/metacat/*.java
109

    
110
clean:
111
	-rm -f *.class Log classes/edu/ucsb/nceas/metacat/*.class classes/*.class
(12-12/32)