File: Makefile.am

package info (click to toggle)
libgconf-java 2.12.3-1
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 1,644 kB
  • ctags: 422
  • sloc: sh: 8,553; ansic: 1,172; java: 971; makefile: 147
file content (179 lines) | stat: -rw-r--r-- 5,089 bytes parent folder | download
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
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
AUTOMAKE_OPTIONS = subdir-objects

CLEANFILES =
BUILT_SOURCES =
CLASSPATH = $(JGJAR):$(GTKJAR)

# Force all the .class files to be built very early in the process --
# in particular before any attempt to generate .h files from those
# classes

BUILT_SOURCES += gconf$(apiversion).jar

if BUILD_GCJ
lib_LTLIBRARIES = libgconfjava.la libgconfjni.la
else
lib_LTLIBRARIES = libgconfjni.la
endif

java_gconf_source_files = \
	src/java/org/gnu/gconf/Config.java \
	src/java/org/gnu/gconf/ConfClient.java \
	src/java/org/gnu/gconf/ConfClientListener.java \
	src/java/org/gnu/gconf/ConfClientPreloadType.java \
	src/java/org/gnu/gconf/ConfEntry.java \
	src/java/org/gnu/gconf/ConfException.java \
	src/java/org/gnu/gconf/ConfMetaInfo.java \
	src/java/org/gnu/gconf/ConfSchema.java \
	src/java/org/gnu/gconf/ConfValue.java \
	src/java/org/gnu/gconf/ConfValueType.java 

jni_gconf_source_files =
include Makefile.jni

examples = gconf

example_files = \
	doc/examples/gconf/BasicGConfApp.java \
	doc/examples/runExample.sh.in


if BUILD_GCJ
libgconfjava_la_SOURCES = $(java_gconf_source_files)
libgconfjava_la_GCJFLAGS = -fjni -I$(srcdir)/src/java -Isrc/java --classpath=$(CLASSPATH):$(srcdir)/src/java
libgconfjava_la_LDFLAGS = $(JGJAVA_LIBS) $(GTKJAVA_LIBS) -release $(apiversion)
endif

libgconfjni_la_SOURCES = $(jni_gconf_source_files)
AM_CFLAGS = $(GCONF_CFLAGS) $(JGJAVA_CFLAGS) $(GTKJAVA_CFLAGS) $(JNI_INCLUDES) -I$(includedir)
libgconfjni_la_LDFLAGS = $(GCONF_LIBS) $(JGJNI_LIBS) $(GTKJNI_LIBS) -release $(apiversion)

# automake should support generating versioned jars
gconf_jardir = $(jardir)
gconf_jar_DATA = gconf$(apiversion).jar

gconf_jar_class_files = $(java_gconf_source_files:.java=.class)

$(gconf_jar_class_files): %.class: %.java
	$(JAVAC) -classpath $(CLASSPATH):$(srcdir)/src/java:src/java -d src/java $<

# all_gconf_jar_class_files includes inner-class generated .class files
# the sed command protects dollar signs in file names from shell expansion
all_gconf_jar_class_files = $(shell find src/java -name '*.class' | sed 's%\$$%\\$$%g')

gconf$(apiversion).jar: $(gconf_jar_class_files)
	$(JAR) cf $@ $(patsubst src/java/%.class,-C src/java %.class,$(all_gconf_jar_class_files))

# install pkg-config file
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = gconf-java.pc

# install examples script
exampledir = $(datadir)/doc/libgconf-java-$(VERSION)/examples
example_SCRIPTS = doc/examples/runExample.sh
example_DATA = doc/examples/runExample.sh

# build api docs
apidir = $(datadir)/doc/libgconf-java-$(VERSION)/api

if BUILD_JAVADOC
all-local: $(top_builddir)/doc-stamp
else
all-local:
endif

if BUILD_JAVADOC
doc-stamp: $(java_gconf_source_files)
	$(JAVADOC) \
		-d doc/api \
		$(JAVADOC_OPTIONS) \
		-sourcepath $(srcdir)/src/java \
		-windowtitle "Java-Gnome $(VERSION) API Reference" \
		-doctitle "Java-Gnome $(VERSION) API Reference" \
		-footer "$(JAVADOC_FOOTER)" \
		-public \
		-classpath $(CLASSPATH):$(srcdir)/src/java:src/java \
		org.gnu.gconf
	touch doc-stamp
endif

# install other docs
docdir = $(datadir)/doc/libgconf-java-$(VERSION)
doc_DATA = $(srcdir)/AUTHORS $(srcdir)/COPYING \
	$(srcdir)/NEWS $(srcdir)/README 

all_dest_gconf_javadoc_html_files = $(patsubst doc/api/%,%,$(shell find doc/api -type f))
dest_gconf_javadoc_dirs = $(patsubst doc/api/%,%,$(shell find doc/api -mindepth 1 -type d))

install-data-hook:
	cd $(DESTDIR)$(jardir) && \
		mv -f gconf$(apiversion).jar gconf$(apiversion)-$(VERSION).jar && \
		$(LN_S) gconf$(apiversion)-$(VERSION).jar gconf$(apiversion).jar

# install api documentation
if BUILD_JAVADOC
	$(mkinstalldirs) $(DESTDIR)$(apidir)
	@for dir in $(dest_gconf_javadoc_dirs); \
	do \
	   $(mkinstalldirs) $(DESTDIR)$(apidir)/$${dir}; \
	done
	@for file in $(all_dest_gconf_javadoc_html_files); \
	do \
	   $(INSTALL_DATA) doc/api/$${file} $(DESTDIR)$(apidir)/$${file}; \
	done
endif

# install examples
	@for dir in $(examples); \
	do \
	   $(mkinstalldirs) $(DESTDIR)$(exampledir)/$${dir}; \
	done
	@for file in $(example_files); \
	do \
	   $(INSTALL_DATA) $(srcdir)/$${file} $(DESTDIR)$(exampledir)/`echo $${file} | \
	      sed 's%^doc/examples/%%'`; \
	done

uninstall-local:
	-rm -rf $(DESTDIR)$(datadir)/doc/libgconf-java-$(VERSION)
	-rm -f $(DESTDIR)$(gconf_jardir)/gconf$(apiversion)-$(VERSION).jar

BUILT_SOURCES += \
	gconf-java.pc \
	doc/examples/runExample.sh \
	src/java/org/gnu/gconf/Config.java

EXTRA_DIST = \
	src/java/org/gnu/gconf/Config.java.in \
	$(example_files) 

clean-local:
	-rm -rf doc/api

distclean-local:
	-rm -rf $(srcdir)/autom4te.cache

DISTCLEANFILES = \
	gconf-java.pc \
	$(srcdir)/Makefile.in \
	$(srcdir)/aclocal.m4 \
	$(srcdir)/compile \
	$(srcdir)/config.guess \
	$(srcdir)/config.sub \
	$(srcdir)/configure \
	$(srcdir)/depcomp \
	$(srcdir)/install-sh \
	$(srcdir)/ltmain.sh \
	$(srcdir)/missing

CLEANFILES += \
	doc-stamp \
	src/java/org/gnu/gconf/Config.class \
	$(all_gconf_jar_class_files) \
	$(gconf_javadoc_html_files) \
	$(shell find doc -name '*.html') \
	doc/api/package-list \
	doc/api/stylesheet.css \
	doc/api/resources/inherit.gif \
	gconf$(apiversion).jar