Use mk_version.tcl on Windows
[idzebra-moved-to-github.git] / win / makefile
index 40cb077..2f79a72 100644 (file)
@@ -1,5 +1,4 @@
 # Zebra makefile for MS NMAKE
-# $Id: makefile,v 1.75 2008-01-18 11:33:36 adam Exp $
  
 ###########################################################
 ############### Parameters 
@@ -7,6 +6,10 @@
 
 DEBUG=0   # 0 for release, 1 for debug
 
+# TCL is optional - ONLY needed for source straight from Git
+TCL="C:\Tcl\bin\tclsh85.exe"
+HAVE_TCL=1
+
 # EXPAT is optional. It's required for grs.xml-filters.
 HAVE_EXPAT=1
 EXPAT_DIR=c:\Program files\Expat 2.0.1
@@ -17,11 +20,11 @@ ICONV_DIR=c:\iconv-1.9.2.win32
 
 # libxslt. For mod_dom and mod_alvis
 HAVE_LIBXSLT=1
-LIBXSLT_DIR=c:\libxslt-1.1.19.win32
+LIBXSLT_DIR=c:\libxslt-1.1.24.win32
 
 # libxml2. Used by libxslt
 HAVE_LIBXML2=1
-LIBXML2_DIR=c:\libxml2-2.6.28.win32
+LIBXML2_DIR=c:\libxml2-2.7.1.win32
 
 # zlib compression.  Used by libxml2
 ZLIB_DIR = c:\zlib-1.2.3.win32
@@ -36,7 +39,7 @@ ICU_DIR=c:\icu
 
 
 default: all
-all: dirs expat iconv libxml2 libxslt icu yaz dll zserver zebraidx tstflock
+all: dirs generate expat iconv libxml2 libxslt icu yaz dll zserver zebraidx tstflock
 
 # Directories
 # The current directory is supposed to be something like
@@ -200,14 +203,14 @@ libxslt:
 !if $(HAVE_ICU)
 ICU_DEF= /DYAZ_HAVE_ICU=1  /I"$(ICU_DIR)\include"
 ICU_LIB= $(ICU_DIR)\lib\icudt.lib $(ICU_DIR)\lib\icuin.lib $(ICU_DIR)\lib\icuuc.lib
-icu: $(BINDIR)\icudt38.dll $(BINDIR)\icuin38.dll $(BINDIR)\icuuc38.dll
-
-$(BINDIR)\icudt38.dll:
-         copy "$(ICU_DIR)\bin\icudt38.dll" $(BINDIR)
-$(BINDIR)\icuin38.dll:
-         copy "$(ICU_DIR)\bin\icuin38.dll" $(BINDIR)
-$(BINDIR)\icuuc38.dll:
-         copy "$(ICU_DIR)\bin\icuuc38.dll" $(BINDIR)
+icu: $(BINDIR)\icudt40.dll $(BINDIR)\icuin40.dll $(BINDIR)\icuuc40.dll
+
+$(BINDIR)\icudt40.dll:
+         copy "$(ICU_DIR)\bin\icudt40.dll" $(BINDIR)
+$(BINDIR)\icuin40.dll:
+         copy "$(ICU_DIR)\bin\icuin40.dll" $(BINDIR)
+$(BINDIR)\icuuc40.dll:
+         copy "$(ICU_DIR)\bin\icuuc40.dll" $(BINDIR)
 !else
 ICU_DEF=  /DYAZ_HAVE_ICU=0
 ICU_LIB=
@@ -332,6 +335,14 @@ LINK_PROGRAM= $(LINK) \
                $(BZIP2LIB) \
                $(LINK_LIBS)
 
+
+# Generated sources
+generate: $(INCLDIR)\idzebra\version.h
+
+$(INCLDIR)\idzebra\version.h:
+       @cd $(ROOTDIR)\util
+       $(TCL) mk_version.tcl $(ROOTDIR)/configure.ac $(INCLDIR)\idzebra\version.h
+
 # Source and object modules
 # Note: Ordinary source files are not specified here at 
 # all, make finds them in suitable dirs. The object modules