1 ## This file is part of the YAZ toolkit.
2 ## Copyright (C) 1995-2013 Index Data
6 lib_LTLIBRARIES = libyaz.la libyaz_server.la libyaz_icu.la
9 test -f $(srcdir)/cql.c || exit 1
11 tabdatadir = $(pkgdatadir)/z39.50
12 tabdata_DATA=datetime.asn esupdate.asn univres.asn z3950v3.asn z.tcl \
13 esadmin.asn charneg-3.asn mterm2.asn oclcui.asn facet.asn
15 illdatadir=$(pkgdatadir)/ill
16 illdata_DATA=ill9702.asn item-req.asn ill.tcl oclc-ill-req-ext.asn
18 EXTRA_DIST=$(tabdata_DATA) $(illdata_DATA) \
19 charconv.tcl codetables.xml codetables-iso5426.xml \
20 csvtodiag.tcl csvtobib1.tcl csvtosrw.tcl bib1.csv srw.csv \
21 csvtosru_update.tcl sru_update.csv mk_version.tcl \
22 oidtoc.tcl oid.csv sc_test.c
24 YAZCOMP=$(top_srcdir)/util/yaz-asncomp
25 YAZCOMP_Z = $(YAZCOMP) -d $(srcdir)/z.tcl -i yaz -I$(top_srcdir)/include
26 YAZCOMP_I = $(YAZCOMP) -d $(srcdir)/ill.tcl -i yaz -I$(top_srcdir)/include
28 AM_CPPFLAGS=-I$(top_srcdir)/include $(XML2_CFLAGS) $(SSL_CFLAGS)
29 libyaz_la_LIBADD = $(SSL_LIBS) $(TCPD_LIBS)
30 libyaz_server_la_LIBADD = libyaz.la
31 libyaz_icu_la_CPPFLAGS = $(AM_CPPFLAGS) $(ICU_CPPFLAGS) -I$(top_srcdir)/libstemmer_c/include
32 libyaz_icu_la_LIBADD = libyaz.la $(ICU_LIBS)
36 # MARC8->UTF8 conversion is generated from codetables.xml
37 marc8.c: charconv.tcl codetables.xml
38 $(TCLSH) $(srcdir)/charconv.tcl -p marc8 $(srcdir)/codetables.xml -o $@
40 # UTF-8->MARC8 conversion is generated from codetables.xml
41 marc8r.c: charconv.tcl codetables.xml
42 $(TCLSH) $(srcdir)/charconv.tcl -r -p marc8r $(srcdir)/codetables.xml -o $@
44 # ISO5426->UTF8 conversion is generated from codetables-iso5426.xml
45 iso5426.c: charconv.tcl codetables-iso5426.xml
46 $(TCLSH) $(srcdir)/charconv.tcl -p iso5426 $(srcdir)/codetables-iso5426.xml -o $@
48 # Generate OID database from CSV
49 oid_std.c $(top_srcdir)/include/yaz/oid_std.h: oidtoc.tcl oid.csv
50 $(TCLSH) $(srcdir)/oidtoc.tcl $(srcdir) $(srcdir)/oid.csv oid_std.c oid_std.h
52 # Generate diagnostics from CSVs
53 diagbib1.c $(top_srcdir)/include/yaz/diagbib1.h: csvtobib1.tcl bib1.csv
54 $(TCLSH) $(srcdir)/csvtobib1.tcl $(srcdir)
56 diagsrw.c $(top_srcdir)/include/yaz/diagsrw.h: csvtosrw.tcl srw.csv
57 $(TCLSH) $(srcdir)/csvtosrw.tcl $(srcdir)
59 diagsru_update.c $(top_srcdir)/include/yaz/diagsru_update.h: csvtosru_update.tcl sru_update.csv
60 $(TCLSH) $(srcdir)/csvtosru_update.tcl $(srcdir)
62 # Auto-generated C-files
63 GEN_FILES = oid_std.c \
64 marc8.c marc8r.c iso5426.c \
65 diagbib1.c diagsrw.c diagsru_update.c \
66 z-accdes1.c z-accform1.c z-acckrb1.c z-core.c z-facet-1.c \
67 z-diag1.c z-espec1.c z-estask.c z-exp.c z-grs.c z-mterm2.c z-opac.c \
68 z-uifr1.c z-rrf1.c z-rrf2.c z-sum.c z-sutrs.c z-oclcui.c\
69 zes-expi.c zes-exps.c zes-order.c zes-pquery.c zes-psched.c \
70 zes-pset.c zes-update0.c z-date.c z-univ.c zes-update.c zes-admin.c \
72 ill-core.c item-req.c oclc-ill-req-ext.c
74 libyaz_la_SOURCES=base64.c version.c options.c log.c \
76 marcdisp.c marc_read_xml.c marc_read_iso2709.c marc_read_line.c \
77 wrbuf.c oid_db.c errno.c \
78 nmemsdup.c xmalloc.c readconf.c tpath.c nmem.c matchstr.c atoin.c \
79 siconv.c iconv-p.h utf8.c ucs4.c iso5428.c advancegreek.c \
80 odr_bool.c ber_bool.c ber_len.c ber_tag.c odr_util.c facet.c \
81 odr_null.c ber_null.c odr_int.c ber_int.c odr_tag.c odr_cons.c \
82 odr_seq.c odr_oct.c ber_oct.c odr_bit.c ber_bit.c odr_oid.c \
83 ber_oid.c odr_use.c odr_choice.c odr_any.c ber_any.c odr.c odr_mem.c \
84 dumpber.c odr_enum.c odr-priv.h \
85 comstack.c tcpip.c unix.c \
88 zget.c yaz-ccl.c diag-entry.c diag-entry.h \
90 otherinfo.c pquery.c sortspec.c charneg.c initopt.c init_diag.c \
91 zoom-c.c zoom-z3950.c zoom-sru.c zoom-query.c zoom-record-cache.c \
93 record_render.c zoom-socket.c zoom-opt.c zoom-p.h sru_facet.c sru-p.h \
94 grs1disp.c zgdu.c soap.c srw.c srwutil.c uri.c solr.c diag_map.c \
95 opac_to_xml.c xml_add.c xml_match.c xml_to_opac.c \
96 cclfind.c ccltoken.c cclerrms.c cclqual.c cclptree.c cclp.h \
97 cclqfile.c cclstr.c cclxmlconfig.c ccl_stop_words.c \
98 cql.y cqlstdio.c cqltransform.c cqlutil.c xcqlutil.c cqlstring.c \
99 cql_sortkeys.c cql2ccl.c rpn2cql.c \
100 rpn2solr.c solrtransform.c \
101 cqlstrer.c querytowrbuf.c \
104 xmlquery.c xmlerror.c http.c \
105 mime.c mime.h oid_util.c tokenizer.c \
106 record_conv.c retrieval.c elementset.c snprintf.c query-charset.c \
107 copy_types.c match_glob.c poll.c daemon.c \
108 iconv_encode_marc8.c iconv_encode_iso_8859_1.c iconv_encode_wchar.c \
109 iconv_decode_marc8.c iconv_decode_iso5426.c iconv_decode_danmarc.c sc.c \
110 json.c xml_include.c file_glob.c dirent.c mutex-p.h mutex.c condvar.c \
111 thread_id.c gettimeofday.c thread_create.c spipe.c url.c
113 libyaz_la_LDFLAGS=-version-info $(YAZ_VERSION_INFO)
115 libyaz_server_la_SOURCES = statserv.c seshigh.c eventl.c \
116 requestq.c eventl.h session.h
118 libyaz_server_la_LDFLAGS=-version-info $(YAZ_VERSION_INFO)
121 ../libstemmer_c/include/libstemmer.h \
122 ../libstemmer_c/libstemmer/libstemmer.c \
123 ../libstemmer_c/libstemmer/modules.h \
124 ../libstemmer_c/runtime/api.c \
125 ../libstemmer_c/runtime/api.h \
126 ../libstemmer_c/runtime/header.h \
127 ../libstemmer_c/runtime/utilities.c \
128 ../libstemmer_c/src_c/stem_UTF_8_porter.c \
129 ../libstemmer_c/src_c/stem_UTF_8_porter.h \
130 ../libstemmer_c/src_c/stem_UTF_8_english.c \
131 ../libstemmer_c/src_c/stem_UTF_8_english.h
133 libyaz_icu_la_SOURCES = icu_chain.c icu_utf16.c icu_utf8.c stemmer.c \
134 icu_transform.c icu_casemap.c icu_tokenizer.c icu_sortkey.c \
136 libyaz_icu_la_LDFLAGS=-version-info $(YAZ_VERSION_INFO)
138 # Rules for Z39.50 V3
160 $(top_srcdir)/include/yaz/z-accdes1.h \
161 $(top_srcdir)/include/yaz/z-core.h: z-core.c
163 z-core.c: $(srcdir)/z.tcl $(srcdir)/z3950v3.asn $(YAZCOMP)
164 $(TCLSH) $(YAZCOMP_Z) $(srcdir)/z3950v3.asn
168 $(top_srcdir)/include/yaz/z-date.h: $(srcdir)/z.tcl $(srcdir)/datetime.asn $(YAZCOMP)
169 $(TCLSH) $(YAZCOMP_Z) $(srcdir)/datetime.asn
173 $(top_srcdir)/include/yaz/z-univ.h: \
174 $(srcdir)/z.tcl $(srcdir)/univres.asn $(YAZCOMP)
175 $(TCLSH) $(YAZCOMP_Z) $(srcdir)/univres.asn
177 # New Update extended service
179 $(top_srcdir)/include/yaz/zes-update.h: \
180 $(srcdir)/z.tcl $(srcdir)/esupdate.asn $(YAZCOMP)
181 $(TCLSH) $(YAZCOMP_Z) $(srcdir)/esupdate.asn
183 # Admin extended service
185 $(top_srcdir)/include/yaz/zes-admin.h: \
186 $(srcdir)/z.tcl $(srcdir)/esadmin.asn $(YAZCOMP)
187 $(TCLSH) $(YAZCOMP_Z) $(srcdir)/esadmin.asn
189 # Charset negotiation
191 $(top_srcdir)/include/yaz/z-charneg.h: \
192 $(srcdir)/z.tcl $(srcdir)/charneg-3.asn $(YAZCOMP)
193 $(TCLSH) $(YAZCOMP_Z) $(srcdir)/charneg-3.asn
195 # UserInfoFormat-multipleSearchTerms-2
197 $(top_srcdir)/include/yaz/z-mterm2.h: \
198 $(srcdir)/z.tcl $(srcdir)/mterm2.asn $(YAZCOMP)
199 $(TCLSH) $(YAZCOMP_Z) $(srcdir)/mterm2.asn
201 # UserInfoFormat-multipleSearchTerms-2
203 $(top_srcdir)/include/yaz/z-oclcui.h: \
204 $(srcdir)/z.tcl $(srcdir)/oclcui.asn $(YAZCOMP)
205 $(TCLSH) $(YAZCOMP_Z) $(srcdir)/oclcui.asn
207 # UserInfoFormat-facet-1
209 $(top_srcdir)/include/yaz/z-facet-1.h: $(srcdir)/facet.asn $(YAZCOMP)
210 $(TCLSH) $(YAZCOMP_Z) $(srcdir)/facet.asn
215 $(top_srcdir)/include/yaz/ill-core.h: \
216 $(srcdir)/ill.tcl $(srcdir)/ill9702.asn $(YAZCOMP)
217 $(TCLSH) $(YAZCOMP_I) $(srcdir)/ill9702.asn
219 # OCLC ILL Request Extension
221 $(top_srcdir)/include/yaz/oclc-ill-req-ext.h: \
222 $(srcdir)/ill.tcl $(srcdir)/oclc-ill-req-ext.asn $(YAZCOMP)
223 $(TCLSH) $(YAZCOMP_I) $(srcdir)/oclc-ill-req-ext.asn
227 $(top_srcdir)/include/yaz/item-req.h: \
228 $(srcdir)/ill.tcl $(srcdir)/item-req.asn $(YAZCOMP)
229 $(TCLSH) $(YAZCOMP_I) $(srcdir)/item-req.asn