1 # This file is part of the YAZ toolkit.
2 # Copyright (C) 1995-2009 Index Data
5 # Heikki Levanto & Adam Dickmeiss
9 DEBUG=0 # 0 for release, 1 for debug
13 TCL="C:\Tcl\bin\tclsh85.exe"
14 #TCL="C:\Program Files\Tcl\bin\tclsh83.exe"
17 # iconv charcter conversion utility
19 ICONV_DIR = c:\iconv-1.9.2.win32
21 # icu charcter conversion utility
22 # get icu libraries from http://www.icu-project.org
28 LIBXSLT_DIR=c:\libxslt-1.1.24.win32
32 LIBXML2_DIR=c:\libxml2-2.7.1.win32
34 # zlib compression (used by libxml2)
35 ZLIB_DIR = c:\zlib-1.2.3.win32
37 # get WIN32 binaries libxml2 & iconv & zlib from here:
38 # http://www.zlatkovic.com/libxml.en.html
46 all: dirs generate dll sc_test client ztest yazicu zoomsh utilprog testprog iconv icu libxml2 libxslt
48 NSIS="c:\program files\nsis\makensis.exe"
49 HHC="c:\program files\html help workshop\hhc.exe"
64 # The current directory is supposed to be something like
65 # ..../yaz/win, everything is relative to that
66 ROOTDIR=.. # The home of yaz
68 INCLDIR=$(ROOTDIR)\include # our includes
69 LIBDIR=$(ROOTDIR)\lib # We produce .lib, .exp etc there
70 BINDIR=$(ROOTDIR)\bin # We produce exes and dlls there
71 WINDIR=$(ROOTDIR)\win # all these Win make things
72 SRCDIR=$(ROOTDIR)\src # for the case we move them under src
73 DOCDIR=$(ROOTDIR)\doc # where the doc is
75 # where we store intermediate files
82 CLIENTDIR=$(ROOTDIR)\CLIENT
83 ZTESTDIR=$(ROOTDIR)\ZTEST
84 ZOOMDIR=$(ROOTDIR)\ZOOM
85 UTILDIR=$(ROOTDIR)\UTIL
86 TESTDIR=$(ROOTDIR)\TEST
88 TMPDIR=$(ROOTDIR)\win\tmp
91 # Targets - what to make
94 YAZ_DLL=$(BINDIR)\yaz3d.dll
95 YAZ_IMPLIB=$(LIBDIR)\yaz3d.lib
96 YAZ_ICU_DLL=$(BINDIR)\yaz_icu3d.dll
97 YAZ_ICU_IMPLIB=$(LIBDIR)\yaz_icu3d.lib
99 YAZ_DLL=$(BINDIR)\yaz3.dll
100 YAZ_IMPLIB=$(LIBDIR)\yaz3.lib
101 YAZ_ICU_DLL=$(BINDIR)\yaz_icu3.dll
102 YAZ_ICU_IMPLIB=$(LIBDIR)\yaz_icu3.lib
105 CLIENT=$(BINDIR)\yaz-client.exe
106 YAZ_ICU=$(BINDIR)\yaz-icu.exe
107 ZOOMSH=$(BINDIR)\zoomsh.exe
108 ZTEST=$(BINDIR)\yaz-ztest.exe
109 SC_TEST=$(BINDIR)\sc_test.exe
111 ZOOMTST1=$(BINDIR)\zoomtst1.exe
112 ZOOMTST2=$(BINDIR)\zoomtst2.exe
113 ZOOMTST3=$(BINDIR)\zoomtst3.exe
114 ZOOMTST4=$(BINDIR)\zoomtst4.exe
115 ZOOMTST5=$(BINDIR)\zoomtst5.exe
116 ZOOMTST6=$(BINDIR)\zoomtst6.exe
117 ZOOMTST7=$(BINDIR)\zoomtst7.exe
118 ZOOMTST8=$(BINDIR)\zoomtst8.exe
119 ZOOMTST9=$(BINDIR)\zoomtst9.exe
120 ZOOMTST10=$(BINDIR)\zoomtst10.exe
122 CQL2PQF=$(BINDIR)\cql2pqf.exe
123 CQL2XCQL=$(BINDIR)\cql2xcql.exe
124 YAZ_MARCDUMP=$(BINDIR)\yaz-marcdump.exe
126 TSTLOG=$(BINDIR)\tstlog.exe
127 TST_TIMING=$(BINDIR)\tst_timing.exe
129 # shortcut names defined here
130 dll: dirs generate $(YAZ_DLL)
131 client: dirs generate $(CLIENT)
132 ztest: dirs generate $(ZTEST)
136 zoomsh: $(ZOOMSH) $(ZOOMTST1) $(ZOOMTST2) $(ZOOMTST3) \
137 $(ZOOMTST4) $(ZOOMTST5) $(ZOOMTST6) $(ZOOMTST7) $(ZOOMTST8) $(ZOOMTST9) \
140 utilprog: $(CQL2PQF) $(CQL2XCQL) $(YAZ_MARCDUMP)
141 testprog: $(TSTLOG) $(TST_TIMING)
143 htmlhelp: $(DOCDIR)\htmlhelp.chm
145 # Modules and conditional flags, etc
150 /I"$(ICONV_DIR)\include"
152 "$(ICONV_DIR)\lib\iconv.lib"
153 iconv: $(BINDIR)\iconv.dll
156 copy "$(ICONV_DIR)\bin\iconv.dll" $(BINDIR)
165 ###TRYING ICU FLAGS HERE WORKS ####
166 ## ADAM ARE THESE FLAGS OK and the DLL sufficient ##
167 ##IT COMPILES AND SEEMS TO WORK
171 /D YAZ_HAVE_ICU=1 /D HAVE_ICU_H=1 \
172 /I"$(ICU_DIR)\include"
174 $(ICU_DIR)\lib\icudt.lib $(ICU_DIR)\lib\icuin.lib $(ICU_DIR)\lib\icuuc.lib
175 icu: $(BINDIR)\icudt40.dll $(BINDIR)\icuin40.dll $(BINDIR)\icuuc40.dll
176 yazicu: dirs generate $(YAZ_ICU)
178 $(BINDIR)\icudt40.dll:
179 copy "$(ICU_DIR)\bin\icudt40.dll" $(BINDIR)
180 $(BINDIR)\icuin40.dll:
181 copy "$(ICU_DIR)\bin\icuin40.dll" $(BINDIR)
182 $(BINDIR)\icuuc40.dll:
183 copy "$(ICU_DIR)\bin\icuuc40.dll" $(BINDIR)
195 LIBXML2_LIB="$(LIBXML2_DIR)\lib\libxml2.lib"
196 LIBXML2_DEF=/D YAZ_HAVE_XML2=1 /I"$(LIBXML2_DIR)\include"
197 libxml2: $(BINDIR)\libxml2.dll $(BINDIR)\zlib1.dll
199 $(BINDIR)\libxml2.dll:
200 copy "$(LIBXML2_DIR)\bin\libxml2.dll" $(BINDIR)
203 copy "$(ZLIB_DIR)\bin\zlib1.dll" $(BINDIR)
207 LIBXML2_DEF=/D YAZ_HAVE_XML2=0
213 LIBXSLT_LIB="$(LIBXSLT_DIR)\lib\libxslt.lib"
215 /D HAVE_XSLTSAVERESULTTOSTRING=1 \
217 /I"$(LIBXSLT_DIR)\include"
218 libxslt: $(BINDIR)\libxslt.dll
220 $(BINDIR)\libxslt.dll:
221 copy "$(LIBXSLT_DIR)\bin\libxslt.dll" $(BINDIR)
225 LIBXSLT_DEF=/D YAZ_HAVE_XSLT=0
230 ### C and CPP compiler (the same thing)
231 # Note: $(CPP) has already been defined in the environment
232 # (if you set things up right!)
235 /nologo /W3 /EHsc /FD /c \
240 /D "_CRT_SECURE_NO_DEPRECATE" \
241 /D "_CRT_NONSTDC_NO_DEPRECATE" \
249 /I"$(ROOTDIR)\include"
259 # /W3 = warning level
260 # /GX = Enable exception handling
261 # /FD = Generate file dependencies (what ever they are)
262 # /c = compile without linking
263 # /FR = Generate browse info (.sbr file that gets combined into .bsc)
264 # /Fo = object file name (or at least path)
265 # /Fd = debug database name (or path)
266 # /MD = Runtime library: Multithread DLL
267 # /MDd = Runtime library: Multithread DLL (debug)
268 # /Od = Disable optimising (debug)
269 # /O2 = Optimize for speed
270 # /Gm = Minimal rebuild (some cpp class stuff)
271 # /Zi = Program database for debuggers
272 # /ZI = Pgm database with special "edit&continue" stuff - not available in C5
284 LINK_LIBS= kernel32.lib ws2_32.lib advapi32.lib \
285 $(ICONV_LIB) $(LIBXML2_LIB) $(LIBXSLT_LIB)
287 COMMON_LNK_OPTIONS= /nologo /subsystem:windows /machine:i386 /incremental:no
289 DEBUG_LNK_OPTIONS= /debug
293 DLL_LINK_OPTIONS= /dll
294 CLIENT_LINK_OPTIONS = /subsystem:console
296 COMMON_TCL_OPTIONS= ..\util\yaz-asncomp -I$(INCLDIR) -i yaz
298 # Final opt variables
300 COPT= $(COMMON_C_OPTIONS) $(DEBUG_C_OPTIONS) $(COMMON_C_INCLUDES)
301 LNKOPT= $(COMMON_LNK_OPTIONS) $(DEBUG_LNK_OPTIONS) $(LNK_LIBS)
302 TCLOPT= $(COMMON_TCL_OPTIONS)
305 COPT= $(COMMON_C_OPTIONS) $(RELEASE_C_OPTIONS) $(COMMON_C_INCLUDES)
306 LNKOPT= $(COMMON_LNK_OPTIONS) $(RELEASE_LNK_OPTIONS) $(LNK_LIBS)
307 TCLOPT= $(COMMON_TCL_OPTIONS)
310 LINK_PROGRAM = $(LINK) $(LNKOPT) \
311 $(CLIENT_LINK_OPTIONS) $(LINK_LIBS) $(YAZ_IMPLIB)
313 LINK_DLL = $(LINK) $(LNKOPT) \
314 $(LINK_LIBS) $(DLL_LINK_OPTIONS)
316 # Source and object modules
318 # Note: Ordinary source files are not specified here at
319 # all, make finds them in suitable dirs. The object modules
320 # need to be specified, though
323 $(OBJDIR)\client.obj \
324 $(OBJDIR)\tabcomplete.obj \
325 $(OBJDIR)\admin.obj \
326 $(OBJDIR)\fhistory.obj
328 YAZ_ICU_OBJS= $(OBJDIR)\yaz-icu.obj
331 $(OBJDIR)\dummy-opac.obj \
332 $(OBJDIR)\read-marc.obj \
333 $(OBJDIR)\read-grs.obj \
337 $(OBJDIR)\sc_test.obj
342 YAZ_ZOOMTST1_OBJS = \
343 $(OBJDIR)\zoomtst1.obj
344 YAZ_ZOOMTST2_OBJS = \
345 $(OBJDIR)\zoomtst2.obj
346 YAZ_ZOOMTST3_OBJS = \
347 $(OBJDIR)\zoomtst3.obj
348 YAZ_ZOOMTST4_OBJS = \
349 $(OBJDIR)\zoomtst4.obj
350 YAZ_ZOOMTST5_OBJS = \
351 $(OBJDIR)\zoomtst5.obj
352 YAZ_ZOOMTST6_OBJS = \
353 $(OBJDIR)\zoomtst6.obj
354 YAZ_ZOOMTST7_OBJS = \
355 $(OBJDIR)\zoomtst7.obj
356 YAZ_ZOOMTST8_OBJS = \
357 $(OBJDIR)\zoomtst8.obj
358 YAZ_ZOOMTST9_OBJS = \
359 $(OBJDIR)\zoomtst9.obj
360 YAZ_ZOOMTST10_OBJS = \
361 $(OBJDIR)\zoomtst10.obj
364 $(OBJDIR)\cql2pqf.obj
365 YAZ_CQL2XCQL_OBJS = \
366 $(OBJDIR)\cql2xcql.obj
367 YAZ_MARCDUMP_OBJS = \
368 $(OBJDIR)\marcdump.obj
375 $(OBJDIR)\tst_timing.obj
378 $(OBJDIR)\version.obj \
379 $(OBJDIR)\oid_std.obj \
380 $(OBJDIR)\eventl.obj \
381 $(OBJDIR)\requestq.obj \
382 $(OBJDIR)\seshigh.obj \
383 $(OBJDIR)\statserv.obj \
384 $(OBJDIR)\tcpdchk.obj \
385 $(OBJDIR)\cclerrms.obj \
386 $(OBJDIR)\cclfind.obj \
387 $(OBJDIR)\cclptree.obj \
388 $(OBJDIR)\cclqfile.obj \
389 $(OBJDIR)\cclqual.obj \
390 $(OBJDIR)\cclstr.obj \
391 $(OBJDIR)\ccltoken.obj \
392 $(OBJDIR)\ccl_stop_words.obj \
393 $(OBJDIR)\comstack.obj \
394 $(OBJDIR)\tcpip.obj \
395 $(OBJDIR)\waislen.obj \
396 $(OBJDIR)\ber_any.obj \
397 $(OBJDIR)\ber_bit.obj \
398 $(OBJDIR)\ber_bool.obj \
399 $(OBJDIR)\ber_int.obj \
400 $(OBJDIR)\ber_len.obj \
401 $(OBJDIR)\ber_null.obj \
402 $(OBJDIR)\ber_oct.obj \
403 $(OBJDIR)\ber_oid.obj \
404 $(OBJDIR)\ber_tag.obj \
405 $(OBJDIR)\dumpber.obj \
406 $(OBJDIR)\errno.obj \
408 $(OBJDIR)\odr_any.obj \
409 $(OBJDIR)\odr_bit.obj \
410 $(OBJDIR)\odr_bool.obj \
411 $(OBJDIR)\odr_choice.obj \
412 $(OBJDIR)\odr_cons.obj \
413 $(OBJDIR)\odr_enum.obj \
414 $(OBJDIR)\odr_int.obj \
415 $(OBJDIR)\odr_mem.obj \
416 $(OBJDIR)\odr_null.obj \
417 $(OBJDIR)\odr_oct.obj \
418 $(OBJDIR)\odr_oid.obj \
419 $(OBJDIR)\odr_seq.obj \
420 $(OBJDIR)\odr_tag.obj \
421 $(OBJDIR)\odr_use.obj \
422 $(OBJDIR)\odr_util.obj \
423 $(OBJDIR)\atoin.obj \
425 $(OBJDIR)\marcdisp.obj \
426 $(OBJDIR)\marc_read_xml.obj \
427 $(OBJDIR)\marc_read_iso2709.obj \
428 $(OBJDIR)\marc_read_line.obj \
430 $(OBJDIR)\nmemsdup.obj \
431 $(OBJDIR)\oid_db.obj \
432 $(OBJDIR)\oid_util.obj \
433 $(OBJDIR)\options.obj \
434 $(OBJDIR)\readconf.obj \
435 $(OBJDIR)\tpath.obj \
436 $(OBJDIR)\wrbuf.obj \
437 $(OBJDIR)\xmalloc.obj \
438 $(OBJDIR)\matchstr.obj \
439 $(OBJDIR)\siconv.obj \
440 $(OBJDIR)\iso5428.obj \
443 $(OBJDIR)\advancegreek.obj \
444 $(OBJDIR)\snprintf.obj \
445 $(OBJDIR)\marc8.obj \
446 $(OBJDIR)\marc8r.obj \
447 $(OBJDIR)\iso5426.obj \
448 $(OBJDIR)\record_conv.obj \
449 $(OBJDIR)\retrieval.obj \
450 $(OBJDIR)\libxml2_error.obj \
452 $(OBJDIR)\diagbib1.obj \
453 $(OBJDIR)\diagsru_update.obj \
454 $(OBJDIR)\diagsrw.obj \
455 $(OBJDIR)\diag-entry.obj \
457 $(OBJDIR)\logrpn.obj \
458 $(OBJDIR)\querytowrbuf.obj \
459 $(OBJDIR)\pquery.obj \
460 $(OBJDIR)\yaz-ccl.obj \
461 $(OBJDIR)\otherinfo.obj \
462 $(OBJDIR)\sortspec.obj \
463 $(OBJDIR)\charneg.obj \
464 $(OBJDIR)\grs1disp.obj \
465 $(OBJDIR)\opacdisp.obj \
469 $(OBJDIR)\srwutil.obj \
470 $(OBJDIR)\zoom-c.obj \
471 $(OBJDIR)\zoom-opt.obj \
472 $(OBJDIR)\zoom-socket.obj \
473 $(OBJDIR)\initopt.obj \
474 $(OBJDIR)\xmlquery.obj \
475 $(OBJDIR)\xmlerror.obj \
478 $(OBJDIR)\cqlstdio.obj \
479 $(OBJDIR)\cqlstring.obj \
480 $(OBJDIR)\cqltransform.obj \
481 $(OBJDIR)\cqlutil.obj \
482 $(OBJDIR)\cqlstrer.obj \
483 $(OBJDIR)\rpn2cql.obj \
484 $(OBJDIR)\xcqlutil.obj \
485 $(OBJDIR)\elementset.obj \
486 $(OBJDIR)\timing.obj \
487 $(OBJDIR)\query-charset.obj \
488 $(OBJDIR)\tokenizer.obj \
489 $(OBJDIR)\copy_types.obj \
491 $(OBJDIR)\match_glob.obj \
493 $(OBJDIR)\daemon.obj \
494 $(OBJDIR)\iconv_encode_iso_8859_1.obj \
495 $(OBJDIR)\iconv_encode_marc8.obj \
496 $(OBJDIR)\iconv_decode_marc8.obj \
497 $(OBJDIR)\iconv_encode_wchar.obj \
498 $(OBJDIR)\iconv_decode_iso5426.obj \
499 $(OBJDIR)\iconv_decode_danmarc.obj \
500 $(OBJDIR)\mutex.obj \
504 $(OBJDIR)\z-date.obj\
505 $(OBJDIR)\z-univ.obj\
506 $(OBJDIR)\zes-update.obj\
507 $(OBJDIR)\zes-admin.obj \
508 $(OBJDIR)\z-accdes1.obj \
509 $(OBJDIR)\z-accform1.obj \
510 $(OBJDIR)\z-acckrb1.obj \
511 $(OBJDIR)\z-core.obj \
512 $(OBJDIR)\z-diag1.obj \
513 $(OBJDIR)\z-espec1.obj \
514 $(OBJDIR)\z-estask.obj \
515 $(OBJDIR)\z-exp.obj \
516 $(OBJDIR)\z-grs.obj \
517 $(OBJDIR)\z-opac.obj \
518 $(OBJDIR)\z-uifr1.obj \
519 $(OBJDIR)\z-rrf1.obj \
520 $(OBJDIR)\z-rrf2.obj \
521 $(OBJDIR)\z-sum.obj \
522 $(OBJDIR)\z-sutrs.obj \
523 $(OBJDIR)\zes-expi.obj \
524 $(OBJDIR)\zes-exps.obj \
525 $(OBJDIR)\zes-order.obj \
526 $(OBJDIR)\zes-pquery.obj \
527 $(OBJDIR)\zes-psched.obj \
528 $(OBJDIR)\zes-pset.obj \
529 $(OBJDIR)\zes-update0.obj \
530 $(OBJDIR)\prt-ext.obj \
531 $(OBJDIR)\z-charneg.obj \
532 $(OBJDIR)\z-mterm2.obj \
533 $(OBJDIR)\z-oclcui.obj
536 $(OBJDIR)\ill-get.obj\
537 $(OBJDIR)\ill-core.obj\
538 $(OBJDIR)\item-req.obj
546 $(OBJDIR)\icu_I18N.obj
548 # Generated C and H files
550 Z3950_C_DIR=$(SRCDIR)
552 #!!! Should be moved to OBJ, but that requires too much trickery
554 # Files generated from datetime.asn
555 DATETIME_H_FILES = $(INCLDIR)\yaz\z-date.h
556 DATETIME_C_FILES = $(Z3950_C_DIR)\z-date.c
558 # Files generated from univres.asn
559 UNIVRES_H_FILES = $(INCLDIR)\yaz\z-univ.h
560 UNIVRES_C_FILES = $(Z3950_C_DIR)\z-univ.c
562 # Files generated from esupdate.asn
563 ESUPDATE_H_FILES = $(INCLDIR)\yaz\zes-update.h
564 ESUPDATE_C_FILES = $(Z3950_C_DIR)\zes-update.c
566 # Files generated from esadmin.asn
567 ESADMIN_H_FILES = $(INCLDIR)\yaz\zes-admin.h
568 ESADMIN_C_FILES = $(Z3950_C_DIR)\zes-admin.c
570 # Files generated from esadmin.asn
571 CHARNEG_H_FILES = $(INCLDIR)\yaz\z-charneg.h
572 CHARNEG_C_FILES = $(Z3950_C_DIR)\z-charneg.c
574 # Files generated from mterm2.asn
575 MTERM2_H_FILES = $(INCLDIR)\yaz\z-mterm2.h
576 MTERM2_C_FILES = $(Z3950_C_DIR)\z-mterm2.c
578 # Files generated from mterm2.asn
579 OCLCUI_H_FILES = $(INCLDIR)\yaz\z-oclcui.h
580 OCLCUI_C_FILES = $(Z3950_C_DIR)\z-oclcui.c
582 # Files created from z3950v3.asn
584 $(INCLDIR)\yaz\z-accdes1.h \
585 $(INCLDIR)\yaz\z-core.h
588 $(Z3950_C_DIR)\z-accdes1.c \
589 $(Z3950_C_DIR)\z-accform1.c \
590 $(Z3950_C_DIR)\z-acckrb1.c \
591 $(Z3950_C_DIR)\z-core.c \
592 $(Z3950_C_DIR)\z-diag1.c \
593 $(Z3950_C_DIR)\z-espec1.c \
594 $(Z3950_C_DIR)\z-estask.c \
595 $(Z3950_C_DIR)\z-exp.c \
596 $(Z3950_C_DIR)\z-grs.c \
597 $(Z3950_C_DIR)\z-opac.c \
598 $(Z3950_C_DIR)\z-uifr1.c \
599 $(Z3950_C_DIR)\z-rrf1.c \
600 $(Z3950_C_DIR)\z-rrf2.c \
601 $(Z3950_C_DIR)\z-sum.c \
602 $(Z3950_C_DIR)\z-sutrs.c \
603 $(Z3950_C_DIR)\zes-expi.c \
604 $(Z3950_C_DIR)\zes-exps.c \
605 $(Z3950_C_DIR)\zes-order.c \
606 $(Z3950_C_DIR)\zes-pquery.c \
607 $(Z3950_C_DIR)\zes-psched.c \
608 $(Z3950_C_DIR)\zes-pset.c \
609 $(Z3950_C_DIR)\zes-update0.c
611 # Files generated from ill9702.asn
613 $(INCLDIR)\yaz\ill-core.h
616 $(ILL_C_DIR)\ill-core.c
618 # Files generated from itemreq.asn
620 $(INCLDIR)\yaz\item-req.h
623 $(ILL_C_DIR)\item-req.c
626 DATETIME_FILES = $(DATETIME_H_FILES) $(DATETIME_C_FILES)
627 UNIVRES_FILES = $(UNIVRES_H_FILES) $(UNIVRES_C_FILES)
628 ESUPDATE_FILES = $(ESUPDATE_H_FILES) $(ESUPDATE_C_FILES)
629 ESADMIN_FILES = $(ESADMIN_H_FILES) $(ESADMIN_C_FILES)
630 Z3950V3_FILES= $(Z3950V3_C_FILES) $(Z3950V3_H_FILES)
631 ILL_CORE_FILES= $(ILL_CORE_C_FILES) $(ILL_CORE_H_FILES)
632 ITEM_REQ_FILES= $(ITEM_REQ_C_FILES) $(ITEM_REQ_H_FILES)
633 CHARNEG_FILES = $(CHARNEG_C_FILES) $(CHARNEG_H_FILES)
634 MTERM2_FILES = $(MTERM2_C_FILES) $(MTERM2_H_FILES)
635 OCLCUI_FILES = $(OCLCUI_C_FILES) $(OCLCUI_H_FILES)
639 $(ESUPDATE_C_FILES) \
641 $(DATETIME_C_FILES) \
646 $(ILL_CORE_C_FILES) \
651 $(ESUPDATE_H_FILES) \
653 $(DATETIME_H_FILES) \
658 $(ILL_CORE_H_FILES) \
662 $(GENERATED_H_FILES) \
663 $(GENERATED_C_FILES) \
664 $(SRCDIR)\diagsrw.c \
665 $(SRCDIR)\diagbib1.c \
666 $(SRCDIR)\diagsru_update.c \
667 $(INCLDIR)\yaz\yaz-version.h
671 # Note: This defines where to look for the necessary
672 # source files. Funny way of doing it, but it works.
675 {$(CLIENTDIR)}.c{$(OBJDIR)}.obj:
676 $(CPP) $(COPT) $< /D"_CONSOLE"
679 {$(ZTESTDIR)}.c{$(OBJDIR)}.obj:
680 $(CPP) $(COPT) $< /D"_CONSOLE"
683 {$(SERVERDIR)}.c{$(OBJDIR)}.obj:
686 # Various YAZ source directories
687 {$(SRCDIR)}.c{$(OBJDIR)}.obj:
688 $(CPP) $(COPT) /D"YAZ_DLL" $<
690 {$(ZOOMDIR)}.c{$(OBJDIR)}.obj:
693 {$(UTILDIR)}.c{$(OBJDIR)}.obj:
696 {$(TESTDIR)}.c{$(OBJDIR)}.obj:
699 # ASN-generated files
703 $(Z3950V3_FILES): $(SRCDIR)\z3950v3.asn
705 $(TCL) $(TCLOPT) -d z.tcl z3950v3.asn
708 $(DATETIME_FILES): $(SRCDIR)\datetime.asn
710 $(TCL) $(TCLOPT) -d z.tcl datetime.asn
713 $(UNIVRES_FILES): $(SRCDIR)\univres.asn
715 $(TCL) $(TCLOPT) -d z.tcl univres.asn
718 $(ESUPDATE_FILES): $(SRCDIR)\esupdate.asn
720 $(TCL) $(TCLOPT) -d z.tcl esupdate.asn
723 $(ESADMIN_FILES): $(SRCDIR)\esadmin.asn
725 $(TCL) $(TCLOPT) -d z.tcl esadmin.asn
728 $(CHARNEG_FILES): $(SRCDIR)\charneg-3.asn
730 $(TCL) $(TCLOPT) -d z.tcl charneg-3.asn
733 $(MTERM2_FILES): $(SRCDIR)\mterm2.asn
735 $(TCL) $(TCLOPT) -d z.tcl mterm2.asn
738 $(OCLCUI_FILES): $(SRCDIR)\oclcui.asn
740 $(TCL) $(TCLOPT) -d z.tcl oclcui.asn
743 $(ILL_CORE_FILES): $(SRCDIR)\ill9702.asn
745 $(TCL) $(TCLOPT) -d ill.tcl ill9702.asn
748 $(ITEM_REQ_FILES): $(SRCDIR)\item-req.asn
750 $(TCL) $(TCLOPT) -d ill.tcl item-req.asn
753 $(SRCDIR)\marc8.c: $(SRCDIR)\codetables.xml $(SRCDIR)\charconv.tcl
755 $(TCL) charconv.tcl -p marc8 codetables.xml -o marc8.c
757 $(SRCDIR)\marc8r.c: $(SRCDIR)\codetables.xml $(SRCDIR)\charconv.tcl
759 $(TCL) charconv.tcl -r -p marc8r codetables.xml -o marc8r.c
761 $(SRCDIR)\iso5426.c: $(SRCDIR)\codetables-iso5426.xml $(SRCDIR)\charconv.tcl
763 $(TCL) charconv.tcl -r -p iso5426 codetables-iso5426.xml -o iso5426.c
765 $(SRCDIR)\oid_std.c: $(SRCDIR)\oid.csv
767 $(TCL) oidtoc.tcl $(SRCDIR) oid.csv oid_std.c oid_std.h
769 $(SRCDIR)\diagbib1.c: $(SRCDIR)\bib1.csv
771 $(TCL) csvtobib1.tcl $(SRCDIR)
773 $(SRCDIR)\diagsrw.c: $(SRCDIR)\srw.csv
775 $(TCL) csvtosrw.tcl $(SRCDIR)
777 $(SRCDIR)\diagsru_update.c: $(SRCDIR)\sru_update.csv
779 $(TCL) csvtosru_update.tcl $(SRCDIR)
781 $(INCLDIR)\yaz\yaz-version.h:
783 $(TCL) mk_version.tcl $(ROOTDIR)/configure.ac $(INCLDIR)\yaz\yaz-version.h
789 $(SRCDIR)\cql.c: $(SRCDIR)\cql.y
791 $(BISON) -y -p cql_ -o cql.c cql.y
796 # The RC compiler (resource files)
799 YAZ_RC=$(WINDIR)\yaz.rc
800 YAZ_RES=$(OBJDIR)\yaz.res
801 YAZ_ICU_RES=$(OBJDIR)\yaz_icu.res
809 $(YAZ_RES): $(YAZ_RC)
810 $(RSC) $(RSOPT) /I"../include" /fo"$(YAZ_RES)" $(YAZ_RC)
812 $(YAZ_ICU_RES): $(YAZ_RC)
813 $(RSC) $(RSOPT) /DICU=1 /I"../include" /fo"$(YAZ_ICU_RES)" $(YAZ_RC)
817 $(YAZ_DLL) $(YAZ_IMPLIB): "$(BINDIR)" $(DLL_OBJS) $(YAZ_RES)
822 /implib:"$(YAZ_IMPLIB)"
823 $(MT) -manifest $@.manifest -outputresource:$@;2
825 $(YAZ_ICU_DLL) $(YAZ_ICU_IMPLIB): "$(BINDIR)" $(ICU_DLL_OBJS) $(YAZ_ICU_RES)
826 $(LINK_DLL) $(ICU_LIB) $(YAZ_IMPLIB)\
830 /implib:"$(YAZ_ICU_IMPLIB)"
831 $(MT) -manifest $@.manifest -outputresource:$@;2
833 $(CLIENT) : "$(BINDIR)" $(YAZ_CLIENT_OBJS) $(YAZ_DLL)
834 $(LINK_PROGRAM) $(YAZ_CLIENT_OBJS) /out:$@
835 $(MT) -manifest $@.manifest -outputresource:$@;1
837 $(YAZ_ICU) : "$(BINDIR)" $(YAZ_ICU_OBJS) $(YAZ_ICU_DLL)
838 $(LINK_PROGRAM) $(ICU_LIB) $(YAZ_ICU_IMPLIB) $(YAZ_ICU_OBJS) /out:$@
839 $(MT) -manifest $@.manifest -outputresource:$@;1
842 $(SC_TEST) : "$(BINDIR)" $(SC_TEST_OBJS) $(YAZ_DLL)
843 $(LINK_PROGRAM) $(SC_TEST_OBJS) /out:$@
844 $(MT) -manifest $@.manifest -outputresource:$@;1
846 $(ZOOMSH) : "$(BINDIR)" $(YAZ_ZOOMSH_OBJS) $(YAZ_DLL)
847 $(LINK_PROGRAM) $(YAZ_ZOOMSH_OBJS) /out:$@
848 $(MT) -manifest $@.manifest -outputresource:$@;1
850 $(ZOOMTST1) : "$(BINDIR)" $(YAZ_ZOOMTST1_OBJS) $(YAZ_DLL)
851 $(LINK_PROGRAM) $(YAZ_ZOOMTST1_OBJS) /out:$@
852 $(MT) -manifest $@.manifest -outputresource:$@;1
854 $(ZOOMTST2) : "$(BINDIR)" $(YAZ_ZOOMTST2_OBJS) $(YAZ_DLL)
855 $(LINK_PROGRAM) $(YAZ_ZOOMTST2_OBJS) /out:$@
856 $(MT) -manifest $@.manifest -outputresource:$@;1
858 $(ZOOMTST3) : "$(BINDIR)" $(YAZ_ZOOMTST3_OBJS) $(YAZ_DLL)
859 $(LINK_PROGRAM) $(YAZ_ZOOMTST3_OBJS) /out:$@
860 $(MT) -manifest $@.manifest -outputresource:$@;1
862 $(ZOOMTST4) : "$(BINDIR)" $(YAZ_ZOOMTST4_OBJS) $(YAZ_DLL)
863 $(LINK_PROGRAM) $(YAZ_ZOOMTST4_OBJS) /out:$@
864 $(MT) -manifest $@.manifest -outputresource:$@;1
866 $(ZOOMTST5) : "$(BINDIR)" $(YAZ_ZOOMTST5_OBJS) $(YAZ_DLL)
867 $(LINK_PROGRAM) $(YAZ_ZOOMTST5_OBJS) /out:$@
868 $(MT) -manifest $@.manifest -outputresource:$@;1
870 $(ZOOMTST6) : "$(BINDIR)" $(YAZ_ZOOMTST6_OBJS) $(YAZ_DLL)
871 $(LINK_PROGRAM) $(YAZ_ZOOMTST6_OBJS) /out:$@
872 $(MT) -manifest $@.manifest -outputresource:$@;1
874 $(ZOOMTST7) : "$(BINDIR)" $(YAZ_ZOOMTST7_OBJS) $(YAZ_DLL)
875 $(LINK_PROGRAM) $(YAZ_ZOOMTST7_OBJS) /out:$@
876 $(MT) -manifest $@.manifest -outputresource:$@;1
878 $(ZOOMTST8) : "$(BINDIR)" $(YAZ_ZOOMTST8_OBJS) $(YAZ_DLL)
879 $(LINK_PROGRAM) $(YAZ_ZOOMTST8_OBJS) /out:$@
880 $(MT) -manifest $@.manifest -outputresource:$@;1
882 $(ZOOMTST9) : "$(BINDIR)" $(YAZ_ZOOMTST9_OBJS) $(YAZ_DLL)
883 $(LINK_PROGRAM) $(YAZ_ZOOMTST9_OBJS) /out:$@
884 $(MT) -manifest $@.manifest -outputresource:$@;1
886 $(ZOOMTST10) : "$(BINDIR)" $(YAZ_ZOOMTST10_OBJS) $(YAZ_DLL)
887 $(LINK_PROGRAM) $(YAZ_ZOOMTST10_OBJS) /out:$@
888 $(MT) -manifest $@.manifest -outputresource:$@;1
890 $(CQL2PQF) : "$(BINDIR)" $(YAZ_CQL2PQF_OBJS) $(YAZ_DLL)
891 $(LINK_PROGRAM) $(YAZ_CQL2PQF_OBJS) /out:$@
892 $(MT) -manifest $@.manifest -outputresource:$@;1
894 $(CQL2XCQL) : "$(BINDIR)" $(YAZ_CQL2XCQL_OBJS) $(YAZ_DLL)
895 $(LINK_PROGRAM) $(YAZ_CQL2XCQL_OBJS) /out:$@
896 $(MT) -manifest $@.manifest -outputresource:$@;1
898 $(ZTEST) : "$(BINDIR)" $(ZTEST_OBJS) $(YAZ_DLL)
899 $(LINK_PROGRAM) $(ZTEST_OBJS) /out:$@
900 $(MT) -manifest $@.manifest -outputresource:$@;1
902 $(YAZ_MARCDUMP) : "$(BINDIR)" $(YAZ_MARCDUMP_OBJS) $(YAZ_DLL)
903 $(LINK_PROGRAM) $(YAZ_MARCDUMP_OBJS) /out:$@
904 $(MT) -manifest $@.manifest -outputresource:$@;1
907 $(TSTLOG) : "$(BINDIR)" $(TSTLOG_OBJS) $(YAZ_DLL)
908 $(LINK_PROGRAM) $(TSTLOG_OBJS) /out:$@
909 $(MT) -manifest $@.manifest -outputresource:$@;1
911 $(TST_TIMING) : "$(BINDIR)" $(TST_TIMING_OBJS) $(YAZ_DLL)
912 $(LINK_PROGRAM) $(TST_TIMING_OBJS) /out:$@
913 $(MT) -manifest $@.manifest -outputresource:$@;1
917 $(DOCDIR)\htmlhelp.chm: $(DOCDIR)\htmlhelp.hhp
931 -del $(SRCDIR)\marc8.c
934 -del $(SRCDIR)\ill-core.c
935 -del $(SRCDIR)\item-req.c
936 -del $(INCLDIR)\yaz\ill-core.h
937 -del $(INCLDIR)\yaz\item-req.h
938 -del $(INCLDIR)\yaz\z-accdes1.h
939 -del $(INCLDIR)\yaz\z-core.h
940 -del $(DATETIME_H_FILES)
941 -del $(UNIVRES_H_FILES)
942 -del $(ESUPDATE_H_FILES)
944 # Because DOS del will only accept one file name to delete,
945 # the _H_ files work only on sets that have just one file.
946 # Z3950_H_FILES had to be spelled out. One more point for MS!
948 # check directories and create if needed
949 dirs: $(OBJDIR) $(WINDIR) $(LIBDIR) $(BINDIR) $(TMPDIR)
951 $(OBJDIR) $(WINDIR) $(LIBDIR) $(BINDIR) $(TMPDIR):
952 if not exist "$@/$(NUL)" mkdir "$@"
955 # Explicit dependencies
957 # force recompilation of everything, if makefile changed
959 $(Z3950_OBJS): $(GENERATED_C_FILES) $(GENERATED_H_FILES)
961 $(ILL_OBJS): $(ILL_CORE_FILES) $(ITEM_REQ_FILES)
963 # makes sure we generate before compiling anything, as the
964 # new proto.h refers to the generated files, and is included