Version 2.9

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
This commit is contained in:
Sami Kerola 2008-09-06 00:00:00 +02:00
parent 40edcd2aba
commit 573418a9e4
29 changed files with 16790 additions and 7978 deletions

View file

@ -1,3 +1,11 @@
2008-09-06 Sami Kerola <kerolasa@iki.fi>
* Release 2.9 - bug fixes.
* Bug report from Fredrik Vöcks
- Include files & shared network name bug fixed.
- If first range had no leases analysis crashed.
* Linux style indent.
* Autotool files update.
2008-06-21 Sami Kerola <kerolasa@iki.fi>
* dhcpd-pools.c: Default will skip merge sorting.
* getdata.c: Interpretation of range wrote without spaces fixed.

View file

@ -1,8 +1,8 @@
# Makefile.in generated by automake 1.6.3 from Makefile.am.
# Makefile.in generated by automake 1.10.1 from Makefile.am.
# @configure_input@
# Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
# Free Software Foundation, Inc.
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@ -13,129 +13,207 @@
# PARTICULAR PURPOSE.
@SET_MAKE@
SHELL = @SHELL@
srcdir = @srcdir@
top_srcdir = @top_srcdir@
VPATH = @srcdir@
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
sbindir = @sbindir@
libexecdir = @libexecdir@
datadir = @datadir@
sysconfdir = @sysconfdir@
sharedstatedir = @sharedstatedir@
localstatedir = @localstatedir@
libdir = @libdir@
infodir = @infodir@
mandir = @mandir@
includedir = @includedir@
oldincludedir = /usr/include
pkgdatadir = $(datadir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
top_builddir = .
ACLOCAL = @ACLOCAL@
AUTOCONF = @AUTOCONF@
AUTOMAKE = @AUTOMAKE@
AUTOHEADER = @AUTOHEADER@
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA = @INSTALL_DATA@
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_HEADER = $(INSTALL_DATA)
transform = @program_transform_name@
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
EXEEXT = @EXEEXT@
OBJEXT = @OBJEXT@
PATH_SEPARATOR = @PATH_SEPARATOR@
AMTAR = @AMTAR@
AWK = @AWK@
CC = @CC@
DEPDIR = @DEPDIR@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
PACKAGE = @PACKAGE@
PERL = @PERL@
STRIP = @STRIP@
VERSION = @VERSION@
am__include = @am__include@
am__quote = @am__quote@
dhcpd_conf = @dhcpd_conf@
dhcpd_leases = @dhcpd_leases@
install_sh = @install_sh@
output_format = @output_format@
output_limit = @output_limit@
AUTOMAKE_OPTIONS = 1.5 gnits
SUBDIRS = src man
subdir = .
DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
$(srcdir)/Makefile.in $(srcdir)/config.h.in \
$(top_srcdir)/configure AUTHORS COPYING ChangeLog INSTALL NEWS \
THANKS TODO depcomp install-sh missing mkinstalldirs
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/configure.in
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
configure.lineno config.status.lineno
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
CONFIG_HEADER = config.h
CONFIG_CLEAN_FILES =
SOURCES =
DIST_SOURCES =
RECURSIVE_TARGETS = info-recursive dvi-recursive install-info-recursive \
uninstall-info-recursive all-recursive install-data-recursive \
install-exec-recursive installdirs-recursive install-recursive \
uninstall-recursive check-recursive installcheck-recursive
DIST_COMMON = README AUTHORS COPYING ChangeLog INSTALL Makefile.am \
Makefile.in NEWS THANKS TODO aclocal.m4 config.h.in configure \
configure.in depcomp install-sh missing mkinstalldirs
RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
html-recursive info-recursive install-data-recursive \
install-dvi-recursive install-exec-recursive \
install-html-recursive install-info-recursive \
install-pdf-recursive install-ps-recursive install-recursive \
installcheck-recursive installdirs-recursive pdf-recursive \
ps-recursive uninstall-recursive
RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
distclean-recursive maintainer-clean-recursive
ETAGS = etags
CTAGS = ctags
DIST_SUBDIRS = $(SUBDIRS)
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
distdir = $(PACKAGE)-$(VERSION)
top_distdir = $(distdir)
am__remove_distdir = \
{ test ! -d $(distdir) \
|| { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \
&& rm -fr $(distdir); }; }
DIST_ARCHIVES = $(distdir).tar.gz
GZIP_ENV = --best
distuninstallcheck_listfiles = find . -type f -print
distcleancheck_listfiles = find . -type f -print
ACLOCAL = @ACLOCAL@
ALLOCA = @ALLOCA@
AMTAR = @AMTAR@
AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
EXEEXT = @EXEEXT@
GREP = @GREP@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LDFLAGS = @LDFLAGS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LTLIBOBJS = @LTLIBOBJS@
MAKEINFO = @MAKEINFO@
MKDIR_P = @MKDIR_P@
OBJEXT = @OBJEXT@
PACKAGE = @PACKAGE@
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
PERL = @PERL@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
STRIP = @STRIP@
VERSION = @VERSION@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
ac_ct_CC = @ac_ct_CC@
am__include = @am__include@
am__leading_dot = @am__leading_dot@
am__quote = @am__quote@
am__tar = @am__tar@
am__untar = @am__untar@
bindir = @bindir@
build_alias = @build_alias@
builddir = @builddir@
datadir = @datadir@
datarootdir = @datarootdir@
dhcpd_conf = @dhcpd_conf@
dhcpd_leases = @dhcpd_leases@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@
host_alias = @host_alias@
htmldir = @htmldir@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@
output_format = @output_format@
output_limit = @output_limit@
pdfdir = @pdfdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
sysconfdir = @sysconfdir@
target_alias = @target_alias@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
AUTOMAKE_OPTIONS = 1.5 gnits
SUBDIRS = src man
all: config.h
$(MAKE) $(AM_MAKEFLAGS) all-recursive
.SUFFIXES:
am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
configure.lineno
$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4)
am--refresh:
@:
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
echo ' cd $(srcdir) && $(AUTOMAKE) --gnits '; \
cd $(srcdir) && $(AUTOMAKE) --gnits \
&& exit 0; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnits Makefile'; \
cd $(top_srcdir) && \
$(AUTOMAKE) --gnits Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)
.PRECIOUS: Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
echo ' $(SHELL) ./config.status'; \
$(SHELL) ./config.status;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \
esac;
$(top_builddir)/config.status: $(srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
$(SHELL) ./config.status --recheck
$(srcdir)/configure: $(srcdir)/configure.in $(ACLOCAL_M4) $(CONFIGURE_DEPENDENCIES)
cd $(srcdir) && $(AUTOCONF)
$(ACLOCAL_M4): configure.in
$(top_srcdir)/configure: $(am__configure_deps)
cd $(srcdir) && $(AUTOCONF)
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
config.h: stamp-h1
@if test ! -f $@; then \
rm -f stamp-h1; \
$(MAKE) stamp-h1; \
$(MAKE) $(AM_MAKEFLAGS) stamp-h1; \
else :; fi
stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status
@rm -f stamp-h1
cd $(top_builddir) && $(SHELL) ./config.status config.h
$(srcdir)/config.h.in: $(top_srcdir)/configure.in $(ACLOCAL_M4)
$(srcdir)/config.h.in: $(am__configure_deps)
cd $(top_srcdir) && $(AUTOHEADER)
touch $(srcdir)/config.h.in
rm -f stamp-h1
touch $@
distclean-hdr:
-rm -f config.h stamp-h1
uninstall-info-am:
# This directory's subdirectories are mostly independent; you can cd
# into them and run `make' without going through this Makefile.
@ -144,7 +222,13 @@ uninstall-info-am:
# (which will cause the Makefiles to be regenerated when you run `make');
# (2) otherwise, pass the desired values on the `make' command line.
$(RECURSIVE_TARGETS):
@set fnord $$MAKEFLAGS; amf=$$2; \
@failcom='exit 1'; \
for f in x $$MAKEFLAGS; do \
case $$f in \
*=* | --[!k]*);; \
*k*) failcom='fail=yes';; \
esac; \
done; \
dot_seen=no; \
target=`echo $@ | sed s/-recursive//`; \
list='$(SUBDIRS)'; for subdir in $$list; do \
@ -156,15 +240,20 @@ $(RECURSIVE_TARGETS):
local_target="$$target"; \
fi; \
(cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|| case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
|| eval $$failcom; \
done; \
if test "$$dot_seen" = "no"; then \
$(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
fi; test -z "$$fail"
mostlyclean-recursive clean-recursive distclean-recursive \
maintainer-clean-recursive:
@set fnord $$MAKEFLAGS; amf=$$2; \
$(RECURSIVE_CLEAN_TARGETS):
@failcom='exit 1'; \
for f in x $$MAKEFLAGS; do \
case $$f in \
*=* | --[!k]*);; \
*k*) failcom='fail=yes';; \
esac; \
done; \
dot_seen=no; \
case "$@" in \
distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
@ -185,44 +274,67 @@ maintainer-clean-recursive:
local_target="$$target"; \
fi; \
(cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|| case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
|| eval $$failcom; \
done && test -z "$$fail"
tags-recursive:
list='$(SUBDIRS)'; for subdir in $$list; do \
test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
done
ETAGS = etags
ETAGSFLAGS =
tags: TAGS
ctags-recursive:
list='$(SUBDIRS)'; for subdir in $$list; do \
test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
done
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
$(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
END { if (nonempty) { for (i in files) print i; }; }'`; \
mkid -fID $$unique
tags: TAGS
TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
$(TAGS_FILES) $(LISP)
tags=; \
here=`pwd`; \
if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
include_option=--etags-include; \
empty_fix=.; \
else \
include_option=--include; \
empty_fix=; \
fi; \
list='$(SUBDIRS)'; for subdir in $$list; do \
if test "$$subdir" = .; then :; else \
test -f $$subdir/TAGS && tags="$$tags -i $$here/$$subdir/TAGS"; \
test ! -f $$subdir/TAGS || \
tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \
fi; \
done; \
list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
test -z "$(ETAGS_ARGS)$$tags$$unique" \
|| $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in files) print i; }; }'`; \
if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$tags $$unique; \
fi
ctags: CTAGS
CTAGS: ctags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
$(TAGS_FILES) $(LISP)
tags=; \
list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in files) print i; }; }'`; \
test -z "$(CTAGS_ARGS)$$tags$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$tags $$unique
GTAGS:
@ -231,38 +343,32 @@ GTAGS:
&& gtags -i $(GTAGS_ARGS) $$here
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
top_distdir = .
distdir = $(PACKAGE)-$(VERSION)
am__remove_distdir = \
{ test ! -d $(distdir) \
|| { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \
&& rm -fr $(distdir); }; }
GZIP_ENV = --best
distcleancheck_listfiles = find . -type f -print
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(DISTFILES)
@if sed 15q $(srcdir)/NEWS | fgrep -e "$(VERSION)" >/dev/null; \
then :; else \
@case `sed 15q $(srcdir)/NEWS` in \
*"$(VERSION)"*) : ;; \
*) \
echo "NEWS not updated; not releasing" 1>&2; \
exit 1; \
fi
exit 1;; \
esac
$(am__remove_distdir)
mkdir $(distdir)
@list='$(DISTFILES)'; for file in $$list; do \
test -d $(distdir) || mkdir $(distdir)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \
if test "$$dir" != "$$file" && test "$$dir" != "."; then \
dir="/$$dir"; \
$(mkinstalldirs) "$(distdir)$$dir"; \
else \
dir=''; \
fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
fi; \
@ -273,15 +379,19 @@ distdir: $(DISTFILES)
|| exit 1; \
fi; \
done
list='$(SUBDIRS)'; for subdir in $$list; do \
list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
if test "$$subdir" = .; then :; else \
test -d $(distdir)/$$subdir \
|| mkdir $(distdir)/$$subdir \
test -d "$(distdir)/$$subdir" \
|| $(MKDIR_P) "$(distdir)/$$subdir" \
|| exit 1; \
distdir=`$(am__cd) $(distdir) && pwd`; \
top_distdir=`$(am__cd) $(top_distdir) && pwd`; \
(cd $$subdir && \
$(MAKE) $(AM_MAKEFLAGS) \
top_distdir="$(top_distdir)" \
distdir=../$(distdir)/$$subdir \
top_distdir="$$top_distdir" \
distdir="$$distdir/$$subdir" \
am__remove_distdir=: \
am__skip_length_check=: \
distdir) \
|| exit 1; \
fi; \
@ -289,29 +399,63 @@ distdir: $(DISTFILES)
-find $(distdir) -type d ! -perm -777 -exec chmod a+rwx {} \; -o \
! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
! -type d ! -perm -400 -exec chmod a+r {} \; -o \
! -type d ! -perm -444 -exec $(SHELL) $(install_sh) -c -m a+r {} {} \; \
! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \
|| chmod -R a+r $(distdir)
dist-gzip: distdir
$(AMTAR) chof - $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
$(am__remove_distdir)
dist-bzip2: distdir
tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2
$(am__remove_distdir)
dist-lzma: distdir
tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma
$(am__remove_distdir)
dist-tarZ: distdir
tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
$(am__remove_distdir)
dist-shar: distdir
shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
$(am__remove_distdir)
dist-zip: distdir
-rm -f $(distdir).zip
zip -rq $(distdir).zip $(distdir)
$(am__remove_distdir)
dist dist-all: distdir
$(AMTAR) chof - $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
$(am__remove_distdir)
# This target untars the dist file and tries a VPATH configuration. Then
# it guarantees that the distribution is self-contained by making another
# tarfile.
distcheck: dist
$(am__remove_distdir)
GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(AMTAR) xf -
case '$(DIST_ARCHIVES)' in \
*.tar.gz*) \
GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\
*.tar.bz2*) \
bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\
*.tar.lzma*) \
unlzma -c $(distdir).tar.lzma | $(am__untar) ;;\
*.tar.Z*) \
uncompress -c $(distdir).tar.Z | $(am__untar) ;;\
*.shar.gz*) \
GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\
*.zip*) \
unzip $(distdir).zip ;;\
esac
chmod -R a-w $(distdir); chmod a+w $(distdir)
mkdir $(distdir)/=build
mkdir $(distdir)/=inst
mkdir $(distdir)/_build
mkdir $(distdir)/_inst
chmod a-w $(distdir)
dc_install_base=`$(am__cd) $(distdir)/=inst && pwd` \
&& cd $(distdir)/=build \
&& ../configure --srcdir=.. --prefix=$$dc_install_base \
dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \
&& dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
&& cd $(distdir)/_build \
&& ../configure --srcdir=.. --prefix="$$dc_install_base" \
$(DISTCHECK_CONFIGURE_FLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) dvi \
@ -319,23 +463,40 @@ distcheck: dist
&& $(MAKE) $(AM_MAKEFLAGS) install \
&& $(MAKE) $(AM_MAKEFLAGS) installcheck \
&& $(MAKE) $(AM_MAKEFLAGS) uninstall \
&& (test `find $$dc_install_base -type f -print | wc -l` -le 1 \
|| { echo "ERROR: files left after uninstall:" ; \
find $$dc_install_base -type f -print ; \
exit 1; } >&2 ) \
&& $(MAKE) $(AM_MAKEFLAGS) dist-gzip \
&& rm -f $(distdir).tar.gz \
&& $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \
distuninstallcheck \
&& chmod -R a-w "$$dc_install_base" \
&& ({ \
(cd ../.. && umask 077 && mkdir "$$dc_destdir") \
&& $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \
&& $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \
&& $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \
distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \
} || { rm -rf "$$dc_destdir"; exit 1; }) \
&& rm -rf "$$dc_destdir" \
&& $(MAKE) $(AM_MAKEFLAGS) dist \
&& rm -rf $(DIST_ARCHIVES) \
&& $(MAKE) $(AM_MAKEFLAGS) distcleancheck
$(am__remove_distdir)
@echo "$(distdir).tar.gz is ready for distribution" | \
sed 'h;s/./=/g;p;x;p;x'
@(echo "$(distdir) archives ready for distribution: "; \
list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x'
distuninstallcheck:
@cd $(distuninstallcheck_dir) \
&& test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \
|| { echo "ERROR: files left after uninstall:" ; \
if test -n "$(DESTDIR)"; then \
echo " (check DESTDIR support)"; \
fi ; \
$(distuninstallcheck_listfiles) ; \
exit 1; } >&2
distcleancheck: distclean
if test '$(srcdir)' = . ; then \
@if test '$(srcdir)' = . ; then \
echo "ERROR: distcleancheck can only run from a VPATH build" ; \
exit 1 ; \
fi
test `$(distcleancheck_listfiles) | wc -l` -eq 0 \
|| { echo "ERROR: files left after distclean:" ; \
@test `$(distcleancheck_listfiles) | wc -l` -eq 0 \
|| { echo "ERROR: files left in build directory after distclean:" ; \
$(distcleancheck_listfiles) ; \
exit 1; } >&2
check-am: all-am
@ -343,7 +504,6 @@ check: check-recursive
all-am: Makefile config.h
installdirs: installdirs-recursive
installdirs-am:
install: install-recursive
install-exec: install-exec-recursive
install-data: install-data-recursive
@ -355,7 +515,7 @@ install-am: all-am
installcheck: installcheck-recursive
install-strip:
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
INSTALL_STRIP_FLAG=-s \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
`test -z '$(STRIP)' || \
echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
mostlyclean-generic:
@ -363,7 +523,7 @@ mostlyclean-generic:
clean-generic:
distclean-generic:
-rm -f Makefile $(CONFIG_CLEAN_FILES)
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@ -374,54 +534,74 @@ clean-am: clean-generic mostlyclean-am
distclean: distclean-recursive
-rm -f $(am__CONFIG_DISTCLEAN_FILES)
-rm -f Makefile
distclean-am: clean-am distclean-generic distclean-hdr distclean-tags
dvi: dvi-recursive
dvi-am:
html: html-recursive
info: info-recursive
info-am:
install-data-am:
install-dvi: install-dvi-recursive
install-exec-am:
install-html: install-html-recursive
install-info: install-info-recursive
install-man:
install-pdf: install-pdf-recursive
install-ps: install-ps-recursive
installcheck-am:
maintainer-clean: maintainer-clean-recursive
-rm -f $(am__CONFIG_DISTCLEAN_FILES)
-rm -rf autom4te.cache
-rm -rf $(top_srcdir)/autom4te.cache
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-recursive
mostlyclean-am: mostlyclean-generic
uninstall-am: uninstall-info-am
pdf: pdf-recursive
uninstall-info: uninstall-info-recursive
pdf-am:
.PHONY: $(RECURSIVE_TARGETS) GTAGS all all-am check check-am clean \
clean-generic clean-recursive dist dist-all dist-gzip distcheck \
distclean distclean-generic distclean-hdr distclean-recursive \
distclean-tags distcleancheck distdir dvi dvi-am dvi-recursive \
info info-am info-recursive install install-am install-data \
install-data-am install-data-recursive install-exec \
install-exec-am install-exec-recursive install-info \
install-info-am install-info-recursive install-man \
install-recursive install-strip installcheck installcheck-am \
installdirs installdirs-am installdirs-recursive \
maintainer-clean maintainer-clean-generic \
maintainer-clean-recursive mostlyclean mostlyclean-generic \
mostlyclean-recursive tags tags-recursive uninstall \
uninstall-am uninstall-info-am uninstall-info-recursive \
uninstall-recursive
ps: ps-recursive
ps-am:
uninstall-am:
.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) install-am \
install-strip
.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
all all-am am--refresh check check-am clean clean-generic \
ctags ctags-recursive dist dist-all dist-bzip2 dist-gzip \
dist-lzma dist-shar dist-tarZ dist-zip distcheck distclean \
distclean-generic distclean-hdr distclean-tags distcleancheck \
distdir distuninstallcheck dvi dvi-am html html-am info \
info-am install install-am install-data install-data-am \
install-dvi install-dvi-am install-exec install-exec-am \
install-html install-html-am install-info install-info-am \
install-man install-pdf install-pdf-am install-ps \
install-ps-am install-strip installcheck installcheck-am \
installdirs installdirs-am maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-generic pdf \
pdf-am ps ps-am tags tags-recursive uninstall uninstall-am
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.

6
NEWS
View file

@ -5,6 +5,12 @@ See the end for copying conditions.
Please send dhcpd-pools bug reports to kerolasa@iki.fi.
Version 2.9
* Include files & shared network name bug fixed.
* If first range had no leases analysis crashed.
* Linux style indent.
Version 2.8
* dhcpd-pools.c: Default will skip merge sorting.

16
README
View file

@ -14,13 +14,15 @@ printed is the right thing to do when there is thousands of
addresses. If your address space is small some other dhcp
analyzer might be more suitable for you.
Source code is pretty printed with this indent command
configuration.
Source code is pretty printed by using indent command switches.
-nbad -bap -nbc -bbo -bl -bli2 -bls -ncdb -nce -cp1 -cs -di2 -ndj
-nfc1 -nfca -hnl -i2 -ip5 -lp -pcs -psl -nsc -nsob
-kr -i8
If you write patch please use indent and keep style constant.
If you write a patch please use same coding style. In general the
style is copy from Linux kernel.
Command home page is located at
http://dhcpd-pools.sourceforge.net/
http://escher.sourceforge.net/current/etc/linux-coding-style
A dhcpd-pools home page is located at SourceForge.
http://dhcpd-pools.sourceforge.net/

3
THANKS
View file

@ -5,9 +5,10 @@ Project is originated by Sami Kerola.
Many have reported problems, give improvement suggestions and
have some even contributed code. Here is a list of these people.
Otto J. Mäkelä
Otto J. Mäkeä
Mika Paananen
Frank Bulk
Roar Pettersen
Jeff Wieland
Rusty
Fredrik Vöcks

1356
aclocal.m4 vendored

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

6296
autom4te.cache/output.1 Normal file

File diff suppressed because it is too large Load diff

View file

@ -15,7 +15,10 @@
'configure.in'
],
{
'_LT_AC_TAGCONFIG' => 1,
'AM_PROG_F77_C_O' => 1,
'm4_pattern_forbid' => 1,
'AC_CANONICAL_TARGET' => 1,
'AC_CONFIG_LIBOBJ_DIR' => 1,
'AC_TYPE_OFF_T' => 1,
'AC_C_VOLATILE' => 1,
@ -32,6 +35,7 @@
'AC_FUNC_GETMNTENT' => 1,
'AC_FUNC_STRTOD' => 1,
'AC_CHECK_HEADERS' => 1,
'LT_CONFIG_LTDL_DIR' => 1,
'AC_FUNC_STRNLEN' => 1,
'm4_sinclude' => 1,
'AC_PROG_CXX' => 1,
@ -41,13 +45,18 @@
'_m4_warn' => 1,
'AC_HEADER_STDC' => 1,
'AC_HEADER_MAJOR' => 1,
'AM_PROG_CXX_C_O' => 1,
'LT_INIT' => 1,
'AC_FUNC_ERROR_AT_LINE' => 1,
'AC_PROG_GCC_TRADITIONAL' => 1,
'AC_LIBSOURCE' => 1,
'AC_FUNC_MBRTOWC' => 1,
'AC_STRUCT_ST_BLOCKS' => 1,
'AM_PROG_FC_C_O' => 1,
'AC_CANONICAL_BUILD' => 1,
'AC_TYPE_SIGNAL' => 1,
'AC_TYPE_UID_T' => 1,
'_AM_SUBST_NOTMAKE' => 1,
'AC_CONFIG_AUX_DIR' => 1,
'AC_PROG_MAKE_SET' => 1,
'sinclude' => 1,
@ -60,11 +69,13 @@
'AC_FUNC_VPRINTF' => 1,
'AC_FUNC_STRCOLL' => 1,
'AC_PROG_YACC' => 1,
'AC_SUBST_TRACE' => 1,
'AC_INIT' => 1,
'AC_STRUCT_TIMEZONE' => 1,
'AC_FUNC_CHOWN' => 1,
'AC_SUBST' => 1,
'AC_FUNC_ALLOCA' => 1,
'AC_FC_SRCEXT' => 1,
'AC_CANONICAL_HOST' => 1,
'AC_FUNC_GETPGRP' => 1,
'AC_PROG_RANLIB' => 1,
@ -74,16 +85,20 @@
'AC_FUNC_MMAP' => 1,
'AC_FUNC_REALLOC' => 1,
'AC_TYPE_SIZE_T' => 1,
'AC_REQUIRE_AUX_FILE' => 1,
'AC_CONFIG_LINKS' => 1,
'AC_CHECK_TYPES' => 1,
'LT_SUPPORTED_TAG' => 1,
'AC_CHECK_MEMBERS' => 1,
'AM_MAINTAINER_MODE' => 1,
'AC_FUNC_UTIME_NULL' => 1,
'AC_FUNC_SELECT_ARGTYPES' => 1,
'AM_GNU_GETTEXT_INTL_SUBDIR' => 1,
'AC_FUNC_STRFTIME' => 1,
'AC_HEADER_STAT' => 1,
'AC_C_INLINE' => 1,
'AC_PROG_CPP' => 1,
'AM_ENABLE_MULTILIB' => 1,
'AC_TYPE_PID_T' => 1,
'AC_C_CONST' => 1,
'AC_PROG_LEX' => 1,
@ -96,6 +111,7 @@
'AC_CHECK_LIB' => 1,
'AC_FUNC_MALLOC' => 1,
'AC_FUNC_GETGROUPS' => 1,
'AC_FC_FREEFORM' => 1,
'AC_FUNC_GETLOADAVG' => 1,
'AH_OUTPUT' => 1,
'AC_FUNC_FSEEKO' => 1,
@ -111,6 +127,73 @@
'AC_HEADER_DIRENT' => 1,
'AC_CHECK_FUNCS' => 1
}
], 'Autom4te::Request' ),
bless( [
'1',
1,
[
'/usr/share/autoconf'
],
[
'/usr/share/autoconf/autoconf/autoconf.m4f',
'/usr/share/aclocal-1.10/amversion.m4',
'/usr/share/aclocal-1.10/auxdir.m4',
'/usr/share/aclocal-1.10/cond.m4',
'/usr/share/aclocal-1.10/depend.m4',
'/usr/share/aclocal-1.10/depout.m4',
'/usr/share/aclocal-1.10/header.m4',
'/usr/share/aclocal-1.10/init.m4',
'/usr/share/aclocal-1.10/install-sh.m4',
'/usr/share/aclocal-1.10/lead-dot.m4',
'/usr/share/aclocal-1.10/make.m4',
'/usr/share/aclocal-1.10/missing.m4',
'/usr/share/aclocal-1.10/mkdirp.m4',
'/usr/share/aclocal-1.10/options.m4',
'/usr/share/aclocal-1.10/runlog.m4',
'/usr/share/aclocal-1.10/sanity.m4',
'/usr/share/aclocal-1.10/strip.m4',
'/usr/share/aclocal-1.10/substnot.m4',
'/usr/share/aclocal-1.10/tar.m4',
'configure.in'
],
{
'm4_pattern_forbid' => 1,
'AM_SET_CURRENT_AUTOMAKE_VERSION' => 1,
'_AM_SET_OPTION' => 1,
'AC_DEFUN' => 1,
'AM_PROG_MKDIR_P' => 1,
'AM_INIT_AUTOMAKE' => 1,
'AM_AUTOMAKE_VERSION' => 1,
'AM_MISSING_HAS_RUN' => 1,
'AM_MISSING_PROG' => 1,
'AM_OUTPUT_DEPENDENCY_COMMANDS' => 1,
'AC_DEFUN_ONCE' => 1,
'AM_PROG_INSTALL_STRIP' => 1,
'_m4_warn' => 1,
'AM_SANITY_CHECK' => 1,
'include' => 1,
'_AM_PROG_TAR' => 1,
'AM_AUX_DIR_EXPAND' => 1,
'AM_DEP_TRACK' => 1,
'AM_CONFIG_HEADER' => 1,
'_AM_SET_OPTIONS' => 1,
'AM_RUN_LOG' => 1,
'_AM_OUTPUT_DEPENDENCY_COMMANDS' => 1,
'_AM_IF_OPTION' => 1,
'_AM_SUBST_NOTMAKE' => 1,
'_AM_AUTOCONF_VERSION' => 1,
'm4_pattern_allow' => 1,
'_AM_MANGLE_OPTION' => 1,
'AM_SET_LEADING_DOT' => 1,
'AM_CONDITIONAL' => 1,
'AM_SET_DEPDIR' => 1,
'_AM_DEPENDENCIES' => 1,
'm4_include' => 1,
'AM_PROG_INSTALL_SH' => 1,
'_AC_AM_CONFIG_HEADER_HOOK' => 1,
'AU_DEFUN' => 1,
'AM_MAKE_INCLUDE' => 1
}
], 'Autom4te::Request' )
);

View file

@ -1,5 +1,4 @@
m4trace:aclocal.m4:50: -1- m4_pattern_allow([^AM_[A-Z]+FLAGS$])
m4trace:configure.in:5: -1- AC_INIT([dhcpd-pools], [2.8], [kerolasa@iki.fi])
m4trace:configure.in:5: -1- AC_INIT([dhcpd-pools], [2.9], [kerolasa@iki.fi])
m4trace:configure.in:5: -1- m4_pattern_forbid([^_?A[CHUM]_])
m4trace:configure.in:5: -1- m4_pattern_forbid([_AC_])
m4trace:configure.in:5: -1- m4_pattern_forbid([^LIBOBJS$], [do not use LIBOBJS directly, use AC_LIBOBJ (see section `AC_LIBOBJ vs LIBOBJS'])
@ -8,107 +7,316 @@ m4trace:configure.in:5: -1- m4_pattern_forbid([^_?m4_])
m4trace:configure.in:5: -1- m4_pattern_forbid([^dnl$])
m4trace:configure.in:5: -1- m4_pattern_forbid([^_?AS_])
m4trace:configure.in:5: -1- AC_SUBST([SHELL], [${CONFIG_SHELL-/bin/sh}])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([SHELL])
m4trace:configure.in:5: -1- m4_pattern_allow([^SHELL$])
m4trace:configure.in:5: -1- AC_SUBST([PATH_SEPARATOR])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([PATH_SEPARATOR])
m4trace:configure.in:5: -1- m4_pattern_allow([^PATH_SEPARATOR$])
m4trace:configure.in:5: -1- AC_SUBST([PACKAGE_NAME], [m4_ifdef([AC_PACKAGE_NAME], ['AC_PACKAGE_NAME'])])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([PACKAGE_NAME])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_NAME$])
m4trace:configure.in:5: -1- AC_SUBST([PACKAGE_TARNAME], [m4_ifdef([AC_PACKAGE_TARNAME], ['AC_PACKAGE_TARNAME'])])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([PACKAGE_TARNAME])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_TARNAME$])
m4trace:configure.in:5: -1- AC_SUBST([PACKAGE_VERSION], [m4_ifdef([AC_PACKAGE_VERSION], ['AC_PACKAGE_VERSION'])])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([PACKAGE_VERSION])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_VERSION$])
m4trace:configure.in:5: -1- AC_SUBST([PACKAGE_STRING], [m4_ifdef([AC_PACKAGE_STRING], ['AC_PACKAGE_STRING'])])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([PACKAGE_STRING])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_STRING$])
m4trace:configure.in:5: -1- AC_SUBST([PACKAGE_BUGREPORT], [m4_ifdef([AC_PACKAGE_BUGREPORT], ['AC_PACKAGE_BUGREPORT'])])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([PACKAGE_BUGREPORT])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_BUGREPORT$])
m4trace:configure.in:5: -1- AC_SUBST([exec_prefix], [NONE])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([exec_prefix])
m4trace:configure.in:5: -1- m4_pattern_allow([^exec_prefix$])
m4trace:configure.in:5: -1- AC_SUBST([prefix], [NONE])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([prefix])
m4trace:configure.in:5: -1- m4_pattern_allow([^prefix$])
m4trace:configure.in:5: -1- AC_SUBST([program_transform_name], [s,x,x,])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([program_transform_name])
m4trace:configure.in:5: -1- m4_pattern_allow([^program_transform_name$])
m4trace:configure.in:5: -1- AC_SUBST([bindir], ['${exec_prefix}/bin'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([bindir])
m4trace:configure.in:5: -1- m4_pattern_allow([^bindir$])
m4trace:configure.in:5: -1- AC_SUBST([sbindir], ['${exec_prefix}/sbin'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([sbindir])
m4trace:configure.in:5: -1- m4_pattern_allow([^sbindir$])
m4trace:configure.in:5: -1- AC_SUBST([libexecdir], ['${exec_prefix}/libexec'])
m4trace:configure.in:5: -1- AC_SUBST([datadir], ['${prefix}/share'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([libexecdir])
m4trace:configure.in:5: -1- m4_pattern_allow([^libexecdir$])
m4trace:configure.in:5: -1- AC_SUBST([datarootdir], ['${prefix}/share'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([datarootdir])
m4trace:configure.in:5: -1- m4_pattern_allow([^datarootdir$])
m4trace:configure.in:5: -1- AC_SUBST([datadir], ['${datarootdir}'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([datadir])
m4trace:configure.in:5: -1- m4_pattern_allow([^datadir$])
m4trace:configure.in:5: -1- AC_SUBST([sysconfdir], ['${prefix}/etc'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([sysconfdir])
m4trace:configure.in:5: -1- m4_pattern_allow([^sysconfdir$])
m4trace:configure.in:5: -1- AC_SUBST([sharedstatedir], ['${prefix}/com'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([sharedstatedir])
m4trace:configure.in:5: -1- m4_pattern_allow([^sharedstatedir$])
m4trace:configure.in:5: -1- AC_SUBST([localstatedir], ['${prefix}/var'])
m4trace:configure.in:5: -1- AC_SUBST([libdir], ['${exec_prefix}/lib'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([localstatedir])
m4trace:configure.in:5: -1- m4_pattern_allow([^localstatedir$])
m4trace:configure.in:5: -1- AC_SUBST([includedir], ['${prefix}/include'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([includedir])
m4trace:configure.in:5: -1- m4_pattern_allow([^includedir$])
m4trace:configure.in:5: -1- AC_SUBST([oldincludedir], ['/usr/include'])
m4trace:configure.in:5: -1- AC_SUBST([infodir], ['${prefix}/info'])
m4trace:configure.in:5: -1- AC_SUBST([mandir], ['${prefix}/man'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([oldincludedir])
m4trace:configure.in:5: -1- m4_pattern_allow([^oldincludedir$])
m4trace:configure.in:5: -1- AC_SUBST([docdir], [m4_ifset([AC_PACKAGE_TARNAME],
['${datarootdir}/doc/${PACKAGE_TARNAME}'],
['${datarootdir}/doc/${PACKAGE}'])])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([docdir])
m4trace:configure.in:5: -1- m4_pattern_allow([^docdir$])
m4trace:configure.in:5: -1- AC_SUBST([infodir], ['${datarootdir}/info'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([infodir])
m4trace:configure.in:5: -1- m4_pattern_allow([^infodir$])
m4trace:configure.in:5: -1- AC_SUBST([htmldir], ['${docdir}'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([htmldir])
m4trace:configure.in:5: -1- m4_pattern_allow([^htmldir$])
m4trace:configure.in:5: -1- AC_SUBST([dvidir], ['${docdir}'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([dvidir])
m4trace:configure.in:5: -1- m4_pattern_allow([^dvidir$])
m4trace:configure.in:5: -1- AC_SUBST([pdfdir], ['${docdir}'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([pdfdir])
m4trace:configure.in:5: -1- m4_pattern_allow([^pdfdir$])
m4trace:configure.in:5: -1- AC_SUBST([psdir], ['${docdir}'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([psdir])
m4trace:configure.in:5: -1- m4_pattern_allow([^psdir$])
m4trace:configure.in:5: -1- AC_SUBST([libdir], ['${exec_prefix}/lib'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([libdir])
m4trace:configure.in:5: -1- m4_pattern_allow([^libdir$])
m4trace:configure.in:5: -1- AC_SUBST([localedir], ['${datarootdir}/locale'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([localedir])
m4trace:configure.in:5: -1- m4_pattern_allow([^localedir$])
m4trace:configure.in:5: -1- AC_SUBST([mandir], ['${datarootdir}/man'])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([mandir])
m4trace:configure.in:5: -1- m4_pattern_allow([^mandir$])
m4trace:configure.in:5: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_NAME])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_NAME$])
m4trace:configure.in:5: -1- AH_OUTPUT([PACKAGE_NAME], [/* Define to the full name of this package. */
#undef PACKAGE_NAME])
m4trace:configure.in:5: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_TARNAME])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_TARNAME$])
m4trace:configure.in:5: -1- AH_OUTPUT([PACKAGE_TARNAME], [/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME])
m4trace:configure.in:5: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_VERSION])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_VERSION$])
m4trace:configure.in:5: -1- AH_OUTPUT([PACKAGE_VERSION], [/* Define to the version of this package. */
#undef PACKAGE_VERSION])
m4trace:configure.in:5: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_STRING])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_STRING$])
m4trace:configure.in:5: -1- AH_OUTPUT([PACKAGE_STRING], [/* Define to the full name and version of this package. */
#undef PACKAGE_STRING])
m4trace:configure.in:5: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_BUGREPORT])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_BUGREPORT$])
m4trace:configure.in:5: -1- AH_OUTPUT([PACKAGE_BUGREPORT], [/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT])
m4trace:configure.in:5: -1- AC_SUBST([build_alias])
m4trace:configure.in:5: -1- AC_SUBST([host_alias])
m4trace:configure.in:5: -1- AC_SUBST([target_alias])
m4trace:configure.in:5: -1- AC_SUBST([DEFS])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([DEFS])
m4trace:configure.in:5: -1- m4_pattern_allow([^DEFS$])
m4trace:configure.in:5: -1- AC_SUBST([ECHO_C])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([ECHO_C])
m4trace:configure.in:5: -1- m4_pattern_allow([^ECHO_C$])
m4trace:configure.in:5: -1- AC_SUBST([ECHO_N])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([ECHO_N])
m4trace:configure.in:5: -1- m4_pattern_allow([^ECHO_N$])
m4trace:configure.in:5: -1- AC_SUBST([ECHO_T])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([ECHO_T])
m4trace:configure.in:5: -1- m4_pattern_allow([^ECHO_T$])
m4trace:configure.in:5: -1- AC_SUBST([LIBS])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([LIBS])
m4trace:configure.in:5: -1- m4_pattern_allow([^LIBS$])
m4trace:configure.in:5: -1- AC_SUBST([build_alias])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([build_alias])
m4trace:configure.in:5: -1- m4_pattern_allow([^build_alias$])
m4trace:configure.in:5: -1- AC_SUBST([host_alias])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([host_alias])
m4trace:configure.in:5: -1- m4_pattern_allow([^host_alias$])
m4trace:configure.in:5: -1- AC_SUBST([target_alias])
m4trace:configure.in:5: -1- AC_SUBST_TRACE([target_alias])
m4trace:configure.in:5: -1- m4_pattern_allow([^target_alias$])
m4trace:configure.in:7: -1- AM_INIT_AUTOMAKE([1.6 foreign])
m4trace:configure.in:7: -1- AM_AUTOMAKE_VERSION([1.6.3])
m4trace:configure.in:7: -1- m4_pattern_allow([^AM_[A-Z]+FLAGS$])
m4trace:configure.in:7: -1- AM_AUTOMAKE_VERSION([1.10.1])
m4trace:configure.in:7: -1- AC_PROG_INSTALL
m4trace:configure.in:7: -1- AC_REQUIRE_AUX_FILE([install-sh])
m4trace:configure.in:7: -1- AC_SUBST([INSTALL_PROGRAM])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([INSTALL_PROGRAM])
m4trace:configure.in:7: -1- m4_pattern_allow([^INSTALL_PROGRAM$])
m4trace:configure.in:7: -1- AC_SUBST([INSTALL_SCRIPT])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([INSTALL_SCRIPT])
m4trace:configure.in:7: -1- m4_pattern_allow([^INSTALL_SCRIPT$])
m4trace:configure.in:7: -1- AC_SUBST([INSTALL_DATA])
m4trace:configure.in:7: -1- AC_SUBST([PACKAGE], [AC_PACKAGE_TARNAME])
m4trace:configure.in:7: -1- AC_SUBST([VERSION], [AC_PACKAGE_VERSION])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([INSTALL_DATA])
m4trace:configure.in:7: -1- m4_pattern_allow([^INSTALL_DATA$])
m4trace:configure.in:7: -1- AC_SUBST([am__isrc], [' -I$(srcdir)'])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([am__isrc])
m4trace:configure.in:7: -1- m4_pattern_allow([^am__isrc$])
m4trace:configure.in:7: -1- _AM_SUBST_NOTMAKE([am__isrc])
m4trace:configure.in:7: -1- AC_SUBST([CYGPATH_W])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([CYGPATH_W])
m4trace:configure.in:7: -1- m4_pattern_allow([^CYGPATH_W$])
m4trace:configure.in:7: -1- _m4_warn([obsolete], [The macro `AC_FOREACH' is obsolete.
You should run autoupdate.], [../../lib/autoconf/general.m4:196: AC_FOREACH is expanded from...
aclocal.m4:684: _AM_SET_OPTIONS is expanded from...
aclocal.m4:410: AM_INIT_AUTOMAKE is expanded from...
configure.in:7: the top level])
m4trace:configure.in:7: -1- AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([PACKAGE])
m4trace:configure.in:7: -1- m4_pattern_allow([^PACKAGE$])
m4trace:configure.in:7: -1- AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([VERSION])
m4trace:configure.in:7: -1- m4_pattern_allow([^VERSION$])
m4trace:configure.in:7: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE])
m4trace:configure.in:7: -1- m4_pattern_allow([^PACKAGE$])
m4trace:configure.in:7: -1- AH_OUTPUT([PACKAGE], [/* Name of package */
#undef PACKAGE])
m4trace:configure.in:7: -1- AC_DEFINE_TRACE_LITERAL([VERSION])
m4trace:configure.in:7: -1- m4_pattern_allow([^VERSION$])
m4trace:configure.in:7: -1- AH_OUTPUT([VERSION], [/* Version number of package */
#undef VERSION])
m4trace:configure.in:7: -1- AC_REQUIRE_AUX_FILE([missing])
m4trace:configure.in:7: -1- AC_SUBST([ACLOCAL])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([ACLOCAL])
m4trace:configure.in:7: -1- m4_pattern_allow([^ACLOCAL$])
m4trace:configure.in:7: -1- AC_SUBST([AUTOCONF])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([AUTOCONF])
m4trace:configure.in:7: -1- m4_pattern_allow([^AUTOCONF$])
m4trace:configure.in:7: -1- AC_SUBST([AUTOMAKE])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([AUTOMAKE])
m4trace:configure.in:7: -1- m4_pattern_allow([^AUTOMAKE$])
m4trace:configure.in:7: -1- AC_SUBST([AUTOHEADER])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([AUTOHEADER])
m4trace:configure.in:7: -1- m4_pattern_allow([^AUTOHEADER$])
m4trace:configure.in:7: -1- AC_SUBST([MAKEINFO])
m4trace:configure.in:7: -1- AC_SUBST([AMTAR])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([MAKEINFO])
m4trace:configure.in:7: -1- m4_pattern_allow([^MAKEINFO$])
m4trace:configure.in:7: -1- AC_SUBST([install_sh])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([install_sh])
m4trace:configure.in:7: -1- m4_pattern_allow([^install_sh$])
m4trace:configure.in:7: -1- AC_SUBST([STRIP])
m4trace:configure.in:7: -1- AC_SUBST([ac_ct_STRIP])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([STRIP])
m4trace:configure.in:7: -1- m4_pattern_allow([^STRIP$])
m4trace:configure.in:7: -1- AC_SUBST([INSTALL_STRIP_PROGRAM])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([INSTALL_STRIP_PROGRAM])
m4trace:configure.in:7: -1- m4_pattern_allow([^INSTALL_STRIP_PROGRAM$])
m4trace:configure.in:7: -1- AC_REQUIRE_AUX_FILE([install-sh])
m4trace:configure.in:7: -1- AC_SUBST([mkdir_p], ["$MKDIR_P"])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([mkdir_p])
m4trace:configure.in:7: -1- m4_pattern_allow([^mkdir_p$])
m4trace:configure.in:7: -1- AC_PROG_AWK
m4trace:configure.in:7: -1- AC_SUBST([AWK])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([AWK])
m4trace:configure.in:7: -1- m4_pattern_allow([^AWK$])
m4trace:configure.in:7: -1- AC_PROG_MAKE_SET
m4trace:configure.in:7: -1- AC_SUBST([SET_MAKE])
m4trace:configure.in:9: -1- AC_CONFIG_HEADERS([config.h], [# update the timestamp
echo 'timestamp for config.h' >"_AM_STAMP([config.h])"
], [])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([SET_MAKE])
m4trace:configure.in:7: -1- m4_pattern_allow([^SET_MAKE$])
m4trace:configure.in:7: -1- AC_SUBST([am__leading_dot])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([am__leading_dot])
m4trace:configure.in:7: -1- m4_pattern_allow([^am__leading_dot$])
m4trace:configure.in:7: -1- AC_SUBST([AMTAR])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([AMTAR])
m4trace:configure.in:7: -1- m4_pattern_allow([^AMTAR$])
m4trace:configure.in:7: -1- AC_SUBST([am__tar])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([am__tar])
m4trace:configure.in:7: -1- m4_pattern_allow([^am__tar$])
m4trace:configure.in:7: -1- AC_SUBST([am__untar])
m4trace:configure.in:7: -1- AC_SUBST_TRACE([am__untar])
m4trace:configure.in:7: -1- m4_pattern_allow([^am__untar$])
m4trace:configure.in:9: -1- _m4_warn([obsolete], [The macro `AM_CONFIG_HEADER' is obsolete.
You should run autoupdate.], [aclocal.m4:383: AM_CONFIG_HEADER is expanded from...
configure.in:9: the top level])
m4trace:configure.in:9: -1- AC_CONFIG_HEADERS([config.h])
m4trace:configure.in:10: -1- AC_PROG_CC
m4trace:configure.in:10: -1- AC_SUBST([CC])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([CC])
m4trace:configure.in:10: -1- m4_pattern_allow([^CC$])
m4trace:configure.in:10: -1- AC_SUBST([CFLAGS])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([CFLAGS])
m4trace:configure.in:10: -1- m4_pattern_allow([^CFLAGS$])
m4trace:configure.in:10: -1- AC_SUBST([LDFLAGS])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([LDFLAGS])
m4trace:configure.in:10: -1- m4_pattern_allow([^LDFLAGS$])
m4trace:configure.in:10: -1- AC_SUBST([LIBS])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([LIBS])
m4trace:configure.in:10: -1- m4_pattern_allow([^LIBS$])
m4trace:configure.in:10: -1- AC_SUBST([CPPFLAGS])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([CPPFLAGS])
m4trace:configure.in:10: -1- m4_pattern_allow([^CPPFLAGS$])
m4trace:configure.in:10: -1- AC_SUBST([CC])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([CC])
m4trace:configure.in:10: -1- m4_pattern_allow([^CC$])
m4trace:configure.in:10: -1- AC_SUBST([CC])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([CC])
m4trace:configure.in:10: -1- m4_pattern_allow([^CC$])
m4trace:configure.in:10: -1- AC_SUBST([CC])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([CC])
m4trace:configure.in:10: -1- m4_pattern_allow([^CC$])
m4trace:configure.in:10: -1- AC_SUBST([CC])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([CC])
m4trace:configure.in:10: -1- m4_pattern_allow([^CC$])
m4trace:configure.in:10: -1- AC_SUBST([ac_ct_CC])
m4trace:configure.in:10: -1- AC_SUBST([CC])
m4trace:configure.in:10: -1- AC_SUBST([ac_ct_CC])
m4trace:configure.in:10: -1- AC_SUBST([CC])
m4trace:configure.in:10: -1- AC_SUBST([CC])
m4trace:configure.in:10: -1- AC_SUBST([ac_ct_CC])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([ac_ct_CC])
m4trace:configure.in:10: -1- m4_pattern_allow([^ac_ct_CC$])
m4trace:configure.in:10: -1- AC_SUBST([EXEEXT], [$ac_cv_exeext])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([EXEEXT])
m4trace:configure.in:10: -1- m4_pattern_allow([^EXEEXT$])
m4trace:configure.in:10: -1- AC_SUBST([OBJEXT], [$ac_cv_objext])
m4trace:configure.in:10: -1- AC_SUBST([DEPDIR])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([OBJEXT])
m4trace:configure.in:10: -1- m4_pattern_allow([^OBJEXT$])
m4trace:configure.in:10: -1- AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([DEPDIR])
m4trace:configure.in:10: -1- m4_pattern_allow([^DEPDIR$])
m4trace:configure.in:10: -1- AC_SUBST([am__include])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([am__include])
m4trace:configure.in:10: -1- m4_pattern_allow([^am__include$])
m4trace:configure.in:10: -1- AC_SUBST([am__quote])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([am__quote])
m4trace:configure.in:10: -1- m4_pattern_allow([^am__quote$])
m4trace:configure.in:10: -1- AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
m4trace:configure.in:10: -1- AC_SUBST([AMDEP_TRUE])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([AMDEP_TRUE])
m4trace:configure.in:10: -1- m4_pattern_allow([^AMDEP_TRUE$])
m4trace:configure.in:10: -1- AC_SUBST([AMDEP_FALSE])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([AMDEP_FALSE])
m4trace:configure.in:10: -1- m4_pattern_allow([^AMDEP_FALSE$])
m4trace:configure.in:10: -1- _AM_SUBST_NOTMAKE([AMDEP_TRUE])
m4trace:configure.in:10: -1- _AM_SUBST_NOTMAKE([AMDEP_FALSE])
m4trace:configure.in:10: -1- AC_SUBST([AMDEPBACKSLASH])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([AMDEPBACKSLASH])
m4trace:configure.in:10: -1- m4_pattern_allow([^AMDEPBACKSLASH$])
m4trace:configure.in:10: -1- _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])
m4trace:configure.in:10: -1- AC_SUBST([CCDEPMODE], [depmode=$am_cv_CC_dependencies_compiler_type])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([CCDEPMODE])
m4trace:configure.in:10: -1- m4_pattern_allow([^CCDEPMODE$])
m4trace:configure.in:10: -1- AM_CONDITIONAL([am__fastdepCC], [
test "x$enable_dependency_tracking" != xno \
&& test "$am_cv_CC_dependencies_compiler_type" = gcc3])
m4trace:configure.in:10: -1- AC_SUBST([am__fastdepCC_TRUE])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([am__fastdepCC_TRUE])
m4trace:configure.in:10: -1- m4_pattern_allow([^am__fastdepCC_TRUE$])
m4trace:configure.in:10: -1- AC_SUBST([am__fastdepCC_FALSE])
m4trace:configure.in:10: -1- AC_SUBST_TRACE([am__fastdepCC_FALSE])
m4trace:configure.in:10: -1- m4_pattern_allow([^am__fastdepCC_FALSE$])
m4trace:configure.in:10: -1- _AM_SUBST_NOTMAKE([am__fastdepCC_TRUE])
m4trace:configure.in:10: -1- _AM_SUBST_NOTMAKE([am__fastdepCC_FALSE])
m4trace:configure.in:25: -1- AC_SUBST([dhcpd_conf])
m4trace:configure.in:25: -1- AC_SUBST_TRACE([dhcpd_conf])
m4trace:configure.in:25: -1- m4_pattern_allow([^dhcpd_conf$])
m4trace:configure.in:33: -1- AC_SUBST([dhcpd_leases])
m4trace:configure.in:33: -1- AC_SUBST_TRACE([dhcpd_leases])
m4trace:configure.in:33: -1- m4_pattern_allow([^dhcpd_leases$])
m4trace:configure.in:41: -1- AC_SUBST([output_format])
m4trace:configure.in:41: -1- AC_SUBST_TRACE([output_format])
m4trace:configure.in:41: -1- m4_pattern_allow([^output_format$])
m4trace:configure.in:49: -1- AC_SUBST([output_limit])
m4trace:configure.in:49: -1- AC_SUBST_TRACE([output_limit])
m4trace:configure.in:49: -1- m4_pattern_allow([^output_limit$])
m4trace:configure.in:51: -1- AC_CHECK_FUNCS([getopt_long inet_aton inet_addr], [break])
m4trace:configure.in:51: -1- AH_OUTPUT([HAVE_GETOPT_LONG], [/* Define to 1 if you have the `getopt_long\' function. */
#undef HAVE_GETOPT_LONG])
@ -120,95 +328,134 @@ m4trace:configure.in:53: -1- AC_CHECK_LIB([resolv], [inet_ntoa])
m4trace:configure.in:53: -1- AH_OUTPUT([HAVE_LIBRESOLV], [/* Define to 1 if you have the `resolv\' library (-lresolv). */
#undef HAVE_LIBRESOLV])
m4trace:configure.in:53: -1- AC_DEFINE_TRACE_LITERAL([HAVE_LIBRESOLV])
m4trace:configure.in:56: -1- AC_CHECK_HEADERS([arpa/inet.h errno.h netinet/in.h stdio.h \
m4trace:configure.in:53: -1- m4_pattern_allow([^HAVE_LIBRESOLV$])
m4trace:configure.in:55: -1- AC_CHECK_HEADERS([arpa/inet.h errno.h netinet/in.h stdio.h \
stdlib.h string.h sys/socket.h sys/stat.h sys/types.h unistd.h])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_ARPA_INET_H], [/* Define to 1 if you have the <arpa/inet.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_ARPA_INET_H], [/* Define to 1 if you have the <arpa/inet.h> header file. */
#undef HAVE_ARPA_INET_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_ERRNO_H], [/* Define to 1 if you have the <errno.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_ERRNO_H], [/* Define to 1 if you have the <errno.h> header file. */
#undef HAVE_ERRNO_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_NETINET_IN_H], [/* Define to 1 if you have the <netinet/in.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_NETINET_IN_H], [/* Define to 1 if you have the <netinet/in.h> header file. */
#undef HAVE_NETINET_IN_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_STDIO_H], [/* Define to 1 if you have the <stdio.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_STDIO_H], [/* Define to 1 if you have the <stdio.h> header file. */
#undef HAVE_STDIO_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_STDLIB_H], [/* Define to 1 if you have the <stdlib.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_STDLIB_H], [/* Define to 1 if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_STRING_H], [/* Define to 1 if you have the <string.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_STRING_H], [/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_SYS_SOCKET_H], [/* Define to 1 if you have the <sys/socket.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_SYS_SOCKET_H], [/* Define to 1 if you have the <sys/socket.h> header file. */
#undef HAVE_SYS_SOCKET_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_SYS_STAT_H], [/* Define to 1 if you have the <sys/stat.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_SYS_STAT_H], [/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_SYS_TYPES_H], [/* Define to 1 if you have the <sys/types.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_SYS_TYPES_H], [/* Define to 1 if you have the <sys/types.h> header file. */
#undef HAVE_SYS_TYPES_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_UNISTD_H], [/* Define to 1 if you have the <unistd.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_UNISTD_H], [/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H])
m4trace:configure.in:56: -1- AC_HEADER_STDC
m4trace:configure.in:56: -1- AC_PROG_CPP
m4trace:configure.in:56: -1- AC_SUBST([CPP])
m4trace:configure.in:56: -1- AC_SUBST([CPPFLAGS])
m4trace:configure.in:56: -1- AC_SUBST([CPP])
m4trace:configure.in:56: -1- AC_SUBST([EGREP])
m4trace:configure.in:56: -1- AC_DEFINE_TRACE_LITERAL([STDC_HEADERS])
m4trace:configure.in:56: -1- AH_OUTPUT([STDC_HEADERS], [/* Define to 1 if you have the ANSI C header files. */
m4trace:configure.in:55: -1- AC_HEADER_STDC
m4trace:configure.in:55: -1- AC_PROG_CPP
m4trace:configure.in:55: -1- AC_SUBST([CPP])
m4trace:configure.in:55: -1- AC_SUBST_TRACE([CPP])
m4trace:configure.in:55: -1- m4_pattern_allow([^CPP$])
m4trace:configure.in:55: -1- AC_SUBST([CPPFLAGS])
m4trace:configure.in:55: -1- AC_SUBST_TRACE([CPPFLAGS])
m4trace:configure.in:55: -1- m4_pattern_allow([^CPPFLAGS$])
m4trace:configure.in:55: -1- AC_SUBST([CPP])
m4trace:configure.in:55: -1- AC_SUBST_TRACE([CPP])
m4trace:configure.in:55: -1- m4_pattern_allow([^CPP$])
m4trace:configure.in:55: -1- AC_SUBST([GREP])
m4trace:configure.in:55: -1- AC_SUBST_TRACE([GREP])
m4trace:configure.in:55: -1- m4_pattern_allow([^GREP$])
m4trace:configure.in:55: -1- AC_SUBST([GREP])
m4trace:configure.in:55: -1- AC_SUBST_TRACE([GREP])
m4trace:configure.in:55: -1- m4_pattern_allow([^GREP$])
m4trace:configure.in:55: -1- AC_SUBST([EGREP])
m4trace:configure.in:55: -1- AC_SUBST_TRACE([EGREP])
m4trace:configure.in:55: -1- m4_pattern_allow([^EGREP$])
m4trace:configure.in:55: -1- AC_SUBST([EGREP])
m4trace:configure.in:55: -1- AC_SUBST_TRACE([EGREP])
m4trace:configure.in:55: -1- m4_pattern_allow([^EGREP$])
m4trace:configure.in:55: -1- AC_DEFINE_TRACE_LITERAL([STDC_HEADERS])
m4trace:configure.in:55: -1- m4_pattern_allow([^STDC_HEADERS$])
m4trace:configure.in:55: -1- AH_OUTPUT([STDC_HEADERS], [/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS])
m4trace:configure.in:56: -1- AC_CHECK_HEADERS([sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
m4trace:configure.in:55: -1- AC_CHECK_HEADERS([sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
inttypes.h stdint.h unistd.h], [], [], [$ac_includes_default])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_SYS_TYPES_H], [/* Define to 1 if you have the <sys/types.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_SYS_TYPES_H], [/* Define to 1 if you have the <sys/types.h> header file. */
#undef HAVE_SYS_TYPES_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_SYS_STAT_H], [/* Define to 1 if you have the <sys/stat.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_SYS_STAT_H], [/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_STDLIB_H], [/* Define to 1 if you have the <stdlib.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_STDLIB_H], [/* Define to 1 if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_STRING_H], [/* Define to 1 if you have the <string.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_STRING_H], [/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_MEMORY_H], [/* Define to 1 if you have the <memory.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_MEMORY_H], [/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_STRINGS_H], [/* Define to 1 if you have the <strings.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_STRINGS_H], [/* Define to 1 if you have the <strings.h> header file. */
#undef HAVE_STRINGS_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_INTTYPES_H], [/* Define to 1 if you have the <inttypes.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_INTTYPES_H], [/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_STDINT_H], [/* Define to 1 if you have the <stdint.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_STDINT_H], [/* Define to 1 if you have the <stdint.h> header file. */
#undef HAVE_STDINT_H])
m4trace:configure.in:56: -1- AH_OUTPUT([HAVE_UNISTD_H], [/* Define to 1 if you have the <unistd.h> header file. */
m4trace:configure.in:55: -1- AH_OUTPUT([HAVE_UNISTD_H], [/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H])
m4trace:configure.in:59: -2- AC_DEFINE_TRACE_LITERAL([HAVE_GETOPT_H])
m4trace:configure.in:60: -1- AC_CHECK_HEADERS([getopt.h], [cat >>confdefs.h <<\_ACEOF
m4trace:configure.in:59: -2- m4_pattern_allow([^HAVE_GETOPT_H$])
m4trace:configure.in:59: -1- AC_CHECK_HEADERS([getopt.h], [cat >>confdefs.h <<\_ACEOF
@%:@define HAVE_GETOPT_H 1
_ACEOF
], [import_sources="getopt.c getopt1.c $import_sources"])
m4trace:configure.in:60: -1- AH_OUTPUT([HAVE_GETOPT_H], [/* Define to 1 if you have the <getopt.h> header file. */
m4trace:configure.in:59: -1- AH_OUTPUT([HAVE_GETOPT_H], [/* Define to 1 if you have the <getopt.h> header file. */
#undef HAVE_GETOPT_H])
m4trace:configure.in:63: -1- AC_FUNC_ALLOCA
m4trace:configure.in:63: -1- AC_DEFINE_TRACE_LITERAL([HAVE_ALLOCA_H])
m4trace:configure.in:63: -1- m4_pattern_allow([^HAVE_ALLOCA_H$])
m4trace:configure.in:63: -1- AH_OUTPUT([HAVE_ALLOCA_H], [/* Define to 1 if you have <alloca.h> and it should be used (not on Ultrix).
*/
#undef HAVE_ALLOCA_H])
m4trace:configure.in:63: -1- AC_DEFINE_TRACE_LITERAL([HAVE_ALLOCA])
m4trace:configure.in:63: -1- m4_pattern_allow([^HAVE_ALLOCA$])
m4trace:configure.in:63: -1- AH_OUTPUT([HAVE_ALLOCA], [/* Define to 1 if you have `alloca\', as a function or macro. */
#undef HAVE_ALLOCA])
m4trace:configure.in:63: -1- AC_LIBSOURCE([alloca.c])
m4trace:configure.in:63: -1- AC_SUBST([ALLOCA], [alloca.$ac_objext])
m4trace:configure.in:63: -1- AC_SUBST([ALLOCA], [\${LIBOBJDIR}alloca.$ac_objext])
m4trace:configure.in:63: -1- AC_SUBST_TRACE([ALLOCA])
m4trace:configure.in:63: -1- m4_pattern_allow([^ALLOCA$])
m4trace:configure.in:63: -1- AC_DEFINE_TRACE_LITERAL([C_ALLOCA])
m4trace:configure.in:63: -1- m4_pattern_allow([^C_ALLOCA$])
m4trace:configure.in:63: -1- AH_OUTPUT([C_ALLOCA], [/* Define to 1 if using `alloca.c\'. */
#undef C_ALLOCA])
m4trace:configure.in:63: -1- AC_DEFINE_TRACE_LITERAL([CRAY_STACKSEG_END])
m4trace:configure.in:63: -1- m4_pattern_allow([^CRAY_STACKSEG_END$])
m4trace:configure.in:63: -1- AH_OUTPUT([CRAY_STACKSEG_END], [/* Define to one of `_getb67\', `GETB67\', `getb67\' for Cray-2 and Cray-YMP
systems. This function is required for `alloca.c\' support on those systems.
*/
#undef CRAY_STACKSEG_END])
m4trace:configure.in:63: -1- AH_OUTPUT([STACK_DIRECTION], [/* If using the C implementation of alloca, define if you know the
direction of stack growth for your system; otherwise it will be
automatically deduced at run-time.
automatically deduced at runtime.
STACK_DIRECTION > 0 => grows toward higher addresses
STACK_DIRECTION < 0 => grows toward lower addresses
STACK_DIRECTION = 0 => direction of growth unknown */
@%:@undef STACK_DIRECTION])
m4trace:configure.in:63: -1- AC_DEFINE_TRACE_LITERAL([STACK_DIRECTION])
m4trace:configure.in:63: -1- m4_pattern_allow([^STACK_DIRECTION$])
m4trace:configure.in:66: -1- AC_SUBST([PERL])
m4trace:configure.in:66: -1- AC_SUBST_TRACE([PERL])
m4trace:configure.in:66: -1- m4_pattern_allow([^PERL$])
m4trace:configure.in:68: -1- AC_CONFIG_FILES([Makefile man/Makefile src/Makefile])
m4trace:configure.in:70: -1- AC_SUBST([LIB@&t@OBJS], [$ac_libobjs])
m4trace:configure.in:70: -1- AC_SUBST_TRACE([LIB@&t@OBJS])
m4trace:configure.in:70: -1- m4_pattern_allow([^LIB@&t@OBJS$])
m4trace:configure.in:70: -1- AC_SUBST([LTLIBOBJS], [$ac_ltlibobjs])
m4trace:configure.in:70: -1- _m4_warn([obsolete], [back quotes and double quotes must not be escaped in: $as_me:$LINENO: error: conditional \"AMDEP\" was never defined.
Usually this means the macro was only invoked conditionally.], [])
m4trace:configure.in:70: -1- _m4_warn([obsolete], [back quotes and double quotes must not be escaped in: $as_me: error: conditional \"AMDEP\" was never defined.
Usually this means the macro was only invoked conditionally.], [])
m4trace:configure.in:70: -1- AC_SUBST_TRACE([LTLIBOBJS])
m4trace:configure.in:70: -1- m4_pattern_allow([^LTLIBOBJS$])
m4trace:configure.in:70: -1- AC_SUBST_TRACE([top_builddir])
m4trace:configure.in:70: -1- AC_SUBST_TRACE([srcdir])
m4trace:configure.in:70: -1- AC_SUBST_TRACE([abs_srcdir])
m4trace:configure.in:70: -1- AC_SUBST_TRACE([top_srcdir])
m4trace:configure.in:70: -1- AC_SUBST_TRACE([abs_top_srcdir])
m4trace:configure.in:70: -1- AC_SUBST_TRACE([builddir])
m4trace:configure.in:70: -1- AC_SUBST_TRACE([abs_builddir])
m4trace:configure.in:70: -1- AC_SUBST_TRACE([abs_top_builddir])
m4trace:configure.in:70: -1- AC_SUBST_TRACE([INSTALL])
m4trace:configure.in:70: -1- AC_SUBST_TRACE([MKDIR_P])

685
autom4te.cache/traces.1 Normal file
View file

@ -0,0 +1,685 @@
m4trace:/usr/share/aclocal-1.10/amversion.m4:14: -1- AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version='1.10'
dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
dnl require some minimum version. Point them to the right macro.
m4_if([$1], [1.10.1], [],
[AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
])
m4trace:/usr/share/aclocal-1.10/amversion.m4:33: -1- AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], [AM_AUTOMAKE_VERSION([1.10.1])dnl
m4_ifndef([AC_AUTOCONF_VERSION],
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
_AM_AUTOCONF_VERSION(AC_AUTOCONF_VERSION)])
m4trace:/usr/share/aclocal-1.10/auxdir.m4:47: -1- AC_DEFUN([AM_AUX_DIR_EXPAND], [dnl Rely on autoconf to set up CDPATH properly.
AC_PREREQ([2.50])dnl
# expand $ac_aux_dir to an absolute path
am_aux_dir=`cd $ac_aux_dir && pwd`
])
m4trace:/usr/share/aclocal-1.10/cond.m4:15: -1- AC_DEFUN([AM_CONDITIONAL], [AC_PREREQ(2.52)dnl
ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
[$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
AC_SUBST([$1_TRUE])dnl
AC_SUBST([$1_FALSE])dnl
_AM_SUBST_NOTMAKE([$1_TRUE])dnl
_AM_SUBST_NOTMAKE([$1_FALSE])dnl
if $2; then
$1_TRUE=
$1_FALSE='#'
else
$1_TRUE='#'
$1_FALSE=
fi
AC_CONFIG_COMMANDS_PRE(
[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
AC_MSG_ERROR([[conditional "$1" was never defined.
Usually this means the macro was only invoked conditionally.]])
fi])])
m4trace:/usr/share/aclocal-1.10/depend.m4:28: -1- AC_DEFUN([_AM_DEPENDENCIES], [AC_REQUIRE([AM_SET_DEPDIR])dnl
AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
AC_REQUIRE([AM_MAKE_INCLUDE])dnl
AC_REQUIRE([AM_DEP_TRACK])dnl
ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
[$1], CXX, [depcc="$CXX" am_compiler_list=],
[$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
[$1], UPC, [depcc="$UPC" am_compiler_list=],
[$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
[depcc="$$1" am_compiler_list=])
AC_CACHE_CHECK([dependency style of $depcc],
[am_cv_$1_dependencies_compiler_type],
[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
# We make a subdir and do the tests there. Otherwise we can end up
# making bogus files that we don't know about and never remove. For
# instance it was reported that on HP-UX the gcc test will end up
# making a dummy file named `D' -- because `-MD' means `put the output
# in D'.
mkdir conftest.dir
# Copy depcomp to subdir because otherwise we won't find it if we're
# using a relative directory.
cp "$am_depcomp" conftest.dir
cd conftest.dir
# We will build objects and dependencies in a subdirectory because
# it helps to detect inapplicable dependency modes. For instance
# both Tru64's cc and ICC support -MD to output dependencies as a
# side effect of compilation, but ICC will put the dependencies in
# the current directory while Tru64 will put them in the object
# directory.
mkdir sub
am_cv_$1_dependencies_compiler_type=none
if test "$am_compiler_list" = ""; then
am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
fi
for depmode in $am_compiler_list; do
# Setup a source with many dependencies, because some compilers
# like to wrap large dependency lists on column 80 (with \), and
# we should not choose a depcomp mode which is confused by this.
#
# We need to recreate these files for each test, as the compiler may
# overwrite some of them when testing with obscure command lines.
# This happens at least with the AIX C compiler.
: > sub/conftest.c
for i in 1 2 3 4 5 6; do
echo '#include "conftst'$i'.h"' >> sub/conftest.c
# Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
# Solaris 8's {/usr,}/bin/sh.
touch sub/conftst$i.h
done
echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
case $depmode in
nosideeffect)
# after this tag, mechanisms are not by side-effect, so they'll
# only be used when explicitly requested
if test "x$enable_dependency_tracking" = xyes; then
continue
else
break
fi
;;
none) break ;;
esac
# We check with `-c' and `-o' for the sake of the "dashmstdout"
# mode. It turns out that the SunPro C++ compiler does not properly
# handle `-M -o', and we need to detect this.
if depmode=$depmode \
source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
$SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
>/dev/null 2>conftest.err &&
grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
${MAKE-make} -s -f confmf > /dev/null 2>&1; then
# icc doesn't choke on unknown options, it will just issue warnings
# or remarks (even with -Werror). So we grep stderr for any message
# that says an option was ignored or not supported.
# When given -MP, icc 7.0 and 7.1 complain thusly:
# icc: Command line warning: ignoring option '-M'; no argument required
# The diagnosis changed in icc 8.0:
# icc: Command line remark: option '-MP' not supported
if (grep 'ignoring option' conftest.err ||
grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
am_cv_$1_dependencies_compiler_type=$depmode
break
fi
fi
done
cd ..
rm -rf conftest.dir
else
am_cv_$1_dependencies_compiler_type=none
fi
])
AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
AM_CONDITIONAL([am__fastdep$1], [
test "x$enable_dependency_tracking" != xno \
&& test "$am_cv_$1_dependencies_compiler_type" = gcc3])
])
m4trace:/usr/share/aclocal-1.10/depend.m4:139: -1- AC_DEFUN([AM_SET_DEPDIR], [AC_REQUIRE([AM_SET_LEADING_DOT])dnl
AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
])
m4trace:/usr/share/aclocal-1.10/depend.m4:147: -1- AC_DEFUN([AM_DEP_TRACK], [AC_ARG_ENABLE(dependency-tracking,
[ --disable-dependency-tracking speeds up one-time build
--enable-dependency-tracking do not reject slow dependency extractors])
if test "x$enable_dependency_tracking" != xno; then
am_depcomp="$ac_aux_dir/depcomp"
AMDEPBACKSLASH='\'
fi
AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
AC_SUBST([AMDEPBACKSLASH])dnl
_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl
])
m4trace:/usr/share/aclocal-1.10/depout.m4:14: -1- AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [for mf in $CONFIG_FILES; do
# Strip MF so we end up with the name of the file.
mf=`echo "$mf" | sed -e 's/:.*$//'`
# Check whether this is an Automake generated Makefile or not.
# We used to match only the files named `Makefile.in', but
# some people rename them; so instead we look at the file content.
# Grep'ing the first line is not enough: some people post-process
# each Makefile.in and add a new line on top of each file to say so.
# Grep'ing the whole file is not good either: AIX grep has a line
# limit of 2048, but all sed's we know have understand at least 4000.
if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
dirpart=`AS_DIRNAME("$mf")`
else
continue
fi
# Extract the definition of DEPDIR, am__include, and am__quote
# from the Makefile without running `make'.
DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
test -z "$DEPDIR" && continue
am__include=`sed -n 's/^am__include = //p' < "$mf"`
test -z "am__include" && continue
am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
# When using ansi2knr, U may be empty or an underscore; expand it
U=`sed -n 's/^U = //p' < "$mf"`
# Find all dependency output files, they are included files with
# $(DEPDIR) in their names. We invoke sed twice because it is the
# simplest approach to changing $(DEPDIR) to its actual value in the
# expansion.
for file in `sed -n "
s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
# Make sure the directory exists.
test -f "$dirpart/$file" && continue
fdir=`AS_DIRNAME(["$file"])`
AS_MKDIR_P([$dirpart/$fdir])
# echo "creating $dirpart/$file"
echo '# dummy' > "$dirpart/$file"
done
done
])
m4trace:/usr/share/aclocal-1.10/depout.m4:64: -1- AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles],
[test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
[AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
])
m4trace:/usr/share/aclocal-1.10/header.m4:12: -1- AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
m4trace:/usr/share/aclocal-1.10/header.m4:12: -1- AC_DEFUN([AM_CONFIG_HEADER], [AC_DIAGNOSE([obsolete], [The macro `AM_CONFIG_HEADER' is obsolete.
You should run autoupdate.])dnl
AC_CONFIG_HEADERS($@)])
m4trace:/usr/share/aclocal-1.10/init.m4:26: -1- AC_DEFUN([AM_INIT_AUTOMAKE], [AC_PREREQ([2.60])dnl
dnl Autoconf wants to disallow AM_ names. We explicitly allow
dnl the ones we care about.
m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
AC_REQUIRE([AC_PROG_INSTALL])dnl
if test "`cd $srcdir && pwd`" != "`pwd`"; then
# Use -I$(srcdir) only when $(srcdir) != ., so that make's output
# is not polluted with repeated "-I."
AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl
# test to see if srcdir already configured
if test -f $srcdir/config.status; then
AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
fi
fi
# test whether we have cygpath
if test -z "$CYGPATH_W"; then
if (cygpath --version) >/dev/null 2>/dev/null; then
CYGPATH_W='cygpath -w'
else
CYGPATH_W=echo
fi
fi
AC_SUBST([CYGPATH_W])
# Define the identity of the package.
dnl Distinguish between old-style and new-style calls.
m4_ifval([$2],
[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
AC_SUBST([PACKAGE], [$1])dnl
AC_SUBST([VERSION], [$2])],
[_AM_SET_OPTIONS([$1])dnl
dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT.
m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,,
[m4_fatal([AC_INIT should be called with package and version arguments])])dnl
AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
_AM_IF_OPTION([no-define],,
[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
# Some tools Automake needs.
AC_REQUIRE([AM_SANITY_CHECK])dnl
AC_REQUIRE([AC_ARG_PROGRAM])dnl
AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
AM_MISSING_PROG(AUTOCONF, autoconf)
AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
AM_MISSING_PROG(AUTOHEADER, autoheader)
AM_MISSING_PROG(MAKEINFO, makeinfo)
AM_PROG_INSTALL_SH
AM_PROG_INSTALL_STRIP
AC_REQUIRE([AM_PROG_MKDIR_P])dnl
# We need awk for the "check" target. The system "awk" is bad on
# some platforms.
AC_REQUIRE([AC_PROG_AWK])dnl
AC_REQUIRE([AC_PROG_MAKE_SET])dnl
AC_REQUIRE([AM_SET_LEADING_DOT])dnl
_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
[_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
[_AM_PROG_TAR([v7])])])
_AM_IF_OPTION([no-dependencies],,
[AC_PROVIDE_IFELSE([AC_PROG_CC],
[_AM_DEPENDENCIES(CC)],
[define([AC_PROG_CC],
defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
AC_PROVIDE_IFELSE([AC_PROG_CXX],
[_AM_DEPENDENCIES(CXX)],
[define([AC_PROG_CXX],
defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
AC_PROVIDE_IFELSE([AC_PROG_OBJC],
[_AM_DEPENDENCIES(OBJC)],
[define([AC_PROG_OBJC],
defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
])
])
m4trace:/usr/share/aclocal-1.10/init.m4:113: -1- AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], [# Compute $1's index in $config_headers.
_am_arg=$1
_am_stamp_count=1
for _am_header in $config_headers :; do
case $_am_header in
$_am_arg | $_am_arg:* )
break ;;
* )
_am_stamp_count=`expr $_am_stamp_count + 1` ;;
esac
done
echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
m4trace:/usr/share/aclocal-1.10/install-sh.m4:11: -1- AC_DEFUN([AM_PROG_INSTALL_SH], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"}
AC_SUBST(install_sh)])
m4trace:/usr/share/aclocal-1.10/lead-dot.m4:12: -1- AC_DEFUN([AM_SET_LEADING_DOT], [rm -rf .tst 2>/dev/null
mkdir .tst 2>/dev/null
if test -d .tst; then
am__leading_dot=.
else
am__leading_dot=_
fi
rmdir .tst 2>/dev/null
AC_SUBST([am__leading_dot])])
m4trace:/usr/share/aclocal-1.10/make.m4:14: -1- AC_DEFUN([AM_MAKE_INCLUDE], [am_make=${MAKE-make}
cat > confinc << 'END'
am__doit:
@echo done
.PHONY: am__doit
END
# If we don't find an include directive, just comment out the code.
AC_MSG_CHECKING([for style of include used by $am_make])
am__include="#"
am__quote=
_am_result=none
# First try GNU make style include.
echo "include confinc" > confmf
# We grep out `Entering directory' and `Leaving directory'
# messages which can occur if `w' ends up in MAKEFLAGS.
# In particular we don't look at `^make:' because GNU make might
# be invoked under some other name (usually "gmake"), in which
# case it prints its new name instead of `make'.
if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
am__include=include
am__quote=
_am_result=GNU
fi
# Now try BSD make style include.
if test "$am__include" = "#"; then
echo '.include "confinc"' > confmf
if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
am__include=.include
am__quote="\""
_am_result=BSD
fi
fi
AC_SUBST([am__include])
AC_SUBST([am__quote])
AC_MSG_RESULT([$_am_result])
rm -f confinc confmf
])
m4trace:/usr/share/aclocal-1.10/missing.m4:14: -1- AC_DEFUN([AM_MISSING_PROG], [AC_REQUIRE([AM_MISSING_HAS_RUN])
$1=${$1-"${am_missing_run}$2"}
AC_SUBST($1)])
m4trace:/usr/share/aclocal-1.10/missing.m4:24: -1- AC_DEFUN([AM_MISSING_HAS_RUN], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
AC_REQUIRE_AUX_FILE([missing])dnl
test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
# Use eval to expand $SHELL
if eval "$MISSING --run true"; then
am_missing_run="$MISSING --run "
else
am_missing_run=
AC_MSG_WARN([`missing' script is too old or missing])
fi
])
m4trace:/usr/share/aclocal-1.10/mkdirp.m4:11: -1- AC_DEFUN([AM_PROG_MKDIR_P], [AC_PREREQ([2.60])dnl
AC_REQUIRE([AC_PROG_MKDIR_P])dnl
dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P,
dnl while keeping a definition of mkdir_p for backward compatibility.
dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile.
dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of
dnl Makefile.ins that do not define MKDIR_P, so we do our own
dnl adjustment using top_builddir (which is defined more often than
dnl MKDIR_P).
AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl
case $mkdir_p in
[[\\/$]]* | ?:[[\\/]]*) ;;
*/*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
esac
])
m4trace:/usr/share/aclocal-1.10/options.m4:13: -1- AC_DEFUN([_AM_MANGLE_OPTION], [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
m4trace:/usr/share/aclocal-1.10/options.m4:19: -1- AC_DEFUN([_AM_SET_OPTION], [m4_define(_AM_MANGLE_OPTION([$1]), 1)])
m4trace:/usr/share/aclocal-1.10/options.m4:25: -1- AC_DEFUN([_AM_SET_OPTIONS], [AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
m4trace:/usr/share/aclocal-1.10/options.m4:31: -1- AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
m4trace:/usr/share/aclocal-1.10/runlog.m4:12: -1- AC_DEFUN([AM_RUN_LOG], [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
(exit $ac_status); }])
m4trace:/usr/share/aclocal-1.10/sanity.m4:14: -1- AC_DEFUN([AM_SANITY_CHECK], [AC_MSG_CHECKING([whether build environment is sane])
# Just in case
sleep 1
echo timestamp > conftest.file
# Do `set' in a subshell so we don't clobber the current shell's
# arguments. Must try -L first in case configure is actually a
# symlink; some systems play weird games with the mod time of symlinks
# (eg FreeBSD returns the mod time of the symlink's containing
# directory).
if (
set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
if test "$[*]" = "X"; then
# -L didn't work.
set X `ls -t $srcdir/configure conftest.file`
fi
rm -f conftest.file
if test "$[*]" != "X $srcdir/configure conftest.file" \
&& test "$[*]" != "X conftest.file $srcdir/configure"; then
# If neither matched, then we have a broken ls. This can happen
# if, for instance, CONFIG_SHELL is bash and it inherits a
# broken ls alias from the environment. This has actually
# happened. Such a system could not be considered "sane".
AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
alias in your environment])
fi
test "$[2]" = conftest.file
)
then
# Ok.
:
else
AC_MSG_ERROR([newly created file is older than distributed files!
Check your system clock])
fi
AC_MSG_RESULT(yes)])
m4trace:/usr/share/aclocal-1.10/strip.m4:17: -1- AC_DEFUN([AM_PROG_INSTALL_STRIP], [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
# Installed binaries are usually stripped using `strip' when the user
# run `make install-strip'. However `strip' might not be the right
# tool to use in cross-compilation environments, therefore Automake
# will honor the `STRIP' environment variable to overrule this program.
dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
if test "$cross_compiling" != no; then
AC_CHECK_TOOL([STRIP], [strip], :)
fi
INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
AC_SUBST([INSTALL_STRIP_PROGRAM])])
m4trace:/usr/share/aclocal-1.10/substnot.m4:12: -1- AC_DEFUN([_AM_SUBST_NOTMAKE])
m4trace:/usr/share/aclocal-1.10/tar.m4:24: -1- AC_DEFUN([_AM_PROG_TAR], [# Always define AMTAR for backward compatibility.
AM_MISSING_PROG([AMTAR], [tar])
m4_if([$1], [v7],
[am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'],
[m4_case([$1], [ustar],, [pax],,
[m4_fatal([Unknown tar format])])
AC_MSG_CHECKING([how to create a $1 tar archive])
# Loop over all known methods to create a tar archive until one works.
_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
_am_tools=${am_cv_prog_tar_$1-$_am_tools}
# Do not fold the above two line into one, because Tru64 sh and
# Solaris sh will not grok spaces in the rhs of `-'.
for _am_tool in $_am_tools
do
case $_am_tool in
gnutar)
for _am_tar in tar gnutar gtar;
do
AM_RUN_LOG([$_am_tar --version]) && break
done
am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
am__untar="$_am_tar -xf -"
;;
plaintar)
# Must skip GNU tar: if it does not support --format= it doesn't create
# ustar tarball either.
(tar --version) >/dev/null 2>&1 && continue
am__tar='tar chf - "$$tardir"'
am__tar_='tar chf - "$tardir"'
am__untar='tar xf -'
;;
pax)
am__tar='pax -L -x $1 -w "$$tardir"'
am__tar_='pax -L -x $1 -w "$tardir"'
am__untar='pax -r'
;;
cpio)
am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
am__untar='cpio -i -H $1 -d'
;;
none)
am__tar=false
am__tar_=false
am__untar=false
;;
esac
# If the value was cached, stop now. We just wanted to have am__tar
# and am__untar set.
test -n "${am_cv_prog_tar_$1}" && break
# tar/untar a dummy directory, and stop if the command works
rm -rf conftest.dir
mkdir conftest.dir
echo GrepMe > conftest.dir/file
AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
rm -rf conftest.dir
if test -s conftest.tar; then
AM_RUN_LOG([$am__untar <conftest.tar])
grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
fi
done
rm -rf conftest.dir
AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
AC_MSG_RESULT([$am_cv_prog_tar_$1])])
AC_SUBST([am__tar])
AC_SUBST([am__untar])
])
m4trace:configure.in:5: -1- m4_pattern_forbid([^_?A[CHUM]_])
m4trace:configure.in:5: -1- m4_pattern_forbid([_AC_])
m4trace:configure.in:5: -1- m4_pattern_forbid([^LIBOBJS$], [do not use LIBOBJS directly, use AC_LIBOBJ (see section `AC_LIBOBJ vs LIBOBJS'])
m4trace:configure.in:5: -1- m4_pattern_allow([^AS_FLAGS$])
m4trace:configure.in:5: -1- m4_pattern_forbid([^_?m4_])
m4trace:configure.in:5: -1- m4_pattern_forbid([^dnl$])
m4trace:configure.in:5: -1- m4_pattern_forbid([^_?AS_])
m4trace:configure.in:5: -1- m4_pattern_allow([^SHELL$])
m4trace:configure.in:5: -1- m4_pattern_allow([^PATH_SEPARATOR$])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_NAME$])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_TARNAME$])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_VERSION$])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_STRING$])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_BUGREPORT$])
m4trace:configure.in:5: -1- m4_pattern_allow([^exec_prefix$])
m4trace:configure.in:5: -1- m4_pattern_allow([^prefix$])
m4trace:configure.in:5: -1- m4_pattern_allow([^program_transform_name$])
m4trace:configure.in:5: -1- m4_pattern_allow([^bindir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^sbindir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^libexecdir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^datarootdir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^datadir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^sysconfdir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^sharedstatedir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^localstatedir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^includedir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^oldincludedir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^docdir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^infodir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^htmldir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^dvidir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^pdfdir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^psdir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^libdir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^localedir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^mandir$])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_NAME$])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_TARNAME$])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_VERSION$])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_STRING$])
m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_BUGREPORT$])
m4trace:configure.in:5: -1- m4_pattern_allow([^DEFS$])
m4trace:configure.in:5: -1- m4_pattern_allow([^ECHO_C$])
m4trace:configure.in:5: -1- m4_pattern_allow([^ECHO_N$])
m4trace:configure.in:5: -1- m4_pattern_allow([^ECHO_T$])
m4trace:configure.in:5: -1- m4_pattern_allow([^LIBS$])
m4trace:configure.in:5: -1- m4_pattern_allow([^build_alias$])
m4trace:configure.in:5: -1- m4_pattern_allow([^host_alias$])
m4trace:configure.in:5: -1- m4_pattern_allow([^target_alias$])
m4trace:configure.in:7: -1- AM_INIT_AUTOMAKE([1.6 foreign])
m4trace:configure.in:7: -1- m4_pattern_allow([^AM_[A-Z]+FLAGS$])
m4trace:configure.in:7: -1- AM_SET_CURRENT_AUTOMAKE_VERSION
m4trace:configure.in:7: -1- AM_AUTOMAKE_VERSION([1.10.1])
m4trace:configure.in:7: -1- _AM_AUTOCONF_VERSION([2.61])
m4trace:configure.in:7: -1- m4_pattern_allow([^INSTALL_PROGRAM$])
m4trace:configure.in:7: -1- m4_pattern_allow([^INSTALL_SCRIPT$])
m4trace:configure.in:7: -1- m4_pattern_allow([^INSTALL_DATA$])
m4trace:configure.in:7: -1- m4_pattern_allow([^am__isrc$])
m4trace:configure.in:7: -1- _AM_SUBST_NOTMAKE([am__isrc])
m4trace:configure.in:7: -1- m4_pattern_allow([^CYGPATH_W$])
m4trace:configure.in:7: -1- _AM_SET_OPTIONS([1.6 foreign])
m4trace:configure.in:7: -1- _AM_SET_OPTION([1.6])
m4trace:configure.in:7: -2- _AM_MANGLE_OPTION([1.6])
m4trace:configure.in:7: -1- _AM_SET_OPTION([foreign])
m4trace:configure.in:7: -2- _AM_MANGLE_OPTION([foreign])
m4trace:configure.in:7: -1- _m4_warn([obsolete], [The macro `AC_FOREACH' is obsolete.
You should run autoupdate.], [../../lib/autoconf/general.m4:196: AC_FOREACH is expanded from...
/usr/share/aclocal-1.10/options.m4:25: _AM_SET_OPTIONS is expanded from...
/usr/share/aclocal-1.10/init.m4:26: AM_INIT_AUTOMAKE is expanded from...
configure.in:7: the top level])
m4trace:configure.in:7: -1- m4_pattern_allow([^PACKAGE$])
m4trace:configure.in:7: -1- m4_pattern_allow([^VERSION$])
m4trace:configure.in:7: -1- _AM_IF_OPTION([no-define], [], [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])
m4trace:configure.in:7: -2- _AM_MANGLE_OPTION([no-define])
m4trace:configure.in:7: -1- m4_pattern_allow([^PACKAGE$])
m4trace:configure.in:7: -1- m4_pattern_allow([^VERSION$])
m4trace:configure.in:7: -1- AM_SANITY_CHECK
m4trace:configure.in:7: -1- AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}])
m4trace:configure.in:7: -1- AM_MISSING_HAS_RUN
m4trace:configure.in:7: -1- AM_AUX_DIR_EXPAND
m4trace:configure.in:7: -1- m4_pattern_allow([^ACLOCAL$])
m4trace:configure.in:7: -1- AM_MISSING_PROG([AUTOCONF], [autoconf])
m4trace:configure.in:7: -1- m4_pattern_allow([^AUTOCONF$])
m4trace:configure.in:7: -1- AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}])
m4trace:configure.in:7: -1- m4_pattern_allow([^AUTOMAKE$])
m4trace:configure.in:7: -1- AM_MISSING_PROG([AUTOHEADER], [autoheader])
m4trace:configure.in:7: -1- m4_pattern_allow([^AUTOHEADER$])
m4trace:configure.in:7: -1- AM_MISSING_PROG([MAKEINFO], [makeinfo])
m4trace:configure.in:7: -1- m4_pattern_allow([^MAKEINFO$])
m4trace:configure.in:7: -1- AM_PROG_INSTALL_SH
m4trace:configure.in:7: -1- m4_pattern_allow([^install_sh$])
m4trace:configure.in:7: -1- AM_PROG_INSTALL_STRIP
m4trace:configure.in:7: -1- m4_pattern_allow([^STRIP$])
m4trace:configure.in:7: -1- m4_pattern_allow([^INSTALL_STRIP_PROGRAM$])
m4trace:configure.in:7: -1- AM_PROG_MKDIR_P
m4trace:configure.in:7: -1- m4_pattern_allow([^mkdir_p$])
m4trace:configure.in:7: -1- m4_pattern_allow([^AWK$])
m4trace:configure.in:7: -1- m4_pattern_allow([^SET_MAKE$])
m4trace:configure.in:7: -1- AM_SET_LEADING_DOT
m4trace:configure.in:7: -1- m4_pattern_allow([^am__leading_dot$])
m4trace:configure.in:7: -1- _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])],
[_AM_PROG_TAR([v7])])])
m4trace:configure.in:7: -2- _AM_MANGLE_OPTION([tar-ustar])
m4trace:configure.in:7: -1- _AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], [_AM_PROG_TAR([v7])])
m4trace:configure.in:7: -2- _AM_MANGLE_OPTION([tar-pax])
m4trace:configure.in:7: -1- _AM_PROG_TAR([v7])
m4trace:configure.in:7: -1- AM_MISSING_PROG([AMTAR], [tar])
m4trace:configure.in:7: -1- m4_pattern_allow([^AMTAR$])
m4trace:configure.in:7: -1- m4_pattern_allow([^am__tar$])
m4trace:configure.in:7: -1- m4_pattern_allow([^am__untar$])
m4trace:configure.in:7: -1- _AM_IF_OPTION([no-dependencies], [], [AC_PROVIDE_IFELSE([AC_PROG_CC],
[_AM_DEPENDENCIES(CC)],
[define([AC_PROG_CC],
defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
AC_PROVIDE_IFELSE([AC_PROG_CXX],
[_AM_DEPENDENCIES(CXX)],
[define([AC_PROG_CXX],
defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
AC_PROVIDE_IFELSE([AC_PROG_OBJC],
[_AM_DEPENDENCIES(OBJC)],
[define([AC_PROG_OBJC],
defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl
])
m4trace:configure.in:7: -2- _AM_MANGLE_OPTION([no-dependencies])
m4trace:configure.in:9: -1- AM_CONFIG_HEADER([config.h])
m4trace:configure.in:9: -1- _m4_warn([obsolete], [The macro `AM_CONFIG_HEADER' is obsolete.
You should run autoupdate.], [/usr/share/aclocal-1.10/header.m4:12: AM_CONFIG_HEADER is expanded from...
configure.in:9: the top level])
m4trace:configure.in:10: -1- m4_pattern_allow([^CC$])
m4trace:configure.in:10: -1- m4_pattern_allow([^CFLAGS$])
m4trace:configure.in:10: -1- m4_pattern_allow([^LDFLAGS$])
m4trace:configure.in:10: -1- m4_pattern_allow([^LIBS$])
m4trace:configure.in:10: -1- m4_pattern_allow([^CPPFLAGS$])
m4trace:configure.in:10: -1- m4_pattern_allow([^CC$])
m4trace:configure.in:10: -1- m4_pattern_allow([^CC$])
m4trace:configure.in:10: -1- m4_pattern_allow([^CC$])
m4trace:configure.in:10: -1- m4_pattern_allow([^CC$])
m4trace:configure.in:10: -1- m4_pattern_allow([^ac_ct_CC$])
m4trace:configure.in:10: -1- m4_pattern_allow([^EXEEXT$])
m4trace:configure.in:10: -1- m4_pattern_allow([^OBJEXT$])
m4trace:configure.in:10: -1- _AM_DEPENDENCIES([CC])
m4trace:configure.in:10: -1- AM_SET_DEPDIR
m4trace:configure.in:10: -1- m4_pattern_allow([^DEPDIR$])
m4trace:configure.in:10: -1- AM_OUTPUT_DEPENDENCY_COMMANDS
m4trace:configure.in:10: -1- AM_MAKE_INCLUDE
m4trace:configure.in:10: -1- m4_pattern_allow([^am__include$])
m4trace:configure.in:10: -1- m4_pattern_allow([^am__quote$])
m4trace:configure.in:10: -1- AM_DEP_TRACK
m4trace:configure.in:10: -1- AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
m4trace:configure.in:10: -1- m4_pattern_allow([^AMDEP_TRUE$])
m4trace:configure.in:10: -1- m4_pattern_allow([^AMDEP_FALSE$])
m4trace:configure.in:10: -1- _AM_SUBST_NOTMAKE([AMDEP_TRUE])
m4trace:configure.in:10: -1- _AM_SUBST_NOTMAKE([AMDEP_FALSE])
m4trace:configure.in:10: -1- m4_pattern_allow([^AMDEPBACKSLASH$])
m4trace:configure.in:10: -1- _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])
m4trace:configure.in:10: -1- m4_pattern_allow([^CCDEPMODE$])
m4trace:configure.in:10: -1- AM_CONDITIONAL([am__fastdepCC], [
test "x$enable_dependency_tracking" != xno \
&& test "$am_cv_CC_dependencies_compiler_type" = gcc3])
m4trace:configure.in:10: -1- m4_pattern_allow([^am__fastdepCC_TRUE$])
m4trace:configure.in:10: -1- m4_pattern_allow([^am__fastdepCC_FALSE$])
m4trace:configure.in:10: -1- _AM_SUBST_NOTMAKE([am__fastdepCC_TRUE])
m4trace:configure.in:10: -1- _AM_SUBST_NOTMAKE([am__fastdepCC_FALSE])
m4trace:configure.in:25: -1- m4_pattern_allow([^dhcpd_conf$])
m4trace:configure.in:33: -1- m4_pattern_allow([^dhcpd_leases$])
m4trace:configure.in:41: -1- m4_pattern_allow([^output_format$])
m4trace:configure.in:49: -1- m4_pattern_allow([^output_limit$])
m4trace:configure.in:53: -1- m4_pattern_allow([^HAVE_LIBRESOLV$])
m4trace:configure.in:55: -1- m4_pattern_allow([^CPP$])
m4trace:configure.in:55: -1- m4_pattern_allow([^CPPFLAGS$])
m4trace:configure.in:55: -1- m4_pattern_allow([^CPP$])
m4trace:configure.in:55: -1- m4_pattern_allow([^GREP$])
m4trace:configure.in:55: -1- m4_pattern_allow([^GREP$])
m4trace:configure.in:55: -1- m4_pattern_allow([^EGREP$])
m4trace:configure.in:55: -1- m4_pattern_allow([^EGREP$])
m4trace:configure.in:55: -1- m4_pattern_allow([^STDC_HEADERS$])
m4trace:configure.in:59: -2- m4_pattern_allow([^HAVE_GETOPT_H$])
m4trace:configure.in:63: -1- m4_pattern_allow([^HAVE_ALLOCA_H$])
m4trace:configure.in:63: -1- m4_pattern_allow([^HAVE_ALLOCA$])
m4trace:configure.in:63: -1- m4_pattern_allow([^ALLOCA$])
m4trace:configure.in:63: -1- m4_pattern_allow([^C_ALLOCA$])
m4trace:configure.in:63: -1- m4_pattern_allow([^CRAY_STACKSEG_END$])
m4trace:configure.in:63: -1- m4_pattern_allow([^STACK_DIRECTION$])
m4trace:configure.in:66: -1- m4_pattern_allow([^PERL$])
m4trace:configure.in:70: -1- m4_pattern_allow([^LIB@&t@OBJS$])
m4trace:configure.in:70: -1- m4_pattern_allow([^LTLIBOBJS$])
m4trace:configure.in:70: -1- _AC_AM_CONFIG_HEADER_HOOK([$ac_file])
m4trace:configure.in:70: -1- _AM_OUTPUT_DEPENDENCY_COMMANDS

View file

@ -1,4 +0,0 @@
No, 'backup' means that the secondary server in a failover pair can
allocate this address. The lease states should *always* be the same on both
servers

View file

@ -92,7 +92,7 @@
/* If using the C implementation of alloca, define if you know the
direction of stack growth for your system; otherwise it will be
automatically deduced at run-time.
automatically deduced at runtime.
STACK_DIRECTION > 0 => grows toward higher addresses
STACK_DIRECTION < 0 => grows toward lower addresses
STACK_DIRECTION = 0 => direction of growth unknown */

105
config.h.in~ Normal file
View file

@ -0,0 +1,105 @@
/* config.h.in. Generated from configure.in by autoheader. */
/* Define to one of `_getb67', `GETB67', `getb67' for Cray-2 and Cray-YMP
systems. This function is required for `alloca.c' support on those systems.
*/
#undef CRAY_STACKSEG_END
/* Define to 1 if using `alloca.c'. */
#undef C_ALLOCA
/* Define to 1 if you have `alloca', as a function or macro. */
#undef HAVE_ALLOCA
/* Define to 1 if you have <alloca.h> and it should be used (not on Ultrix).
*/
#undef HAVE_ALLOCA_H
/* Define to 1 if you have the <arpa/inet.h> header file. */
#undef HAVE_ARPA_INET_H
/* Define to 1 if you have the <errno.h> header file. */
#undef HAVE_ERRNO_H
/* Define to 1 if you have the <getopt.h> header file. */
#undef HAVE_GETOPT_H
/* Define to 1 if you have the `getopt_long' function. */
#undef HAVE_GETOPT_LONG
/* Define to 1 if you have the `inet_addr' function. */
#undef HAVE_INET_ADDR
/* Define to 1 if you have the `inet_aton' function. */
#undef HAVE_INET_ATON
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
/* Define to 1 if you have the `resolv' library (-lresolv). */
#undef HAVE_LIBRESOLV
/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
/* Define to 1 if you have the <netinet/in.h> header file. */
#undef HAVE_NETINET_IN_H
/* Define to 1 if you have the <stdint.h> header file. */
#undef HAVE_STDINT_H
/* Define to 1 if you have the <stdio.h> header file. */
#undef HAVE_STDIO_H
/* Define to 1 if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H
/* Define to 1 if you have the <strings.h> header file. */
#undef HAVE_STRINGS_H
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
/* Define to 1 if you have the <sys/socket.h> header file. */
#undef HAVE_SYS_SOCKET_H
/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H
/* Define to 1 if you have the <sys/types.h> header file. */
#undef HAVE_SYS_TYPES_H
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* Name of package */
#undef PACKAGE
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
/* Define to the full name of this package. */
#undef PACKAGE_NAME
/* Define to the full name and version of this package. */
#undef PACKAGE_STRING
/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME
/* Define to the version of this package. */
#undef PACKAGE_VERSION
/* If using the C implementation of alloca, define if you know the
direction of stack growth for your system; otherwise it will be
automatically deduced at run-time.
STACK_DIRECTION > 0 => grows toward higher addresses
STACK_DIRECTION < 0 => grows toward lower addresses
STACK_DIRECTION = 0 => direction of growth unknown */
#undef STACK_DIRECTION
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Version number of package */
#undef VERSION

5225
configure vendored

File diff suppressed because it is too large Load diff

View file

@ -2,7 +2,7 @@ dnl Process this file with autoconf to produce a configure script.
AC_PREREQ(2.59)
AC_INIT([dhcpd-pools], [2.8], [kerolasa@iki.fi])
AC_INIT([dhcpd-pools], [2.9], [kerolasa@iki.fi])
AM_INIT_AUTOMAKE([1.6 foreign])

View file

@ -1,8 +1,8 @@
# Makefile.in generated by automake 1.6.3 from Makefile.am.
# Makefile.in generated by automake 1.10.1 from Makefile.am.
# @configure_input@
# Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
# Free Software Foundation, Inc.
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@ -13,105 +13,170 @@
# PARTICULAR PURPOSE.
@SET_MAKE@
SHELL = @SHELL@
srcdir = @srcdir@
top_srcdir = @top_srcdir@
VPATH = @srcdir@
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
sbindir = @sbindir@
libexecdir = @libexecdir@
datadir = @datadir@
sysconfdir = @sysconfdir@
sharedstatedir = @sharedstatedir@
localstatedir = @localstatedir@
libdir = @libdir@
infodir = @infodir@
mandir = @mandir@
includedir = @includedir@
oldincludedir = /usr/include
pkgdatadir = $(datadir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
top_builddir = ..
ACLOCAL = @ACLOCAL@
AUTOCONF = @AUTOCONF@
AUTOMAKE = @AUTOMAKE@
AUTOHEADER = @AUTOHEADER@
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA = @INSTALL_DATA@
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_HEADER = $(INSTALL_DATA)
transform = @program_transform_name@
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
EXEEXT = @EXEEXT@
OBJEXT = @OBJEXT@
PATH_SEPARATOR = @PATH_SEPARATOR@
AMTAR = @AMTAR@
AWK = @AWK@
CC = @CC@
DEPDIR = @DEPDIR@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
PACKAGE = @PACKAGE@
PERL = @PERL@
STRIP = @STRIP@
VERSION = @VERSION@
am__include = @am__include@
am__quote = @am__quote@
dhcpd_conf = @dhcpd_conf@
dhcpd_leases = @dhcpd_leases@
install_sh = @install_sh@
output_format = @output_format@
output_limit = @output_limit@
man_MANS = dhcpd-pools.1
HELP2MAN = help2man
noinst_SCRIPTS = $(HELP2MAN)
EXTRA_DIST = $(man_MANS) $(noinst_SCRIPTS) # $(man_aux)
MAINTAINERCLEANFILES = $(man_MANS)
subdir = man
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/configure.in
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES =
SCRIPTS = $(noinst_SCRIPTS)
SOURCES =
DIST_SOURCES =
man1dir = $(mandir)/man1
am__installdirs = "$(DESTDIR)$(man1dir)"
NROFF = nroff
MANS = $(man_MANS)
DIST_COMMON = Makefile.am Makefile.in
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
ALLOCA = @ALLOCA@
AMTAR = @AMTAR@
AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
EXEEXT = @EXEEXT@
GREP = @GREP@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LDFLAGS = @LDFLAGS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LTLIBOBJS = @LTLIBOBJS@
MAKEINFO = @MAKEINFO@
MKDIR_P = @MKDIR_P@
OBJEXT = @OBJEXT@
PACKAGE = @PACKAGE@
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
PERL = @PERL@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
STRIP = @STRIP@
VERSION = @VERSION@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
ac_ct_CC = @ac_ct_CC@
am__include = @am__include@
am__leading_dot = @am__leading_dot@
am__quote = @am__quote@
am__tar = @am__tar@
am__untar = @am__untar@
bindir = @bindir@
build_alias = @build_alias@
builddir = @builddir@
datadir = @datadir@
datarootdir = @datarootdir@
dhcpd_conf = @dhcpd_conf@
dhcpd_leases = @dhcpd_leases@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@
host_alias = @host_alias@
htmldir = @htmldir@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@
output_format = @output_format@
output_limit = @output_limit@
pdfdir = @pdfdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
sysconfdir = @sysconfdir@
target_alias = @target_alias@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
man_MANS = dhcpd-pools.1
HELP2MAN = help2man
noinst_SCRIPTS = $(HELP2MAN)
EXTRA_DIST = $(man_MANS) $(noinst_SCRIPTS) # $(man_aux)
MAINTAINERCLEANFILES = $(man_MANS)
all: all-am
.SUFFIXES:
$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4)
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
&& exit 0; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign man/Makefile'; \
cd $(top_srcdir) && \
$(AUTOMAKE) --foreign man/Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)
uninstall-info-am:
.PRECIOUS: Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
esac;
man1dir = $(mandir)/man1
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(top_srcdir)/configure: $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
install-man1: $(man1_MANS) $(man_MANS)
@$(NORMAL_INSTALL)
$(mkinstalldirs) $(DESTDIR)$(man1dir)
test -z "$(man1dir)" || $(MKDIR_P) "$(DESTDIR)$(man1dir)"
@list='$(man1_MANS) $(dist_man1_MANS) $(nodist_man1_MANS)'; \
l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \
for i in $$l2; do \
@ -130,8 +195,8 @@ install-man1: $(man1_MANS) $(man_MANS)
inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \
inst=`echo $$inst | sed -e 's/^.*\///'`; \
inst=`echo $$inst | sed '$(transform)'`.$$ext; \
echo " $(INSTALL_DATA) $$file $(DESTDIR)$(man1dir)/$$inst"; \
$(INSTALL_DATA) $$file $(DESTDIR)$(man1dir)/$$inst; \
echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \
$(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst"; \
done
uninstall-man1:
@$(NORMAL_UNINSTALL)
@ -144,31 +209,39 @@ uninstall-man1:
done; \
for i in $$list; do \
ext=`echo $$i | sed -e 's/^.*\\.//'`; \
case "$$ext" in \
1*) ;; \
*) ext='1' ;; \
esac; \
inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \
inst=`echo $$inst | sed -e 's/^.*\///'`; \
inst=`echo $$inst | sed '$(transform)'`.$$ext; \
echo " rm -f $(DESTDIR)$(man1dir)/$$inst"; \
rm -f $(DESTDIR)$(man1dir)/$$inst; \
echo " rm -f '$(DESTDIR)$(man1dir)/$$inst'"; \
rm -f "$(DESTDIR)$(man1dir)/$$inst"; \
done
tags: TAGS
TAGS:
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ctags: CTAGS
CTAGS:
top_distdir = ..
distdir = $(top_distdir)/$(PACKAGE)-$(VERSION)
distdir: $(DISTFILES)
@list='$(DISTFILES)'; for file in $$list; do \
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \
if test "$$dir" != "$$file" && test "$$dir" != "."; then \
dir="/$$dir"; \
$(mkinstalldirs) "$(distdir)$$dir"; \
else \
dir=''; \
fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
fi; \
@ -182,10 +255,10 @@ distdir: $(DISTFILES)
check-am: all-am
check: check-am
all-am: Makefile $(SCRIPTS) $(MANS)
installdirs:
$(mkinstalldirs) $(DESTDIR)$(man1dir)
for dir in "$(DESTDIR)$(man1dir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-am
install-exec: install-exec-am
install-data: install-data-am
@ -197,7 +270,7 @@ install-am: all-am
installcheck: installcheck-am
install-strip:
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
INSTALL_STRIP_FLAG=-s \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
`test -z '$(STRIP)' || \
echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
mostlyclean-generic:
@ -205,7 +278,7 @@ mostlyclean-generic:
clean-generic:
distclean-generic:
-rm -f Makefile $(CONFIG_CLEAN_FILES)
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@ -216,47 +289,69 @@ clean: clean-am
clean-am: clean-generic mostlyclean-am
distclean: distclean-am
-rm -f Makefile
distclean-am: clean-am distclean-generic
dvi: dvi-am
dvi-am:
html: html-am
info: info-am
info-am:
install-data-am: install-man
install-dvi: install-dvi-am
install-exec-am:
install-html: install-html-am
install-info: install-info-am
install-man: install-man1
install-pdf: install-pdf-am
install-ps: install-ps-am
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-am
mostlyclean-am: mostlyclean-generic
uninstall-am: uninstall-info-am uninstall-man
pdf: pdf-am
pdf-am:
ps: ps-am
ps-am:
uninstall-am: uninstall-man
uninstall-man: uninstall-man1
.MAKE: install-am install-strip
.PHONY: all all-am check check-am clean clean-generic distclean \
distclean-generic distdir dvi dvi-am info info-am install \
install-am install-data install-data-am install-exec \
install-exec-am install-info install-info-am install-man \
install-man1 install-strip installcheck installcheck-am \
distclean-generic distdir dvi dvi-am html html-am info info-am \
install install-am install-data install-data-am install-dvi \
install-dvi-am install-exec install-exec-am install-html \
install-html-am install-info install-info-am install-man \
install-man1 install-pdf install-pdf-am install-ps \
install-ps-am install-strip installcheck installcheck-am \
installdirs maintainer-clean maintainer-clean-generic \
mostlyclean mostlyclean-generic uninstall uninstall-am \
uninstall-info-am uninstall-man uninstall-man1
mostlyclean mostlyclean-generic pdf pdf-am ps ps-am uninstall \
uninstall-am uninstall-man uninstall-man1
dhcpd-pools.1: ../src/dhcpd-pools $(HELP2MAN)

View file

@ -2,7 +2,7 @@
.\" http://www.iki.fi/kerolasa/
.\" kerolasa@iki.fi
.\"
.TH DHCPD-POOLS 1 "May 18 2008 - version 2.8"
.TH DHCPD-POOLS 1 "May 18 2008 - version 2.9"
.SH NAME
dhcpd-pools \- ISC dhcp pools usage analysis
.SH SYNOPSIS

View file

@ -1 +0,0 @@
/usr/share/automake-1.6/mkinstalldirs

5
mkinstalldirs Executable file
View file

@ -0,0 +1,5 @@
XSym
0037
113008ccb0cc2608a09cd091919df7c4
/usr/share/automake-1.6/mkinstalldirs

View file

@ -1,8 +1,8 @@
# Makefile.in generated by automake 1.6.3 from Makefile.am.
# Makefile.in generated by automake 1.10.1 from Makefile.am.
# @configure_input@
# Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
# Free Software Foundation, Inc.
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@ -13,135 +13,189 @@
# PARTICULAR PURPOSE.
@SET_MAKE@
SHELL = @SHELL@
srcdir = @srcdir@
top_srcdir = @top_srcdir@
VPATH = @srcdir@
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
sbindir = @sbindir@
libexecdir = @libexecdir@
datadir = @datadir@
sysconfdir = @sysconfdir@
sharedstatedir = @sharedstatedir@
localstatedir = @localstatedir@
libdir = @libdir@
infodir = @infodir@
mandir = @mandir@
includedir = @includedir@
oldincludedir = /usr/include
pkgdatadir = $(datadir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
top_builddir = ..
ACLOCAL = @ACLOCAL@
AUTOCONF = @AUTOCONF@
AUTOMAKE = @AUTOMAKE@
AUTOHEADER = @AUTOHEADER@
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA = @INSTALL_DATA@
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_HEADER = $(INSTALL_DATA)
transform = @program_transform_name@
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
EXEEXT = @EXEEXT@
OBJEXT = @OBJEXT@
PATH_SEPARATOR = @PATH_SEPARATOR@
AMTAR = @AMTAR@
AWK = @AWK@
CC = @CC@
DEPDIR = @DEPDIR@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
PACKAGE = @PACKAGE@
PERL = @PERL@
STRIP = @STRIP@
VERSION = @VERSION@
am__include = @am__include@
am__quote = @am__quote@
dhcpd_conf = @dhcpd_conf@
dhcpd_leases = @dhcpd_leases@
install_sh = @install_sh@
output_format = @output_format@
output_limit = @output_limit@
bin_PROGRAMS = dhcpd-pools
AC_PROG_RANLIB = resolv
dhcpd_pools_SOURCES = dhcpd-pools.c analyze.c getdata.c getopt1.c getopt.c other.c sort.c output.c getopt.h
INCLUDES = -I.
bin_PROGRAMS = dhcpd-pools$(EXEEXT)
subdir = src
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/configure.in
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES =
bin_PROGRAMS = dhcpd-pools$(EXEEXT)
am__installdirs = "$(DESTDIR)$(bindir)"
binPROGRAMS_INSTALL = $(INSTALL_PROGRAM)
PROGRAMS = $(bin_PROGRAMS)
am_dhcpd_pools_OBJECTS = dhcpd-pools.$(OBJEXT) analyze.$(OBJEXT) \
getdata.$(OBJEXT) getopt1.$(OBJEXT) getopt.$(OBJEXT) \
other.$(OBJEXT) sort.$(OBJEXT) output.$(OBJEXT)
dhcpd_pools_OBJECTS = $(am_dhcpd_pools_OBJECTS)
dhcpd_pools_LDADD = $(LDADD)
dhcpd_pools_DEPENDENCIES =
dhcpd_pools_LDFLAGS =
DEFS = @DEFS@
DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir)
CPPFLAGS = @CPPFLAGS@
LDFLAGS = @LDFLAGS@
LIBS = @LIBS@
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
@AMDEP_TRUE@DEP_FILES = ./$(DEPDIR)/analyze.Po \
@AMDEP_TRUE@ ./$(DEPDIR)/dhcpd-pools.Po ./$(DEPDIR)/getdata.Po \
@AMDEP_TRUE@ ./$(DEPDIR)/getopt.Po ./$(DEPDIR)/getopt1.Po \
@AMDEP_TRUE@ ./$(DEPDIR)/other.Po ./$(DEPDIR)/output.Po \
@AMDEP_TRUE@ ./$(DEPDIR)/sort.Po
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
CCLD = $(CC)
LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
CFLAGS = @CFLAGS@
DIST_SOURCES = $(dhcpd_pools_SOURCES)
DIST_COMMON = Makefile.am Makefile.in
SOURCES = $(dhcpd_pools_SOURCES)
DIST_SOURCES = $(dhcpd_pools_SOURCES)
ETAGS = etags
CTAGS = ctags
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
ALLOCA = @ALLOCA@
AMTAR = @AMTAR@
AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
EXEEXT = @EXEEXT@
GREP = @GREP@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LDFLAGS = @LDFLAGS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LTLIBOBJS = @LTLIBOBJS@
MAKEINFO = @MAKEINFO@
MKDIR_P = @MKDIR_P@
OBJEXT = @OBJEXT@
PACKAGE = @PACKAGE@
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
PERL = @PERL@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
STRIP = @STRIP@
VERSION = @VERSION@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
ac_ct_CC = @ac_ct_CC@
am__include = @am__include@
am__leading_dot = @am__leading_dot@
am__quote = @am__quote@
am__tar = @am__tar@
am__untar = @am__untar@
bindir = @bindir@
build_alias = @build_alias@
builddir = @builddir@
datadir = @datadir@
datarootdir = @datarootdir@
dhcpd_conf = @dhcpd_conf@
dhcpd_leases = @dhcpd_leases@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@
host_alias = @host_alias@
htmldir = @htmldir@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@
output_format = @output_format@
output_limit = @output_limit@
pdfdir = @pdfdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
sysconfdir = @sysconfdir@
target_alias = @target_alias@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
AC_PROG_RANLIB = resolv
dhcpd_pools_SOURCES = dhcpd-pools.c analyze.c getdata.c getopt1.c getopt.c other.c sort.c output.c getopt.h
INCLUDES = -I.
all: all-am
.SUFFIXES:
.SUFFIXES: .c .o .obj
$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4)
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
&& exit 0; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/Makefile'; \
cd $(top_srcdir) && \
$(AUTOMAKE) --foreign src/Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)
binPROGRAMS_INSTALL = $(INSTALL_PROGRAM)
.PRECIOUS: Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(top_srcdir)/configure: $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
install-binPROGRAMS: $(bin_PROGRAMS)
@$(NORMAL_INSTALL)
$(mkinstalldirs) $(DESTDIR)$(bindir)
test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)"
@list='$(bin_PROGRAMS)'; for p in $$list; do \
p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \
if test -f $$p \
; then \
f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \
echo " $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) $$p $(DESTDIR)$(bindir)/$$f"; \
$(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) $$p $(DESTDIR)$(bindir)/$$f; \
echo " $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \
$(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \
else :; fi; \
done
@ -149,18 +203,18 @@ uninstall-binPROGRAMS:
@$(NORMAL_UNINSTALL)
@list='$(bin_PROGRAMS)'; for p in $$list; do \
f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \
echo " rm -f $(DESTDIR)$(bindir)/$$f"; \
rm -f $(DESTDIR)$(bindir)/$$f; \
echo " rm -f '$(DESTDIR)$(bindir)/$$f'"; \
rm -f "$(DESTDIR)$(bindir)/$$f"; \
done
clean-binPROGRAMS:
-test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS)
dhcpd-pools$(EXEEXT): $(dhcpd_pools_OBJECTS) $(dhcpd_pools_DEPENDENCIES)
@rm -f dhcpd-pools$(EXEEXT)
$(LINK) $(dhcpd_pools_LDFLAGS) $(dhcpd_pools_OBJECTS) $(dhcpd_pools_LDADD) $(LIBS)
$(LINK) $(dhcpd_pools_OBJECTS) $(dhcpd_pools_LDADD) $(LIBS)
mostlyclean-compile:
-rm -f *.$(OBJEXT) core *.core
-rm -f *.$(OBJEXT)
distclean-compile:
-rm -f *.tab.c
@ -174,36 +228,29 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/output.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sort.Po@am__quote@
distclean-depend:
-rm -rf ./$(DEPDIR)
.c.o:
@AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@
@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
$(COMPILE) -c `test -f '$<' || echo '$(srcdir)/'`$<
@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(COMPILE) -c $<
.c.obj:
@AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@
@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
$(COMPILE) -c `cygpath -w $<`
CCDEPMODE = @CCDEPMODE@
uninstall-info-am:
ETAGS = etags
ETAGSFLAGS =
tags: TAGS
@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'`
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
$(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
END { if (nonempty) { for (i in files) print i; }; }'`; \
mkid -fID $$unique
tags: TAGS
TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
$(TAGS_FILES) $(LISP)
@ -213,10 +260,25 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
test -z "$(ETAGS_ARGS)$$tags$$unique" \
|| $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in files) print i; }; }'`; \
if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$tags $$unique; \
fi
ctags: CTAGS
CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
$(TAGS_FILES) $(LISP)
tags=; \
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in files) print i; }; }'`; \
test -z "$(CTAGS_ARGS)$$tags$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$tags $$unique
GTAGS:
@ -225,23 +287,24 @@ GTAGS:
&& gtags -i $(GTAGS_ARGS) $$here
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
top_distdir = ..
distdir = $(top_distdir)/$(PACKAGE)-$(VERSION)
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(DISTFILES)
@list='$(DISTFILES)'; for file in $$list; do \
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \
if test "$$dir" != "$$file" && test "$$dir" != "."; then \
dir="/$$dir"; \
$(mkinstalldirs) "$(distdir)$$dir"; \
else \
dir=''; \
fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
fi; \
@ -255,10 +318,10 @@ distdir: $(DISTFILES)
check-am: all-am
check: check-am
all-am: Makefile $(PROGRAMS)
installdirs:
$(mkinstalldirs) $(DESTDIR)$(bindir)
for dir in "$(DESTDIR)$(bindir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-am
install-exec: install-exec-am
install-data: install-data-am
@ -270,7 +333,7 @@ install-am: all-am
installcheck: installcheck-am
install-strip:
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
INSTALL_STRIP_FLAG=-s \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
`test -z '$(STRIP)' || \
echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
mostlyclean-generic:
@ -278,7 +341,7 @@ mostlyclean-generic:
clean-generic:
distclean-generic:
-rm -f Makefile $(CONFIG_CLEAN_FILES)
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@ -288,48 +351,72 @@ clean: clean-am
clean-am: clean-binPROGRAMS clean-generic mostlyclean-am
distclean: distclean-am
distclean-am: clean-am distclean-compile distclean-depend \
distclean-generic distclean-tags
-rm -rf ./$(DEPDIR)
-rm -f Makefile
distclean-am: clean-am distclean-compile distclean-generic \
distclean-tags
dvi: dvi-am
dvi-am:
html: html-am
info: info-am
info-am:
install-data-am:
install-dvi: install-dvi-am
install-exec-am: install-binPROGRAMS
install-html: install-html-am
install-info: install-info-am
install-man:
install-pdf: install-pdf-am
install-ps: install-ps-am
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -rf ./$(DEPDIR)
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-am
mostlyclean-am: mostlyclean-compile mostlyclean-generic
uninstall-am: uninstall-binPROGRAMS uninstall-info-am
pdf: pdf-am
.PHONY: GTAGS all all-am check check-am clean clean-binPROGRAMS \
clean-generic distclean distclean-compile distclean-depend \
distclean-generic distclean-tags distdir dvi dvi-am info \
info-am install install-am install-binPROGRAMS install-data \
install-data-am install-exec install-exec-am install-info \
install-info-am install-man install-strip installcheck \
installcheck-am installdirs maintainer-clean \
pdf-am:
ps: ps-am
ps-am:
uninstall-am: uninstall-binPROGRAMS
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \
clean-generic ctags distclean distclean-compile \
distclean-generic distclean-tags distdir dvi dvi-am html \
html-am info info-am install install-am install-binPROGRAMS \
install-data install-data-am install-dvi install-dvi-am \
install-exec install-exec-am install-html install-html-am \
install-info install-info-am install-man install-pdf \
install-pdf-am install-ps install-ps-am install-strip \
installcheck installcheck-am installdirs maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-compile \
mostlyclean-generic tags uninstall uninstall-am \
uninstall-binPROGRAMS uninstall-info-am
mostlyclean-generic pdf pdf-am ps ps-am tags uninstall \
uninstall-am uninstall-binPROGRAMS
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.

View file

@ -26,150 +26,138 @@
#include "dhcpd-pools.h"
/* Clean up data */
int
prepare_data (void)
int prepare_data(void)
{
unsigned long int i, j, k;
unsigned long int i, j, k;
/* Sort leases */
qsort (leases, (size_t) num_leases, sizeof (long int), &intcomp);
/* Sort leases */
qsort(leases, (size_t) num_leases, sizeof(long int), &intcomp);
/* Get rid of lease dublicates */
for (k = j = i = 0; i < num_leases; i++)
{
if (j != leases[i])
{
leases[k] = leases[i];
j = leases[i];
k++;
/* Get rid of lease dublicates */
for (k = j = i = 0; i < num_leases; i++) {
if (j != leases[i]) {
leases[k] = leases[i];
j = leases[i];
k++;
}
}
}
num_leases = k;
num_leases = k;
/* Delete touched IPs that are in use. */
j = 0;
for (i = 0; i < num_touches; i++)
{
if (bsearch
(&touches[i], leases, (size_t) num_leases, sizeof (long int),
&intcomp) == NULL)
{
touches[j] = touches[i];
j++;
/* Delete touched IPs that are in use. */
j = 0;
for (i = 0; i < num_touches; i++) {
if (bsearch
(&touches[i], leases, (size_t) num_leases,
sizeof(long int), &intcomp) == NULL) {
touches[j] = touches[i];
j++;
}
}
}
num_touches = j;
qsort (touches, (size_t) num_touches, sizeof (long int), &intcomp);
num_touches = j;
qsort(touches, (size_t) num_touches, sizeof(long int), &intcomp);
/* Sort ranges */
qsort (ranges, (size_t) num_ranges, sizeof (struct range_t), &rangecomp);
/* Sort ranges */
qsort(ranges, (size_t) num_ranges, sizeof(struct range_t),
&rangecomp);
/* Sort backups */
if (num_backups > 0)
{
qsort (backups, (size_t) num_backups, sizeof (long int), &intcomp);
}
/* Sort backups */
if (num_backups > 0) {
qsort(backups, (size_t) num_backups, sizeof(long int),
&intcomp);
}
return 0;
return 0;
}
/* Join leases and ranges into couter structs */
int
do_counting (void)
int do_counting(void)
{
struct range_t *range_p;
unsigned int i, j, k, m, block_size;
struct range_t *range_p;
unsigned int i, j, k, m, block_size;
i = j = m = 0;
range_p = ranges;
i = j = m = 0;
range_p = ranges;
/* Walk through ranges */
for (k = 0; k < num_ranges; k++)
{
/* Count IPs in use */
for (; range_p->last_ip > leases[i] && (unsigned long) i < num_leases;
i++)
{
if (range_p->first_ip > leases[i])
{
continue;
}
/* IP with in range */
range_p->count++;
if (range_p->shared_net)
{
range_p->shared_net->used++;
}
}
/* Count touched IPs */
for (; range_p->last_ip > touches[j] && (unsigned long) j < num_touches;
j++)
{
if (range_p->first_ip > touches[j])
{
continue;
}
/* IP with in range */
range_p->touched++;
if (range_p->shared_net)
{
range_p->shared_net->touched++;
}
}
/* Count backup IPs */
if (num_backups > 0)
{
for (;
range_p->last_ip > backups[m]
&& (unsigned long) m < num_touches; m++)
{
if (range_p->first_ip > touches[m])
{
continue;
/* Walk through ranges */
for (k = 0; k < num_ranges; k++) {
/* Count IPs in use */
for (;
range_p->last_ip > leases[i]
&& (unsigned long) i < num_leases; i++) {
if (range_p->first_ip > leases[i]) {
continue;
}
/* IP with in range */
range_p->count++;
if (range_p->shared_net) {
range_p->shared_net->used++;
}
}
/* IP with in range */
range_p->backups++;
if (range_p->shared_net)
{
range_p->shared_net->backups++;
/* Count touched IPs */
for (;
range_p->last_ip > touches[j]
&& (unsigned long) j < num_touches; j++) {
if (range_p->first_ip > touches[j]) {
continue;
}
/* IP with in range */
range_p->touched++;
if (range_p->shared_net) {
range_p->shared_net->touched++;
}
}
}
/* Count backup IPs */
if (num_backups > 0) {
for (; range_p->last_ip > backups[m]
&& (unsigned long) m < num_touches; m++) {
if (range_p->first_ip > touches[m]) {
continue;
}
/* IP with in range */
range_p->backups++;
if (range_p->shared_net) {
range_p->shared_net->backups++;
}
}
}
/* Size of range, shared net & all networks */
block_size =
(unsigned int) (range_p->last_ip - range_p->first_ip -
1);
if (range_p->shared_net) {
range_p->shared_net->available += block_size;
}
/* Reverse so that not even a one IP will be missed. */
if (i) {
i--;
}
if (j) {
j--;
}
range_p++;
}
/* Size of range, shared net & all networks */
block_size = (unsigned int) (range_p->last_ip - range_p->first_ip - 1);
if (range_p->shared_net)
{
range_p->shared_net->available += block_size;
/* During count of other shared networks default network and
* all networks got mixed to gether semantically. This fixes
* the problem, but is not elegant. TODO: fix semantics of all
* and default share_network. */
shared_networks->available = 0;
shared_networks->used = 0;
shared_networks->touched = 0;
range_p = ranges;
for (k = 0; k < num_ranges; k++) {
shared_networks->available +=
range_p->last_ip - range_p->first_ip - 1;
shared_networks->used += range_p->count;
shared_networks->touched += range_p->touched;
shared_networks->backups += range_p->backups;
range_p++;
}
/* Reverse so that not even a one IP will be missed. */
i--;
j--;
range_p++;
}
/* During count of other shared networks default network and
* all networks got mixed to gether semantically. This fixes
* the problem, but is not elegant. TODO: fix semantics of all
* and default share_network. */
shared_networks->available = 0;
shared_networks->used = 0;
shared_networks->touched = 0;
range_p = ranges;
for (k = 0; k < num_ranges; k++)
{
shared_networks->available += range_p->last_ip - range_p->first_ip - 1;
shared_networks->used += range_p->count;
shared_networks->touched += range_p->touched;
shared_networks->backups += range_p->backups;
range_p++;
}
return 0;
return 0;
}

View file

@ -26,10 +26,10 @@
#endif
#ifdef HAVE_STDLIB_H
#include <stdlib.h>
#else /* Not STDC_HEADERS */
extern void exit ();
extern char *malloc ();
#endif /* STDC_HEADERS */
#else /* Not STDC_HEADERS */
extern void exit();
extern char *malloc();
#endif /* STDC_HEADERS */
#ifdef HAVE_STRING_H
#include <string.h>
#else
@ -40,252 +40,238 @@ extern char *malloc ();
#include "dhcpd-pools.h"
#include "defaults.h"
int
main (int argc, char **argv)
int main(int argc, char **argv)
{
int c, i, sorts = 0;
int option_index = 0;
char *tmp;
struct range_t *tmp_ranges;
int c, i, sorts = 0;
int option_index = 0;
char *tmp;
struct range_t *tmp_ranges;
/* Options for getopt_long */
static struct option const long_options[] = {
{"config", required_argument, 0, (int) 'c'},
{"leases", required_argument, 0, (int) 'l'},
{"format", required_argument, 0, (int) 'f'},
{"sort", required_argument, 0, (int) 's'},
{"reverse", no_argument, 0, (int) 'r'},
{"output", required_argument, 0, (int) 'o'},
{"limit", required_argument, 0, (int) 'L'},
{"version", no_argument, 0, (int) 'v'},
{"help", no_argument, 0, (int) 'h'},
{0, 0, 0, 0}
};
/* Options for getopt_long */
static struct option const long_options[] = {
{"config", required_argument, 0, (int) 'c'},
{"leases", required_argument, 0, (int) 'l'},
{"format", required_argument, 0, (int) 'f'},
{"sort", required_argument, 0, (int) 's'},
{"reverse", no_argument, 0, (int) 'r'},
{"output", required_argument, 0, (int) 'o'},
{"limit", required_argument, 0, (int) 'L'},
{"version", no_argument, 0, (int) 'v'},
{"help", no_argument, 0, (int) 'h'},
{0, 0, 0, 0}
};
program_name = argv[0];
program_name = argv[0];
/* TODO: make either dynamic or find out max path lenght that auto config
* provides */
config.dhcpdconf_file = safe_malloc (sizeof (char) * MAXLEN);
config.dhcpdlease_file = safe_malloc (sizeof (char) * MAXLEN);
config.output_file = safe_malloc (sizeof (char) * MAXLEN);
/* TODO: make either dynamic or find out max path lenght that auto config
* provides */
config.dhcpdconf_file = safe_malloc(sizeof(char) * MAXLEN);
config.dhcpdlease_file = safe_malloc(sizeof(char) * MAXLEN);
config.output_file = safe_malloc(sizeof(char) * MAXLEN);
/* Make sure string has zero lenght if there is no command line
* option */
config.output_file[0] = '\0';
/* Make sure string has zero lenght if there is no command line
* option */
config.output_file[0] = '\0';
/* File location defaults */
strncpy (config.dhcpdconf_file, DHCPDCONF_FILE, (size_t) MAXLEN - 1);
strncpy (config.dhcpdlease_file, DHCPDLEASE_FILE, (size_t) MAXLEN - 1);
tmp = OUTPUT_LIMIT;
config.output_limit[0] = (int) (*tmp - '0');
tmp++;
config.output_limit[1] = (int) (*tmp - '0');
/* File location defaults */
strncpy(config.dhcpdconf_file, DHCPDCONF_FILE,
(size_t) MAXLEN - 1);
strncpy(config.dhcpdlease_file, DHCPDLEASE_FILE,
(size_t) MAXLEN - 1);
tmp = OUTPUT_LIMIT;
config.output_limit[0] = (int) (*tmp - '0');
tmp++;
config.output_limit[1] = (int) (*tmp - '0');
/* Make sure some output format is selected by default */
strncpy (config.output_format, OUTPUT_FORMAT, (size_t) 1);
/* Make sure some output format is selected by default */
strncpy(config.output_format, OUTPUT_FORMAT, (size_t) 1);
/* Default sort order is by IPs small to big */
config.reverse_order = false;
/* Default sort order is by IPs small to big */
config.reverse_order = false;
/* Parse command line options */
while (1)
{
c =
getopt_long (argc, argv, "c:l:f:o:s:rL:vh", long_options,
&option_index);
/* Parse command line options */
while (1) {
c = getopt_long(argc, argv, "c:l:f:o:s:rL:vh",
long_options, &option_index);
if (c == EOF)
break;
if (c == EOF)
break;
switch (c)
{
case 0:
break;
case 'c':
/* config file */
if (optarg != NULL)
{
strncpy (config.dhcpdconf_file, optarg, (size_t) MAXLEN - 1);
}
else
{
eprintf
("main: for argument configuration file parameter not set");
print_help ();
exit (EXIT_FAILURE);
}
break;
case 'l':
/* lease file */
if (optarg != NULL)
{
strncpy (config.dhcpdlease_file, optarg, (size_t) MAXLEN - 1);
}
else
{
eprintf ("main: for argument lease file parameter not set");
print_help ();
exit (EXIT_FAILURE);
}
break;
case 'f':
/* Output format */
if (optarg != NULL)
{
strncpy (config.output_format, optarg, (size_t) 1);
}
else
{
eprintf ("main: for argument output format parameter not set");
print_help ();
exit (EXIT_FAILURE);
}
break;
case 's':
/* Output sorting option */
if (optarg != NULL)
{
sorts = strlen (optarg);
if (sorts > 5)
{
eprintf ("main: only 5 first sort orders will be used");
strncpy (config.sort, optarg, (size_t) 5);
sorts = 5;
switch (c) {
case 0:
break;
case 'c':
/* config file */
if (optarg != NULL) {
strncpy(config.dhcpdconf_file, optarg,
(size_t) MAXLEN - 1);
} else {
eprintf
("main: for argument configuration file parameter not set");
print_help();
exit(EXIT_FAILURE);
}
break;
case 'l':
/* lease file */
if (optarg != NULL) {
strncpy(config.dhcpdlease_file, optarg,
(size_t) MAXLEN - 1);
} else {
eprintf
("main: for argument lease file parameter not set");
print_help();
exit(EXIT_FAILURE);
}
break;
case 'f':
/* Output format */
if (optarg != NULL) {
strncpy(config.output_format, optarg,
(size_t) 1);
} else {
eprintf
("main: for argument output format parameter not set");
print_help();
exit(EXIT_FAILURE);
}
break;
case 's':
/* Output sorting option */
if (optarg != NULL) {
sorts = strlen(optarg);
if (sorts > 5) {
eprintf
("main: only 5 first sort orders will be used");
strncpy(config.sort, optarg,
(size_t) 5);
sorts = 5;
} else {
strncpy(config.sort, optarg,
(size_t) sorts);
}
} else {
eprintf
("main: for argument sort order parameter not set");
print_help();
exit(EXIT_FAILURE);
}
break;
case 'r':
/* What ever sort in reverse order */
config.reverse_order = true;
break;
case 'o':
/* Output file */
if (optarg != NULL) {
strncpy(config.output_file, optarg,
(size_t) MAXLEN - 1);
} else {
eprintf
("main: for argument output file parameter not set");
print_help();
exit(EXIT_FAILURE);
}
break;
case 'L':
/* Specification what will be printed */
if (optarg != NULL) {
if (optarg[0] >= '0' && optarg[0] < '8') {
config.output_limit[0] =
(int) optarg[0] - '0';
} else {
eprintf
("main: output mask %s illegal",
argv[optind]);
print_help();
exit(EXIT_FAILURE);
}
if (optarg[1] >= '0' && optarg[1] < '8') {
config.output_limit[1] =
(int) optarg[1] - '0';
} else {
eprintf
("main: output mask %s illegal",
optarg);
print_help();
exit(EXIT_FAILURE);
}
} else {
eprintf
("main: for argument output mask parameter not set");
print_help();
exit(EXIT_FAILURE);
}
break;
case 'v':
/* Print version */
print_version();
exit(EXIT_SUCCESS);
case 'h':
/* Print help */
print_help();
exit(EXIT_SUCCESS);
default:
print_help();
exit(EXIT_FAILURE);
}
else
{
strncpy (config.sort, optarg, (size_t) sorts);
}
}
else
{
eprintf ("main: for argument sort order parameter not set");
print_help ();
exit (EXIT_FAILURE);
}
break;
case 'r':
/* What ever sort in reverse order */
config.reverse_order = true;
break;
case 'o':
/* Output file */
if (optarg != NULL)
{
strncpy (config.output_file, optarg, (size_t) MAXLEN - 1);
}
else
{
eprintf ("main: for argument output file parameter not set");
print_help ();
exit (EXIT_FAILURE);
}
break;
case 'L':
/* Specification what will be printed */
if (optarg != NULL)
{
if (optarg[0] >= '0' && optarg[0] < '8')
{
config.output_limit[0] = (int) optarg[0] - '0';
}
else
{
eprintf ("main: output mask %s illegal", argv[optind]);
print_help ();
exit (EXIT_FAILURE);
}
if (optarg[1] >= '0' && optarg[1] < '8')
{
config.output_limit[1] = (int) optarg[1] - '0';
}
else
{
eprintf ("main: output mask %s illegal", optarg);
print_help ();
exit (EXIT_FAILURE);
}
}
else
{
eprintf ("main: for argument output mask parameter not set");
print_help ();
exit (EXIT_FAILURE);
}
break;
case 'v':
/* Print version */
print_version ();
exit (EXIT_SUCCESS);
case 'h':
/* Print help */
print_help ();
exit (EXIT_SUCCESS);
default:
print_help ();
exit (EXIT_FAILURE);
}
}
/* Output function selection */
switch (config.output_format[0])
{
case 't':
output_analysis = output_txt;
break;
case 'h':
output_analysis = output_html;
break;
case 'c':
output_analysis = output_csv;
break;
case 's':
/* output_analysis = output_snmp; */
output_analysis = output_txt;
break;
default:
eprintf ("main: unknown ouput format");
print_help ();
exit (EXIT_FAILURE);
}
/* Output function selection */
switch (config.output_format[0]) {
case 't':
output_analysis = output_txt;
break;
case 'h':
output_analysis = output_html;
break;
case 'c':
output_analysis = output_csv;
break;
case 's':
/* output_analysis = output_snmp; */
output_analysis = output_txt;
break;
default:
eprintf("main: unknown ouput format");
print_help();
exit(EXIT_FAILURE);
}
/* Do the job */
prepare_memory ();
parse_config (config.dhcpdconf_file, shared_net_names,
shared_net_names + strlen (shared_net_names) + 1,
shared_networks);
parse_leases ();
prepare_data ();
do_counting ();
tmp_ranges = safe_malloc (sizeof (struct range_t) * num_ranges);
if (sorts != 0)
{
mergesort_ranges (ranges, num_ranges, tmp_ranges);
}
if (config.reverse_order == true)
{
flip_ranges (ranges, tmp_ranges);
}
free (tmp_ranges);
output_analysis ();
clean_up ();
/* Do the job */
prepare_memory();
parse_config(config.dhcpdconf_file, shared_net_names,
shared_net_names + strlen(shared_net_names) + 1,
shared_networks);
parse_leases();
prepare_data();
do_counting();
tmp_ranges = safe_malloc(sizeof(struct range_t) * num_ranges);
if (sorts != 0) {
mergesort_ranges(ranges, num_ranges, tmp_ranges);
}
if (config.reverse_order == true) {
flip_ranges(ranges, tmp_ranges);
}
free(tmp_ranges);
output_analysis();
clean_up();
return 0;
return 0;
}
/* Global allocations, counter resets etc */
int
prepare_memory ()
int prepare_memory()
{
num_ranges = num_shared_networks = 0;
shared_networks =
safe_malloc (sizeof (struct shared_network_t) * SHARED_NETWORKS);
shared_net_names = safe_malloc (sizeof (char) * SHARED_NETWORKS_NAMES);
num_ranges = num_shared_networks = 0;
shared_networks =
safe_malloc(sizeof(struct shared_network_t) * SHARED_NETWORKS);
shared_net_names =
safe_malloc(sizeof(char) * SHARED_NETWORKS_NAMES);
ranges = safe_malloc (sizeof (struct range_t) * RANGES);
ranges = safe_malloc(sizeof(struct range_t) * RANGES);
/* First shared network entry is all networks */
strcpy (shared_net_names, "All networks");
return 0;
/* First shared network entry is all networks */
strcpy(shared_net_names, "All networks");
return 0;
}

View file

@ -88,7 +88,7 @@ unsigned long int num_backups;
/* Function prototypes */
int prepare_memory (void);
int parse_leases (void);
int parse_config (char *, char *, char *, struct shared_network_t *);
char * parse_config (char *, char *, char *, struct shared_network_t *);
int nth_field (int n, char *dest, const char *src);
int prepare_data (void);
int do_counting (void);

View file

@ -26,12 +26,12 @@
#ifdef HAVE_STDLIB_H
#include <stdlib.h>
#else /* Not STDC_HEADERS */
extern void exit ();
extern char *malloc ();
#else /* Not STDC_HEADERS */
extern void exit();
extern char *malloc();
#define EXIT_FAILURE 1 /* Failing exit status. */
#define EXIT_SUCCESS 0 /* Successful exit status. */
#endif /* STDC_HEADERS */
#endif /* STDC_HEADERS */
#ifdef HAVE_STRING_H
#include <string.h>
@ -51,81 +51,71 @@ extern char *malloc ();
/* Parse dhcpd.leases file. All performance boosts for this
* function are wellcome */
int
parse_leases (void)
int parse_leases(void)
{
FILE *dhcpd_leases;
char *line, *ipstring;
struct in_addr inp;
struct stat lease_file_stats;
FILE *dhcpd_leases;
char *line, *ipstring;
struct in_addr inp;
struct stat lease_file_stats;
num_touches = num_leases = num_backups = 0;
num_touches = num_leases = num_backups = 0;
dhcpd_leases = fopen (config.dhcpdlease_file, "r");
if (dhcpd_leases == NULL)
{
eprintf ("parse_leases: %s:", config.dhcpdlease_file);
exit (EXIT_FAILURE);
}
/* I found out that there's one lease address per 300 bytes in
* dhcpd.leases file. Malloc is little bit pessimistic and uses
* 250. If someone has higher density in lease file I'm
* interested to hear about that. */
if (stat (config.dhcpdlease_file, &lease_file_stats))
{
eprintf ("parse_leases: %s:", config.dhcpdlease_file);
exit (EXIT_FAILURE);
}
leases =
safe_malloc (sizeof (long int) *
((lease_file_stats.st_size / 250) + MAXLEN));
touches =
safe_malloc ((size_t) sizeof (long int) *
((lease_file_stats.st_size / 250) + MAXLEN));
line = safe_malloc (sizeof (long int) * MAXLEN);
ipstring = safe_malloc (sizeof (long int) * MAXLEN);
while (!feof (dhcpd_leases))
{
fgets (line, MAXLEN, dhcpd_leases);
/* It's a lease */
if (strstr (line, "lease") == line)
{
strncpy (ipstring, line, (size_t) MAXLEN - 1);
dhcpd_leases = fopen(config.dhcpdlease_file, "r");
if (dhcpd_leases == NULL) {
eprintf("parse_leases: %s:", config.dhcpdlease_file);
exit(EXIT_FAILURE);
}
/* And this is lease state which we are interested about */
else if (strstr (line, "binding state active"))
{
nth_field (2, ipstring, ipstring);
inet_aton (ipstring, &inp);
leases[num_leases] = htonl (inp.s_addr);
num_leases++;
}
else if (strstr (line, " binding state free"))
{
nth_field (2, ipstring, ipstring);
inet_aton (ipstring, &inp);
touches[num_touches] = htonl (inp.s_addr);
num_touches++;
}
else if (strstr (line, " binding state backup"))
{
nth_field (2, ipstring, ipstring);
inet_aton (ipstring, &inp);
if (num_backups == 0)
{
backups =
safe_malloc ((size_t) sizeof (long int) *
((lease_file_stats.st_size / 250) + MAXLEN));
}
backups[num_backups] = htonl (inp.s_addr);
num_backups++;
}
}
return 0;
/* I found out that there's one lease address per 300 bytes in
* dhcpd.leases file. Malloc is little bit pessimistic and uses
* 250. If someone has higher density in lease file I'm
* interested to hear about that. */
if (stat(config.dhcpdlease_file, &lease_file_stats)) {
eprintf("parse_leases: %s:", config.dhcpdlease_file);
exit(EXIT_FAILURE);
}
leases =
safe_malloc(sizeof(long int) *
((lease_file_stats.st_size / 250) + MAXLEN));
touches =
safe_malloc((size_t) sizeof(long int) *
((lease_file_stats.st_size / 250) + MAXLEN));
line = safe_malloc(sizeof(long int) * MAXLEN);
ipstring = safe_malloc(sizeof(long int) * MAXLEN);
while (!feof(dhcpd_leases)) {
fgets(line, MAXLEN, dhcpd_leases);
/* It's a lease */
if (strstr(line, "lease") == line) {
strncpy(ipstring, line, (size_t) MAXLEN - 1);
}
/* And this is lease state which we are interested about */
else if (strstr(line, "binding state active")) {
nth_field(2, ipstring, ipstring);
inet_aton(ipstring, &inp);
leases[num_leases] = htonl(inp.s_addr);
num_leases++;
} else if (strstr(line, " binding state free")) {
nth_field(2, ipstring, ipstring);
inet_aton(ipstring, &inp);
touches[num_touches] = htonl(inp.s_addr);
num_touches++;
} else if (strstr(line, " binding state backup")) {
nth_field(2, ipstring, ipstring);
inet_aton(ipstring, &inp);
if (num_backups == 0) {
backups =
safe_malloc((size_t) sizeof(long int) *
((lease_file_stats.st_size
/ 250) + MAXLEN));
}
backups[num_backups] = htonl(inp.s_addr);
num_backups++;
}
}
return 0;
}
/* Like strcpy but for field which is separated by white spaces.
@ -133,292 +123,260 @@ parse_leases (void)
* have. Question of semantics, send mail to author if this
* annoys. All performance boosts for this function are well
* come. */
int
nth_field (int n, char *dest, const char *src)
int nth_field(int n, char *dest, const char *src)
{
int i, j = 0, wordn = 0;
int i, j = 0, wordn = 0;
for (i = 0; i < MAXLEN; i++)
{
if (isspace (src[i]))
{
if (!(wordn < n))
{
dest[j] = '\0';
break;
}
j = 0;
for (i = 0; i < MAXLEN; i++) {
if (isspace(src[i])) {
if (!(wordn < n)) {
dest[j] = '\0';
break;
}
j = 0;
} else {
if (j == 0) {
wordn++;
}
if (wordn == n) {
dest[j] = src[i];
}
j++;
}
}
else
{
if (j == 0)
{
wordn++;
}
if (wordn == n)
{
dest[j] = src[i];
}
j++;
}
}
return 0;
return 0;
}
/* dhcpd.conf interesting words */
int
is_interesting_config_clause (char *s)
int is_interesting_config_clause(char *s)
{
if (strstr (s, "shared-network"))
{
return 1;
}
else if (strstr (s, "range"))
{
return 3;
}
else if (strstr (s, "include"))
{
return 4;
}
else
{
return 0;
}
if (strstr(s, "shared-network")) {
return 1;
} else if (strstr(s, "range")) {
return 3;
} else if (strstr(s, "include")) {
return 4;
} else {
return 0;
}
}
/* TODO: This spagetti monster function need to be rewrote at
* least ones. */
int
parse_config (char *config_file, char *current_shared_name,
char *next_free_shared_name, struct shared_network_t *shared_p)
char *parse_config(char *config_file, char *current_shared_name,
char *next_free_shared_name,
struct shared_network_t *shared_p)
{
FILE *dhcpd_config;
int i = 0, newclause = true, argument = false, comment = false, braces =
0, quote = false;
char word[MAXLEN], c;
int braces_shared = 1000;
struct in_addr inp;
struct range_t *range_p;
FILE *dhcpd_config;
int i = 0, newclause = true, argument = false, comment =
false, braces = 0, quote = false;
char word[MAXLEN], c;
int braces_shared = 1000;
struct in_addr inp;
struct range_t *range_p;
char *last_shared_name;
last_shared_name = SHARED_NETWORKS_NAMES + shared_net_names;
char *last_shared_name;
last_shared_name = SHARED_NETWORKS_NAMES + shared_net_names;
/* Default place holder for ranges "All networks".
* If this is include file basicly nothing happens. */
shared_p->name = current_shared_name;
/* Default place holder for ranges "All networks".
* If this is include file basicly nothing happens. */
shared_p->name = current_shared_name;
/* Open configuration file */
dhcpd_config = fopen (config_file, "r");
if (dhcpd_config == NULL)
{
eprintf ("parse_config: %s:", config_file);
exit (EXIT_FAILURE);
}
/* Open configuration file */
dhcpd_config = fopen(config_file, "r");
if (dhcpd_config == NULL) {
eprintf("parse_config: %s:", config_file);
exit(EXIT_FAILURE);
}
/* Very hairy stuff begins. */
while (!feof (dhcpd_config))
{
c = fgetc (dhcpd_config);
/* Certain characters are magical */
switch (c)
{
/* Handle comments if they are not quoted */
case '#':
if (quote == false)
{
comment = true;
}
continue;
case '"':
if (comment == false)
{
quote++;
/* Either one or zero */
quote = quote % 2;
}
continue;
case '\n':
/* New line resets comment section, but not if quoted */
if (quote == false)
{
comment = false;
}
break;
case ';':
/* Quoted colon does not mean new clause */
if (quote == true)
{
break;
}
if (comment == false && argument != 2 && argument != 4)
{
newclause = true;
i = 0;
}
else if (argument == 2)
{
/* Range ends to ; and this hair in code make two
* ranges wrote to gether like...
*
* range 10.20.30.40 10.20.30.41;range 10.20.30.42 10.20.30.43;
*
* ...to be interpreted correctly. */
c = ' ';
}
continue;
case '{':
if (quote == true)
{
break;
}
if (comment == false)
{
braces++;
}
/* i == 0 detects word that ends to brace like:
*
* shared-network DSL{ ... */
if (i == 0)
{
newclause = true;
}
continue;
case '}':
if (quote == true)
{
break;
}
if (comment == false)
{
braces--;
/* End of shared-network */
if (braces_shared == braces)
{
current_shared_name = shared_net_names;
/* TODO: Using 1000 is lame, but works. */
braces_shared = 1000;
shared_p = shared_networks;
/* Very hairy stuff begins. */
while (!feof(dhcpd_config)) {
c = fgetc(dhcpd_config);
/* Certain characters are magical */
switch (c) {
/* Handle comments if they are not quoted */
case '#':
if (quote == false) {
comment = true;
}
continue;
case '"':
if (comment == false) {
quote++;
/* Either one or zero */
quote = quote % 2;
}
continue;
case '\n':
/* New line resets comment section, but not if quoted */
if (quote == false) {
comment = false;
}
break;
case ';':
/* Quoted colon does not mean new clause */
if (quote == true) {
break;
}
if (comment == false && argument != 2
&& argument != 4) {
newclause = true;
i = 0;
} else if (argument == 2) {
/* Range ends to ; and this hair in code make two
* ranges wrote to gether like...
*
* range 10.20.30.40 10.20.30.41;range 10.20.30.42 10.20.30.43;
*
* ...to be interpreted correctly. */
c = ' ';
}
continue;
case '{':
if (quote == true) {
break;
}
if (comment == false) {
braces++;
}
/* i == 0 detects word that ends to brace like:
*
* shared-network DSL{ ... */
if (i == 0) {
newclause = true;
}
continue;
case '}':
if (quote == true) {
break;
}
if (comment == false) {
braces--;
/* End of shared-network */
if (braces_shared == braces) {
current_shared_name =
shared_net_names;
/* TODO: Using 1000 is lame, but works. */
braces_shared = 1000;
shared_p = shared_networks;
}
/* Not literally true, but works for this program */
newclause = true;
}
continue;
default:
break;
}
/* Not literally true, but works for this program */
newclause = true;
}
continue;
default:
break;
}
/* Either inside comment or Nth word of clause. */
if (comment == true || (newclause == false && argument == 0))
{
continue;
}
/* Strip white spaces before new clause word. */
if ((newclause == true || argument != 0) && isspace (c) && i == 0)
{
continue;
}
/* Save to word which clause this is. */
if ((newclause == true || argument != 0)
&& (!isspace (c) || quote == true))
{
word[i] = c;
i++;
/* Long word which is almost causing overflow. Not any of words
* this program is looking for are this long. */
if (i > MAXLEN)
{
newclause = false;
i = 0;
continue;
}
}
/* See if clause is something that parser is looking for. */
else if (newclause == true)
{
/* Insert string end & set state */
word[i] = '\0';
newclause = false;
i = 0;
/* Either inside comment or Nth word of clause. */
if (comment == true
|| (newclause == false && argument == 0)) {
continue;
}
/* Strip white spaces before new clause word. */
if ((newclause == true || argument != 0) && isspace(c)
&& i == 0) {
continue;
}
/* Save to word which clause this is. */
if ((newclause == true || argument != 0)
&& (!isspace(c) || quote == true)) {
word[i] = c;
i++;
/* Long word which is almost causing overflow. Not any of words
* this program is looking for are this long. */
if (i > MAXLEN) {
newclause = false;
i = 0;
continue;
}
}
/* See if clause is something that parser is looking for. */
else if (newclause == true) {
/* Insert string end & set state */
word[i] = '\0';
newclause = false;
i = 0;
argument = is_interesting_config_clause (word);
}
/* words after range, shared-network or include */
else if (argument != 0)
{
word[i] = '\0';
newclause = false;
i = 0;
argument = is_interesting_config_clause(word);
}
/* words after range, shared-network or include */
else if (argument != 0) {
word[i] = '\0';
newclause = false;
i = 0;
switch (argument)
{
case 0:
/* printf ("nothing interesting: %s\n", word); */
argument = 0;
break;
case 1:
/* printf ("shared-network named: %s\n", word); */
strcpy (next_free_shared_name, word);
shared_p = shared_networks + num_shared_networks;
num_shared_networks++;
shared_p++;
shared_p->name = next_free_shared_name;
shared_p->available = 0;
shared_p->used = 0;
shared_p->touched = 0;
shared_p->backups = 0;
/* Temporary abuse of argument variable */
argument = strlen (next_free_shared_name) + 1;
if (last_shared_name > next_free_shared_name + argument)
{
next_free_shared_name += argument;
switch (argument) {
case 0:
/* printf ("nothing interesting: %s\n", word); */
argument = 0;
break;
case 1:
/* printf ("shared-network named: %s\n", word); */
strcpy(next_free_shared_name, word);
shared_p =
shared_networks + num_shared_networks;
num_shared_networks++;
shared_p++;
shared_p->name = next_free_shared_name;
shared_p->available = 0;
shared_p->used = 0;
shared_p->touched = 0;
shared_p->backups = 0;
/* Temporary abuse of argument variable */
argument =
strlen(next_free_shared_name) + 1;
if (last_shared_name >
next_free_shared_name + argument) {
next_free_shared_name += argument;
} else {
/* TODO: make this go away by reallocationg more space. */
eprintf
("parse_config: End of shared-network space, increase SHARED_NETWORKS_NAMES and recompile");
exit(EXIT_FAILURE);
}
argument = 0;
break;
case 2:
/* printf ("range 2nd ip: %s\n", word); */
range_p = ranges + num_ranges;
inet_aton(word, &inp);
argument = 0;
range_p->last_ip = htonl(inp.s_addr) + 1;
range_p->count = 0;
range_p->touched = 0;
range_p->backups = 0;
range_p->shared_net = shared_p;
num_ranges++;
if (num_ranges > RANGES) {
eprintf
("parse_config: Range space full! Increase RANGES and recompile.");
exit(EXIT_FAILURE);
}
newclause = true;
break;
case 3:
/* printf ("range 1nd ip: %s\n", word); */
range_p = ranges + num_ranges;
inet_aton(word, &inp);
range_p->first_ip = htonl(inp.s_addr) - 1;
argument = 2;
break;
case 4:
/* printf ("include file: %s\n", word); */
argument = 0;
next_free_shared_name =
parse_config(word, current_shared_name,
next_free_shared_name,
shared_p);
newclause = true;
break;
default:
eprintf
("parse_config: This cannot happen, report a bug!");
exit(EXIT_FAILURE);
}
}
else
{
/* TODO: make this go away by reallocationg more space. */
eprintf
("parse_config: End of shared-network space, increase SHARED_NETWORKS_NAMES and recompile");
}
argument = 0;
break;
case 2:
/* printf ("range 2nd ip: %s\n", word); */
range_p = ranges + num_ranges;
inet_aton (word, &inp);
argument = 0;
range_p->last_ip = htonl (inp.s_addr) + 1;
range_p->count = 0;
range_p->touched = 0;
range_p->backups = 0;
range_p->shared_net = shared_p;
num_ranges++;
if (num_ranges > RANGES)
{
eprintf
("parse_config: Range space full! Increase RANGES and recompile.");
exit (EXIT_FAILURE);
}
newclause = true;
break;
case 3:
/* printf ("range 1nd ip: %s\n", word); */
range_p = ranges + num_ranges;
inet_aton (word, &inp);
range_p->first_ip = htonl (inp.s_addr) - 1;
argument = 2;
break;
case 4:
/* printf ("include file: %s\n", word); */
argument = 0;
parse_config (word, current_shared_name,
next_free_shared_name, shared_p);
newclause = true;
break;
default:
eprintf ("parse_config: This cannot happen, report a bug!");
exit (EXIT_FAILURE);
}
}
}
return 0;
return next_free_shared_name;
}

File diff suppressed because it is too large Load diff

View file

@ -62,15 +62,15 @@
#define NULL 0
#endif
int
getopt_long (argc, argv, options, long_options, opt_index)
int argc;
char *const *argv;
const char *options;
const struct option *long_options;
int *opt_index;
int getopt_long(argc, argv, options, long_options, opt_index)
int argc;
char *const *argv;
const char *options;
const struct option *long_options;
int *opt_index;
{
return _getopt_internal (argc, argv, options, long_options, opt_index, 0);
return _getopt_internal(argc, argv, options, long_options,
opt_index, 0);
}
/* Like getopt_long, but '-' as well as '--' can indicate a long option.
@ -78,109 +78,110 @@ getopt_long (argc, argv, options, long_options, opt_index)
but does match a short option, it is parsed as a short option
instead. */
int
getopt_long_only (argc, argv, options, long_options, opt_index)
int argc;
char *const *argv;
const char *options;
const struct option *long_options;
int *opt_index;
int getopt_long_only(argc, argv, options, long_options, opt_index)
int argc;
char *const *argv;
const char *options;
const struct option *long_options;
int *opt_index;
{
return _getopt_internal (argc, argv, options, long_options, opt_index, 1);
return _getopt_internal(argc, argv, options, long_options,
opt_index, 1);
}
#endif /* Not ELIDE_CODE. */
#endif /* Not ELIDE_CODE. */
#ifdef TEST
#include <stdio.h>
int
main (argc, argv)
int argc;
char **argv;
int main(argc, argv)
int argc;
char **argv;
{
int c;
int digit_optind = 0;
int c;
int digit_optind = 0;
while (1)
{
int this_option_optind = optind ? optind : 1;
int option_index = 0;
static struct option long_options[] = {
{"add", 1, 0, 0},
{"append", 0, 0, 0},
{"delete", 1, 0, 0},
{"verbose", 0, 0, 0},
{"create", 0, 0, 0},
{"file", 1, 0, 0},
{0, 0, 0, 0}
};
while (1) {
int this_option_optind = optind ? optind : 1;
int option_index = 0;
static struct option long_options[] = {
{"add", 1, 0, 0},
{"append", 0, 0, 0},
{"delete", 1, 0, 0},
{"verbose", 0, 0, 0},
{"create", 0, 0, 0},
{"file", 1, 0, 0},
{0, 0, 0, 0}
};
c = getopt_long (argc, argv, "abc:d:0123456789",
long_options, &option_index);
if (c == -1)
break;
c = getopt_long(argc, argv, "abc:d:0123456789",
long_options, &option_index);
if (c == -1)
break;
switch (c)
{
case 0:
printf ("option %s", long_options[option_index].name);
if (optarg)
printf (" with arg %s", optarg);
printf ("\n");
break;
switch (c) {
case 0:
printf("option %s",
long_options[option_index].name);
if (optarg)
printf(" with arg %s", optarg);
printf("\n");
break;
case '0':
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
if (digit_optind != 0 && digit_optind != this_option_optind)
printf ("digits occur in two different argv-elements.\n");
digit_optind = this_option_optind;
printf ("option %c\n", c);
break;
case '0':
case '1':
case '2':
case '3':
case '4':
case '5':
case '6':
case '7':
case '8':
case '9':
if (digit_optind != 0
&& digit_optind != this_option_optind)
printf
("digits occur in two different argv-elements.\n");
digit_optind = this_option_optind;
printf("option %c\n", c);
break;
case 'a':
printf ("option a\n");
break;
case 'a':
printf("option a\n");
break;
case 'b':
printf ("option b\n");
break;
case 'b':
printf("option b\n");
break;
case 'c':
printf ("option c with value `%s'\n", optarg);
break;
case 'c':
printf("option c with value `%s'\n", optarg);
break;
case 'd':
printf ("option d with value `%s'\n", optarg);
break;
case 'd':
printf("option d with value `%s'\n", optarg);
break;
case '?':
break;
case '?':
break;
default:
printf ("?? getopt returned character code 0%o ??\n", c);
default:
printf
("?? getopt returned character code 0%o ??\n",
c);
}
}
}
if (optind < argc)
{
printf ("non-option ARGV-elements: ");
while (optind < argc)
printf ("%s ", argv[optind++]);
printf ("\n");
}
if (optind < argc) {
printf("non-option ARGV-elements: ");
while (optind < argc)
printf("%s ", argv[optind++]);
printf("\n");
}
exit (0);
exit(0);
}
#endif /* TEST */
#endif /* TEST */

View file

@ -25,10 +25,10 @@
#include <stdio.h>
#ifdef HAVE_STDLIB_H
#include <stdlib.h>
#else /* Not STDC_HEADERS */
extern void exit ();
extern char *malloc ();
#endif /* STDC_HEADERS */
#else /* Not STDC_HEADERS */
extern void exit();
extern char *malloc();
#endif /* STDC_HEADERS */
#include <errno.h>
#include <stdarg.h>
#ifdef HAVE_STRING_H
@ -38,110 +38,100 @@ extern char *malloc ();
#endif
/* Simple memory allocation wrapper */
void *
safe_malloc (size_t size)
void *safe_malloc(size_t size)
{
void *ret = malloc (size);
if (ret == NULL)
{
eprintf ("safe_malloc: malloc: ");
exit (EXIT_FAILURE);
}
return ret;
void *ret = malloc(size);
if (ret == NULL) {
eprintf("safe_malloc: malloc: ");
exit(EXIT_FAILURE);
}
return ret;
}
/* Copyright (C) 1999 Lucent Technologies
* Excerpted from 'The Practice of Programming'
* by Brian W. Kernighan and Rob Pike
* slight modifications Sami Kerola
* slight modifications by Sami Kerola.
* eprintf: print error message and exit */
void
eprintf (char *fmt, ...)
void eprintf(char *fmt, ...)
{
va_list args;
va_list args;
fflush (stdout);
fprintf (stderr, "%s: ", program_name);
fflush(stdout);
fprintf(stderr, "%s: ", program_name);
va_start (args, fmt);
vfprintf (stderr, fmt, args);
va_end (args);
va_start(args, fmt);
vfprintf(stderr, fmt, args);
va_end(args);
if (fmt[0] != '\0' && fmt[strlen (fmt) - 1] == ':')
fprintf (stderr, " %s", strerror (errno));
fprintf (stderr, "\n");
if (fmt[0] != '\0' && fmt[strlen(fmt) - 1] == ':')
fprintf(stderr, " %s", strerror(errno));
fprintf(stderr, "\n");
}
void
flip_ranges (struct range_t *ranges, struct range_t *tmp_ranges)
void flip_ranges(struct range_t *ranges, struct range_t *tmp_ranges)
{
int i = num_ranges - 1, j;
int i = num_ranges - 1, j;
for (j = 0; j < num_ranges; j++)
{
*(tmp_ranges + j) = *(ranges + i);
i--;
}
for (j = 0; j < num_ranges; j++) {
*(tmp_ranges + j) = *(ranges + i);
i--;
}
memcpy (ranges, tmp_ranges, num_ranges * sizeof (struct range_t));
memcpy(ranges, tmp_ranges, num_ranges * sizeof(struct range_t));
}
/* Free memory, flush buffers etc*/
void
clean_up (void)
void clean_up(void)
{
int ret;
free (config.dhcpdconf_file);
free (config.dhcpdlease_file);
free (config.output_file);
free (ranges);
free (shared_net_names);
free (shared_networks);
/* Just in case there something in buffers */
ret = fclose (stdout);
if (errno || ret)
{
eprintf ("clean_up: stdout:");
exit (EXIT_FAILURE);
}
ret = fclose (stderr);
if (errno || ret)
{
eprintf ("clean_up: stderr:");
exit (EXIT_FAILURE);
}
int ret;
free(config.dhcpdconf_file);
free(config.dhcpdlease_file);
free(config.output_file);
free(ranges);
free(shared_net_names);
free(shared_networks);
/* Just in case there something in buffers */
ret = fclose(stdout);
if (errno || ret) {
eprintf("clean_up: stdout:");
exit(EXIT_FAILURE);
}
ret = fclose(stderr);
if (errno || ret) {
eprintf("clean_up: stderr:");
exit(EXIT_FAILURE);
}
}
void
print_version (void)
void print_version(void)
{
fprintf (stdout, "%s version 2.8\n", program_name);
fprintf (stdout,
"Program may be copied only under the terms of GNU General Public\n");
fprintf (stdout,
"License, which may be found in the dhcpd-pools source distribution.\n");
fprintf(stdout, "%s version 2.9\n", program_name);
fprintf(stdout,
"Program may be copied only under the terms of GNU General Public\n");
fprintf(stdout,
"License, which may be found in the dhcpd-pools source distribution.\n");
}
void
print_help (void)
void print_help(void)
{
fprintf (stdout, "Usage: %s [OPTIONS]\n", program_name);
fprintf (stdout, "\
fprintf(stdout, "Usage: %s [OPTIONS]\n", program_name);
fprintf(stdout, "\
This is ISC dhcpd pools usage analyzer.\n\
\n");
fprintf (stdout, "\
fprintf(stdout, "\
-c --config file path to the dhcpd.conf file\n\
-l --leases file path to the dhcpd.leases file\n\
-f --format [thc] output format\n");
fprintf (stdout, "\
fprintf(stdout, "\
t is text\n\
h is html table\n\
c is comma separated values\n");
/* To be done...
/* TODO
s is snmp\n");
*/
fprintf (stdout, "\
fprintf(stdout, "\
-s --sort [nimcptTe] sort ranges by\n\
n name\n\
i IP\n\
@ -151,12 +141,14 @@ This is ISC dhcpd pools usage analyzer.\n\
t touched\n\
T t+c\n\
e t+c perc\n");
fprintf (stdout, "\
fprintf(stdout, "\
-r --reverse reverse order sort\n\
-o --output file output into a file\n\
-L --limit nr output limit mask 77 - 00\n\
-v --version version information\n\
-h --help this screen\n\
\n\
Report bugs to kerolasa@iki.fi.\n");
For bug repots and feature requests please use \n\
SourceForge tracker.\n\
http://sourceforge.net/tracker/?group_id=161420\n");
}

View file

@ -27,530 +27,480 @@
#include "dhcpd-pools.h"
int
output_txt (void)
int output_txt(void)
{
unsigned int i;
struct in_addr first, last;
struct range_t *range_p;
struct shared_network_t *shared_p;
int ret;
FILE *outfile;
unsigned int i;
struct in_addr first, last;
struct range_t *range_p;
struct shared_network_t *shared_p;
int ret;
FILE *outfile;
if (config.output_file[0])
{
outfile = fopen (config.output_file, "w+");
if (outfile == NULL)
{
eprintf ("output_txt: %s:", config.output_file);
exit (EXIT_FAILURE);
if (config.output_file[0]) {
outfile = fopen(config.output_file, "w+");
if (outfile == NULL) {
eprintf("output_txt: %s:", config.output_file);
exit(EXIT_FAILURE);
}
} else {
outfile = stdout;
}
}
else
{
outfile = stdout;
}
range_p = ranges;
shared_p = shared_networks;
range_p = ranges;
shared_p = shared_networks;
if (config.output_limit[0] & output_limit_bit_1)
{
fprintf (outfile, "Ranges:\n");
fprintf
(outfile,
"shared net name first ip last ip max cur percent touch t+c t+c perc");
if (num_backups > 0)
{
fprintf (outfile, " bu bu perc");
if (config.output_limit[0] & output_limit_bit_1) {
fprintf(outfile, "Ranges:\n");
fprintf
(outfile,
"shared net name first ip last ip max cur percent touch t+c t+c perc");
if (num_backups > 0) {
fprintf(outfile, " bu bu perc");
}
fprintf(outfile, "\n");
}
fprintf (outfile, "\n");
}
if (config.output_limit[1] & output_limit_bit_1)
{
for (i = 0; i < num_ranges; i++)
{
first.s_addr = ntohl (range_p->first_ip + 1);
last.s_addr = ntohl (range_p->last_ip - 1);
if (config.output_limit[1] & output_limit_bit_1) {
for (i = 0; i < num_ranges; i++) {
first.s_addr = ntohl(range_p->first_ip + 1);
last.s_addr = ntohl(range_p->last_ip - 1);
if (range_p->shared_net)
{
fprintf (outfile, "%-20s", range_p->shared_net->name);
}
else
{
fprintf (outfile, "not_defined ");
}
fprintf (outfile, "%-16s", inet_ntoa (first));
fprintf (outfile, " - %-16s %5lu %5lu %10.3f %5lu %5lu %9.3f",
inet_ntoa (last),
range_p->last_ip - range_p->first_ip - 1,
range_p->count,
(float) (100 * range_p->count) / (range_p->last_ip -
range_p->first_ip - 1),
range_p->touched,
range_p->touched + range_p->count,
(float) (100 * (range_p->touched + range_p->count)) /
(range_p->last_ip - range_p->first_ip - 1));
if (num_backups > 0)
{
fprintf (outfile, "%7lu %8.3f", range_p->backups,
(float) (100 * range_p->backups) / (range_p->last_ip -
range_p->first_ip -
1));
}
fprintf (outfile, "\n");
range_p++;
if (range_p->shared_net) {
fprintf(outfile, "%-20s",
range_p->shared_net->name);
} else {
fprintf(outfile, "not_defined ");
}
fprintf(outfile, "%-16s", inet_ntoa(first));
fprintf(outfile,
" - %-16s %5lu %5lu %10.3f %5lu %5lu %9.3f",
inet_ntoa(last),
range_p->last_ip - range_p->first_ip - 1,
range_p->count,
(float) (100 * range_p->count) /
(range_p->last_ip - range_p->first_ip - 1),
range_p->touched,
range_p->touched + range_p->count,
(float) (100 *
(range_p->touched +
range_p->count)) /
(range_p->last_ip - range_p->first_ip -
1));
if (num_backups > 0) {
fprintf(outfile, "%7lu %8.3f",
range_p->backups,
(float) (100 * range_p->backups) /
(range_p->last_ip -
range_p->first_ip - 1));
}
fprintf(outfile, "\n");
range_p++;
}
}
}
if (config.output_limit[1] & output_limit_bit_1
&& config.output_limit[0] & output_limit_bit_2)
{
fprintf (outfile, "\n");
}
if (config.output_limit[0] & output_limit_bit_2)
{
fprintf (outfile, "Shared networks:\n");
fprintf (outfile,
"name max cur percent touch t+c t+c perc");
if (num_backups > 0)
{
fprintf (outfile, " bu bu perc");
if (config.output_limit[1] & output_limit_bit_1
&& config.output_limit[0] & output_limit_bit_2) {
fprintf(outfile, "\n");
}
fprintf (outfile, "\n");
}
if (config.output_limit[1] & output_limit_bit_2)
{
for (i = 0; i < num_shared_networks; i++)
{
shared_p++;
fprintf (outfile, "%-20s %5lu %5lu %10.3f %7lu %6lu %9.3f",
shared_p->name,
shared_p->available,
shared_p->used,
(float) (100 * shared_p->used) / shared_p->available,
shared_p->touched,
shared_p->touched + shared_p->used,
(float) (100 * (shared_p->touched + shared_p->used)) /
shared_p->available);
if (num_backups > 0)
{
fprintf (outfile, "%7lu %8.3f", shared_p->backups,
(float) (100 * shared_p->backups) /
shared_p->available);
}
if (config.output_limit[0] & output_limit_bit_2) {
fprintf(outfile, "Shared networks:\n");
fprintf(outfile,
"name max cur percent touch t+c t+c perc");
if (num_backups > 0) {
fprintf(outfile, " bu bu perc");
}
fprintf(outfile, "\n");
}
if (config.output_limit[1] & output_limit_bit_2) {
for (i = 0; i < num_shared_networks; i++) {
shared_p++;
fprintf(outfile,
"%-20s %5lu %5lu %10.3f %7lu %6lu %9.3f",
shared_p->name, shared_p->available,
shared_p->used,
(float) (100 * shared_p->used) /
shared_p->available, shared_p->touched,
shared_p->touched + shared_p->used,
(float) (100 *
(shared_p->touched +
shared_p->used)) /
shared_p->available);
if (num_backups > 0) {
fprintf(outfile, "%7lu %8.3f",
shared_p->backups,
(float) (100 * shared_p->backups) /
shared_p->available);
}
fprintf (outfile, "\n");
fprintf(outfile, "\n");
}
}
}
if (config.output_limit[1] & output_limit_bit_2
&& config.output_limit[0] & output_limit_bit_3)
{
fprintf (outfile, "\n");
}
if (config.output_limit[0] & output_limit_bit_3)
{
fprintf (outfile, "Sum of all ranges:\n");
fprintf (outfile,
"name max cur percent touch t+c t+c perc");
if (config.output_limit[1] & output_limit_bit_2
&& config.output_limit[0] & output_limit_bit_3) {
fprintf(outfile, "\n");
}
if (config.output_limit[0] & output_limit_bit_3) {
fprintf(outfile, "Sum of all ranges:\n");
fprintf(outfile,
"name max cur percent touch t+c t+c perc");
if (num_backups > 0)
{
fprintf (outfile, " bu bu perc");
if (num_backups > 0) {
fprintf(outfile, " bu bu perc");
}
fprintf(outfile, "\n");
}
fprintf (outfile, "\n");
}
if (config.output_limit[1] & output_limit_bit_3)
{
fprintf (outfile, "%-20s %5lu %5lu %10.3f %7lu %6lu %9.3f",
shared_networks->name,
shared_networks->available,
shared_networks->used,
(float) (100 * shared_networks->used) /
shared_networks->available,
shared_networks->touched,
shared_networks->touched + shared_networks->used,
(float) (100 *
(shared_networks->touched +
shared_networks->used)) /
shared_networks->available);
if (config.output_limit[1] & output_limit_bit_3) {
fprintf(outfile, "%-20s %5lu %5lu %10.3f %7lu %6lu %9.3f",
shared_networks->name,
shared_networks->available,
shared_networks->used,
(float) (100 * shared_networks->used) /
shared_networks->available,
shared_networks->touched,
shared_networks->touched + shared_networks->used,
(float) (100 *
(shared_networks->touched +
shared_networks->used)) /
shared_networks->available);
if (num_backups > 0)
{
fprintf (outfile, "%7lu %8.3f", shared_networks->backups,
(float) (100 * shared_networks->backups) /
shared_networks->available);
if (num_backups > 0) {
fprintf(outfile, "%7lu %8.3f",
shared_networks->backups,
(float) (100 * shared_networks->backups) /
shared_networks->available);
}
fprintf(outfile, "\n");
}
fprintf (outfile, "\n");
}
if (outfile == stdout)
{
ret = fflush (stdout);
if (ret)
{
eprintf ("output_txt: fflush:");
if (outfile == stdout) {
ret = fflush(stdout);
if (ret) {
eprintf("output_txt: fflush:");
}
} else {
ret = fclose(outfile);
if (ret) {
eprintf("output_txt: fclose:");
}
}
}
else
{
ret = fclose (outfile);
if (ret)
{
eprintf ("output_txt: fclose:");
}
}
return 0;
return 0;
}
int
output_html (void)
int output_html(void)
{
unsigned int i;
struct in_addr first, last;
struct range_t *range_p;
struct shared_network_t *shared_p;
int ret;
FILE *outfile;
unsigned int i;
struct in_addr first, last;
struct range_t *range_p;
struct shared_network_t *shared_p;
int ret;
FILE *outfile;
if (config.output_file[0])
{
outfile = fopen (config.output_file, "w+");
if (outfile == NULL)
{
eprintf ("output_html: %s:", config.output_file);
exit (EXIT_FAILURE);
}
}
else
{
outfile = stdout;
}
range_p = ranges;
shared_p = shared_networks;
fprintf (outfile,
"<table width=\"75%\" class=\"dhcpd-pools\" summary=\"ISC dhcpd pool usage raport\">\n");
if (config.output_limit[0] & output_limit_bit_1)
{
fprintf (outfile, "<tr><th>Ranges:</th></tr>\n");
fprintf
(outfile,
"<tr><th>shared net name</th><th>first ip</th><th>last ip</th><th align=\"right\">max</th><th align=\"right\">cur</th><th align=\"right\">percent</th><th align=\"right\">touch</th><th align=\"right\">t+c</th><th align=\"right\">t+c perc</th>");
if (num_backups > 0)
{
fprintf (outfile,
"<th align=\"right\">bu</th><th align=\"right\">bu perc</th>");
if (config.output_file[0]) {
outfile = fopen(config.output_file, "w+");
if (outfile == NULL) {
eprintf("output_html: %s:", config.output_file);
exit(EXIT_FAILURE);
}
} else {
outfile = stdout;
}
fprintf (outfile, "</tr>\n");
}
if (config.output_limit[1] & output_limit_bit_1)
{
for (i = 0; i < num_ranges; i++)
{
first.s_addr = ntohl (range_p->first_ip + 1);
last.s_addr = ntohl (range_p->last_ip - 1);
range_p = ranges;
shared_p = shared_networks;
if (range_p->shared_net)
{
fprintf (outfile, "<tr><td>%s</td>", range_p->shared_net->name);
}
else
{
fprintf (outfile, "<tr><td>not_defined</td>");
}
fprintf (outfile, "<td>%s</td>", inet_ntoa (first));
fprintf (outfile,
"<td>%s</td><td align=\"right\">%lu</td><td align=\"right\">%lu</td><td align=\"right\">%.3f</td><td align=\"right\">%lu</td><td align=\"right\">%lu</td><td align=\"right\">%.3f</td>",
inet_ntoa (last), range_p->last_ip - range_p->first_ip - 1,
range_p->count,
(float) (100 * range_p->count) / (range_p->last_ip -
range_p->first_ip - 1),
range_p->touched,
range_p->touched + range_p->count,
(float) (100 * (range_p->touched + range_p->count)) /
(range_p->last_ip - range_p->first_ip - 1));
if (num_backups > 0)
{
fprintf (outfile,
"<td align=\"right\">%lu</td><td align=\"right\">%.3f</td>",
range_p->backups,
(float) (100 * range_p->backups) / (range_p->last_ip -
range_p->first_ip -
1));
}
fprintf(outfile,
"<table width=\"75%\" class=\"dhcpd-pools\" summary=\"ISC dhcpd pool usage raport\">\n");
if (config.output_limit[0] & output_limit_bit_1) {
fprintf(outfile, "<tr><th>Ranges:</th></tr>\n");
fprintf
(outfile,
"<tr><th>shared net name</th><th>first ip</th><th>last ip</th><th align=\"right\">max</th><th align=\"right\">cur</th><th align=\"right\">percent</th><th align=\"right\">touch</th><th align=\"right\">t+c</th><th align=\"right\">t+c perc</th>");
if (num_backups > 0) {
fprintf(outfile,
"<th align=\"right\">bu</th><th align=\"right\">bu perc</th>");
}
fprintf (outfile, "</tr>\n");
range_p++;
}
}
if (config.output_limit[0] & output_limit_bit_2)
{
fprintf (outfile, "\n<tr><th>Shared networks:</th></tr>\n");
fprintf (outfile,
"<tr><th>name</td><th align=\"right\">max</th><th align=\"right\">cur</th><th align=\"right\">percent</th><th align=\"right\">touch</th><th align=\"right\">t+c</th><th align=\"right\">t+c perc</th>");
if (num_backups > 0)
{
fprintf (outfile,
"<th align=\"right\">bu</th><th align=\"right\">bu perc</th>");
fprintf(outfile, "</tr>\n");
}
if (config.output_limit[1] & output_limit_bit_1) {
for (i = 0; i < num_ranges; i++) {
first.s_addr = ntohl(range_p->first_ip + 1);
last.s_addr = ntohl(range_p->last_ip - 1);
fprintf (outfile, "</tr>\n");
}
if (config.output_limit[1] & output_limit_bit_2)
{
for (i = 0; i < num_shared_networks; i++)
{
shared_p++;
fprintf (outfile,
"<tr><td>%s</td><td align=\"right\">%lu</td><td align=\"right\">%lu</td><td align=\"right\">%.3f</td><td align=\"right\">%lu</td><td align=\"right\">%lu</td><td align=\"right\">%.3f</td>",
shared_p->name, shared_p->available, shared_p->used,
(float) (100 * shared_p->used) / shared_p->available,
shared_p->touched,
shared_p->touched + shared_p->used,
(float) (100 * (shared_p->touched + shared_p->used)) /
shared_p->available);
if (num_backups > 0)
{
fprintf (outfile,
"<td align=\"right\">%lu</td><td align=\"right\">%.3f</td>",
shared_p->backups,
(float) (100 * shared_p->backups) /
shared_p->available);
}
if (range_p->shared_net) {
fprintf(outfile, "<tr><td>%s</td>",
range_p->shared_net->name);
} else {
fprintf(outfile,
"<tr><td>not_defined</td>");
}
fprintf(outfile, "<td>%s</td>", inet_ntoa(first));
fprintf(outfile,
"<td>%s</td><td align=\"right\">%lu</td><td align=\"right\">%lu</td><td align=\"right\">%.3f</td><td align=\"right\">%lu</td><td align=\"right\">%lu</td><td align=\"right\">%.3f</td>",
inet_ntoa(last),
range_p->last_ip - range_p->first_ip - 1,
range_p->count,
(float) (100 * range_p->count) /
(range_p->last_ip - range_p->first_ip - 1),
range_p->touched,
range_p->touched + range_p->count,
(float) (100 *
(range_p->touched +
range_p->count)) /
(range_p->last_ip - range_p->first_ip -
1));
if (num_backups > 0) {
fprintf(outfile,
"<td align=\"right\">%lu</td><td align=\"right\">%.3f</td>",
range_p->backups,
(float) (100 * range_p->backups) /
(range_p->last_ip -
range_p->first_ip - 1));
}
fprintf (outfile, "</tr>\n");
}
}
if (config.output_limit[0] & output_limit_bit_3)
{
fprintf (outfile, "\n<tr><th>Sum of all ranges:</th></tr>\n");
fprintf (outfile,
"<tr><th>name</th><th align=\"right\">max</th><th align=\"right\">cur</th><th align=\"right\">percent</th><th align=\"right\">touch</th><th align=\"right\">t+c</th><th align=\"right\">t+c perc</th>");
if (num_backups > 0)
{
fprintf (outfile,
"<th align=\"right\">bu</th><th align=\"right\">bu perc</th>");
fprintf(outfile, "</tr>\n");
range_p++;
}
}
if (config.output_limit[0] & output_limit_bit_2) {
fprintf(outfile, "\n<tr><th>Shared networks:</th></tr>\n");
fprintf(outfile,
"<tr><th>name</td><th align=\"right\">max</th><th align=\"right\">cur</th><th align=\"right\">percent</th><th align=\"right\">touch</th><th align=\"right\">t+c</th><th align=\"right\">t+c perc</th>");
if (num_backups > 0) {
fprintf(outfile,
"<th align=\"right\">bu</th><th align=\"right\">bu perc</th>");
}
fprintf (outfile, "</tr>\n");
}
if (config.output_limit[1] & output_limit_bit_3)
{
fprintf (outfile,
"<tr><td>%s</td><td align=\"right\">%lu</td><td align=\"right\">%lu</td><td align=\"right\">%.3f</td><td align=\"right\">%lu</td><td align=\"right\">%lu</td><td align=\"right\">%.3f</td>",
shared_networks->name, shared_networks->available,
shared_networks->used,
(float) (100 * shared_networks->used) /
shared_networks->available,
shared_networks->touched,
shared_networks->touched + shared_networks->used,
(float) (100 *
(shared_networks->touched +
shared_networks->used)) /
shared_networks->available);
if (num_backups > 0)
{
fprintf (outfile,
"<td align=\"right\">%lu</td><td align=\"right\">%.3f</td>",
shared_networks->backups,
(float) (100 * shared_networks->backups) /
shared_networks->available);
}
fprintf (outfile, "\n");
fprintf (outfile, "</tr>\n");
}
fprintf (outfile, "</table>\n");
if (outfile == stdout)
{
ret = fflush (stdout);
if (ret)
{
eprintf ("output_html: fflush:");
}
}
else
{
ret = fclose (outfile);
if (ret)
{
eprintf ("output_html: fclose:");
fprintf(outfile, "</tr>\n");
}
if (config.output_limit[1] & output_limit_bit_2) {
for (i = 0; i < num_shared_networks; i++) {
shared_p++;
fprintf(outfile,
"<tr><td>%s</td><td align=\"right\">%lu</td><td align=\"right\">%lu</td><td align=\"right\">%.3f</td><td align=\"right\">%lu</td><td align=\"right\">%lu</td><td align=\"right\">%.3f</td>",
shared_p->name, shared_p->available,
shared_p->used,
(float) (100 * shared_p->used) /
shared_p->available, shared_p->touched,
shared_p->touched + shared_p->used,
(float) (100 *
(shared_p->touched +
shared_p->used)) /
shared_p->available);
if (num_backups > 0) {
fprintf(outfile,
"<td align=\"right\">%lu</td><td align=\"right\">%.3f</td>",
shared_p->backups,
(float) (100 * shared_p->backups) /
shared_p->available);
}
}
return 0;
fprintf(outfile, "</tr>\n");
}
}
if (config.output_limit[0] & output_limit_bit_3) {
fprintf(outfile,
"\n<tr><th>Sum of all ranges:</th></tr>\n");
fprintf(outfile,
"<tr><th>name</th><th align=\"right\">max</th><th align=\"right\">cur</th><th align=\"right\">percent</th><th align=\"right\">touch</th><th align=\"right\">t+c</th><th align=\"right\">t+c perc</th>");
if (num_backups > 0) {
fprintf(outfile,
"<th align=\"right\">bu</th><th align=\"right\">bu perc</th>");
}
fprintf(outfile, "</tr>\n");
}
if (config.output_limit[1] & output_limit_bit_3) {
fprintf(outfile,
"<tr><td>%s</td><td align=\"right\">%lu</td><td align=\"right\">%lu</td><td align=\"right\">%.3f</td><td align=\"right\">%lu</td><td align=\"right\">%lu</td><td align=\"right\">%.3f</td>",
shared_networks->name, shared_networks->available,
shared_networks->used,
(float) (100 * shared_networks->used) /
shared_networks->available,
shared_networks->touched,
shared_networks->touched + shared_networks->used,
(float) (100 *
(shared_networks->touched +
shared_networks->used)) /
shared_networks->available);
if (num_backups > 0) {
fprintf(outfile,
"<td align=\"right\">%lu</td><td align=\"right\">%.3f</td>",
shared_networks->backups,
(float) (100 * shared_networks->backups) /
shared_networks->available);
}
fprintf(outfile, "\n");
fprintf(outfile, "</tr>\n");
}
fprintf(outfile, "</table>\n");
if (outfile == stdout) {
ret = fflush(stdout);
if (ret) {
eprintf("output_html: fflush:");
}
} else {
ret = fclose(outfile);
if (ret) {
eprintf("output_html: fclose:");
}
}
return 0;
}
int
output_csv (void)
int output_csv(void)
{
unsigned int i;
struct in_addr first, last;
struct range_t *range_p;
struct shared_network_t *shared_p;
FILE *outfile;
int ret;
unsigned int i;
struct in_addr first, last;
struct range_t *range_p;
struct shared_network_t *shared_p;
FILE *outfile;
int ret;
if (config.output_file[0])
{
outfile = fopen (config.output_file, "w+");
if (outfile == NULL)
{
eprintf ("output_csv: %s:", config.output_file);
exit (EXIT_FAILURE);
}
}
else
{
outfile = stdout;
}
range_p = ranges;
shared_p = shared_networks;
if (config.output_limit[0] & output_limit_bit_1)
{
fprintf (outfile, "\"Ranges:\"\n");
fprintf
(outfile,
"\"shared net name\",\"first ip\",\"last ip\",\"max\",\"cur\",\"percent\",\"touch\",\"t+c\",\"t+c perc\"");
if (num_backups > 0)
{
fprintf (outfile, ",\"bu\",\"bu perc\"");
}
fprintf (outfile, "\n");
}
if (config.output_limit[1] & output_limit_bit_1)
{
for (i = 0; i < num_ranges; i++)
{
first.s_addr = ntohl (range_p->first_ip + 1);
last.s_addr = ntohl (range_p->last_ip - 1);
if (range_p->shared_net)
{
fprintf (outfile, "\"%s\",", range_p->shared_net->name);
}
else
{
fprintf (outfile, "\"not_defined\",");
}
fprintf (outfile, "\"%s\",", inet_ntoa (first));
fprintf (outfile,
"\"%s\",\"%lu\",\"%lu\",\"%.3f\",\"%lu\",\"%lu\",\"%.3f\"",
inet_ntoa (last), range_p->last_ip - range_p->first_ip - 1,
range_p->count,
(float) (100 * range_p->count) / (range_p->last_ip -
range_p->first_ip - 1),
range_p->touched, range_p->touched + range_p->count,
(float) (100 * (range_p->touched + range_p->count)) /
(range_p->last_ip - range_p->first_ip - 1));
if (num_backups > 0)
{
fprintf (outfile, ",\"%lu\",\"%.3f\"", range_p->backups,
(float) (100 * range_p->backups) / (range_p->last_ip -
range_p->first_ip -
1));
}
fprintf (outfile, "\n");
range_p++;
}
fprintf (outfile, "\n");
}
if (config.output_limit[0] & output_limit_bit_2)
{
fprintf (outfile, "\"Shared networks:\"\n");
fprintf (outfile,
"\"name\",\"max\",\"cur\",\"percent\",\"touch\",\"t+c\",\"t+c perc\"");
if (num_backups > 0)
{
fprintf (outfile, ",\"bu\",\"bu perc\"");
}
fprintf (outfile, "\n");
}
if (config.output_limit[1] & output_limit_bit_2)
{
for (i = 0; i < num_shared_networks; i++)
{
shared_p++;
fprintf (outfile,
"\"%s\",\"%lu\",\"%lu\",\"%.3f\",\"%lu\",\"%lu\",\"%.3f\"",
shared_p->name, shared_p->available, shared_p->used,
(float) (100 * shared_p->used) / shared_p->available,
shared_p->touched,
shared_p->touched + shared_p->used,
(float) (100 * (shared_p->touched + shared_p->used)) /
shared_p->available);
if (num_backups > 0)
{
fprintf (outfile, ",\"%lu\",\"%.3f\"", shared_p->backups,
(float) (100 * shared_p->backups) /
shared_p->available);
}
fprintf (outfile, "\n");
}
fprintf (outfile, "\n");
}
if (config.output_limit[0] & output_limit_bit_3)
{
fprintf (outfile, "\"Sum of all ranges:\"\n");
fprintf (outfile,
"\"name\",\"max\",\"cur\",\"percent\",\"touch\",\"t+c\",\"t+c perc\"");
if (num_backups > 0)
{
fprintf (outfile, ",\"bu\",\"bu perc\"");
}
fprintf (outfile, "\n");
}
if (config.output_limit[1] & output_limit_bit_3)
{
fprintf (outfile,
"\"%s\",\"%lu\",\"%lu\",\"%.3f\",\"%lu\",\"%lu\",\"%.3f\"",
shared_networks->name, shared_networks->available,
shared_networks->used,
(float) (100 * shared_networks->used) /
shared_networks->available, shared_networks->touched,
shared_networks->touched + shared_networks->used,
(float) (100 *
(shared_networks->touched +
shared_networks->used)) /
shared_networks->available);
if (num_backups > 0)
{
fprintf (outfile, "%7lu %8.3f", shared_networks->backups,
(float) (100 * shared_networks->backups) /
shared_networks->available);
}
fprintf (outfile, "\n");
}
if (outfile == stdout)
{
ret = fflush (stdout);
if (ret)
{
eprintf ("output_cvs: fflush:");
if (config.output_file[0]) {
outfile = fopen(config.output_file, "w+");
if (outfile == NULL) {
eprintf("output_csv: %s:", config.output_file);
exit(EXIT_FAILURE);
}
} else {
outfile = stdout;
}
}
else
{
ret = fclose (outfile);
if (ret)
{
eprintf ("output_cvs: fclose:");
}
range_p = ranges;
shared_p = shared_networks;
}
return 0;
if (config.output_limit[0] & output_limit_bit_1) {
fprintf(outfile, "\"Ranges:\"\n");
fprintf
(outfile,
"\"shared net name\",\"first ip\",\"last ip\",\"max\",\"cur\",\"percent\",\"touch\",\"t+c\",\"t+c perc\"");
if (num_backups > 0) {
fprintf(outfile, ",\"bu\",\"bu perc\"");
}
fprintf(outfile, "\n");
}
if (config.output_limit[1] & output_limit_bit_1) {
for (i = 0; i < num_ranges; i++) {
first.s_addr = ntohl(range_p->first_ip + 1);
last.s_addr = ntohl(range_p->last_ip - 1);
if (range_p->shared_net) {
fprintf(outfile, "\"%s\",",
range_p->shared_net->name);
} else {
fprintf(outfile, "\"not_defined\",");
}
fprintf(outfile, "\"%s\",", inet_ntoa(first));
fprintf(outfile,
"\"%s\",\"%lu\",\"%lu\",\"%.3f\",\"%lu\",\"%lu\",\"%.3f\"",
inet_ntoa(last),
range_p->last_ip - range_p->first_ip - 1,
range_p->count,
(float) (100 * range_p->count) /
(range_p->last_ip - range_p->first_ip - 1),
range_p->touched,
range_p->touched + range_p->count,
(float) (100 *
(range_p->touched +
range_p->count)) /
(range_p->last_ip - range_p->first_ip -
1));
if (num_backups > 0) {
fprintf(outfile, ",\"%lu\",\"%.3f\"",
range_p->backups,
(float) (100 * range_p->backups) /
(range_p->last_ip -
range_p->first_ip - 1));
}
fprintf(outfile, "\n");
range_p++;
}
fprintf(outfile, "\n");
}
if (config.output_limit[0] & output_limit_bit_2) {
fprintf(outfile, "\"Shared networks:\"\n");
fprintf(outfile,
"\"name\",\"max\",\"cur\",\"percent\",\"touch\",\"t+c\",\"t+c perc\"");
if (num_backups > 0) {
fprintf(outfile, ",\"bu\",\"bu perc\"");
}
fprintf(outfile, "\n");
}
if (config.output_limit[1] & output_limit_bit_2) {
for (i = 0; i < num_shared_networks; i++) {
shared_p++;
fprintf(outfile,
"\"%s\",\"%lu\",\"%lu\",\"%.3f\",\"%lu\",\"%lu\",\"%.3f\"",
shared_p->name, shared_p->available,
shared_p->used,
(float) (100 * shared_p->used) /
shared_p->available, shared_p->touched,
shared_p->touched + shared_p->used,
(float) (100 *
(shared_p->touched +
shared_p->used)) /
shared_p->available);
if (num_backups > 0) {
fprintf(outfile, ",\"%lu\",\"%.3f\"",
shared_p->backups,
(float) (100 * shared_p->backups) /
shared_p->available);
}
fprintf(outfile, "\n");
}
fprintf(outfile, "\n");
}
if (config.output_limit[0] & output_limit_bit_3) {
fprintf(outfile, "\"Sum of all ranges:\"\n");
fprintf(outfile,
"\"name\",\"max\",\"cur\",\"percent\",\"touch\",\"t+c\",\"t+c perc\"");
if (num_backups > 0) {
fprintf(outfile, ",\"bu\",\"bu perc\"");
}
fprintf(outfile, "\n");
}
if (config.output_limit[1] & output_limit_bit_3) {
fprintf(outfile,
"\"%s\",\"%lu\",\"%lu\",\"%.3f\",\"%lu\",\"%lu\",\"%.3f\"",
shared_networks->name, shared_networks->available,
shared_networks->used,
(float) (100 * shared_networks->used) /
shared_networks->available,
shared_networks->touched,
shared_networks->touched + shared_networks->used,
(float) (100 *
(shared_networks->touched +
shared_networks->used)) /
shared_networks->available);
if (num_backups > 0) {
fprintf(outfile, "%7lu %8.3f",
shared_networks->backups,
(float) (100 * shared_networks->backups) /
shared_networks->available);
}
fprintf(outfile, "\n");
}
if (outfile == stdout) {
ret = fflush(stdout);
if (ret) {
eprintf("output_cvs: fflush:");
}
} else {
ret = fclose(outfile);
if (ret) {
eprintf("output_cvs: fclose:");
}
}
return 0;
}

View file

@ -28,217 +28,188 @@
#include "defaults.h"
/* Sort functions for range sorting */
int
intcomp (const void *x, const void *y)
int intcomp(const void *x, const void *y)
{
if (*(unsigned long int *) x < *(unsigned long int *) y)
return -1;
else if (*(unsigned long int *) y < *(unsigned long int *) x)
return 1;
else
return 0;
if (*(unsigned long int *) x < *(unsigned long int *) y)
return -1;
else if (*(unsigned long int *) y < *(unsigned long int *) x)
return 1;
else
return 0;
}
int
rangecomp (const void *r1, const void *r2)
int rangecomp(const void *r1, const void *r2)
{
if ((((struct range_t *) r1)->first_ip) <
(((struct range_t *) r2)->first_ip))
return -1;
else if ((((struct range_t *) r2)->first_ip) <
(((struct range_t *) r1)->first_ip))
return 1;
else
return 0;
if ((((struct range_t *) r1)->first_ip) <
(((struct range_t *) r2)->first_ip))
return -1;
else if ((((struct range_t *) r2)->first_ip) <
(((struct range_t *) r1)->first_ip))
return 1;
else
return 0;
}
unsigned long int
ret_ip (struct range_t r)
unsigned long int ret_ip(struct range_t r)
{
return (r.first_ip);
return (r.first_ip);
}
unsigned long int
ret_cur (struct range_t r)
unsigned long int ret_cur(struct range_t r)
{
return (r.count);
return (r.count);
}
unsigned long int
ret_max (struct range_t r)
unsigned long int ret_max(struct range_t r)
{
return (r.last_ip - r.first_ip);
return (r.last_ip - r.first_ip);
}
unsigned long int
ret_percent (struct range_t r)
unsigned long int ret_percent(struct range_t r)
{
float f;
f = (float) r.count / (r.last_ip - r.first_ip - 1);
return ((unsigned long int) (f * 100000));
float f;
f = (float) r.count / (r.last_ip - r.first_ip - 1);
return ((unsigned long int) (f * 100000));
}
unsigned long int
ret_touched (struct range_t r)
unsigned long int ret_touched(struct range_t r)
{
return (r.touched);
return (r.touched);
}
unsigned long int
ret_tc (struct range_t r)
unsigned long int ret_tc(struct range_t r)
{
return (r.count + r.touched);
return (r.count + r.touched);
}
unsigned long int
ret_tcperc (struct range_t r)
unsigned long int ret_tcperc(struct range_t r)
{
float f;
f = (float) (r.count + r.touched) / (r.last_ip - r.first_ip - 1);
return ((unsigned long int) (f * 10000));
float f;
f = (float) (r.count + r.touched) / (r.last_ip - r.first_ip - 1);
return ((unsigned long int) (f * 10000));
}
void
field_selector (char c)
void field_selector(char c)
{
switch (c)
{
case 'n':
break;
case 'i':
returner = ret_ip;
break;
case 'm':
returner = ret_max;
break;
case 'c':
returner = ret_cur;
break;
case 'p':
returner = ret_percent;
break;
case 't':
returner = ret_touched;
break;
case 'T':
returner = ret_tc;
break;
case 'e':
returner = ret_tcperc;
break;
default:
eprintf ("field_selector: unknown sort order: %c", config.sort[0]);
print_help;
exit (EXIT_FAILURE);
}
switch (c) {
case 'n':
break;
case 'i':
returner = ret_ip;
break;
case 'm':
returner = ret_max;
break;
case 'c':
returner = ret_cur;
break;
case 'p':
returner = ret_percent;
break;
case 't':
returner = ret_touched;
break;
case 'T':
returner = ret_tc;
break;
case 'e':
returner = ret_tcperc;
break;
default:
eprintf("field_selector: unknown sort order: %c",
config.sort[0]);
print_help;
exit(EXIT_FAILURE);
}
}
/* Needed to support multiple key sorting. */
int
get_order (struct range_t *left, struct range_t *right)
int get_order(struct range_t *left, struct range_t *right)
{
int i, len, ret;
unsigned long int lint, rint;
int i, len, ret;
unsigned long int lint, rint;
len = strlen (config.sort);
for (i = 0; i < len; i++)
{
/* Handling strings is case of it's own */
if (config.sort[i] == 'n')
{
ret = strcmp (left->shared_net->name, right->shared_net->name);
if (ret > 0)
{
return (0);
}
else if (ret < 0)
{
return (1);
}
else
{
continue;
}
}
/* Select which function is pointed by returner */
field_selector (config.sort[i]);
lint = returner (*left);
rint = returner (*right);
/* If fields are equal use next sort method */
if (lint == rint)
{
continue;
}
if (lint < rint)
{
return (1);
}
return (0);
}
/* If all returners where equal */
return (0);
}
void
mergesort_ranges (struct range_t *orig, int size, struct range_t *temp)
{
int left, right, i;
long int val;
struct range_t hold;
if (size < MIN_MERGE_SIZE)
{
for (left = 0; left < size; left++)
{
hold = *(orig + left);
for (right = left - 1; right >= 0; right--)
{
if (get_order ((orig + right), &hold))
{
break;
len = strlen(config.sort);
for (i = 0; i < len; i++) {
/* Handling strings is case of it's own */
if (config.sort[i] == 'n') {
ret =
strcmp(left->shared_net->name,
right->shared_net->name);
if (ret > 0) {
return (0);
} else if (ret < 0) {
return (1);
} else {
continue;
}
}
*(orig + right + 1) = *(orig + right);
}
*(orig + right + 1) = hold;
/* Select which function is pointed by returner */
field_selector(config.sort[i]);
lint = returner(*left);
rint = returner(*right);
/* If fields are equal use next sort method */
if (lint == rint) {
continue;
}
if (lint < rint) {
return (1);
}
return (0);
}
return;
}
mergesort_ranges (orig, size / 2, temp);
mergesort_ranges (orig + size / 2, size - size / 2, temp);
left = 0;
right = size / 2;
i = 0;
while (left < size / 2 && right < size)
{
if (get_order ((orig + left), (orig + right)))
{
*(temp + i) = *(orig + left);
left++;
}
else
{
*(temp + i) = *(orig + right);
right++;
}
i++;
}
while (left < size / 2)
{
*(temp + i) = *(orig + left);
left++;
i++;
}
while (right < size)
{
*(temp + i) = *(orig + right);
right++;
i++;
}
memcpy (orig, temp, size * sizeof (struct range_t));
/* If all returners where equal */
return (0);
}
void mergesort_ranges(struct range_t *orig, int size, struct range_t *temp)
{
int left, right, i;
long int val;
struct range_t hold;
if (size < MIN_MERGE_SIZE) {
for (left = 0; left < size; left++) {
hold = *(orig + left);
for (right = left - 1; right >= 0; right--) {
if (get_order((orig + right), &hold)) {
break;
}
*(orig + right + 1) = *(orig + right);
}
*(orig + right + 1) = hold;
}
return;
}
mergesort_ranges(orig, size / 2, temp);
mergesort_ranges(orig + size / 2, size - size / 2, temp);
left = 0;
right = size / 2;
i = 0;
while (left < size / 2 && right < size) {
if (get_order((orig + left), (orig + right))) {
*(temp + i) = *(orig + left);
left++;
} else {
*(temp + i) = *(orig + right);
right++;
}
i++;
}
while (left < size / 2) {
*(temp + i) = *(orig + left);
left++;
i++;
}
while (right < size) {
*(temp + i) = *(orig + right);
right++;
i++;
}
memcpy(orig, temp, size * sizeof(struct range_t));
}