blob: 014f2b103b9fa75a39a3af95db6a272f2cea7d20 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
|
JAVA_DEPEND = java.dep
## silently try to include these, if it fails gnu make
## will remake these 'makefiles' with the rules given in
## this file and restart the make process again
sinclude $(JAVA_DEPEND)
propertydirs := $(shell cd $(top_srcdir)/resource && $(FIND) gnu java org -type d ! -name CVS -print)
propertyfiles := $(shell cd $(top_srcdir)/resource && $(FIND) gnu java org -name \*\.properties -print)
compile_classpath = $(top_srcdir):$(top_srcdir)/vm/reference:$(top_srcdir)/external/w3c_dom:$(top_srcdir)/external/sax:.:$(USER_CLASSLIB)
# handling source to bytecode compiler programs like gcj, jikes and kjc
if FOUND_GCJ
JAVAC = $(GCJ) --bootclasspath '' --classpath $(compile_classpath) -C -d . @classes.standard \
&& $(GCJ) -Wno-deprecated --bootclasspath '' --classpath $(compile_classpath) -C -d . @classes.awt \
&& $(GCJ) -Wno-deprecated --bootclasspath '' --classpath $(compile_classpath) -C -d . @classes.locale1 \
&& $(GCJ) -Wno-deprecated --bootclasspath '' --classpath $(compile_classpath) -C -d . @classes.locale2 \
&& $(GCJ) -Wno-deprecated --bootclasspath '' --classpath $(compile_classpath) -C -d . @classes.xml \
&& $(GCJ) -Wno-deprecated --bootclasspath '' --classpath $(compile_classpath) -C -d . @classes.standardx
else
if FOUND_JIKES
JAVAC = $(JIKES) +Pno-shadow +F -bootclasspath '' -extdirs '' -sourcepath '' --classpath $(compile_classpath) -d . @classes
else
if FOUND_KJC
JAVAC = $(KJC) -classpath .:$(USER_CLASSLIB) -d . @classes
else
if FOUND_GCJX
JAVAC = $(GCJX) -classpath .:$(USER_CLASSLIB) -d . @classes
endif # FOUND_GCJX
endif # FOUND_KJC
endif # FOUND_GCJ
endif # FOUND_JIKES
JAVAH = $(USER_JAVAH) -jni -classpath .:$(USER_CLASSLIB)
if INSTALL_GLIBJ_ZIP
pkgdata_DATA = glibj.zip
endif # INSTALL_GLIBJ_ZIP
if INSTALL_CLASS_FILES
noinst_DATA = genclasses compile-classes resources
install-data-local: genclasses compile-classes
-$(top_srcdir)/mkinstalldirs $(DESTDIR)$(pkgdatadir)
cp -R gnu $(DESTDIR)$(pkgdatadir)
cp -R java $(DESTDIR)$(pkgdatadir)
cp -R javax $(DESTDIR)$(pkgdatadir)
cp -R org $(DESTDIR)$(pkgdatadir)
# FIXME - should mimic doc/api/Makefile.am instead...
uninstall-local:
rm -rf $(DESTDIR)$(pkgdatadir)/gnu
rm -rf $(DESTDIR)$(pkgdatadir)/java
rm -rf $(DESTDIR)$(pkgdatadir)/javax
rm -rf $(DESTDIR)$(pkgdatadir)/org
endif # INSTALL_CLASS_FILES
.PHONY: genclasses
glibj.zip: classes compile-classes resources
if test "$(ZIP)" != ""; then $(ZIP) -r -D glibj.zip gnu java javax org > /dev/null; fi
resources:
if ! [ -e gnu ]; then mkdir gnu; fi
if ! [ -e gnu/java ]; then mkdir gnu/java; fi
if ! [ -e gnu/java/locale ]; then mkdir gnu/java/locale; fi
@list='$(propertydirs)'; for p in $$list; do \
if ! [ -e $$p ]; then mkdir $$p; fi; \
done
@list='$(propertyfiles)'; for p in $$list; do \
cp $(top_srcdir)/resource/$$p $$p; \
done
touch resources
classes: genclasses
$(top_builddir)/java/util/LocaleData.java: $(top_srcdir)/scripts/generate-locale-list.sh
mkdir -p $(top_builddir)/java/util
$(top_srcdir)/scripts/generate-locale-list.sh > $(top_builddir)/java/util/LocaleData.java
genclasses: gen-classlist.sh standard.omit $(top_builddir)/java/util/LocaleData.java gen-xpath-parser
top_builddir=$(top_builddir) $(SHELL) ./gen-classlist.sh standard
# Only rebuild parsers when explicitly asked to.
if REGEN_PARSERS
gen-xpath-parser: $(top_srcdir)/gnu/xml/xpath/XPathParser.java
$(top_srcdir)/gnu/xml/xpath/XPathParser.java: $(top_srcdir)/gnu/xml/xpath/XPathParser.y
( cd $(top_srcdir)/gnu/xml/xpath; \
$(JAY) XPathParser.y < $(JAY_SKELETON) > XPathParser.java )
else
gen-xpath-parser:
true
endif # REGEN_PARSER
$(JAVA_DEPEND): genclasses
compile-classes: classes $(JAVA_SRCS) Makefile
$(JAVAC)
touch compile-classes
EXTRA_DIST = standard.omit mkcollections.pl.in
CLEANFILES = compile-classes resources classes \
classes.standard classes.awt classes.standardx classes.xml \
classes.locale1 classes.locale2 glibj.zip classes.1 \
$(top_builddir)/java/util/LocaleData.java \
$(JAVA_DEPEND)
clean-local:
-rm -rf gnu
-rm -rf java
-rm -rf javax
-rm -rf org
dist-hook:
mkdir -p $(distdir)
cp -dfR $(top_srcdir)/gnu $(top_srcdir)/java $(top_srcdir)/javax $(top_srcdir)/org $(top_srcdir)/vm $(top_srcdir)/resource $(top_distdir)
# Delete not wanted files.
$(FIND) $(top_distdir)/gnu $(top_distdir)/java $(top_distdir)/javax $(top_distdir)/org $(top_distdir)/vm -name CVS -print | xargs rm -fr
$(FIND) $(top_distdir)/gnu $(top_distdir)/java $(top_distdir)/javax $(top_distdir)/org $(top_distdir)/vm -name .cvsignore -print | xargs rm -f
$(FIND) $(top_distdir)/gnu $(top_distdir)/java $(top_distdir)/javax $(top_distdir)/org $(top_distdir)/vm -name class-dependencies.conf -print | xargs rm -f
rm -f $(top_distdir)/gnu/classpath/Configuration.java
rm -f $(top_distdir)/java/util/LocaleData.java
# Omit files listed in standard.omit.
( cd $(top_distdir)/lib ; cat $(top_builddir)/lib/standard.omit | sed -e 's/\$$//' | sed -e 's/\/\.\*//' | xargs rm -fr )
|