Merge branch 'gnome-3-0'
[platform/upstream/gcr.git] / gcr / Makefile.am
1
2 if WITH_TESTS
3 TESTS_DIR = tests
4 TESTABLE_LIB = libgcr-testable.la
5 else
6 TESTS_DIR =
7 TESTABLE_LIB =
8 endif
9
10 SUBDIRS = . $(TESTS_DIR)
11
12 # ------------------------------------------------------------------
13 # UI BUILDER
14 #
15
16 uidir = $(datadir)/gcr@GCR_VERSION_SUFFIX@/ui/
17
18 ui_DATA = \
19         gcr-import-dialog.ui \
20         gcr-unlock-options-widget.ui
21
22 # ------------------------------------------------------------------
23 # HEADERS
24
25 incdir = $(includedir)/gcr@GCR_VERSION_SUFFIX@/gcr
26
27 inc_HEADERS = \
28         gcr.h \
29         gcr-certificate.h \
30         gcr-certificate-basics-widget.h \
31         gcr-certificate-chain.h \
32         gcr-certificate-details-widget.h \
33         gcr-certificate-renderer.h \
34         gcr-certificate-widget.h \
35         gcr-collection.h \
36         gcr-collection-model.h \
37         gcr-column.h \
38         gcr-combo-selector.h \
39         gcr-comparable.h \
40         gcr-key-renderer.h \
41         gcr-key-widget.h \
42         gcr-importer.h \
43         gcr-library.h \
44         gcr-parser.h \
45         gcr-pkcs11-certificate.h \
46         gcr-renderer.h \
47         gcr-simple-certificate.h \
48         gcr-simple-collection.h \
49         gcr-tree-selector.h \
50         gcr-trust.h \
51         gcr-types.h \
52         gcr-unlock-options.h \
53         gcr-unlock-options-widget.h \
54         gcr-viewer.h
55
56 # ------------------------------------------------------------------
57 # LIBRARY
58
59 INCLUDES = \
60         -I$(top_builddir) \
61         -I$(top_srcdir) \
62         $(GTK_CFLAGS) \
63         $(GOBJECT_CFLAGS) \
64         $(GLIB_CFLAGS) \
65         $(LIBGCRYPT_CFLAGS) \
66         $(LIBTASN1_CFLAGS)
67
68 BUILT_SOURCES = \
69         gcr-marshal.c gcr-marshal.h
70
71 lib_LTLIBRARIES = libgcr@GCR_VERSION_SUFFIX@.la
72
73 libgcr@GCR_VERSION_SUFFIX@_la_SOURCES = \
74         gcr-certificate.c gcr-certificate.h \
75         gcr-certificate-basics-widget.h gcr-certificate-basics-widget.c \
76         gcr-certificate-chain.c gcr-certificate-chain.h \
77         gcr-certificate-details-widget.h gcr-certificate-details-widget.c \
78         gcr-certificate-renderer.c gcr-certificate-renderer.h \
79         gcr-certificate-exporter.c gcr-certificate-exporter.h \
80         gcr-certificate-widget.c gcr-certificate-widget.h \
81         gcr-collection.c gcr-collection.h \
82         gcr-collection-model.c gcr-collection-model.h \
83         gcr-combo-selector.c gcr-combo-selector.h \
84         gcr-comparable.c gcr-comparable.h \
85         gcr-debug.c gcr-debug.h \
86         gcr-display-scrolled.c gcr-display-scrolled.h \
87         gcr-display-view.c gcr-display-view.h \
88         gcr-gnupg-collection.c gcr-gnupg-collection.h \
89         gcr-gnupg-key.c gcr-gnupg-key.h \
90         gcr-fingerprint.c gcr-fingerprint.h \
91         gcr-icons.c gcr-icons.h \
92         gcr-import-dialog.c gcr-import-dialog.h \
93         gcr-importer.c gcr-importer.h  \
94         gcr-internal.h \
95         gcr-key-renderer.c gcr-key-renderer.h \
96         gcr-key-widget.c gcr-key-widget.h \
97         gcr-library.c gcr-library.h \
98         gcr-parser.c gcr-parser.h \
99         gcr-pkcs11-certificate.c gcr-pkcs11-certificate.h \
100         gcr-record.c gcr-record.h \
101         gcr-renderer.c gcr-renderer.h \
102         gcr-simple-certificate.c gcr-simple-certificate.h \
103         gcr-simple-collection.c gcr-simple-collection.h \
104         gcr-tree-selector.c gcr-tree-selector.h \
105         gcr-trust.c gcr-trust.h \
106         gcr-types.h \
107         gcr-unlock-options.h \
108         gcr-unlock-options-widget.c gcr-unlock-options-widget.h \
109         gcr-util.c gcr-util.h \
110         gcr-viewer.c gcr-viewer.h \
111         $(BUILT_SOURCES)
112
113 libgcr@GCR_VERSION_SUFFIX@_la_CFLAGS = \
114         -DGCK_API_SUBJECT_TO_CHANGE \
115         -DGCR_API_SUBJECT_TO_CHANGE \
116         -DGCR_COMPILATION \
117         -DUIDIR=\""$(uidir)"\"
118
119 libgcr@GCR_VERSION_SUFFIX@_la_LDFLAGS = \
120         -version-info $(GCR_LT_RELEASE) \
121         -no-undefined \
122         -export-symbols-regex '^gcr_*'
123
124 libgcr@GCR_VERSION_SUFFIX@_la_LIBADD = \
125         $(top_builddir)/egg/libegg.la \
126         $(top_builddir)/egg/libegg-entry-buffer.la \
127         $(top_builddir)/gck/libgck.la \
128         $(GOBJECT_LIBS) \
129         $(GLIB_LIBS) \
130         $(LIBGCRYPT_LIBS) \
131         $(GTK_LIBS)
132
133 noinst_LTLIBRARIES = $(TESTABLE_LIB)
134 libgcr_testable_la_SOURCES =
135 libgcr_testable_la_LIBADD = $(libgcr@GCR_VERSION_SUFFIX@_la_OBJECTS) \
136         $(libgcr@GCR_VERSION_SUFFIX@_la_LIBADD)
137 libgcr_testable_la_DEPENDENCIES = $(libgcr@GCR_VERSION_SUFFIX@_la_OBJECTS)
138
139 gcr-marshal.h: gcr-marshal.list $(GLIB_GENMARSHAL)
140         $(GLIB_GENMARSHAL) $< --header --prefix=_gcr_marshal > $@
141
142 gcr-marshal.c: gcr-marshal.list $(GLIB_GENMARSHAL)
143         echo "#include \"gcr-marshal.h\"" > $@ && \
144         $(GLIB_GENMARSHAL) $< --body --prefix=_gcr_marshal >> $@
145
146 pkgconfigdir = $(libdir)/pkgconfig
147 pkgconfig_DATA = gcr-$(GCR_MAJOR).pc
148
149 gcr-$(GCR_MAJOR).pc: gcr.pc
150         cp gcr.pc gcr-$(GCR_MAJOR).pc
151
152
153 # ----------------------------------------------------------------
154
155 libgcr.symbols: .libs/libgcr@GCR_VERSION_SUFFIX@.so
156         nm -D .libs/libgcr@GCR_VERSION_SUFFIX@.so | grep -F ' T ' | \
157                 cut -d ' ' -f 3 | sort > $@
158
159 EXTRA_DIST = \
160         gcr.pc.in \
161         gcr-marshal.list \
162         $(ui_DATA) \
163         $(conf_DATA) \
164         libgcr.symbols
165
166 CLEANFILES = \
167         $(BUILT_SOURCES) \
168         $(pkgconfig_DATA)
169
170 DISTCLEANFILES = \
171         $(pkgconfig_DATA) \
172         libgcr.symbols