-# Gnu Makefile for Win32 target * 29-Jan-2006\r
+# Gnu Makefile for Win32 target * 19-May-2006\r
# for use with MingW32 gcc or Metrowerks CodeWarrior compiler\r
-# use with: make -f Makefile.Win32 [all|clean|dist]\r
+# use with: make -f Makefile.Win32 [all|clean|dist|distclean]\r
\r
DESCR = Round Robin Database Tool\r
COPYR = Copyright (c) 1997-2006 by Tobias Oetiker\r
\r
# Set the default font used in graphs.\r
ifndef RRD_DEFAULT_FONT\r
-RRD_DEFAULT_FONT = "arial.ttf"\r
+#RRD_DEFAULT_FONT = "arial.ttf"\r
#RRD_DEFAULT_FONT = "DejaVuSansMono-Roman.ttf"\r
-#RRD_DEFAULT_FONT = "VeraMono.ttf"\r
+RRD_DEFAULT_FONT = "VeraMono.ttf"\r
endif\r
\r
# Vertical label angle: 90.0 (default) or 270.0\r
# Set to one if you want to have piecharts.\r
WITH_PIECHART = 1\r
\r
-# Edit the path below to point to your install destination.\r
-INSTDIR = c:/rrdtool\r
+# Set the extension used for rrdcgi.\r
+ifndef CGIEXT\r
+CGIEXT = exe\r
+endif\r
\r
# Base for the lib sources\r
ifndef LIBBASE\r
# All library code is statically linked to avoid problems with other lib DLLs. \r
# Edit the path below to point to your libpng sources or set environment var.\r
ifndef LIBPNG\r
-LIBPNG = $(LIBBASE)/libpng-1.2.8\r
+LIBPNG = $(LIBBASE)/libpng-1.2.10\r
endif\r
# Edit the path below to point to your freetype sources or set environment var.\r
ifndef LIBFT2\r
-#LIBFT2 = $(LIBBASE)/freetype-2.1.9\r
-LIBFT2 = $(LIBBASE)/../mingw32/freetype-2.1.9\r
+#LIBFT2 = $(LIBBASE)/freetype-2.1.10\r
+LIBFT2 = $(LIBBASE)/../mingw32/freetype-2.1.10\r
endif\r
# Edit the path below to point to your freetype sources or set environment var.\r
ifndef LIBART\r
LIBCGI = $(LIBBASE)/cgilib-0.5\r
endif\r
\r
+# Edit the path below to point to your distribution folder.\r
+ifndef DISTDIR\r
+DISTDIR = rrdtool-$(RRD_VERSION_STR)-w32\r
+endif\r
+ARCHIVE = $(DISTDIR).zip\r
+\r
# whatever...\r
NO_NULL_REALLOC = 1\r
\r
CP = cp -afv\r
\r
ZIP = zip -qzR9\r
-ARCHIVE = rrdtool-$(RRD_VERSION_STR)-w32.zip\r
\r
# must be equal to DEBUG or NDEBUG\r
DB = NDEBUG\r
all: rrdtool rrdcgi\r
\r
rrdtool: $(OBJDIR) config.h $(OBJDIR)/rrdtool.exe\r
-rrdcgi: $(OBJDIR) config.h $(OBJDIR)/rrdcgi.exe\r
+rrdcgi: $(OBJDIR) config.h $(OBJDIR)/rrdcgi.$(CGIEXT)\r
librrd: $(OBJDIR) config.h $(OBJDIR)/librrd.$(LIBEXT)\r
\r
-dist: all $(OBJDIR)/readme.txt\r
- -$(RM) $(OBJDIR)/*.o $(OBJDIR)/*.map $(OBJDIR)/*.ncv\r
- -$(RM) $(OBJDIR)/*.def $(OBJDIR)/*.res $(OBJDIR)/*.rc\r
- -$(RM) $(OBJDIR)/version.inc\r
- @-$(CP) ../CHANGES $(OBJDIR)\r
- @-$(CP) ../COPYING $(OBJDIR)\r
- @-$(CP) ../COPYRIGHT $(OBJDIR)\r
- @-$(CP) ../NEWS $(OBJDIR)\r
- @-$(CP) ../README $(OBJDIR)\r
+dist: all $(DISTDIR) $(DISTDIR)/readme.txt\r
+# @-$(CP) $(OBJDIR)/librrd.$(LIBEXT) $(DISTDIR)\r
+ @-$(CP) $(OBJDIR)/rrdcgi.$(CGIEXT) $(DISTDIR)\r
+ @-$(CP) $(OBJDIR)/rrdtool.exe $(DISTDIR)\r
+ @-$(CP) $(RRD_DEFAULT_FONT) $(DISTDIR)\r
+ @-$(CP) ../CHANGES $(DISTDIR)\r
+ @-$(CP) ../COPYING $(DISTDIR)\r
+ @-$(CP) ../COPYRIGHT $(DISTDIR)\r
+ @-$(CP) ../NEWS $(DISTDIR)\r
+ @-$(CP) ../README $(DISTDIR)\r
@echo Creating $(ARCHIVE)\r
- @$(ZIP) $(ARCHIVE) $(OBJDIR)/* < $(OBJDIR)/readme.txt\r
-\r
-install: all\r
- @[ -d $(INSTDIR) ] || mkdir $(INSTDIR)\r
- @$(CP) $(OBJDIR)/*.exe $(INSTDIR)\r
+ @$(ZIP) $(ARCHIVE) $(DISTDIR)/* < $(DISTDIR)/readme.txt\r
\r
clean:\r
-$(RM) -r $(OBJDIR)\r
-$(RM) config.h\r
\r
-cleandist: clean\r
+distclean: clean\r
+ -$(RM) -r $(DISTDIR)\r
-$(RM) $(ARCHIVE)\r
\r
$(OBJDIR):\r
- @mkdir $(OBJDIR)\r
+ @mkdir $@\r
+\r
+$(DISTDIR):\r
+ @mkdir $@\r
\r
$(OBJDIR)/version.inc: ../configure.ac $(OBJDIR) get_ver.awk\r
@echo Creating $@\r
@echo Compiling $<\r
@$(CC) $(CFLAGS) -c $< -o $@\r
\r
-$(OBJDIR)/rrdcgi.exe: $(OBJCGI) $(OBJDIR)/rrdcgi.res\r
+$(OBJDIR)/rrdcgi.$(CGIEXT): $(OBJCGI) $(OBJDIR)/rrdcgi.res\r
@echo Linking $@\r
@-$(RM) $@\r
@$(LD) $(LDFLAGS) $^ -o $@ $(LIBPATH) $(LDLIBS)\r
@echo $(DL)#define WITH_PIECHART 1$(DL) >> $@\r
endif\r
\r
-$(OBJDIR)/readme.txt: Makefile.Win32\r
+$(DISTDIR)/readme.txt: Makefile.Win32\r
@echo Creating $@\r
@echo $(DL)This is a binary distribution for Win32 platform.$(DL) > $@\r
@echo $(DL)RRDTool version $(RRD_VERSION_STR)$(DL) >> $@\r