# Copyright (C) 1994-2005, Index Data ApS
# All rights reserved.
-# $Id: makefile,v 1.95 2005-08-18 18:42:37 adam Exp $
+# $Id: makefile,v 1.97 2005-11-29 20:40:33 adam Exp $
#
# Programmed by
# Heikki Levanto & Adam Dickmeiss
default: all
-all: dirs generate dll client ztest zoomsh utilprog iconv libxml2
+all: dirs generate dll client ztest zoomsh utilprog testprog iconv libxml2
NSIS="c:\program files\nsis\makensis.exe"
+HHC="c:\program files\html help workshop\hhc.exe"
dist:
nmake DEBUG=1 clean
generate: generated_files
+
+
###########################################################
############### Directories
###########################################################
BINDIR=$(ROOTDIR)\bin # We produce exes and dlls there
WINDIR=$(ROOTDIR)\win # all these Win make things
SRCDIR=$(ROOTDIR)\src # for the case we move them under src
+DOCDIR=$(ROOTDIR)\doc # where the doc is
# where we store intermediate files
!if $(DEBUG)
ZTESTDIR=$(ROOTDIR)\ZTEST
ZOOMDIR=$(ROOTDIR)\ZOOM
UTILDIR=$(ROOTDIR)\UTIL
+TESTDIR=$(ROOTDIR)\TEST
TMPDIR=$(ROOTDIR)\win\tmp
TMP=$(TMPDIR)
ZOOMTST6=$(BINDIR)\zoomtst6.exe
ZOOMTST7=$(BINDIR)\zoomtst7.exe
ZOOMTST8=$(BINDIR)\zoomtst8.exe
+ZOOMTST9=$(BINDIR)\zoomtst9.exe
CQL2PQF=$(BINDIR)\cql2pqf.exe
CQL2XCQL=$(BINDIR)\cql2xcql.exe
YAZ_MARCDUMP=$(BINDIR)\yaz-marcdump.exe
+TSTLOG=$(BINDIR)\tstlog.exe
+
# shortcut names defined here
dll: dirs generate $(DLL)
client: dirs generate $(CLIENT)
ztest: dirs generate $(ZTEST)
zoomsh: $(ZOOMSH) $(ZOOMTST1) $(ZOOMTST2) $(ZOOMTST3) \
- $(ZOOMTST4) $(ZOOMTST5) $(ZOOMTST6) $(ZOOMTST7) $(ZOOMTST8)
+ $(ZOOMTST4) $(ZOOMTST5) $(ZOOMTST6) $(ZOOMTST7) $(ZOOMTST8) $(ZOOMTST9)
utilprog: $(CQL2PQF) $(CQL2XCQL) $(YAZ_MARCDUMP)
+testprog: $(TSTLOG)
+
+htmlhelp: $(DOCDIR)\htmlhelp.chm
+
###########################################################
############### Compiler and linker options
###########################################################
$(OBJDIR)\zoomtst7.obj
YAZ_ZOOMTST8_OBJS = \
$(OBJDIR)\zoomtst8.obj
+YAZ_ZOOMTST9_OBJS = \
+ $(OBJDIR)\zoomtst9.obj
YAZ_CQL2PQF_OBJS = \
$(OBJDIR)\cql2pqf.obj
YAZ_MARCDUMP_OBJS = \
$(OBJDIR)\marcdump.obj
+TSTLOG_OBJS = \
+ $(OBJDIR)\tstlog.obj
+
YAZ_SERVER_OBJS= \
"$(OBJDIR)\eventl.obj" \
"$(OBJDIR)\requestq.obj" \
{$(UTILDIR)}.c{$(OBJDIR)}.obj:
$(CPP) $(COPT) $<
+{$(TESTDIR)}.c{$(OBJDIR)}.obj:
+ $(CPP) $(COPT) $<
+
############### ASN-generated files
!if $(HAVE_TCL)
/out:$(ZOOMTST8)
<<
+
+$(ZOOMTST9) : "$(BINDIR)" $(YAZ_ZOOMTST9_OBJS)
+ @echo Linking $(ZOOMTST9)
+ $(LINK) @<<
+ $(LNKOPT)
+ $(CLIENT_LINK_OPTIONS)
+ $(LINK_LIBS)
+ $(IMPLIB)
+ $(YAZ_ZOOMTST9_OBJS)
+ /map:"$(LIBDIR)\zoomtst9.map"
+ /out:$(ZOOMTST9)
+<<
+
$(CQL2PQF) : "$(BINDIR)" $(YAZ_CQL2PQF_OBJS)
@echo Linking $(CQL2PQF)
$(LINK) @<<
<<
+$(TSTLOG) : "$(BINDIR)" $(TSTLOG_OBJS)
+ @echo Linking $(TSTLOG)
+ $(LINK) @<<
+ $(LNKOPT)
+ $(CLIENT_LINK_OPTIONS)
+ $(LINK_LIBS)
+ $(IMPLIB)
+ $(TSTLOG_OBJS)
+ /map:"$(LIBDIR)\tstlog.map"
+ /out:$(TSTLOG)
+<<
+
+$(DOCDIR)\htmlhelp.chm: $(DOCDIR)\htmlhelp.hhp
+ @cd $(DOCDIR)
+ -$(HHC) htmlhelp.hhp
+ @cd $(WINDIR)
+
# note that this links a lib, so it uses completely different options.
###########################################################