summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOndřej Surý <ondrej@sury.org>2013-07-29 17:14:20 +0200
committerOndřej Surý <ondrej@sury.org>2013-07-29 17:14:20 +0200
commitadbc92de0cd2832e84dc5d684c31d5a25bf13b5d (patch)
treedf03690388d4c9acb870a9ce02e9592c827e378f
parent93f582ba0ad3d1f69b796b70660ccfd1530303f1 (diff)
downloadknot-upstream/1.3.0_rc5.tar.gz
New upstream version 1.3.0~rc5upstream/1.3.0_rc5
-rw-r--r--INSTALL8
-rw-r--r--Makefile.in153
-rw-r--r--NEWS11
-rw-r--r--aclocal.m4511
-rwxr-xr-xar-lib2
-rwxr-xr-xcompile10
-rwxr-xr-xconfig.guess1021
-rwxr-xr-xconfig.sub482
-rwxr-xr-xconfigure380
-rw-r--r--configure.ac28
-rwxr-xr-xdepcomp89
-rw-r--r--doc/Makefile.in71
-rw-r--r--doc/configuration.texi5
-rw-r--r--doc/knot.info320
-rwxr-xr-xdoc/mdate-sh15
-rw-r--r--doc/reference.texi2
-rw-r--r--doc/running.texi2
-rw-r--r--doc/stamp-vti6
-rw-r--r--doc/texinfo.tex361
-rw-r--r--doc/version.texi6
-rwxr-xr-xinstall-sh14
-rw-r--r--ltmain.sh97
-rw-r--r--m4/ax_recvmmsg.m496
-rw-r--r--m4/libtool.m455
-rw-r--r--man/Makefile.in29
-rw-r--r--man/kdig.12
-rw-r--r--man/khost.12
-rw-r--r--man/knot.conf.512
-rw-r--r--man/knot.conf.5.in10
-rw-r--r--man/knotc.85
-rw-r--r--man/knotc.8.in3
-rw-r--r--man/knotd.82
-rw-r--r--man/knsupdate.12
-rwxr-xr-xmissing99
-rw-r--r--samples/Makefile.in25
-rw-r--r--samples/knot.full.conf6
-rw-r--r--samples/knot.sample.conf.in2
-rw-r--r--src/Makefile.in370
-rw-r--r--src/common/acl.c137
-rw-r--r--src/common/descriptor.c49
-rw-r--r--src/common/descriptor.h33
-rw-r--r--src/common/errcode.c2
-rw-r--r--src/common/errcode.h2
-rw-r--r--src/config.h.in6
-rw-r--r--src/knot/conf/conf.c4
-rw-r--r--src/knot/conf/conf.h2
-rw-r--r--src/knot/conf/libknotd_la-cf-lex.c244
-rw-r--r--src/knot/conf/libknotd_la-cf-parse.c809
-rw-r--r--src/knot/conf/libknotd_la-cf-parse.h39
-rw-r--r--src/knot/ctl/knotc_main.c14
-rw-r--r--src/knot/server/dthreads.c3
-rw-r--r--src/knot/server/server.c5
-rw-r--r--src/knot/server/tcp-handler.c72
-rw-r--r--src/knot/server/udp-handler.c12
-rw-r--r--src/knot/server/xfr-handler.c27
-rw-r--r--src/knot/zone/semantic-check.c54
-rw-r--r--src/knot/zone/semantic-check.h1
-rw-r--r--src/knot/zone/zone-load.c4
-rw-r--r--src/libknot/nameserver/name-server.c2
-rw-r--r--src/libknot/rrset.c49
-rw-r--r--src/libknot/rrset.h8
-rw-r--r--src/libknot/updates/ddns.c83
-rw-r--r--src/libknot/updates/xfr-in.c140
-rw-r--r--src/libknot/zone/zone-contents.c48
-rw-r--r--src/libknot/zone/zone-contents.h20
-rw-r--r--src/tests/Makefile.in93
-rw-r--r--src/tests/common/acl_tests.c2
-rw-r--r--src/tests/common/descriptor_tests.c37
-rw-r--r--src/tests/common/events_tests.c8
-rw-r--r--src/tests/common/fdset_tests.c5
-rw-r--r--src/tests/knot/dthreads_tests.c4
-rw-r--r--src/zscanner/scanner_functions.c1
-rw-r--r--src/zscanner/test/cases/06-0_INCLUDE.in4
-rw-r--r--src/zscanner/test/cases/06-3_INCLUDE.in2
-rw-r--r--src/zscanner/test/cases/06-4_INCLUDE.in2
-rw-r--r--src/zscanner/test/run_tests.sh4
-rwxr-xr-xylwrap176
77 files changed, 3111 insertions, 3410 deletions
diff --git a/INSTALL b/INSTALL
index a1e89e1..6e90e07 100644
--- a/INSTALL
+++ b/INSTALL
@@ -1,7 +1,7 @@
Installation Instructions
*************************
-Copyright (C) 1994-1996, 1999-2002, 2004-2011 Free Software Foundation,
+Copyright (C) 1994-1996, 1999-2002, 2004-2012 Free Software Foundation,
Inc.
Copying and distribution of this file, with or without modification,
@@ -309,9 +309,10 @@ causes the specified `gcc' to be used as the C compiler (unless it is
overridden in the site shell script).
Unfortunately, this technique does not work for `CONFIG_SHELL' due to
-an Autoconf bug. Until the bug is fixed you can use this workaround:
+an Autoconf limitation. Until the limitation is lifted, you can use
+this workaround:
- CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
+ CONFIG_SHELL=/bin/bash ./configure CONFIG_SHELL=/bin/bash
`configure' Invocation
======================
@@ -367,4 +368,3 @@ operates.
`configure' also accepts some other, not widely useful, options. Run
`configure --help' for more details.
-
diff --git a/Makefile.in b/Makefile.in
index 22bbfc2..aafeaf0 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1,9 +1,8 @@
-# Makefile.in generated by automake 1.11.6 from Makefile.am.
+# Makefile.in generated by automake 1.12.6 from Makefile.am.
# @configure_input@
-# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
-# Foundation, Inc.
+# Copyright (C) 1994-2012 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.
@@ -64,10 +63,10 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_compile_flag.m4 \
$(top_srcdir)/m4/ax_ext.m4 \
$(top_srcdir)/m4/ax_gcc_x86_cpuid.m4 \
- $(top_srcdir)/m4/ax_recvmmsg.m4 $(top_srcdir)/m4/libtool.m4 \
- $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
- $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
- $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
+ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
+ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/visibility.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
@@ -79,12 +78,18 @@ CONFIG_CLEAN_FILES = src/zscanner/test/run_tests.sh \
src/zscanner/test/cases/06-4_INCLUDE.in \
src/zscanner/test/cases/06-0_INCLUDE.in
CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
AM_V_GEN = $(am__v_GEN_@AM_V@)
am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
-am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
AM_V_at = $(am__v_at_@AM_V@)
am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
+am__v_at_1 =
SOURCES =
DIST_SOURCES =
RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
@@ -103,9 +108,10 @@ RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
distclean-recursive maintainer-clean-recursive
AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
- distdir dist dist-all distcheck
+ cscope distdir dist dist-all distcheck
ETAGS = etags
CTAGS = ctags
+CSCOPE = cscope
DIST_SUBDIRS = $(SUBDIRS)
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
distdir = $(PACKAGE)-$(VERSION)
@@ -116,6 +122,7 @@ am__remove_distdir = \
&& rm -rf "$(distdir)" \
|| { sleep 5 && rm -rf "$(distdir)"; }; \
else :; fi
+am__post_remove_distdir = $(am__remove_distdir)
am__relativize = \
dir0=`pwd`; \
sed_first='s,^\([^/]*\)/.*$$,\1,'; \
@@ -143,6 +150,7 @@ am__relativize = \
reldir="$$dir2"
DIST_ARCHIVES = $(distdir).tar.gz $(distdir).tar.bz2 $(distdir).tar.xz
GZIP_ENV = --best
+DIST_TARGETS = dist-xz dist-bzip2 dist-gzip
distuninstallcheck_listfiles = find . -type f -print
am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \
| sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$'
@@ -341,12 +349,12 @@ distclean-libtool:
-rm -f libtool config.lt
# This directory's subdirectories are mostly independent; you can cd
-# into them and run `make' without going through this Makefile.
-# To change the values of `make' variables: instead of editing Makefiles,
-# (1) if the variable is set in `config.status', edit `config.status'
-# (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):
+# into them and run 'make' without going through this Makefile.
+# To change the values of 'make' variables: instead of editing Makefiles,
+# (1) if the variable is set in 'config.status', edit 'config.status'
+# (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) $(RECURSIVE_CLEAN_TARGETS):
@fail= failcom='exit 1'; \
for f in x $$MAKEFLAGS; do \
case $$f in \
@@ -356,7 +364,11 @@ $(RECURSIVE_TARGETS):
done; \
dot_seen=no; \
target=`echo $@ | sed s/-recursive//`; \
- list='$(SUBDIRS)'; for subdir in $$list; do \
+ case "$@" in \
+ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
+ *) list='$(SUBDIRS)' ;; \
+ esac; \
+ for subdir in $$list; do \
echo "Making $$target in $$subdir"; \
if test "$$subdir" = "."; then \
dot_seen=yes; \
@@ -370,37 +382,6 @@ $(RECURSIVE_TARGETS):
if test "$$dot_seen" = "no"; then \
$(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
fi; test -z "$$fail"
-
-$(RECURSIVE_CLEAN_TARGETS):
- @fail= 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)' ;; \
- *) list='$(SUBDIRS)' ;; \
- esac; \
- rev=''; for subdir in $$list; do \
- if test "$$subdir" = "."; then :; else \
- rev="$$subdir $$rev"; \
- fi; \
- done; \
- rev="$$rev ."; \
- target=`echo $@ | sed s/-recursive//`; \
- for subdir in $$rev; do \
- echo "Making $$target in $$subdir"; \
- if test "$$subdir" = "."; then \
- local_target="$$target-am"; \
- else \
- local_target="$$target"; \
- fi; \
- ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
- || eval $$failcom; \
- done && test -z "$$fail"
tags-recursive:
list='$(SUBDIRS)'; for subdir in $$list; do \
test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
@@ -409,6 +390,10 @@ ctags-recursive:
list='$(SUBDIRS)'; for subdir in $$list; do \
test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
done
+cscopelist-recursive:
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) cscopelist); \
+ done
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
@@ -472,8 +457,32 @@ GTAGS:
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
+cscope: cscope.files
+ test ! -s cscope.files \
+ || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS)
+
+clean-cscope:
+ -rm -f cscope.files
+
+cscope.files: clean-cscope cscopelist-recursive cscopelist
+
+cscopelist: cscopelist-recursive $(HEADERS) $(SOURCES) $(LISP)
+ list='$(SOURCES) $(HEADERS) $(LISP)'; \
+ case "$(srcdir)" in \
+ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
+ *) sdir=$(subdir)/$(srcdir) ;; \
+ esac; \
+ for i in $$list; do \
+ if test -f "$$i"; then \
+ echo "$(subdir)/$$i"; \
+ else \
+ echo "$$sdir/$$i"; \
+ fi; \
+ done >> $(top_builddir)/cscope.files
+
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+ -rm -f cscope.out cscope.in.out cscope.po.out cscope.files
distdir: $(DISTFILES)
@case `sed 15q $(srcdir)/NEWS` in \
@@ -547,40 +556,34 @@ distdir: $(DISTFILES)
|| chmod -R a+r "$(distdir)"
dist-gzip: distdir
tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
- $(am__remove_distdir)
+ $(am__post_remove_distdir)
dist-bzip2: distdir
tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2
- $(am__remove_distdir)
+ $(am__post_remove_distdir)
dist-lzip: distdir
tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz
- $(am__remove_distdir)
-
-dist-lzma: distdir
- tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma
- $(am__remove_distdir)
+ $(am__post_remove_distdir)
dist-xz: distdir
tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz
- $(am__remove_distdir)
+ $(am__post_remove_distdir)
dist-tarZ: distdir
tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
- $(am__remove_distdir)
+ $(am__post_remove_distdir)
dist-shar: distdir
shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
- $(am__remove_distdir)
+ $(am__post_remove_distdir)
dist-zip: distdir
-rm -f $(distdir).zip
zip -rq $(distdir).zip $(distdir)
- $(am__remove_distdir)
+ $(am__post_remove_distdir)
-dist dist-all: distdir
- tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
- tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2
- tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz
- $(am__remove_distdir)
+dist dist-all:
+ $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:'
+ $(am__post_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
@@ -591,8 +594,6 @@ distcheck: dist
GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\
*.tar.bz2*) \
bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\
- *.tar.lzma*) \
- lzma -dc $(distdir).tar.lzma | $(am__untar) ;;\
*.tar.lz*) \
lzip -dc $(distdir).tar.lz | $(am__untar) ;;\
*.tar.xz*) \
@@ -604,9 +605,9 @@ distcheck: dist
*.zip*) \
unzip $(distdir).zip ;;\
esac
- chmod -R a-w $(distdir); chmod u+w $(distdir)
- mkdir $(distdir)/_build
- mkdir $(distdir)/_inst
+ chmod -R a-w $(distdir)
+ chmod u+w $(distdir)
+ mkdir $(distdir)/_build $(distdir)/_inst
chmod a-w $(distdir)
test -d $(distdir)/_build || exit 0; \
dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \
@@ -638,7 +639,7 @@ distcheck: dist
&& $(MAKE) $(AM_MAKEFLAGS) distcleancheck \
&& cd "$$am__cwd" \
|| exit 1
- $(am__remove_distdir)
+ $(am__post_remove_distdir)
@(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'
@@ -773,13 +774,15 @@ ps-am:
uninstall-am:
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \
- install-am install-strip tags-recursive
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) \
+ cscopelist-recursive ctags-recursive install-am install-strip \
+ tags-recursive
.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
- all all-am am--refresh check check-am clean clean-generic \
- clean-libtool ctags ctags-recursive dist dist-all dist-bzip2 \
- dist-gzip dist-lzip dist-lzma dist-shar dist-tarZ dist-xz \
+ all all-am am--refresh check check-am clean clean-cscope \
+ clean-generic clean-libtool cscope cscopelist \
+ cscopelist-recursive ctags ctags-recursive dist dist-all \
+ dist-bzip2 dist-gzip dist-lzip dist-shar dist-tarZ dist-xz \
dist-zip distcheck distclean distclean-generic \
distclean-libtool distclean-tags distcleancheck distdir \
distuninstallcheck dvi dvi-am html html-am info info-am \
diff --git a/NEWS b/NEWS
index 1497951..225de37 100644
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,16 @@
Knot DNS NEWS
+v1.3.0-rc5 - Jul 29, 2013
+-------------------------
+Features:
+ * Much faster bootstrap of many zones
+Bugfixes:
+ * Removed deprecated 'knotc -w' option
+ * Slave ignores out-of-zone records in zone
+ * Support for obsolete types in zone transfers
+ * Slave zone file names fixes
+ * Long transfers being randomly dropped
+
v1.3.0-rc4 - Jul 15, 2013
-------------------------
Features:
diff --git a/aclocal.m4 b/aclocal.m4
index 4dcf33a..8f1356f 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -1,8 +1,7 @@
-# generated automatically by aclocal 1.11.6 -*- Autoconf -*-
+# generated automatically by aclocal 1.12.6 -*- Autoconf -*-
+
+# Copyright (C) 1996-2012 Free Software Foundation, Inc.
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation,
-# Inc.
# This file 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.
@@ -18,7 +17,7 @@ m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
[m4_warning([this file was generated for autoconf 2.69.
You have another version of autoconf. It may work, but is not guaranteed to.
If you have problems, you may need to regenerate the build system entirely.
-To do so, use the procedure documented by the package, typically `autoreconf'.])])
+To do so, use the procedure documented by the package, typically 'autoreconf'.])])
# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
# serial 1 (pkg-config-0.24)
@@ -180,25 +179,150 @@ else
fi[]dnl
])# PKG_CHECK_MODULES
-# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008, 2011 Free Software
-# Foundation, Inc.
+# PKG_INSTALLDIR(DIRECTORY)
+# -------------------------
+# Substitutes the variable pkgconfigdir as the location where a module
+# should install pkg-config .pc files. By default the directory is
+# $libdir/pkgconfig, but the default can be changed by passing
+# DIRECTORY. The user can override through the --with-pkgconfigdir
+# parameter.
+AC_DEFUN([PKG_INSTALLDIR],
+[m4_pushdef([pkg_default], [m4_default([$1], ['${libdir}/pkgconfig'])])
+m4_pushdef([pkg_description],
+ [pkg-config installation directory @<:@]pkg_default[@:>@])
+AC_ARG_WITH([pkgconfigdir],
+ [AS_HELP_STRING([--with-pkgconfigdir], pkg_description)],,
+ [with_pkgconfigdir=]pkg_default)
+AC_SUBST([pkgconfigdir], [$with_pkgconfigdir])
+m4_popdef([pkg_default])
+m4_popdef([pkg_description])
+]) dnl PKG_INSTALLDIR
+
+
+# PKG_NOARCH_INSTALLDIR(DIRECTORY)
+# -------------------------
+# Substitutes the variable noarch_pkgconfigdir as the location where a
+# module should install arch-independent pkg-config .pc files. By
+# default the directory is $datadir/pkgconfig, but the default can be
+# changed by passing DIRECTORY. The user can override through the
+# --with-noarch-pkgconfigdir parameter.
+AC_DEFUN([PKG_NOARCH_INSTALLDIR],
+[m4_pushdef([pkg_default], [m4_default([$1], ['${datadir}/pkgconfig'])])
+m4_pushdef([pkg_description],
+ [pkg-config arch-independent installation directory @<:@]pkg_default[@:>@])
+AC_ARG_WITH([noarch-pkgconfigdir],
+ [AS_HELP_STRING([--with-noarch-pkgconfigdir], pkg_description)],,
+ [with_noarch_pkgconfigdir=]pkg_default)
+AC_SUBST([noarch_pkgconfigdir], [$with_noarch_pkgconfigdir])
+m4_popdef([pkg_default])
+m4_popdef([pkg_description])
+]) dnl PKG_NOARCH_INSTALLDIR
+
+
+# PKG_CHECK_VAR(VARIABLE, MODULE, CONFIG-VARIABLE,
+# [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
+# -------------------------------------------
+# Retrieves the value of the pkg-config variable for the given module.
+AC_DEFUN([PKG_CHECK_VAR],
+[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
+AC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])dnl
+
+_PKG_CONFIG([$1], [variable="][$3]["], [$2])
+AS_VAR_COPY([$1], [pkg_cv_][$1])
+
+AS_VAR_IF([$1], [""], [$5], [$4])dnl
+])# PKG_CHECK_VAR
+
+# PKG_WITH_MODULES(VARIABLE-PREFIX, MODULES,
+# [ACTION-IF-FOUND],[ACTION-IF-NOT-FOUND],
+# [DESCRIPTION], [DEFAULT])
+#
+# Prepare a "--with-" configure option using the lowercase [VARIABLE-PREFIX]
+# name, merging the behaviour of AC_ARG_WITH and PKG_CHECK_MODULES in a single
+# macro
+#
+# --------------------------------------------------------------
+AC_DEFUN([PKG_WITH_MODULES],
+[
+m4_pushdef([with_arg], m4_tolower([$1]))
+
+m4_pushdef([description],
+ [m4_default([$5], [build with ]with_arg[ support])])
+
+m4_pushdef([def_arg], [m4_default([$6], [auto])])
+m4_pushdef([def_action_if_found], [AS_TR_SH([with_]with_arg)=yes])
+m4_pushdef([def_action_if_not_found], [AS_TR_SH([with_]with_arg)=no])
+
+m4_case(def_arg,
+ [yes],[m4_pushdef([with_without], [--without-]with_arg)],
+ [m4_pushdef([with_without],[--with-]with_arg)])
+
+AC_ARG_WITH(with_arg,
+ AS_HELP_STRING(with_without, description[ @<:@default=]def_arg[@:>@]),,
+ [AS_TR_SH([with_]with_arg)=def_arg])
+
+AS_CASE([$AS_TR_SH([with_]with_arg)],
+ [yes],[PKG_CHECK_MODULES([$1],[$2],$3,$4)],
+ [auto],[PKG_CHECK_MODULES([$1],[$2],
+ [m4_n([def_action_if_found]) $3],
+ [m4_n([def_action_if_not_found]) $4])])
+
+m4_popdef([with_arg])
+m4_popdef([description])
+m4_popdef([def_arg])
+
+]) dnl PKG_WITH_MODULES
+
+# PKG_HAVE_WITH_MODULES(VARIABLE-PREFIX, MODULES,
+# [DESCRIPTION], [DEFAULT])
+#
+# Convenience macro to trigger AM_CONDITIONAL after
+# PKG_WITH_MODULES check.
+#
+# HAVE_[VARIABLE-PREFIX] is exported as make variable.
+#
+# --------------------------------------------------------------
+AC_DEFUN([PKG_HAVE_WITH_MODULES],
+[
+PKG_WITH_MODULES([$1],[$2],,,[$3],[$4])
+
+AM_CONDITIONAL([HAVE_][$1],
+ [test "$AS_TR_SH([with_]m4_tolower([$1]))" = "yes"])
+])
+
+# PKG_HAVE_DEFINE_WITH_MODULES(VARIABLE-PREFIX, MODULES,
+# [DESCRIPTION], [DEFAULT])
+#
+# Convenience macro to run AM_CONDITIONAL and AC_DEFINE after
+# PKG_WITH_MODULES check.
+#
+# HAVE_[VARIABLE-PREFIX] is exported as make and preprocessor variable.
+#
+# --------------------------------------------------------------
+AC_DEFUN([PKG_HAVE_DEFINE_WITH_MODULES],
+[
+PKG_HAVE_WITH_MODULES([$1],[$2],[$3],[$4])
+
+AS_IF([test "$AS_TR_SH([with_]m4_tolower([$1]))" = "yes"],
+ [AC_DEFINE([HAVE_][$1], 1, [Enable ]m4_tolower([$1])[ support])])
+])
+
+# Copyright (C) 2002-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 1
-
# AM_AUTOMAKE_VERSION(VERSION)
# ----------------------------
# Automake X.Y traces this macro to ensure aclocal.m4 has been
# generated from the m4 files accompanying Automake X.Y.
# (This private macro should not be called outside this file.)
AC_DEFUN([AM_AUTOMAKE_VERSION],
-[am__api_version='1.11'
+[am__api_version='1.12'
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.11.6], [],
+m4_if([$1], [1.12.6], [],
[AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
])
@@ -214,19 +338,17 @@ m4_define([_AM_AUTOCONF_VERSION], [])
# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
-[AM_AUTOMAKE_VERSION([1.11.6])dnl
+[AM_AUTOMAKE_VERSION([1.12.6])dnl
m4_ifndef([AC_AUTOCONF_VERSION],
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
-# Copyright (C) 2011 Free Software Foundation, Inc.
+# Copyright (C) 2011-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 1
-
# AM_PROG_AR([ACT-IF-FAIL])
# -------------------------
# Try to determine the archiver interface, and trigger the ar-lib wrapper
@@ -282,17 +404,15 @@ AC_SUBST([AR])dnl
# AM_AUX_DIR_EXPAND -*- Autoconf -*-
-# Copyright (C) 2001, 2003, 2005, 2011 Free Software Foundation, Inc.
+# Copyright (C) 2001-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 1
-
# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
-# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
-# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
+# $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to
+# '$srcdir', '$srcdir/..', or '$srcdir/../..'.
#
# Of course, Automake must honor this variable whenever it calls a
# tool from the auxiliary directory. The problem is that $srcdir (and
@@ -311,7 +431,7 @@ AC_SUBST([AR])dnl
#
# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
# are both prefixed by $srcdir. In an in-source build this is usually
-# harmless because $srcdir is `.', but things will broke when you
+# harmless because $srcdir is '.', but things will broke when you
# start a VPATH build or use an absolute $srcdir.
#
# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
@@ -337,22 +457,19 @@ am_aux_dir=`cd $ac_aux_dir && pwd`
# AM_CONDITIONAL -*- Autoconf -*-
-# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008
-# Free Software Foundation, Inc.
+# Copyright (C) 1997-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 9
-
# AM_CONDITIONAL(NAME, SHELL-CONDITION)
# -------------------------------------
# Define a conditional.
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_PREREQ([2.52])dnl
+ m4_if([$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
@@ -371,16 +488,14 @@ AC_CONFIG_COMMANDS_PRE(
Usually this means the macro was only invoked conditionally.]])
fi])])
-# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009,
-# 2010, 2011 Free Software Foundation, Inc.
+# Copyright (C) 1999-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 12
-# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
+# There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be
# written in clear, in which case automake, when reading aclocal.m4,
# will think it sees a *use*, and therefore will trigger all it's
# C support machinery. Also note that it means that autoscan, seeing
@@ -390,7 +505,7 @@ fi])])
# _AM_DEPENDENCIES(NAME)
# ----------------------
# See how the compiler implements dependency checking.
-# NAME is "CC", "CXX", "GCJ", or "OBJC".
+# NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC".
# We try a few techniques and use that to set a single cache variable.
#
# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
@@ -403,12 +518,13 @@ 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=])
+m4_if([$1], [CC], [depcc="$CC" am_compiler_list=],
+ [$1], [CXX], [depcc="$CXX" am_compiler_list=],
+ [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
+ [$1], [OBJCXX], [depcc="$OBJCXX" 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],
@@ -416,8 +532,8 @@ AC_CACHE_CHECK([dependency style of $depcc],
# 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'.
+ # making a dummy file named 'D' -- because '-MD' means "put the output
+ # in D".
rm -rf conftest.dir
mkdir conftest.dir
# Copy depcomp to subdir because otherwise we won't find it if we're
@@ -457,16 +573,16 @@ AC_CACHE_CHECK([dependency style of $depcc],
: > 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
+ # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
+ # Solaris 10 /bin/sh.
+ echo '/* dummy */' > sub/conftst$i.h
done
echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
- # We check with `-c' and `-o' for the sake of the "dashmstdout"
+ # 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. Also, some Intel
- # versions had trouble with output in subdirs
+ # handle '-M -o', and we need to detect this. Also, some Intel
+ # versions had trouble with output in subdirs.
am__obj=sub/conftest.${OBJEXT-o}
am__minus_obj="-o $am__obj"
case $depmode in
@@ -475,8 +591,8 @@ AC_CACHE_CHECK([dependency style of $depcc],
test "$am__universal" = false || continue
;;
nosideeffect)
- # after this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested
+ # 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
@@ -484,7 +600,7 @@ AC_CACHE_CHECK([dependency style of $depcc],
fi
;;
msvc7 | msvc7msys | msvisualcpp | msvcmsys)
- # This compiler won't grok `-c -o', but also, the minuso test has
+ # This compiler won't grok '-c -o', but also, the minuso test has
# not run yet. These depmodes are late enough in the game, and
# so weak that their functioning should not be impacted.
am__obj=conftest.${OBJEXT-o}
@@ -532,7 +648,7 @@ AM_CONDITIONAL([am__fastdep$1], [
# AM_SET_DEPDIR
# -------------
# Choose a directory name for dependency files.
-# This macro is AC_REQUIREd in _AM_DEPENDENCIES
+# This macro is AC_REQUIREd in _AM_DEPENDENCIES.
AC_DEFUN([AM_SET_DEPDIR],
[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
@@ -542,9 +658,13 @@ AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
# AM_DEP_TRACK
# ------------
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])
+[AC_ARG_ENABLE([dependency-tracking], [dnl
+AS_HELP_STRING(
+ [--enable-dependency-tracking],
+ [do not reject slow dependency extractors])
+AS_HELP_STRING(
+ [--disable-dependency-tracking],
+ [speeds up one-time build])])
if test "x$enable_dependency_tracking" != xno; then
am_depcomp="$ac_aux_dir/depcomp"
AMDEPBACKSLASH='\'
@@ -559,14 +679,12 @@ _AM_SUBST_NOTMAKE([am__nodep])dnl
# Generate code to set up dependency tracking. -*- Autoconf -*-
-# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008
-# Free Software Foundation, Inc.
+# Copyright (C) 1999-2012 Free Software Foundation, Inc.
#
# This file 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.
-#serial 5
# _AM_OUTPUT_DEPENDENCY_COMMANDS
# ------------------------------
@@ -585,7 +703,7 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
# 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
+ # 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.
@@ -597,21 +715,19 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
continue
fi
# Extract the definition of DEPDIR, am__include, and am__quote
- # from the Makefile without running `make'.
+ # 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
+ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
# Make sure the directory exists.
test -f "$dirpart/$file" && continue
fdir=`AS_DIRNAME(["$file"])`
@@ -629,7 +745,7 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
# This macro should only be invoked once -- use via AC_REQUIRE.
#
# This code is only required when automatic dependency tracking
-# is enabled. FIXME. This creates each `.P' file that we will
+# is enabled. FIXME. This creates each '.P' file that we will
# need in order to bootstrap the dependency handling code.
AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
[AC_CONFIG_COMMANDS([depfiles],
@@ -639,15 +755,12 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
# Do all the work for Automake. -*- Autoconf -*-
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2008, 2009 Free Software Foundation, Inc.
+# Copyright (C) 1996-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 16
-
# This macro actually does too much. Some checks are only needed if
# your package does certain things. But this isn't really a big deal.
@@ -692,31 +805,41 @@ 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_DIAGNOSE([obsolete],
+[$0: two- and three-arguments forms are deprecated. For more info, see:
+http://www.gnu.org/software/automake/manual/automake.html#Modernize-AM_INIT_AUTOMAKE-invocation])
+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_if(
+ m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]),
+ [ok:ok],,
[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
+[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_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])
AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl
-AC_REQUIRE([AM_PROG_MKDIR_P])dnl
+AC_REQUIRE([AC_PROG_MKDIR_P])dnl
+# For better backward compatibility. To be removed once Automake 1.9.x
+# dies out for good. For more background, see:
+# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
+# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
+AC_SUBST([mkdir_p], ['$(MKDIR_P)'])
# We need awk for the "check" target. The system "awk" is bad on
# some platforms.
AC_REQUIRE([AC_PROG_AWK])dnl
@@ -727,28 +850,35 @@ _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])],
[_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
+ [_AM_DEPENDENCIES([CC])],
+ [m4_define([AC_PROG_CC],
+ m4_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
+ [_AM_DEPENDENCIES([CXX])],
+ [m4_define([AC_PROG_CXX],
+ m4_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
+ [_AM_DEPENDENCIES([OBJC])],
+ [m4_define([AC_PROG_OBJC],
+ m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
+dnl Support for Objective C++ was only introduced in Autoconf 2.65,
+dnl but we still cater to Autoconf 2.62.
+m4_ifdef([AC_PROG_OBJCXX],
+[AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
+ [_AM_DEPENDENCIES([OBJCXX])],
+ [m4_define([AC_PROG_OBJCXX],
+ m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])])dnl
])
_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
-dnl The `parallel-tests' driver may need to know about EXEEXT, so add the
-dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro
+dnl The 'parallel-tests' driver may need to know about EXEEXT, so add the
+dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro
dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
AC_CONFIG_COMMANDS_PRE(dnl
[m4_provide_if([_AM_COMPILER_EXEEXT],
[AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
])
-dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
+dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
dnl mangled by Autoconf and run in a shell conditional statement.
m4_define([_AC_COMPILER_EXEEXT],
@@ -776,15 +906,12 @@ for _am_header in $config_headers :; do
done
echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
-# Copyright (C) 2001, 2003, 2005, 2008, 2011 Free Software Foundation,
-# Inc.
+# Copyright (C) 2001-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 1
-
# AM_PROG_INSTALL_SH
# ------------------
# Define $install_sh.
@@ -798,16 +925,14 @@ if test x"${install_sh}" != xset; then
install_sh="\${SHELL} $am_aux_dir/install-sh"
esac
fi
-AC_SUBST(install_sh)])
+AC_SUBST([install_sh])])
-# Copyright (C) 2003, 2005 Free Software Foundation, Inc.
+# Copyright (C) 2003-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 2
-
# Check whether the underlying file-system supports filenames
# with a leading dot. For instance MS-DOS doesn't.
AC_DEFUN([AM_SET_LEADING_DOT],
@@ -821,21 +946,18 @@ fi
rmdir .tst 2>/dev/null
AC_SUBST([am__leading_dot])])
-# Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2005
-# Free Software Foundation, Inc.
+# Copyright (C) 1998-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 5
-
# AM_PROG_LEX
# -----------
# Autoconf leaves LEX=: if lex or flex can't be found. Change that to a
# "missing" invocation, for better error output.
AC_DEFUN([AM_PROG_LEX],
-[AC_PREREQ(2.50)dnl
+[AC_PREREQ([2.50])dnl
AC_REQUIRE([AM_MISSING_HAS_RUN])dnl
AC_REQUIRE([AC_PROG_LEX])dnl
if test "$LEX" = :; then
@@ -844,14 +966,12 @@ fi])
# Check to see how 'make' treats includes. -*- Autoconf -*-
-# Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc.
+# Copyright (C) 2001-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 4
-
# AM_MAKE_INCLUDE()
# -----------------
# Check to see how make treats includes.
@@ -869,7 +989,7 @@ am__quote=
_am_result=none
# First try GNU make style include.
echo "include confinc" > confmf
-# Ignore all kinds of additional output from `make'.
+# Ignore all kinds of additional output from 'make'.
case `$am_make -s -f confmf 2> /dev/null` in #(
*the\ am__doit\ target*)
am__include=include
@@ -894,15 +1014,12 @@ AC_MSG_RESULT([$_am_result])
rm -f confinc confmf
])
-# Copyright (C) 1999, 2000, 2001, 2003, 2004, 2005, 2008
-# Free Software Foundation, Inc.
+# Copyright (C) 1999-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 6
-
# AM_PROG_CC_C_O
# --------------
# Like AC_PROG_CC_C_O, but changed for automake.
@@ -931,15 +1048,12 @@ m4_define([AC_PROG_CC],
# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*-
-# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008
-# Free Software Foundation, Inc.
+# Copyright (C) 1997-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 6
-
# AM_MISSING_PROG(NAME, PROGRAM)
# ------------------------------
AC_DEFUN([AM_MISSING_PROG],
@@ -947,7 +1061,6 @@ AC_DEFUN([AM_MISSING_PROG],
$1=${$1-"${am_missing_run}$2"}
AC_SUBST($1)])
-
# AM_MISSING_HAS_RUN
# ------------------
# Define MISSING if not defined so far and test if it supports --run.
@@ -968,50 +1081,18 @@ 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])
+ AC_MSG_WARN(['missing' script is too old or missing])
fi
])
-# Copyright (C) 2003, 2004, 2005, 2006, 2011 Free Software Foundation,
-# Inc.
-#
-# This file 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.
-
-# serial 1
-
-# AM_PROG_MKDIR_P
-# ---------------
-# Check for `mkdir -p'.
-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
-])
-
# Helper functions for option handling. -*- Autoconf -*-
-# Copyright (C) 2001, 2002, 2003, 2005, 2008, 2010 Free Software
-# Foundation, Inc.
+# Copyright (C) 2001-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 5
-
# _AM_MANGLE_OPTION(NAME)
# -----------------------
AC_DEFUN([_AM_MANGLE_OPTION],
@@ -1021,7 +1102,7 @@ AC_DEFUN([_AM_MANGLE_OPTION],
# --------------------
# Set option NAME. Presently that only means defining a flag for this option.
AC_DEFUN([_AM_SET_OPTION],
-[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
+[m4_define(_AM_MANGLE_OPTION([$1]), [1])])
# _AM_SET_OPTIONS(OPTIONS)
# ------------------------
@@ -1037,22 +1118,16 @@ AC_DEFUN([_AM_IF_OPTION],
# Check to make sure that the build environment is sane. -*- Autoconf -*-
-# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008
-# Free Software Foundation, Inc.
+# Copyright (C) 1996-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 5
-
# AM_SANITY_CHECK
# ---------------
AC_DEFUN([AM_SANITY_CHECK],
[AC_MSG_CHECKING([whether build environment is sane])
-# Just in case
-sleep 1
-echo timestamp > conftest.file
# Reject unsafe characters in $srcdir or the absolute working directory
# name. Accept space and tab only in the latter.
am_lf='
@@ -1063,32 +1138,40 @@ case `pwd` in
esac
case $srcdir in
*[[\\\"\#\$\&\'\`$am_lf\ \ ]]*)
- AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);;
+ AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);;
esac
-# Do `set' in a subshell so we don't clobber the current shell's
+# 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
-
+ am_has_slept=no
+ for am_try in 1 2; do
+ echo "timestamp, slept: $am_has_slept" > conftest.file
+ 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
+ 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
+ if test "$[2]" = conftest.file || test $am_try -eq 2; then
+ break
+ fi
+ # Just in case.
+ sleep 1
+ am_has_slept=yes
+ done
test "$[2]" = conftest.file
)
then
@@ -1098,31 +1181,50 @@ else
AC_MSG_ERROR([newly created file is older than distributed files!
Check your system clock])
fi
-AC_MSG_RESULT(yes)])
+AC_MSG_RESULT([yes])
+# If we didn't sleep, we still need to ensure time stamps of config.status and
+# generated files are strictly newer.
+am_sleep_pid=
+if grep 'slept: no' conftest.file >/dev/null 2>&1; then
+ ( sleep 1 ) &
+ am_sleep_pid=$!
+fi
+AC_CONFIG_COMMANDS_PRE(
+ [AC_MSG_CHECKING([that generated files are newer than configure])
+ if test -n "$am_sleep_pid"; then
+ # Hide warnings about reused PIDs.
+ wait $am_sleep_pid 2>/dev/null
+ fi
+ AC_MSG_RESULT([done])])
+rm -f conftest.file
+])
-# Copyright (C) 2009, 2011 Free Software Foundation, Inc.
+# Copyright (C) 2009-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 2
-
# AM_SILENT_RULES([DEFAULT])
# --------------------------
# Enable less verbose build rules; with the default set to DEFAULT
-# (`yes' being less verbose, `no' or empty being verbose).
+# ("yes" being less verbose, "no" or empty being verbose).
AC_DEFUN([AM_SILENT_RULES],
-[AC_ARG_ENABLE([silent-rules],
-[ --enable-silent-rules less verbose build output (undo: `make V=1')
- --disable-silent-rules verbose build output (undo: `make V=0')])
-case $enable_silent_rules in
-yes) AM_DEFAULT_VERBOSITY=0;;
-no) AM_DEFAULT_VERBOSITY=1;;
-*) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
+[AC_ARG_ENABLE([silent-rules], [dnl
+AS_HELP_STRING(
+ [--enable-silent-rules],
+ [less verbose build output (undo: "make V=1")])
+AS_HELP_STRING(
+ [--disable-silent-rules],
+ [verbose build output (undo: "make V=0")])dnl
+])
+case $enable_silent_rules in @%:@ (((
+ yes) AM_DEFAULT_VERBOSITY=0;;
+ no) AM_DEFAULT_VERBOSITY=1;;
+ *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
esac
dnl
-dnl A few `make' implementations (e.g., NonStop OS and NextStep)
+dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
dnl do not support nested variable expansions.
dnl See automake bug#9928 and bug#10237.
am_make=${MAKE-make}
@@ -1140,7 +1242,7 @@ else
am_cv_make_support_nested_variables=no
fi])
if test $am_cv_make_support_nested_variables = yes; then
- dnl Using `$V' instead of `$(V)' breaks IRIX make.
+ dnl Using '$V' instead of '$(V)' breaks IRIX make.
AM_V='$(V)'
AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
else
@@ -1157,44 +1259,40 @@ AC_SUBST([AM_BACKSLASH])dnl
_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
])
-# Copyright (C) 2001, 2003, 2005, 2011 Free Software Foundation, Inc.
+# Copyright (C) 2001-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 1
-
# AM_PROG_INSTALL_STRIP
# ---------------------
-# One issue with vendor `install' (even GNU) is that you can't
+# One issue with vendor 'install' (even GNU) is that you can't
# specify the program used to strip binaries. This is especially
# annoying in cross-compiling environments, where the build's strip
# is unlikely to handle the host's binaries.
# Fortunately install-sh will honor a STRIPPROG variable, so we
-# always use install-sh in `make install-strip', and initialize
+# always use install-sh in "make install-strip", and initialize
# STRIPPROG with the value of the STRIP variable (set by the user).
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
+# 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'.
+# 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])])
-# Copyright (C) 2006, 2008, 2010 Free Software Foundation, Inc.
+# Copyright (C) 2006-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 3
-
# _AM_SUBST_NOTMAKE(VARIABLE)
# ---------------------------
# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in.
@@ -1208,18 +1306,16 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
# Check how to create a tarball. -*- Autoconf -*-
-# Copyright (C) 2004, 2005, 2012 Free Software Foundation, Inc.
+# Copyright (C) 2004-2012 Free Software Foundation, Inc.
#
# This file 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.
-# serial 2
-
# _AM_PROG_TAR(FORMAT)
# --------------------
# Check how to create a tarball in format FORMAT.
-# FORMAT should be one of `v7', `ustar', or `pax'.
+# FORMAT should be one of 'v7', 'ustar', or 'pax'.
#
# Substitute a variable $(am__tar) that is a command
# writing to stdout a FORMAT-tarball containing the directory
@@ -1242,7 +1338,7 @@ AC_MSG_CHECKING([how to create a $1 tar archive])
_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 `-'.
+# Solaris sh will not grok spaces in the rhs of '-'.
for _am_tool in $_am_tools
do
case $_am_tool in
@@ -1306,7 +1402,6 @@ AC_SUBST([am__untar])
m4_include([m4/ax_check_compile_flag.m4])
m4_include([m4/ax_ext.m4])
m4_include([m4/ax_gcc_x86_cpuid.m4])
-m4_include([m4/ax_recvmmsg.m4])
m4_include([m4/libtool.m4])
m4_include([m4/ltoptions.m4])
m4_include([m4/ltsugar.m4])
diff --git a/ar-lib b/ar-lib
index 0f62c6f..67f5f36 100755
--- a/ar-lib
+++ b/ar-lib
@@ -4,7 +4,7 @@
me=ar-lib
scriptversion=2012-03-01.08; # UTC
-# Copyright (C) 2010, 2012 Free Software Foundation, Inc.
+# Copyright (C) 2010-2012 Free Software Foundation, Inc.
# Written by Peter Rosin <peda@lysator.liu.se>.
#
# This program is free software; you can redistribute it and/or modify
diff --git a/compile b/compile
index 862a14e..718dc6d 100755
--- a/compile
+++ b/compile
@@ -1,10 +1,9 @@
#! /bin/sh
# Wrapper for compilers which do not understand '-c -o'.
-scriptversion=2012-03-05.13; # UTC
+scriptversion=2012-10-14.11; # UTC
-# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2009, 2010, 2012 Free
-# Software Foundation, Inc.
+# Copyright (C) 1999-2012 Free Software Foundation, Inc.
# Written by Tom Tromey <tromey@cygnus.com>.
#
# This program is free software; you can redistribute it and/or modify
@@ -113,6 +112,11 @@ func_cl_dashl ()
lib=$dir/$lib.lib
break
fi
+ if test -f "$dir/lib$lib.a"; then
+ found=yes
+ lib=$dir/lib$lib.a
+ break
+ fi
done
IFS=$save_IFS
diff --git a/config.guess b/config.guess
index d622a44..0e30d56 100755
--- a/config.guess
+++ b/config.guess
@@ -1,10 +1,9 @@
#! /bin/sh
# Attempt to guess a canonical system name.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
-# 2011, 2012 Free Software Foundation, Inc.
+# 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
-timestamp='2012-02-10'
+timestamp='2003-07-02'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -17,24 +16,24 @@ timestamp='2012-02-10'
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
-# along with this program; if not, see <http://www.gnu.org/licenses/>.
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
-
-# Originally written by Per Bothner. Please send patches (context
-# diff format) to <config-patches@gnu.org> and include a ChangeLog
-# entry.
+# Originally written by Per Bothner <per@bothner.com>.
+# Please send patches to <config-patches@gnu.org>. Submit a context
+# diff and a properly formatted ChangeLog entry.
#
# This script attempts to guess a canonical system name similar to
# config.sub. If it succeeds, it prints the system name on stdout, and
# exits with 0. Otherwise, it exits with 1.
#
-# You can get the latest version of this script from:
-# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
+# The plan is that this can be called by configure scripts if you
+# don't specify an explicit build system type.
me=`echo "$0" | sed -e 's,.*/,,'`
@@ -54,8 +53,7 @@ version="\
GNU config.guess ($timestamp)
Originally written by Per Bothner.
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
@@ -68,11 +66,11 @@ Try \`$me --help' for more information."
while test $# -gt 0 ; do
case $1 in
--time-stamp | --time* | -t )
- echo "$timestamp" ; exit ;;
+ echo "$timestamp" ; exit 0 ;;
--version | -v )
- echo "$version" ; exit ;;
+ echo "$version" ; exit 0 ;;
--help | --h* | -h )
- echo "$usage"; exit ;;
+ echo "$usage"; exit 0 ;;
-- ) # Stop option processing
shift; break ;;
- ) # Use stdin as input.
@@ -106,7 +104,7 @@ set_cc_for_build='
trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ;
trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ;
: ${TMPDIR=/tmp} ;
- { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
+ { tmp=`(umask 077 && mktemp -d -q "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
{ test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } ||
{ tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } ||
{ echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ;
@@ -125,7 +123,7 @@ case $CC_FOR_BUILD,$HOST_CC,$CC in
;;
,,*) CC_FOR_BUILD=$CC ;;
,*,*) CC_FOR_BUILD=$HOST_CC ;;
-esac ; set_cc_for_build= ;'
+esac ;'
# This is needed to find uname on a Pyramid OSx when run in the BSD universe.
# (ghazi@noc.rutgers.edu 1994-08-24)
@@ -143,7 +141,7 @@ UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
*:NetBSD:*:*)
# NetBSD (nbsd) targets should (where applicable) match one or
- # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*,
+ # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*,
# *-*-netbsdecoff* and *-*-netbsd*. For targets that recently
# switched to ELF, *-*-netbsd* would select the old
# object file format. This provides both forward
@@ -160,7 +158,6 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
arm*) machine=arm-unknown ;;
sh3el) machine=shl-unknown ;;
sh3eb) machine=sh-unknown ;;
- sh5el) machine=sh5le-unknown ;;
*) machine=${UNAME_MACHINE_ARCH}-unknown ;;
esac
# The Operating System including object format, if it has switched
@@ -169,7 +166,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
arm*|i386|m68k|ns32k|sh3*|sparc|vax)
eval $set_cc_for_build
if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
- | grep -q __ELF__
+ | grep __ELF__ >/dev/null
then
# Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout).
# Return netbsd for either. FIX?
@@ -179,7 +176,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
fi
;;
*)
- os=netbsd
+ os=netbsd
;;
esac
# The OS release
@@ -199,32 +196,50 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
# contains redundant information, the shorter form:
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
echo "${machine}-${os}${release}"
- exit ;;
+ exit 0 ;;
+ amiga:OpenBSD:*:*)
+ echo m68k-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
+ arc:OpenBSD:*:*)
+ echo mipsel-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
+ hp300:OpenBSD:*:*)
+ echo m68k-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
+ mac68k:OpenBSD:*:*)
+ echo m68k-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
+ macppc:OpenBSD:*:*)
+ echo powerpc-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
+ mvme68k:OpenBSD:*:*)
+ echo m68k-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
+ mvme88k:OpenBSD:*:*)
+ echo m88k-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
+ mvmeppc:OpenBSD:*:*)
+ echo powerpc-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
+ pmax:OpenBSD:*:*)
+ echo mipsel-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
+ sgi:OpenBSD:*:*)
+ echo mipseb-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
+ sun3:OpenBSD:*:*)
+ echo m68k-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
+ wgrisc:OpenBSD:*:*)
+ echo mipsel-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
*:OpenBSD:*:*)
- UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'`
- echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE}
- exit ;;
- *:ekkoBSD:*:*)
- echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE}
- exit ;;
- *:SolidBSD:*:*)
- echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE}
- exit ;;
- macppc:MirBSD:*:*)
- echo powerpc-unknown-mirbsd${UNAME_RELEASE}
- exit ;;
- *:MirBSD:*:*)
- echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE}
- exit ;;
+ echo ${UNAME_MACHINE}-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
alpha:OSF1:*:*)
- case $UNAME_RELEASE in
- *4.0)
+ if test $UNAME_RELEASE = "V4.0"; then
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
- ;;
- *5.*)
- UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
- ;;
- esac
+ fi
# According to Compaq, /usr/sbin/psrinfo has been available on
# OSF/1 and Tru64 systems produced since 1995. I hope that
# covers most systems running today. This code pipes the CPU
@@ -262,52 +277,42 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
"EV7.9 (21364A)")
UNAME_MACHINE="alphaev79" ;;
esac
- # A Pn.n version is a patched version.
# A Vn.n version is a released version.
# A Tn.n version is a released field test version.
# A Xn.n version is an unreleased experimental baselevel.
# 1.2 uses "1.2" for uname -r.
- echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
- # Reset EXIT trap before exiting to avoid spurious non-zero exit code.
- exitcode=$?
- trap '' 0
- exit $exitcode ;;
+ echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
+ exit 0 ;;
+ Alpha*:OpenVMS:*:*)
+ echo alpha-hp-vms
+ exit 0 ;;
Alpha\ *:Windows_NT*:*)
# How do we know it's Interix rather than the generic POSIX subsystem?
# Should we change UNAME_MACHINE based on the output of uname instead
# of the specific Alpha model?
echo alpha-pc-interix
- exit ;;
+ exit 0 ;;
21064:Windows_NT:50:3)
echo alpha-dec-winnt3.5
- exit ;;
+ exit 0 ;;
Amiga*:UNIX_System_V:4.0:*)
echo m68k-unknown-sysv4
- exit ;;
+ exit 0;;
*:[Aa]miga[Oo][Ss]:*:*)
echo ${UNAME_MACHINE}-unknown-amigaos
- exit ;;
+ exit 0 ;;
*:[Mm]orph[Oo][Ss]:*:*)
echo ${UNAME_MACHINE}-unknown-morphos
- exit ;;
+ exit 0 ;;
*:OS/390:*:*)
echo i370-ibm-openedition
- exit ;;
- *:z/VM:*:*)
- echo s390-ibm-zvmoe
- exit ;;
- *:OS400:*:*)
- echo powerpc-ibm-os400
- exit ;;
+ exit 0 ;;
arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
echo arm-acorn-riscix${UNAME_RELEASE}
- exit ;;
- arm:riscos:*:*|arm:RISCOS:*:*)
- echo arm-unknown-riscos
- exit ;;
+ exit 0;;
SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*)
echo hppa1.1-hitachi-hiuxmpp
- exit ;;
+ exit 0;;
Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*)
# akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE.
if test "`(/bin/universe) 2>/dev/null`" = att ; then
@@ -315,51 +320,32 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
else
echo pyramid-pyramid-bsd
fi
- exit ;;
+ exit 0 ;;
NILE*:*:*:dcosx)
echo pyramid-pyramid-svr4
- exit ;;
+ exit 0 ;;
DRS?6000:unix:4.0:6*)
echo sparc-icl-nx6
- exit ;;
- DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*)
+ exit 0 ;;
+ DRS?6000:UNIX_SV:4.2*:7*)
case `/usr/bin/uname -p` in
- sparc) echo sparc-icl-nx7; exit ;;
+ sparc) echo sparc-icl-nx7 && exit 0 ;;
esac ;;
- s390x:SunOS:*:*)
- echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit ;;
sun4H:SunOS:5.*:*)
echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit ;;
+ exit 0 ;;
sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit ;;
- i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
- echo i386-pc-auroraux${UNAME_RELEASE}
- exit ;;
- i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
- eval $set_cc_for_build
- SUN_ARCH="i386"
- # If there is a compiler, see if it is configured for 64-bit objects.
- # Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
- # This test works for both compilers.
- if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
- if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
- (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
- grep IS_64BIT_ARCH >/dev/null
- then
- SUN_ARCH="x86_64"
- fi
- fi
- echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit ;;
+ exit 0 ;;
+ i86pc:SunOS:5.*:*)
+ echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
+ exit 0 ;;
sun4*:SunOS:6*:*)
# According to config.sub, this is the proper way to canonicalize
# SunOS6. Hard to guess exactly what SunOS6 will be like, but
# it's likely to be more like Solaris than SunOS4.
echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit ;;
+ exit 0 ;;
sun4*:SunOS:*:*)
case "`/usr/bin/arch -k`" in
Series*|S4*)
@@ -368,10 +354,10 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
esac
# Japanese Language versions have a version number like `4.1.3-JL'.
echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'`
- exit ;;
+ exit 0 ;;
sun3*:SunOS:*:*)
echo m68k-sun-sunos${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
sun*:*:4.2BSD:*)
UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3
@@ -383,10 +369,10 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
echo sparc-sun-sunos${UNAME_RELEASE}
;;
esac
- exit ;;
+ exit 0 ;;
aushp:SunOS:*:*)
echo sparc-auspex-sunos${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
# The situation for MiNT is a little confusing. The machine name
# can be virtually everything (everything which is not
# "atarist" or "atariste" at least should have a processor
@@ -396,41 +382,38 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
# MiNT. But MiNT is downward compatible to TOS, so this should
# be no problem.
atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
- echo m68k-atari-mint${UNAME_RELEASE}
- exit ;;
+ echo m68k-atari-mint${UNAME_RELEASE}
+ exit 0 ;;
atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
echo m68k-atari-mint${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
*falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
- echo m68k-atari-mint${UNAME_RELEASE}
- exit ;;
+ echo m68k-atari-mint${UNAME_RELEASE}
+ exit 0 ;;
milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
- echo m68k-milan-mint${UNAME_RELEASE}
- exit ;;
+ echo m68k-milan-mint${UNAME_RELEASE}
+ exit 0 ;;
hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
- echo m68k-hades-mint${UNAME_RELEASE}
- exit ;;
+ echo m68k-hades-mint${UNAME_RELEASE}
+ exit 0 ;;
*:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
- echo m68k-unknown-mint${UNAME_RELEASE}
- exit ;;
- m68k:machten:*:*)
- echo m68k-apple-machten${UNAME_RELEASE}
- exit ;;
+ echo m68k-unknown-mint${UNAME_RELEASE}
+ exit 0 ;;
powerpc:machten:*:*)
echo powerpc-apple-machten${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
RISC*:Mach:*:*)
echo mips-dec-mach_bsd4.3
- exit ;;
+ exit 0 ;;
RISC*:ULTRIX:*:*)
echo mips-dec-ultrix${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
VAX*:ULTRIX*:*:*)
echo vax-dec-ultrix${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
2020:CLIX:*:* | 2430:CLIX:*:*)
echo clipper-intergraph-clix${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
mips:*:*:UMIPS | mips:*:*:RISCos)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
@@ -454,36 +437,35 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
exit (-1);
}
EOF
- $CC_FOR_BUILD -o $dummy $dummy.c &&
- dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` &&
- SYSTEM_NAME=`$dummy $dummyarg` &&
- { echo "$SYSTEM_NAME"; exit; }
+ $CC_FOR_BUILD -o $dummy $dummy.c \
+ && $dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \
+ && exit 0
echo mips-mips-riscos${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
Motorola:PowerMAX_OS:*:*)
echo powerpc-motorola-powermax
- exit ;;
+ exit 0 ;;
Motorola:*:4.3:PL8-*)
echo powerpc-harris-powermax
- exit ;;
+ exit 0 ;;
Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*)
echo powerpc-harris-powermax
- exit ;;
+ exit 0 ;;
Night_Hawk:Power_UNIX:*:*)
echo powerpc-harris-powerunix
- exit ;;
+ exit 0 ;;
m88k:CX/UX:7*:*)
echo m88k-harris-cxux7
- exit ;;
+ exit 0 ;;
m88k:*:4*:R4*)
echo m88k-motorola-sysv4
- exit ;;
+ exit 0 ;;
m88k:*:3*:R3*)
echo m88k-motorola-sysv3
- exit ;;
+ exit 0 ;;
AViiON:dgux:*:*)
- # DG/UX returns AViiON for all architectures
- UNAME_PROCESSOR=`/usr/bin/uname -p`
+ # DG/UX returns AViiON for all architectures
+ UNAME_PROCESSOR=`/usr/bin/uname -p`
if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ]
then
if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \
@@ -496,29 +478,29 @@ EOF
else
echo i586-dg-dgux${UNAME_RELEASE}
fi
- exit ;;
+ exit 0 ;;
M88*:DolphinOS:*:*) # DolphinOS (SVR3)
echo m88k-dolphin-sysv3
- exit ;;
+ exit 0 ;;
M88*:*:R3*:*)
# Delta 88k system running SVR3
echo m88k-motorola-sysv3
- exit ;;
+ exit 0 ;;
XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3)
echo m88k-tektronix-sysv3
- exit ;;
+ exit 0 ;;
Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD)
echo m68k-tektronix-bsd
- exit ;;
+ exit 0 ;;
*:IRIX*:*:*)
echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'`
- exit ;;
+ exit 0 ;;
????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
- echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
- exit ;; # Note that: echo "'`uname -s`'" gives 'AIX '
+ echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
+ exit 0 ;; # Note that: echo "'`uname -s`'" gives 'AIX '
i*86:AIX:*:*)
echo i386-ibm-aix
- exit ;;
+ exit 0 ;;
ia64:AIX:*:*)
if [ -x /usr/bin/oslevel ] ; then
IBM_REV=`/usr/bin/oslevel`
@@ -526,7 +508,7 @@ EOF
IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
fi
echo ${UNAME_MACHINE}-ibm-aix${IBM_REV}
- exit ;;
+ exit 0 ;;
*:AIX:2:3)
if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
eval $set_cc_for_build
@@ -541,19 +523,15 @@ EOF
exit(0);
}
EOF
- if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy`
- then
- echo "$SYSTEM_NAME"
- else
- echo rs6000-ibm-aix3.2.5
- fi
+ $CC_FOR_BUILD -o $dummy $dummy.c && $dummy && exit 0
+ echo rs6000-ibm-aix3.2.5
elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
echo rs6000-ibm-aix3.2.4
else
echo rs6000-ibm-aix3.2
fi
- exit ;;
- *:AIX:*:[4567])
+ exit 0 ;;
+ *:AIX:*:[45])
IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
IBM_ARCH=rs6000
@@ -566,28 +544,28 @@ EOF
IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
fi
echo ${IBM_ARCH}-ibm-aix${IBM_REV}
- exit ;;
+ exit 0 ;;
*:AIX:*:*)
echo rs6000-ibm-aix
- exit ;;
+ exit 0 ;;
ibmrt:4.4BSD:*|romp-ibm:BSD:*)
echo romp-ibm-bsd4.4
- exit ;;
+ exit 0 ;;
ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and
echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to
- exit ;; # report: romp-ibm BSD 4.3
+ exit 0 ;; # report: romp-ibm BSD 4.3
*:BOSX:*:*)
echo rs6000-bull-bosx
- exit ;;
+ exit 0 ;;
DPX/2?00:B.O.S.:*:*)
echo m68k-bull-sysv3
- exit ;;
+ exit 0 ;;
9000/[34]??:4.3bsd:1.*:*)
echo m68k-hp-bsd
- exit ;;
+ exit 0 ;;
hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*)
echo m68k-hp-bsd4.4
- exit ;;
+ exit 0 ;;
9000/[34678]??:HP-UX:*:*)
HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
case "${UNAME_MACHINE}" in
@@ -596,52 +574,52 @@ EOF
9000/[678][0-9][0-9])
if [ -x /usr/bin/getconf ]; then
sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
- sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
- case "${sc_cpu_version}" in
- 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0
- 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1
- 532) # CPU_PA_RISC2_0
- case "${sc_kernel_bits}" in
- 32) HP_ARCH="hppa2.0n" ;;
- 64) HP_ARCH="hppa2.0w" ;;
+ sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
+ case "${sc_cpu_version}" in
+ 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0
+ 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1
+ 532) # CPU_PA_RISC2_0
+ case "${sc_kernel_bits}" in
+ 32) HP_ARCH="hppa2.0n" ;;
+ 64) HP_ARCH="hppa2.0w" ;;
'') HP_ARCH="hppa2.0" ;; # HP-UX 10.20
- esac ;;
- esac
+ esac ;;
+ esac
fi
if [ "${HP_ARCH}" = "" ]; then
eval $set_cc_for_build
- sed 's/^ //' << EOF >$dummy.c
+ sed 's/^ //' << EOF >$dummy.c
- #define _HPUX_SOURCE
- #include <stdlib.h>
- #include <unistd.h>
+ #define _HPUX_SOURCE
+ #include <stdlib.h>
+ #include <unistd.h>
- int main ()
- {
- #if defined(_SC_KERNEL_BITS)
- long bits = sysconf(_SC_KERNEL_BITS);
- #endif
- long cpu = sysconf (_SC_CPU_VERSION);
+ int main ()
+ {
+ #if defined(_SC_KERNEL_BITS)
+ long bits = sysconf(_SC_KERNEL_BITS);
+ #endif
+ long cpu = sysconf (_SC_CPU_VERSION);
- switch (cpu)
- {
- case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
- case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
- case CPU_PA_RISC2_0:
- #if defined(_SC_KERNEL_BITS)
- switch (bits)
- {
- case 64: puts ("hppa2.0w"); break;
- case 32: puts ("hppa2.0n"); break;
- default: puts ("hppa2.0"); break;
- } break;
- #else /* !defined(_SC_KERNEL_BITS) */
- puts ("hppa2.0"); break;
- #endif
- default: puts ("hppa1.0"); break;
- }
- exit (0);
- }
+ switch (cpu)
+ {
+ case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
+ case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
+ case CPU_PA_RISC2_0:
+ #if defined(_SC_KERNEL_BITS)
+ switch (bits)
+ {
+ case 64: puts ("hppa2.0w"); break;
+ case 32: puts ("hppa2.0n"); break;
+ default: puts ("hppa2.0"); break;
+ } break;
+ #else /* !defined(_SC_KERNEL_BITS) */
+ puts ("hppa2.0"); break;
+ #endif
+ default: puts ("hppa1.0"); break;
+ }
+ exit (0);
+ }
EOF
(CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy`
test -z "$HP_ARCH" && HP_ARCH=hppa
@@ -649,19 +627,9 @@ EOF
esac
if [ ${HP_ARCH} = "hppa2.0w" ]
then
- eval $set_cc_for_build
-
- # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating
- # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler
- # generating 64-bit code. GNU and HP use different nomenclature:
- #
- # $ CC_FOR_BUILD=cc ./config.guess
- # => hppa2.0w-hp-hpux11.23
- # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess
- # => hppa64-hp-hpux11.23
-
- if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) |
- grep -q __LP64__
+ # avoid double evaluation of $set_cc_for_build
+ test -n "$CC_FOR_BUILD" || eval $set_cc_for_build
+ if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E -) | grep __LP64__ >/dev/null
then
HP_ARCH="hppa2.0w"
else
@@ -669,11 +637,11 @@ EOF
fi
fi
echo ${HP_ARCH}-hp-hpux${HPUX_REV}
- exit ;;
+ exit 0 ;;
ia64:HP-UX:*:*)
HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
echo ia64-hp-hpux${HPUX_REV}
- exit ;;
+ exit 0 ;;
3050*:HI-UX:*:*)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
@@ -701,266 +669,211 @@ EOF
exit (0);
}
EOF
- $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` &&
- { echo "$SYSTEM_NAME"; exit; }
+ $CC_FOR_BUILD -o $dummy $dummy.c && $dummy && exit 0
echo unknown-hitachi-hiuxwe2
- exit ;;
+ exit 0 ;;
9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
echo hppa1.1-hp-bsd
- exit ;;
+ exit 0 ;;
9000/8??:4.3bsd:*:*)
echo hppa1.0-hp-bsd
- exit ;;
+ exit 0 ;;
*9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*)
echo hppa1.0-hp-mpeix
- exit ;;
+ exit 0 ;;
hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* )
echo hppa1.1-hp-osf
- exit ;;
+ exit 0 ;;
hp8??:OSF1:*:*)
echo hppa1.0-hp-osf
- exit ;;
+ exit 0 ;;
i*86:OSF1:*:*)
if [ -x /usr/sbin/sysversion ] ; then
echo ${UNAME_MACHINE}-unknown-osf1mk
else
echo ${UNAME_MACHINE}-unknown-osf1
fi
- exit ;;
+ exit 0 ;;
parisc*:Lites*:*:*)
echo hppa1.1-hp-lites
- exit ;;
+ exit 0 ;;
C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
echo c1-convex-bsd
- exit ;;
+ exit 0 ;;
C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
if getsysinfo -f scalar_acc
then echo c32-convex-bsd
else echo c2-convex-bsd
fi
- exit ;;
+ exit 0 ;;
C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
echo c34-convex-bsd
- exit ;;
+ exit 0 ;;
C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
echo c38-convex-bsd
- exit ;;
+ exit 0 ;;
C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
echo c4-convex-bsd
- exit ;;
+ exit 0 ;;
CRAY*Y-MP:*:*:*)
echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
- exit ;;
+ exit 0 ;;
CRAY*[A-Z]90:*:*:*)
echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \
| sed -e 's/CRAY.*\([A-Z]90\)/\1/' \
-e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \
-e 's/\.[^.]*$/.X/'
- exit ;;
+ exit 0 ;;
CRAY*TS:*:*:*)
echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
- exit ;;
+ exit 0 ;;
CRAY*T3E:*:*:*)
echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
- exit ;;
+ exit 0 ;;
CRAY*SV1:*:*:*)
echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
- exit ;;
+ exit 0 ;;
*:UNICOS/mp:*:*)
- echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
- exit ;;
+ echo nv1-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
+ exit 0 ;;
F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
- FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
- FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
- echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
- exit ;;
- 5000:UNIX_System_V:4.*:*)
- FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
- FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'`
- echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
- exit ;;
+ FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
+ FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
+ echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
+ exit 0 ;;
i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
sparc*:BSD/OS:*:*)
echo sparc-unknown-bsdi${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
*:BSD/OS:*:*)
echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
- exit ;;
- *:FreeBSD:*:*)
- UNAME_PROCESSOR=`/usr/bin/uname -p`
- case ${UNAME_PROCESSOR} in
- amd64)
- echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
- *)
- echo ${UNAME_PROCESSOR}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
- esac
- exit ;;
+ exit 0 ;;
+ *:FreeBSD:*:*|*:GNU/FreeBSD:*:*)
+ # Determine whether the default compiler uses glibc.
+ eval $set_cc_for_build
+ sed 's/^ //' << EOF >$dummy.c
+ #include <features.h>
+ #if __GLIBC__ >= 2
+ LIBC=gnu
+ #else
+ LIBC=
+ #endif
+EOF
+ eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
+ # GNU/FreeBSD systems have a "k" prefix to indicate we are using
+ # FreeBSD's kernel, but not the complete OS.
+ case ${LIBC} in gnu) kernel_only='k' ;; esac
+ echo ${UNAME_MACHINE}-unknown-${kernel_only}freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC}
+ exit 0 ;;
i*:CYGWIN*:*)
echo ${UNAME_MACHINE}-pc-cygwin
- exit ;;
- *:MINGW*:*)
+ exit 0 ;;
+ i*:MINGW*:*)
echo ${UNAME_MACHINE}-pc-mingw32
- exit ;;
- i*:MSYS*:*)
- echo ${UNAME_MACHINE}-pc-msys
- exit ;;
- i*:windows32*:*)
- # uname -m includes "-pc" on this system.
- echo ${UNAME_MACHINE}-mingw32
- exit ;;
+ exit 0 ;;
i*:PW*:*)
echo ${UNAME_MACHINE}-pc-pw32
- exit ;;
- *:Interix*:*)
- case ${UNAME_MACHINE} in
- x86)
- echo i586-pc-interix${UNAME_RELEASE}
- exit ;;
- authenticamd | genuineintel | EM64T)
- echo x86_64-unknown-interix${UNAME_RELEASE}
- exit ;;
- IA64)
- echo ia64-unknown-interix${UNAME_RELEASE}
- exit ;;
- esac ;;
+ exit 0 ;;
+ x86:Interix*:[34]*)
+ echo i586-pc-interix${UNAME_RELEASE}|sed -e 's/\..*//'
+ exit 0 ;;
[345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
echo i${UNAME_MACHINE}-pc-mks
- exit ;;
- 8664:Windows_NT:*)
- echo x86_64-pc-mks
- exit ;;
+ exit 0 ;;
i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
# How do we know it's Interix rather than the generic POSIX subsystem?
# It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
# UNAME_MACHINE based on the output of uname instead of i386?
echo i586-pc-interix
- exit ;;
+ exit 0 ;;
i*:UWIN*:*)
echo ${UNAME_MACHINE}-pc-uwin
- exit ;;
- amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*)
- echo x86_64-unknown-cygwin
- exit ;;
+ exit 0 ;;
p*:CYGWIN*:*)
echo powerpcle-unknown-cygwin
- exit ;;
+ exit 0 ;;
prep*:SunOS:5.*:*)
echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit ;;
+ exit 0 ;;
*:GNU:*:*)
- # the GNU system
echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
- exit ;;
- *:GNU/*:*:*)
- # other systems with GNU libc and userland
- echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu
- exit ;;
+ exit 0 ;;
i*86:Minix:*:*)
echo ${UNAME_MACHINE}-pc-minix
- exit ;;
- aarch64:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
- aarch64_be:Linux:*:*)
- UNAME_MACHINE=aarch64_be
- echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
- alpha:Linux:*:*)
- case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
- EV5) UNAME_MACHINE=alphaev5 ;;
- EV56) UNAME_MACHINE=alphaev56 ;;
- PCA56) UNAME_MACHINE=alphapca56 ;;
- PCA57) UNAME_MACHINE=alphapca56 ;;
- EV6) UNAME_MACHINE=alphaev6 ;;
- EV67) UNAME_MACHINE=alphaev67 ;;
- EV68*) UNAME_MACHINE=alphaev68 ;;
- esac
- objdump --private-headers /bin/sh | grep -q ld.so.1
- if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
- echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
- exit ;;
+ exit 0 ;;
arm*:Linux:*:*)
- eval $set_cc_for_build
- if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
- | grep -q __ARM_EABI__
- then
- echo ${UNAME_MACHINE}-unknown-linux-gnu
- else
- if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \
- | grep -q __ARM_PCS_VFP
- then
- echo ${UNAME_MACHINE}-unknown-linux-gnueabi
- else
- echo ${UNAME_MACHINE}-unknown-linux-gnueabihf
- fi
- fi
- exit ;;
- avr32*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
+ exit 0 ;;
cris:Linux:*:*)
- echo ${UNAME_MACHINE}-axis-linux-gnu
- exit ;;
- crisv32:Linux:*:*)
- echo ${UNAME_MACHINE}-axis-linux-gnu
- exit ;;
- frv:Linux:*:*)
+ echo cris-axis-linux-gnu
+ exit 0 ;;
+ ia64:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
- hexagon:Linux:*:*)
+ exit 0 ;;
+ m68*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
- i*86:Linux:*:*)
- LIBC=gnu
+ exit 0 ;;
+ mips:Linux:*:*)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
- #ifdef __dietlibc__
- LIBC=dietlibc
+ #undef CPU
+ #undef mips
+ #undef mipsel
+ #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
+ CPU=mipsel
+ #else
+ #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
+ CPU=mips
+ #else
+ CPU=
+ #endif
#endif
EOF
- eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'`
- echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
- exit ;;
- ia64:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
- m32r*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
- m68*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
- mips:Linux:*:* | mips64:Linux:*:*)
+ eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
+ test x"${CPU}" != x && echo "${CPU}-unknown-linux-gnu" && exit 0
+ ;;
+ mips64:Linux:*:*)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#undef CPU
- #undef ${UNAME_MACHINE}
- #undef ${UNAME_MACHINE}el
+ #undef mips64
+ #undef mips64el
#if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
- CPU=${UNAME_MACHINE}el
+ CPU=mips64el
#else
#if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
- CPU=${UNAME_MACHINE}
+ CPU=mips64
#else
CPU=
#endif
#endif
EOF
- eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
- test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
+ eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
+ test x"${CPU}" != x && echo "${CPU}-unknown-linux-gnu" && exit 0
;;
- or32:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
- padre:Linux:*:*)
- echo sparc-unknown-linux-gnu
- exit ;;
- parisc64:Linux:*:* | hppa64:Linux:*:*)
- echo hppa64-unknown-linux-gnu
- exit ;;
+ ppc:Linux:*:*)
+ echo powerpc-unknown-linux-gnu
+ exit 0 ;;
+ ppc64:Linux:*:*)
+ echo powerpc64-unknown-linux-gnu
+ exit 0 ;;
+ alpha:Linux:*:*)
+ case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
+ EV5) UNAME_MACHINE=alphaev5 ;;
+ EV56) UNAME_MACHINE=alphaev56 ;;
+ PCA56) UNAME_MACHINE=alphapca56 ;;
+ PCA57) UNAME_MACHINE=alphapca56 ;;
+ EV6) UNAME_MACHINE=alphaev6 ;;
+ EV67) UNAME_MACHINE=alphaev67 ;;
+ EV68*) UNAME_MACHINE=alphaev68 ;;
+ esac
+ objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null
+ if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
+ echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
+ exit 0 ;;
parisc:Linux:*:* | hppa:Linux:*:*)
# Look for CPU level
case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
@@ -968,71 +881,109 @@ EOF
PA8*) echo hppa2.0-unknown-linux-gnu ;;
*) echo hppa-unknown-linux-gnu ;;
esac
- exit ;;
- ppc64:Linux:*:*)
- echo powerpc64-unknown-linux-gnu
- exit ;;
- ppc:Linux:*:*)
- echo powerpc-unknown-linux-gnu
- exit ;;
+ exit 0 ;;
+ parisc64:Linux:*:* | hppa64:Linux:*:*)
+ echo hppa64-unknown-linux-gnu
+ exit 0 ;;
s390:Linux:*:* | s390x:Linux:*:*)
echo ${UNAME_MACHINE}-ibm-linux
- exit ;;
+ exit 0 ;;
sh64*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
+ exit 0 ;;
sh*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
+ exit 0 ;;
sparc:Linux:*:* | sparc64:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
- tile*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
- vax:Linux:*:*)
- echo ${UNAME_MACHINE}-dec-linux-gnu
- exit ;;
+ exit 0 ;;
x86_64:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
- xtensa*:Linux:*:*)
- echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit ;;
+ echo x86_64-unknown-linux-gnu
+ exit 0 ;;
+ i*86:Linux:*:*)
+ # The BFD linker knows what the default object file format is, so
+ # first see if it will tell us. cd to the root directory to prevent
+ # problems with other programs or directories called `ld' in the path.
+ # Set LC_ALL=C to ensure ld outputs messages in English.
+ ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \
+ | sed -ne '/supported targets:/!d
+ s/[ ][ ]*/ /g
+ s/.*supported targets: *//
+ s/ .*//
+ p'`
+ case "$ld_supported_targets" in
+ elf32-i386)
+ TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu"
+ ;;
+ a.out-i386-linux)
+ echo "${UNAME_MACHINE}-pc-linux-gnuaout"
+ exit 0 ;;
+ coff-i386)
+ echo "${UNAME_MACHINE}-pc-linux-gnucoff"
+ exit 0 ;;
+ "")
+ # Either a pre-BFD a.out linker (linux-gnuoldld) or
+ # one that does not give us useful --help.
+ echo "${UNAME_MACHINE}-pc-linux-gnuoldld"
+ exit 0 ;;
+ esac
+ # Determine whether the default compiler is a.out or elf
+ eval $set_cc_for_build
+ sed 's/^ //' << EOF >$dummy.c
+ #include <features.h>
+ #ifdef __ELF__
+ # ifdef __GLIBC__
+ # if __GLIBC__ >= 2
+ LIBC=gnu
+ # else
+ LIBC=gnulibc1
+ # endif
+ # else
+ LIBC=gnulibc1
+ # endif
+ #else
+ #ifdef __INTEL_COMPILER
+ LIBC=gnu
+ #else
+ LIBC=gnuaout
+ #endif
+ #endif
+EOF
+ eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
+ test x"${LIBC}" != x && echo "${UNAME_MACHINE}-pc-linux-${LIBC}" && exit 0
+ test x"${TENTATIVE}" != x && echo "${TENTATIVE}" && exit 0
+ ;;
i*86:DYNIX/ptx:4*:*)
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
# earlier versions are messed up and put the nodename in both
# sysname and nodename.
echo i386-sequent-sysv4
- exit ;;
+ exit 0 ;;
i*86:UNIX_SV:4.2MP:2.*)
- # Unixware is an offshoot of SVR4, but it has its own version
- # number series starting with 2...
- # I am not positive that other SVR4 systems won't match this,
+ # Unixware is an offshoot of SVR4, but it has its own version
+ # number series starting with 2...
+ # I am not positive that other SVR4 systems won't match this,
# I just have to hope. -- rms.
- # Use sysv4.2uw... so that sysv4* matches it.
+ # Use sysv4.2uw... so that sysv4* matches it.
echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
- exit ;;
+ exit 0 ;;
i*86:OS/2:*:*)
# If we were able to find `uname', then EMX Unix compatibility
# is probably installed.
echo ${UNAME_MACHINE}-pc-os2-emx
- exit ;;
+ exit 0 ;;
i*86:XTS-300:*:STOP)
echo ${UNAME_MACHINE}-unknown-stop
- exit ;;
+ exit 0 ;;
i*86:atheos:*:*)
echo ${UNAME_MACHINE}-unknown-atheos
- exit ;;
- i*86:syllable:*:*)
- echo ${UNAME_MACHINE}-pc-syllable
- exit ;;
- i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*)
+ exit 0 ;;
+ i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*)
echo i386-unknown-lynxos${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
i*86:*DOS:*:*)
echo ${UNAME_MACHINE}-pc-msdosdjgpp
- exit ;;
+ exit 0 ;;
i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*)
UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'`
if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
@@ -1040,16 +991,15 @@ EOF
else
echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL}
fi
- exit ;;
- i*86:*:5:[678]*)
- # UnixWare 7.x, OpenUNIX and OpenServer 6.
+ exit 0 ;;
+ i*86:*:5:[78]*)
case `/bin/uname -X | grep "^Machine"` in
*486*) UNAME_MACHINE=i486 ;;
*Pentium) UNAME_MACHINE=i586 ;;
*Pent*|*Celeron) UNAME_MACHINE=i686 ;;
esac
echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}
- exit ;;
+ exit 0 ;;
i*86:*:3.2:*)
if test -f /usr/options/cb.name; then
UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
@@ -1067,86 +1017,73 @@ EOF
else
echo ${UNAME_MACHINE}-pc-sysv32
fi
- exit ;;
+ exit 0 ;;
pc:*:*:*)
# Left here for compatibility:
- # uname -m prints for DJGPP always 'pc', but it prints nothing about
- # the processor, so we play safe by assuming i586.
- # Note: whatever this is, it MUST be the same as what config.sub
- # prints for the "djgpp" host, or else GDB configury will decide that
- # this is a cross-build.
- echo i586-pc-msdosdjgpp
- exit ;;
+ # uname -m prints for DJGPP always 'pc', but it prints nothing about
+ # the processor, so we play safe by assuming i386.
+ echo i386-pc-msdosdjgpp
+ exit 0 ;;
Intel:Mach:3*:*)
echo i386-pc-mach3
- exit ;;
+ exit 0 ;;
paragon:*:*:*)
echo i860-intel-osf1
- exit ;;
+ exit 0 ;;
i860:*:4.*:*) # i860-SVR4
if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then
echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4
else # Add other i860-SVR4 vendors below as they are discovered.
echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4
fi
- exit ;;
+ exit 0 ;;
mini*:CTIX:SYS*5:*)
# "miniframe"
echo m68010-convergent-sysv
- exit ;;
+ exit 0 ;;
mc68k:UNIX:SYSTEM5:3.51m)
echo m68k-convergent-sysv
- exit ;;
+ exit 0 ;;
M680?0:D-NIX:5.3:*)
echo m68k-diab-dnix
- exit ;;
- M68*:*:R3V[5678]*:*)
- test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;;
- 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0)
+ exit 0 ;;
+ M68*:*:R3V[567]*:*)
+ test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;;
+ 3[34]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0)
OS_REL=''
test -r /etc/.relid \
&& OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
- && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
+ && echo i486-ncr-sysv4.3${OS_REL} && exit 0
/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
- && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
+ && echo i586-ncr-sysv4.3${OS_REL} && exit 0 ;;
3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
- /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
- && { echo i486-ncr-sysv4; exit; } ;;
- NCR*:*:4.2:* | MPRAS*:*:4.2:*)
- OS_REL='.3'
- test -r /etc/.relid \
- && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
- /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
- && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
- /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
- && { echo i586-ncr-sysv4.3${OS_REL}; exit; }
- /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \
- && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
+ /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
+ && echo i486-ncr-sysv4 && exit 0 ;;
m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
echo m68k-unknown-lynxos${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
mc68030:UNIX_System_V:4.*:*)
echo m68k-atari-sysv4
- exit ;;
+ exit 0 ;;
TSUNAMI:LynxOS:2.*:*)
echo sparc-unknown-lynxos${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
rs6000:LynxOS:2.*:*)
echo rs6000-unknown-lynxos${UNAME_RELEASE}
- exit ;;
- PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*)
+ exit 0 ;;
+ PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*)
echo powerpc-unknown-lynxos${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
SM[BE]S:UNIX_SV:*:*)
echo mips-dde-sysv${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
RM*:ReliantUNIX-*:*:*)
echo mips-sni-sysv4
- exit ;;
+ exit 0 ;;
RM*:SINIX-*:*:*)
echo mips-sni-sysv4
- exit ;;
+ exit 0 ;;
*:SINIX-*:*:*)
if uname -p 2>/dev/null >/dev/null ; then
UNAME_MACHINE=`(uname -p) 2>/dev/null`
@@ -1154,94 +1091,68 @@ EOF
else
echo ns32k-sni-sysv
fi
- exit ;;
- PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
- # says <Richard.M.Bartel@ccMail.Census.GOV>
- echo i586-unisys-sysv4
- exit ;;
+ exit 0 ;;
+ PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
+ # says <Richard.M.Bartel@ccMail.Census.GOV>
+ echo i586-unisys-sysv4
+ exit 0 ;;
*:UNIX_System_V:4*:FTX*)
# From Gerald Hewes <hewes@openmarket.com>.
# How about differentiating between stratus architectures? -djm
echo hppa1.1-stratus-sysv4
- exit ;;
+ exit 0 ;;
*:*:*:FTX*)
# From seanf@swdc.stratus.com.
echo i860-stratus-sysv4
- exit ;;
- i*86:VOS:*:*)
- # From Paul.Green@stratus.com.
- echo ${UNAME_MACHINE}-stratus-vos
- exit ;;
+ exit 0 ;;
*:VOS:*:*)
# From Paul.Green@stratus.com.
echo hppa1.1-stratus-vos
- exit ;;
+ exit 0 ;;
mc68*:A/UX:*:*)
echo m68k-apple-aux${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
news*:NEWS-OS:6*:*)
echo mips-sony-newsos6
- exit ;;
+ exit 0 ;;
R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
if [ -d /usr/nec ]; then
- echo mips-nec-sysv${UNAME_RELEASE}
+ echo mips-nec-sysv${UNAME_RELEASE}
else
- echo mips-unknown-sysv${UNAME_RELEASE}
+ echo mips-unknown-sysv${UNAME_RELEASE}
fi
- exit ;;
+ exit 0 ;;
BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
echo powerpc-be-beos
- exit ;;
+ exit 0 ;;
BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only.
echo powerpc-apple-beos
- exit ;;
+ exit 0 ;;
BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
echo i586-pc-beos
- exit ;;
- BePC:Haiku:*:*) # Haiku running on Intel PC compatible.
- echo i586-pc-haiku
- exit ;;
+ exit 0 ;;
SX-4:SUPER-UX:*:*)
echo sx4-nec-superux${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
SX-5:SUPER-UX:*:*)
echo sx5-nec-superux${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
SX-6:SUPER-UX:*:*)
echo sx6-nec-superux${UNAME_RELEASE}
- exit ;;
- SX-7:SUPER-UX:*:*)
- echo sx7-nec-superux${UNAME_RELEASE}
- exit ;;
- SX-8:SUPER-UX:*:*)
- echo sx8-nec-superux${UNAME_RELEASE}
- exit ;;
- SX-8R:SUPER-UX:*:*)
- echo sx8r-nec-superux${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
Power*:Rhapsody:*:*)
echo powerpc-apple-rhapsody${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
*:Rhapsody:*:*)
echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
*:Darwin:*:*)
- UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
- case $UNAME_PROCESSOR in
- i386)
- eval $set_cc_for_build
- if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
- if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
- (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
- grep IS_64BIT_ARCH >/dev/null
- then
- UNAME_PROCESSOR="x86_64"
- fi
- fi ;;
- unknown) UNAME_PROCESSOR=powerpc ;;
+ case `uname -p` in
+ *86) UNAME_PROCESSOR=i686 ;;
+ powerpc) UNAME_PROCESSOR=powerpc ;;
esac
echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
*:procnto*:*:* | *:QNX:[0123456789]*:*)
UNAME_PROCESSOR=`uname -p`
if test "$UNAME_PROCESSOR" = "x86"; then
@@ -1249,28 +1160,22 @@ EOF
UNAME_MACHINE=pc
fi
echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
*:QNX:*:4*)
echo i386-pc-qnx
- exit ;;
- NEO-?:NONSTOP_KERNEL:*:*)
- echo neo-tandem-nsk${UNAME_RELEASE}
- exit ;;
- NSE-?:NONSTOP_KERNEL:*:*)
- echo nse-tandem-nsk${UNAME_RELEASE}
- exit ;;
- NSR-?:NONSTOP_KERNEL:*:*)
+ exit 0 ;;
+ NSR-[DGKLNPTVW]:NONSTOP_KERNEL:*:*)
echo nsr-tandem-nsk${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
*:NonStop-UX:*:*)
echo mips-compaq-nonstopux
- exit ;;
+ exit 0 ;;
BS2000:POSIX*:*:*)
echo bs2000-siemens-sysv
- exit ;;
+ exit 0 ;;
DS/*:UNIX_System_V:*:*)
echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE}
- exit ;;
+ exit 0 ;;
*:Plan9:*:*)
# "uname -m" is not consistent, so use $cputype instead. 386
# is converted to i386 for consistency with other x86
@@ -1281,53 +1186,28 @@ EOF
UNAME_MACHINE="$cputype"
fi
echo ${UNAME_MACHINE}-unknown-plan9
- exit ;;
+ exit 0 ;;
*:TOPS-10:*:*)
echo pdp10-unknown-tops10
- exit ;;
+ exit 0 ;;
*:TENEX:*:*)
echo pdp10-unknown-tenex
- exit ;;
+ exit 0 ;;
KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*)
echo pdp10-dec-tops20
- exit ;;
+ exit 0 ;;
XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*)
echo pdp10-xkl-tops20
- exit ;;
+ exit 0 ;;
*:TOPS-20:*:*)
echo pdp10-unknown-tops20
- exit ;;
+ exit 0 ;;
*:ITS:*:*)
echo pdp10-unknown-its
- exit ;;
+ exit 0 ;;
SEI:*:*:SEIUX)
- echo mips-sei-seiux${UNAME_RELEASE}
- exit ;;
- *:DragonFly:*:*)
- echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
- exit ;;
- *:*VMS:*:*)
- UNAME_MACHINE=`(uname -p) 2>/dev/null`
- case "${UNAME_MACHINE}" in
- A*) echo alpha-dec-vms ; exit ;;
- I*) echo ia64-dec-vms ; exit ;;
- V*) echo vax-dec-vms ; exit ;;
- esac ;;
- *:XENIX:*:SysV)
- echo i386-pc-xenix
- exit ;;
- i*86:skyos:*:*)
- echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//'
- exit ;;
- i*86:rdos:*:*)
- echo ${UNAME_MACHINE}-pc-rdos
- exit ;;
- i*86:AROS:*:*)
- echo ${UNAME_MACHINE}-pc-aros
- exit ;;
- x86_64:VMkernel:*:*)
- echo ${UNAME_MACHINE}-unknown-esx
- exit ;;
+ echo mips-sei-seiux${UNAME_RELEASE}
+ exit 0 ;;
esac
#echo '(No uname command or uname output not recognized.)' 1>&2
@@ -1350,16 +1230,16 @@ main ()
#include <sys/param.h>
printf ("m68k-sony-newsos%s\n",
#ifdef NEWSOS4
- "4"
+ "4"
#else
- ""
+ ""
#endif
- ); exit (0);
+ ); exit (0);
#endif
#endif
#if defined (__arm) && defined (__acorn) && defined (__unix)
- printf ("arm-acorn-riscix\n"); exit (0);
+ printf ("arm-acorn-riscix"); exit (0);
#endif
#if defined (hp300) && !defined (hpux)
@@ -1448,12 +1328,11 @@ main ()
}
EOF
-$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` &&
- { echo "$SYSTEM_NAME"; exit; }
+$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && $dummy && exit 0
# Apollos put the system type in the environment.
-test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; }
+test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit 0; }
# Convex versions that predate uname can use getsysinfo(1)
@@ -1462,22 +1341,22 @@ then
case `getsysinfo -f cpu_type` in
c1*)
echo c1-convex-bsd
- exit ;;
+ exit 0 ;;
c2*)
if getsysinfo -f scalar_acc
then echo c32-convex-bsd
else echo c2-convex-bsd
fi
- exit ;;
+ exit 0 ;;
c34*)
echo c34-convex-bsd
- exit ;;
+ exit 0 ;;
c38*)
echo c38-convex-bsd
- exit ;;
+ exit 0 ;;
c4*)
echo c4-convex-bsd
- exit ;;
+ exit 0 ;;
esac
fi
@@ -1488,9 +1367,7 @@ This script, last modified $timestamp, has failed to recognize
the operating system you are using. It is advised that you
download the most up to date version of the config scripts from
- http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
-and
- http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
+ ftp://ftp.gnu.org/pub/gnu/config/
If the version you run ($0) is already up to date, please
send the following data and any information you think might be
diff --git a/config.sub b/config.sub
index 6205f84..9d7f733 100755
--- a/config.sub
+++ b/config.sub
@@ -1,10 +1,9 @@
#! /bin/sh
# Configuration validation subroutine script.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
-# 2011, 2012 Free Software Foundation, Inc.
+# 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
-timestamp='2012-04-18'
+timestamp='2003-07-04'
# This file is (in principle) common to ALL GNU software.
# The presence of a machine in this file suggests that SOME GNU software
@@ -21,25 +20,23 @@ timestamp='2012-04-18'
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
-# along with this program; if not, see <http://www.gnu.org/licenses/>.
-#
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330,
+# Boston, MA 02111-1307, USA.
+
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
-
# Please send patches to <config-patches@gnu.org>. Submit a context
-# diff and a properly formatted GNU ChangeLog entry.
+# diff and a properly formatted ChangeLog entry.
#
# Configuration subroutine to validate and canonicalize a configuration type.
# Supply the specified configuration type as an argument.
# If it is invalid, we print an error message on stderr and exit with code 1.
# Otherwise, we print the canonical config type on stdout and succeed.
-# You can get the latest version of this script from:
-# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
-
# This file is supposed to be the same for all GNU packages
# and recognize all the CPU types, system types and aliases
# that are meaningful with *any* GNU software.
@@ -73,8 +70,7 @@ Report bugs and patches to <config-patches@gnu.org>."
version="\
GNU config.sub ($timestamp)
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
@@ -87,11 +83,11 @@ Try \`$me --help' for more information."
while test $# -gt 0 ; do
case $1 in
--time-stamp | --time* | -t )
- echo "$timestamp" ; exit ;;
+ echo "$timestamp" ; exit 0 ;;
--version | -v )
- echo "$version" ; exit ;;
+ echo "$version" ; exit 0 ;;
--help | --h* | -h )
- echo "$usage"; exit ;;
+ echo "$usage"; exit 0 ;;
-- ) # Stop option processing
shift; break ;;
- ) # Use stdin as input.
@@ -103,7 +99,7 @@ while test $# -gt 0 ; do
*local*)
# First pass through any local machine types.
echo $1
- exit ;;
+ exit 0;;
* )
break ;;
@@ -122,18 +118,10 @@ esac
# Here we must recognize all the valid KERNEL-OS combinations.
maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
case $maybe_os in
- nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \
- linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \
- knetbsd*-gnu* | netbsd*-gnu* | \
- kopensolaris*-gnu* | \
- storm-chaos* | os2-emx* | rtmk-nova*)
+ nto-qnx* | linux-gnu* | kfreebsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*)
os=-$maybe_os
basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
;;
- android-linux)
- os=-linux-android
- basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`-unknown
- ;;
*)
basic_machine=`echo $1 | sed 's/-[^-]*$//'`
if [ $basic_machine != $1 ]
@@ -156,13 +144,10 @@ case $os in
-convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
-c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
-harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
- -apple | -axis | -knuth | -cray | -microblaze)
+ -apple | -axis)
os=
basic_machine=$1
;;
- -bluegene*)
- os=-cnk
- ;;
-sim | -cisco | -oki | -wec | -winbond)
os=
basic_machine=$1
@@ -177,17 +162,13 @@ case $os in
os=-chorusos
basic_machine=$1
;;
- -chorusrdb)
- os=-chorusrdb
+ -chorusrdb)
+ os=-chorusrdb
basic_machine=$1
- ;;
+ ;;
-hiux*)
os=-hiuxwe2
;;
- -sco6)
- os=-sco5v6
- basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
- ;;
-sco5)
os=-sco3.2v5
basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
@@ -204,10 +185,6 @@ case $os in
# Don't forget version if it is 3.2v4 or newer.
basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
;;
- -sco5v6*)
- # Don't forget version if it is 3.2v4 or newer.
- basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
- ;;
-sco*)
os=-sco3.2v2
basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
@@ -225,12 +202,6 @@ case $os in
-isc*)
basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
;;
- -lynx*178)
- os=-lynxos178
- ;;
- -lynx*5)
- os=-lynxos5
- ;;
-lynx*)
os=-lynxos
;;
@@ -255,103 +226,55 @@ case $basic_machine in
# Some are omitted here because they have special meanings below.
1750a | 580 \
| a29k \
- | aarch64 | aarch64_be \
| alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
| alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
- | am33_2.0 \
- | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \
- | be32 | be64 \
- | bfin \
+ | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \
| c4x | clipper \
| d10v | d30v | dlx | dsp16xx \
- | epiphany \
- | fido | fr30 | frv \
+ | fr30 | frv \
| h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
- | hexagon \
| i370 | i860 | i960 | ia64 \
- | ip2k | iq2000 \
- | le32 | le64 \
- | lm32 \
- | m32c | m32r | m32rle | m68000 | m68k | m88k \
- | maxq | mb | microblaze | mcore | mep | metag \
+ | ip2k \
+ | m32r | m68000 | m68k | m88k | mcore \
| mips | mipsbe | mipseb | mipsel | mipsle \
| mips16 \
| mips64 | mips64el \
- | mips64octeon | mips64octeonel \
- | mips64orion | mips64orionel \
- | mips64r5900 | mips64r5900el \
| mips64vr | mips64vrel \
+ | mips64orion | mips64orionel \
| mips64vr4100 | mips64vr4100el \
| mips64vr4300 | mips64vr4300el \
| mips64vr5000 | mips64vr5000el \
- | mips64vr5900 | mips64vr5900el \
| mipsisa32 | mipsisa32el \
| mipsisa32r2 | mipsisa32r2el \
| mipsisa64 | mipsisa64el \
- | mipsisa64r2 | mipsisa64r2el \
| mipsisa64sb1 | mipsisa64sb1el \
| mipsisa64sr71k | mipsisa64sr71kel \
| mipstx39 | mipstx39el \
| mn10200 | mn10300 \
- | moxie \
- | mt \
| msp430 \
- | nds32 | nds32le | nds32be \
- | nios | nios2 \
| ns16k | ns32k \
- | open8 \
- | or32 \
+ | openrisc | or32 \
| pdp10 | pdp11 | pj | pjl \
- | powerpc | powerpc64 | powerpc64le | powerpcle \
+ | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
| pyramid \
- | rl78 | rx \
- | score \
- | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
+ | sh | sh[1234] | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \
| sh64 | sh64le \
- | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \
- | sparcv8 | sparcv9 | sparcv9b | sparcv9v \
- | spu \
- | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \
- | ubicom32 \
- | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \
+ | sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv9 | sparcv9b \
+ | strongarm \
+ | tahoe | thumb | tic4x | tic80 | tron \
+ | v850 | v850e \
| we32k \
- | x86 | xc16x | xstormy16 | xtensa \
- | z8k | z80)
+ | x86 | xscale | xstormy16 | xtensa \
+ | z8k)
basic_machine=$basic_machine-unknown
;;
- c54x)
- basic_machine=tic54x-unknown
- ;;
- c55x)
- basic_machine=tic55x-unknown
- ;;
- c6x)
- basic_machine=tic6x-unknown
- ;;
- m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | picochip)
+ m6811 | m68hc11 | m6812 | m68hc12)
+ # Motorola 68HC11/12.
basic_machine=$basic_machine-unknown
os=-none
;;
m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k)
;;
- ms1)
- basic_machine=mt-unknown
- ;;
-
- strongarm | thumb | xscale)
- basic_machine=arm-unknown
- ;;
- xgate)
- basic_machine=$basic_machine-unknown
- os=-none
- ;;
- xscaleeb)
- basic_machine=armeb-unknown
- ;;
-
- xscaleel)
- basic_machine=armel-unknown
- ;;
# We use `pc' rather than `unknown'
# because (1) that's what they normally are, and
@@ -367,80 +290,58 @@ case $basic_machine in
# Recognize the basic CPU types with company name.
580-* \
| a29k-* \
- | aarch64-* | aarch64_be-* \
| alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
| alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
- | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
+ | alphapca5[67]-* | alpha64pca5[67]-* | amd64-* | arc-* \
| arm-* | armbe-* | armle-* | armeb-* | armv*-* \
- | avr-* | avr32-* \
- | be32-* | be64-* \
- | bfin-* | bs2000-* \
- | c[123]* | c30-* | [cjt]90-* | c4x-* \
- | clipper-* | craynv-* | cydra-* \
+ | avr-* \
+ | bs2000-* \
+ | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \
+ | clipper-* | cydra-* \
| d10v-* | d30v-* | dlx-* \
| elxsi-* \
- | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \
+ | f30[01]-* | f700-* | fr30-* | frv-* | fx80-* \
| h8300-* | h8500-* \
| hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
- | hexagon-* \
| i*86-* | i860-* | i960-* | ia64-* \
- | ip2k-* | iq2000-* \
- | le32-* | le64-* \
- | lm32-* \
- | m32c-* | m32r-* | m32rle-* \
+ | ip2k-* \
+ | m32r-* \
| m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
- | m88110-* | m88k-* | maxq-* | mcore-* | metag-* | microblaze-* \
+ | m88110-* | m88k-* | mcore-* \
| mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
| mips16-* \
| mips64-* | mips64el-* \
- | mips64octeon-* | mips64octeonel-* \
- | mips64orion-* | mips64orionel-* \
- | mips64r5900-* | mips64r5900el-* \
| mips64vr-* | mips64vrel-* \
+ | mips64orion-* | mips64orionel-* \
| mips64vr4100-* | mips64vr4100el-* \
| mips64vr4300-* | mips64vr4300el-* \
| mips64vr5000-* | mips64vr5000el-* \
- | mips64vr5900-* | mips64vr5900el-* \
| mipsisa32-* | mipsisa32el-* \
| mipsisa32r2-* | mipsisa32r2el-* \
| mipsisa64-* | mipsisa64el-* \
- | mipsisa64r2-* | mipsisa64r2el-* \
| mipsisa64sb1-* | mipsisa64sb1el-* \
| mipsisa64sr71k-* | mipsisa64sr71kel-* \
| mipstx39-* | mipstx39el-* \
- | mmix-* \
- | mt-* \
| msp430-* \
- | nds32-* | nds32le-* | nds32be-* \
- | nios-* | nios2-* \
- | none-* | np1-* | ns16k-* | ns32k-* \
- | open8-* \
+ | none-* | np1-* | nv1-* | ns16k-* | ns32k-* \
| orion-* \
| pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
- | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \
+ | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
| pyramid-* \
- | rl78-* | romp-* | rs6000-* | rx-* \
- | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
+ | romp-* | rs6000-* \
+ | sh-* | sh[1234]-* | sh[23]e-* | sh[34]eb-* | shbe-* \
| shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
- | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \
- | sparclite-* \
- | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx?-* \
- | tahoe-* \
+ | sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \
+ | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
+ | tahoe-* | thumb-* \
| tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
- | tile*-* \
| tron-* \
- | ubicom32-* \
- | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \
- | vax-* \
+ | v850-* | v850e-* | vax-* \
| we32k-* \
- | x86-* | x86_64-* | xc16x-* | xps100-* \
- | xstormy16-* | xtensa*-* \
+ | x86-* | x86_64-* | xps100-* | xscale-* | xstormy16-* \
+ | xtensa-* \
| ymp-* \
- | z8k-* | z80-*)
- ;;
- # Recognize the basic CPU types without company name, with glob match.
- xtensa*)
- basic_machine=$basic_machine-unknown
+ | z8k-*)
;;
# Recognize the various machine names and aliases which stand
# for a CPU type and a company and sometimes even an OS.
@@ -458,9 +359,6 @@ case $basic_machine in
basic_machine=a29k-amd
os=-udi
;;
- abacus)
- basic_machine=abacus-unknown
- ;;
adobe68k)
basic_machine=m68010-adobe
os=-scout
@@ -478,9 +376,6 @@ case $basic_machine in
amd64)
basic_machine=x86_64-pc
;;
- amd64-*)
- basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'`
- ;;
amdahl)
basic_machine=580-amdahl
os=-sysv
@@ -504,10 +399,6 @@ case $basic_machine in
basic_machine=m68k-apollo
os=-bsd
;;
- aros)
- basic_machine=i386-pc
- os=-aros
- ;;
aux)
basic_machine=m68k-apple
os=-aux
@@ -516,35 +407,10 @@ case $basic_machine in
basic_machine=ns32k-sequent
os=-dynix
;;
- blackfin)
- basic_machine=bfin-unknown
- os=-linux
- ;;
- blackfin-*)
- basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'`
- os=-linux
- ;;
- bluegene*)
- basic_machine=powerpc-ibm
- os=-cnk
- ;;
- c54x-*)
- basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'`
- ;;
- c55x-*)
- basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'`
- ;;
- c6x-*)
- basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'`
- ;;
c90)
basic_machine=c90-cray
os=-unicos
;;
- cegcc)
- basic_machine=arm-unknown
- os=-cegcc
- ;;
convex-c1)
basic_machine=c1-convex
os=-bsd
@@ -569,27 +435,12 @@ case $basic_machine in
basic_machine=j90-cray
os=-unicos
;;
- craynv)
- basic_machine=craynv-cray
- os=-unicosmp
- ;;
- cr16 | cr16-*)
- basic_machine=cr16-unknown
- os=-elf
- ;;
crds | unos)
basic_machine=m68k-crds
;;
- crisv32 | crisv32-* | etraxfs*)
- basic_machine=crisv32-axis
- ;;
cris | cris-* | etrax*)
basic_machine=cris-axis
;;
- crx)
- basic_machine=crx-unknown
- os=-elf
- ;;
da30 | da30-*)
basic_machine=m68k-da30
;;
@@ -612,14 +463,6 @@ case $basic_machine in
basic_machine=m88k-motorola
os=-sysv3
;;
- dicos)
- basic_machine=i686-pc
- os=-dicos
- ;;
- djgpp)
- basic_machine=i586-pc
- os=-msdosdjgpp
- ;;
dpx20 | dpx20-*)
basic_machine=rs6000-bull
os=-bosx
@@ -731,6 +574,7 @@ case $basic_machine in
i370-ibm* | ibm*)
basic_machine=i370-ibm
;;
+# I'm not sure what "Sysv32" means. Should this be sysv3.2?
i*86v32)
basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
os=-sysv32
@@ -769,14 +613,6 @@ case $basic_machine in
basic_machine=m68k-isi
os=-sysv
;;
- m68knommu)
- basic_machine=m68k-unknown
- os=-linux
- ;;
- m68knommu-*)
- basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'`
- os=-linux
- ;;
m88k-omron*)
basic_machine=m88k-omron
;;
@@ -788,17 +624,10 @@ case $basic_machine in
basic_machine=ns32k-utek
os=-sysv
;;
- microblaze)
- basic_machine=microblaze-xilinx
- ;;
mingw32)
basic_machine=i386-pc
os=-mingw32
;;
- mingw32ce)
- basic_machine=arm-unknown
- os=-mingw32ce
- ;;
miniframe)
basic_machine=m68000-convergent
;;
@@ -812,6 +641,10 @@ case $basic_machine in
mips3*)
basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown
;;
+ mmix*)
+ basic_machine=mmix-knuth
+ os=-mmixware
+ ;;
monitor)
basic_machine=m68k-rom68k
os=-coff
@@ -824,21 +657,10 @@ case $basic_machine in
basic_machine=i386-pc
os=-msdos
;;
- ms1-*)
- basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'`
- ;;
- msys)
- basic_machine=i386-pc
- os=-msys
- ;;
mvs)
basic_machine=i370-ibm
os=-mvs
;;
- nacl)
- basic_machine=le32-unknown
- os=-nacl
- ;;
ncr3000)
basic_machine=i486-ncr
os=-sysv4
@@ -903,11 +725,9 @@ case $basic_machine in
np1)
basic_machine=np1-gould
;;
- neo-tandem)
- basic_machine=neo-tandem
- ;;
- nse-tandem)
- basic_machine=nse-tandem
+ nv1)
+ basic_machine=nv1-cray
+ os=-unicosmp
;;
nsr-tandem)
basic_machine=nsr-tandem
@@ -916,12 +736,9 @@ case $basic_machine in
basic_machine=hppa1.1-oki
os=-proelf
;;
- openrisc | openrisc-*)
+ or32 | or32-*)
basic_machine=or32-unknown
- ;;
- os400)
- basic_machine=powerpc-ibm
- os=-os400
+ os=-coff
;;
OSE68000 | ose68000)
basic_machine=m68000-ericsson
@@ -939,14 +756,6 @@ case $basic_machine in
basic_machine=i860-intel
os=-osf
;;
- parisc)
- basic_machine=hppa-unknown
- os=-linux
- ;;
- parisc-*)
- basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'`
- os=-linux
- ;;
pbd)
basic_machine=sparc-tti
;;
@@ -956,12 +765,6 @@ case $basic_machine in
pc532 | pc532-*)
basic_machine=ns32k-pc532
;;
- pc98)
- basic_machine=i386-pc
- ;;
- pc98-*)
- basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'`
- ;;
pentium | p5 | k5 | k6 | nexgen | viac3)
basic_machine=i586-pc
;;
@@ -991,10 +794,9 @@ case $basic_machine in
;;
power) basic_machine=power-ibm
;;
- ppc | ppcbe) basic_machine=powerpc-unknown
+ ppc) basic_machine=powerpc-unknown
;;
- ppc-* | ppcbe-*)
- basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
+ ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
ppcle | powerpclittle | ppc-le | powerpc-little)
basic_machine=powerpcle-unknown
@@ -1019,10 +821,6 @@ case $basic_machine in
basic_machine=i586-unknown
os=-pw32
;;
- rdos)
- basic_machine=i386-pc
- os=-rdos
- ;;
rom68k)
basic_machine=m68k-rom68k
os=-coff
@@ -1049,10 +847,6 @@ case $basic_machine in
sb1el)
basic_machine=mipsisa64sb1el-unknown
;;
- sde)
- basic_machine=mipsisa32-sde
- os=-elf
- ;;
sei)
basic_machine=mips-sei
os=-seiux
@@ -1064,9 +858,6 @@ case $basic_machine in
basic_machine=sh-hitachi
os=-hms
;;
- sh5el)
- basic_machine=sh5le-unknown
- ;;
sh64)
basic_machine=sh64-unknown
;;
@@ -1088,9 +879,6 @@ case $basic_machine in
basic_machine=i860-stratus
os=-sysv4
;;
- strongarm-* | thumb-*)
- basic_machine=arm-`echo $basic_machine | sed 's/^[^-]*-//'`
- ;;
sun2)
basic_machine=m68000-sun
;;
@@ -1147,9 +935,17 @@ case $basic_machine in
basic_machine=t90-cray
os=-unicos
;;
- tile*)
- basic_machine=$basic_machine-unknown
- os=-linux-gnu
+ tic54x | c54x*)
+ basic_machine=tic54x-unknown
+ os=-coff
+ ;;
+ tic55x | c55x*)
+ basic_machine=tic55x-unknown
+ os=-coff
+ ;;
+ tic6x | c6x*)
+ basic_machine=tic6x-unknown
+ os=-coff
;;
tx39)
basic_machine=mipstx39-unknown
@@ -1164,10 +960,6 @@ case $basic_machine in
tower | tower-32)
basic_machine=m68k-ncr
;;
- tpf)
- basic_machine=s390x-ibm
- os=-tpf
- ;;
udi29k)
basic_machine=a29k-amd
os=-udi
@@ -1211,16 +1003,9 @@ case $basic_machine in
basic_machine=hppa1.1-winbond
os=-proelf
;;
- xbox)
- basic_machine=i686-pc
- os=-mingw32
- ;;
xps | xps100)
basic_machine=xps100-honeywell
;;
- xscale-* | xscalee[bl]-*)
- basic_machine=`echo $basic_machine | sed 's/^xscale/arm/'`
- ;;
ymp)
basic_machine=ymp-cray
os=-unicos
@@ -1229,10 +1014,6 @@ case $basic_machine in
basic_machine=z8k-unknown
os=-sim
;;
- z80-*-coff)
- basic_machine=z80-unknown
- os=-sim
- ;;
none)
basic_machine=none-none
os=-none
@@ -1252,9 +1033,6 @@ case $basic_machine in
romp)
basic_machine=romp-ibm
;;
- mmix)
- basic_machine=mmix-knuth
- ;;
rs6000)
basic_machine=rs6000-ibm
;;
@@ -1271,10 +1049,13 @@ case $basic_machine in
we32k)
basic_machine=we32k-att
;;
- sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele)
+ sh3 | sh4 | sh[34]eb | sh[1234]le | sh[23]ele)
basic_machine=sh-unknown
;;
- sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v)
+ sh64)
+ basic_machine=sh64-unknown
+ ;;
+ sparc | sparcv9 | sparcv9b)
basic_machine=sparc-sun
;;
cydra)
@@ -1318,12 +1099,9 @@ esac
if [ x"$os" != x"" ]
then
case $os in
- # First match some system type aliases
- # that might get confused with valid system types.
+ # First match some system type aliases
+ # that might get confused with valid system types.
# -solaris* is a basic system type, with this one exception.
- -auroraux)
- os=-auroraux
- ;;
-solaris1 | -solaris1.*)
os=`echo $os | sed -e 's|solaris1|sunos4|'`
;;
@@ -1344,31 +1122,25 @@ case $os in
# Each alternative MUST END IN A *, to match a version number.
# -sysv* is not here because it comes later, after sysvr4.
-gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
- | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\
- | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \
- | -sym* | -kopensolaris* \
+ | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\
+ | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \
| -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
- | -aos* | -aros* \
+ | -aos* \
| -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
| -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
- | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \
- | -openbsd* | -solidbsd* \
- | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \
- | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
+ | -hiux* | -386bsd* | -netbsd* | -openbsd* | -kfreebsd* | -freebsd* | -riscix* \
+ | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
| -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
| -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
- | -chorusos* | -chorusrdb* | -cegcc* \
- | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
- | -mingw32* | -linux-gnu* | -linux-android* \
- | -linux-newlib* | -linux-uclibc* \
- | -uxpv* | -beos* | -mpeix* | -udk* \
+ | -chorusos* | -chorusrdb* \
+ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
+ | -mingw32* | -linux-gnu* | -uxpv* | -beos* | -mpeix* | -udk* \
| -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
| -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
| -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
| -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
| -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
- | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
- | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*)
+ | -powermax* | -dnix* | -nx6 | -nx7 | -sei*)
# Remember, each alternative MUST END IN *, to match a version number.
;;
-qnx*)
@@ -1386,15 +1158,12 @@ case $os in
os=`echo $os | sed -e 's|nto|nto-qnx|'`
;;
-sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \
- | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \
+ | -windows* | -osx | -abug | -netware* | -os9* | -beos* \
| -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*)
;;
-mac*)
os=`echo $os | sed -e 's|mac|macos|'`
;;
- -linux-dietlibc)
- os=-linux-dietlibc
- ;;
-linux*)
os=`echo $os | sed -e 's|linux|linux-gnu|'`
;;
@@ -1407,9 +1176,6 @@ case $os in
-opened*)
os=-openedition
;;
- -os400*)
- os=-os400
- ;;
-wince*)
os=-wince
;;
@@ -1431,9 +1197,6 @@ case $os in
-atheos*)
os=-atheos
;;
- -syllable*)
- os=-syllable
- ;;
-386bsd)
os=-bsd
;;
@@ -1456,9 +1219,6 @@ case $os in
-sinix*)
os=-sysv4
;;
- -tpf*)
- os=-tpf
- ;;
-triton*)
os=-sysv3
;;
@@ -1495,14 +1255,6 @@ case $os in
-kaos*)
os=-kaos
;;
- -zvmoe)
- os=-zvmoe
- ;;
- -dicos*)
- os=-dicos
- ;;
- -nacl*)
- ;;
-none)
;;
*)
@@ -1525,12 +1277,6 @@ else
# system, and we'll never get to this point.
case $basic_machine in
- score-*)
- os=-elf
- ;;
- spu-*)
- os=-elf
- ;;
*-acorn)
os=-riscix1.2
;;
@@ -1540,21 +1286,9 @@ case $basic_machine in
arm*-semi)
os=-aout
;;
- c4x-* | tic4x-*)
- os=-coff
- ;;
- hexagon-*)
- os=-elf
- ;;
- tic54x-*)
- os=-coff
- ;;
- tic55x-*)
- os=-coff
- ;;
- tic6x-*)
- os=-coff
- ;;
+ c4x-* | tic4x-*)
+ os=-coff
+ ;;
# This must come before the *-dec entry.
pdp10-*)
os=-tops20
@@ -1573,13 +1307,13 @@ case $basic_machine in
;;
m68000-sun)
os=-sunos3
+ # This also exists in the configure program, but was not the
+ # default.
+ # os=-sunos4
;;
m68*-cisco)
os=-aout
;;
- mep-*)
- os=-elf
- ;;
mips*-cisco)
os=-elf
;;
@@ -1598,15 +1332,9 @@ case $basic_machine in
*-be)
os=-beos
;;
- *-haiku)
- os=-haiku
- ;;
*-ibm)
os=-aix
;;
- *-knuth)
- os=-mmixware
- ;;
*-wec)
os=-proelf
;;
@@ -1709,7 +1437,7 @@ case $basic_machine in
-sunos*)
vendor=sun
;;
- -cnk*|-aix*)
+ -aix*)
vendor=ibm
;;
-beos*)
@@ -1739,15 +1467,9 @@ case $basic_machine in
-mvs* | -opened*)
vendor=ibm
;;
- -os400*)
- vendor=ibm
- ;;
-ptx*)
vendor=sequent
;;
- -tpf*)
- vendor=ibm
- ;;
-vxsim* | -vxworks* | -windiss*)
vendor=wrs
;;
@@ -1772,7 +1494,7 @@ case $basic_machine in
esac
echo $basic_machine$os
-exit
+exit 0
# Local variables:
# eval: (add-hook 'write-file-hooks 'time-stamp)
diff --git a/configure b/configure
index 51e19f3..91d40ea 100755
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for knot 1.3.0-rc4.
+# Generated by GNU Autoconf 2.69 for knot 1.3.0-rc5.
#
# Report bugs to <knot-dns@labs.nic.cz>.
#
@@ -590,8 +590,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='knot'
PACKAGE_TARNAME='knot'
-PACKAGE_VERSION='1.3.0-rc4'
-PACKAGE_STRING='knot 1.3.0-rc4'
+PACKAGE_VERSION='1.3.0-rc5'
+PACKAGE_STRING='knot 1.3.0-rc5'
PACKAGE_BUGREPORT='knot-dns@labs.nic.cz'
PACKAGE_URL=''
@@ -1355,7 +1355,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures knot 1.3.0-rc4 to adapt to many kinds of systems.
+\`configure' configures knot 1.3.0-rc5 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1425,7 +1425,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of knot 1.3.0-rc4:";;
+ short | recursive ) echo "Configuration of knot 1.3.0-rc5:";;
esac
cat <<\_ACEOF
@@ -1433,10 +1433,12 @@ Optional Features:
--disable-option-checking ignore unrecognized --enable/--with options
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --enable-silent-rules less verbose build output (undo: `make V=1')
- --disable-silent-rules verbose build output (undo: `make V=0')
- --disable-dependency-tracking speeds up one-time build
- --enable-dependency-tracking do not reject slow dependency extractors
+ --enable-silent-rules less verbose build output (undo: "make V=1")
+ --disable-silent-rules verbose build output (undo: "make V=0")
+ --enable-dependency-tracking
+ do not reject slow dependency extractors
+ --disable-dependency-tracking
+ speeds up one-time build
--enable-static[=PKGS] build static libraries [default=no]
--enable-shared[=PKGS] build shared libraries [default=yes]
--enable-fast-install[=PKGS]
@@ -1570,7 +1572,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-knot configure 1.3.0-rc4
+knot configure 1.3.0-rc5
generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
@@ -1993,7 +1995,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by knot $as_me 1.3.0-rc4, which was
+It was created by knot $as_me 1.3.0-rc5, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
@@ -2349,7 +2351,7 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-am__api_version='1.11'
+am__api_version='1.12'
ac_aux_dir=
for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
@@ -2475,9 +2477,6 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
$as_echo_n "checking whether build environment is sane... " >&6; }
-# Just in case
-sleep 1
-echo timestamp > conftest.file
# Reject unsafe characters in $srcdir or the absolute working directory
# name. Accept space and tab only in the latter.
am_lf='
@@ -2488,32 +2487,40 @@ case `pwd` in
esac
case $srcdir in
*[\\\"\#\$\&\'\`$am_lf\ \ ]*)
- as_fn_error $? "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
+ as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
esac
-# Do `set' in a subshell so we don't clobber the current shell's
+# 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".
- as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
-alias in your environment" "$LINENO" 5
- fi
-
+ am_has_slept=no
+ for am_try in 1 2; do
+ echo "timestamp, slept: $am_has_slept" > conftest.file
+ 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
+ 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".
+ as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
+ alias in your environment" "$LINENO" 5
+ fi
+ if test "$2" = conftest.file || test $am_try -eq 2; then
+ break
+ fi
+ # Just in case.
+ sleep 1
+ am_has_slept=yes
+ done
test "$2" = conftest.file
)
then
@@ -2525,6 +2532,16 @@ Check your system clock" "$LINENO" 5
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
+# If we didn't sleep, we still need to ensure time stamps of config.status and
+# generated files are strictly newer.
+am_sleep_pid=
+if grep 'slept: no' conftest.file >/dev/null 2>&1; then
+ ( sleep 1 ) &
+ am_sleep_pid=$!
+fi
+
+rm -f conftest.file
+
test "$program_prefix" != NONE &&
program_transform_name="s&^&$program_prefix&;$program_transform_name"
# Use a double $ so make ignores it.
@@ -2551,8 +2568,8 @@ if eval "$MISSING --run true"; then
am_missing_run="$MISSING --run "
else
am_missing_run=
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
-$as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
+ { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
+$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
fi
if test x"${install_sh}" != xset; then
@@ -2564,10 +2581,10 @@ if test x"${install_sh}" != xset; then
esac
fi
-# Installed binaries are usually stripped using `strip' when the user
-# run `make install-strip'. However `strip' might not be the right
+# 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.
+# will honor the 'STRIP' environment variable to overrule this program.
if test "$cross_compiling" != no; then
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
@@ -2706,12 +2723,6 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
$as_echo "$MKDIR_P" >&6; }
-mkdir_p="$MKDIR_P"
-case $mkdir_p in
- [\\/$]* | ?:[\\/]*) ;;
- */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
-esac
-
for ac_prog in gawk mawk nawk awk
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
@@ -2816,7 +2827,7 @@ fi
# Define the identity of the package.
PACKAGE='knot'
- VERSION='1.3.0-rc4'
+ VERSION='1.3.0-rc5'
cat >>confdefs.h <<_ACEOF
@@ -2844,6 +2855,12 @@ AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
+# For better backward compatibility. To be removed once Automake 1.9.x
+# dies out for good. For more background, see:
+# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
+# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
+mkdir_p='$(MKDIR_P)'
+
# We need awk for the "check" target. The system "awk" is bad on
# some platforms.
# Always define AMTAR for backward compatibility. Yes, it's still used
@@ -2861,10 +2878,10 @@ if test "${enable_silent_rules+set}" = set; then :
enableval=$enable_silent_rules;
fi
-case $enable_silent_rules in
-yes) AM_DEFAULT_VERBOSITY=0;;
-no) AM_DEFAULT_VERBOSITY=1;;
-*) AM_DEFAULT_VERBOSITY=0;;
+case $enable_silent_rules in # (((
+ yes) AM_DEFAULT_VERBOSITY=0;;
+ no) AM_DEFAULT_VERBOSITY=1;;
+ *) AM_DEFAULT_VERBOSITY=0;;
esac
am_make=${MAKE-make}
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
@@ -2918,7 +2935,7 @@ am__quote=
_am_result=none
# First try GNU make style include.
echo "include confinc" > confmf
-# Ignore all kinds of additional output from `make'.
+# Ignore all kinds of additional output from 'make'.
case `$am_make -s -f confmf 2> /dev/null` in #(
*the\ am__doit\ target*)
am__include=include
@@ -3762,8 +3779,8 @@ else
# 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'.
+ # making a dummy file named 'D' -- because '-MD' means "put the output
+ # in D".
rm -rf conftest.dir
mkdir conftest.dir
# Copy depcomp to subdir because otherwise we won't find it if we're
@@ -3798,16 +3815,16 @@ else
: > 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
+ # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
+ # Solaris 10 /bin/sh.
+ echo '/* dummy */' > sub/conftst$i.h
done
echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
- # We check with `-c' and `-o' for the sake of the "dashmstdout"
+ # 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. Also, some Intel
- # versions had trouble with output in subdirs
+ # handle '-M -o', and we need to detect this. Also, some Intel
+ # versions had trouble with output in subdirs.
am__obj=sub/conftest.${OBJEXT-o}
am__minus_obj="-o $am__obj"
case $depmode in
@@ -3816,8 +3833,8 @@ else
test "$am__universal" = false || continue
;;
nosideeffect)
- # after this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested
+ # 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
@@ -3825,7 +3842,7 @@ else
fi
;;
msvc7 | msvc7msys | msvisualcpp | msvcmsys)
- # This compiler won't grok `-c -o', but also, the minuso test has
+ # This compiler won't grok '-c -o', but also, the minuso test has
# not run yet. These depmodes are late enough in the game, and
# so weak that their functioning should not be impacted.
am__obj=conftest.${OBJEXT-o}
@@ -6422,6 +6439,10 @@ freebsd* | dragonfly*)
fi
;;
+gnu*)
+ lt_cv_deplibs_check_method=pass_all
+ ;;
+
haiku*)
lt_cv_deplibs_check_method=pass_all
;;
@@ -6460,11 +6481,11 @@ irix5* | irix6* | nonstopux*)
;;
# This must be glibc/ELF.
-linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
+linux* | k*bsd*-gnu | kopensolaris*-gnu)
lt_cv_deplibs_check_method=pass_all
;;
-netbsd* | netbsdelf*-gnu)
+netbsd*)
if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
else
@@ -9089,7 +9110,7 @@ lt_prog_compiler_static=
lt_prog_compiler_static='-non_shared'
;;
- linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
case $cc_basename in
# old Intel for x86_64 which still supported -KPIC.
ecc*)
@@ -9567,9 +9588,6 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie
openbsd*)
with_gnu_ld=no
;;
- linux* | k*bsd*-gnu | gnu*)
- link_all_deplibs=no
- ;;
esac
ld_shlibs=yes
@@ -9791,7 +9809,7 @@ _LT_EOF
fi
;;
- netbsd* | netbsdelf*-gnu)
+ netbsd*)
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
wlarc=
@@ -9968,7 +9986,6 @@ _LT_EOF
if test "$aix_use_runtimelinking" = yes; then
shared_flag="$shared_flag "'${wl}-G'
fi
- link_all_deplibs=no
else
# not using gcc
if test "$host_cpu" = ia64; then
@@ -10422,7 +10439,7 @@ $as_echo "$lt_cv_irix_exported_symbol" >&6; }
link_all_deplibs=yes
;;
- netbsd* | netbsdelf*-gnu)
+ netbsd*)
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
else
@@ -11259,6 +11276,17 @@ freebsd* | dragonfly*)
esac
;;
+gnu*)
+ version_type=linux # correct to gnu/linux during the next big refactor
+ need_lib_prefix=no
+ need_version=no
+ library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
+ soname_spec='${libname}${release}${shared_ext}$major'
+ shlibpath_var=LD_LIBRARY_PATH
+ shlibpath_overrides_runpath=no
+ hardcode_into_libs=yes
+ ;;
+
haiku*)
version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
@@ -11375,7 +11403,7 @@ linux*oldld* | linux*aout* | linux*coff*)
;;
# This must be glibc/ELF.
-linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
+linux* | k*bsd*-gnu | kopensolaris*-gnu)
version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
@@ -11439,18 +11467,6 @@ fi
dynamic_linker='GNU/Linux ld.so'
;;
-netbsdelf*-gnu)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- dynamic_linker='NetBSD ld.elf_so'
- ;;
-
netbsd*)
version_type=sunos
need_lib_prefix=no
@@ -12957,140 +12973,43 @@ $as_echo "#define DEBUG_ENABLE_BRIEF 1" >>confdefs.h
fi
+# recvmmsg() (valgrind doesn't support it, so disable for debugging)
+# The check for struct mmsghdr is required when libc doesn't have an API but the function links
+# Check whether --enable-recvmmsg was given.
+if test "${enable_recvmmsg+set}" = set; then :
+ enableval=$enable_recvmmsg; case "${enableval}" in
+ yes)
+ for ac_func in sendmmsg
+do :
+ ac_fn_c_check_func "$LINENO" "sendmmsg" "ac_cv_func_sendmmsg"
+if test "x$ac_cv_func_sendmmsg" = xyes; then :
+ cat >>confdefs.h <<_ACEOF
+#define HAVE_SENDMMSG 1
+_ACEOF
+fi
+done
-
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for recv_mmsg support" >&5
-$as_echo_n "checking for recv_mmsg support... " >&6; }
-if ${ax_cv_have_msg_waitforone+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- if test "$cross_compiling" = yes; then :
- ax_cv_have_msg_waitforone=no
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
-
-
-#ifndef _GNU_SOURCE
- #define _GNU_SOURCE
-#endif
-#include <sys/types.h>
#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
-#include <netinet/ip.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <errno.h>
-#include <signal.h>
-
-volatile int _intr = 0;
-void sighandle(int s) {
- _intr = 1;
-}
-
int
main ()
{
-
-#ifndef MSG_WAITFORONE
- return 3; /* Not supported. */
-#else
- int port = 35353;
- int fd = socket(AF_INET, SOCK_DGRAM, 0);
- if (fd < 0) return 1;
- struct mmsghdr msgs[2];
- struct iovec iovecs[2];
- char bufs[2][64];
- unsigned i = 0;
- memset(msgs, 0, sizeof(msgs));
- for (i = 0; i < 2; i++) {
- iovecs[i].iov_base = bufs[i];
- iovecs[i].iov_len = 64;
- msgs[i].msg_hdr.msg_iov = &iovecs[i];
- msgs[i].msg_hdr.msg_iovlen = 1;
- }
-
- struct sockaddr_in sa; /* Bind to socket. */
- sa.sin_family = AF_INET;
- sa.sin_addr.s_addr = htonl(INADDR_LOOPBACK);
- sa.sin_port = htons(port); /* Find free port. */
- while (bind(fd, (struct sockaddr *)&sa, sizeof(sa)) == -1) {
- if (errno == EADDRINUSE) sa.sin_port = ++port;
- else break;
- }
-
- int cfd = socket(AF_INET, SOCK_DGRAM, 0); /* Send datagram. */
- char pkt[32] = { '\xdf' };
- sendto(cfd, pkt, sizeof(pkt), 0, (struct sockaddr*)&sa, sizeof(sa));
-
- /* Broken implementation doesn't respect recvmmsg timeout. */
- struct sigaction aset;
- memset(&aset, 0, sizeof(struct sigaction));
- aset.sa_handler = sighandle;
- sigaction(SIGALRM, &aset, NULL);
- alarm(1);
-
- int ret = recvmmsg(fd, msgs, 2, MSG_WAITFORONE, NULL);
- close(cfd);
- close(fd);
- if (ret < 0) { /* Completely failed. */
- return 2;
- }
-
- return _intr; /* OK if not interrupted. */
-#endif
-
+struct mmsghdr v; recvmmsg(0,0,0,0,0);
;
return 0;
}
_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- ax_cv_have_msg_waitforone=yes
-else
- ax_cv_have_msg_waitforone=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_have_msg_waitforone" >&5
-$as_echo "$ax_cv_have_msg_waitforone" >&6; }
-
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-# recvmmsg() (valgrind doesn't support it, so disable for debugging)
-# Check whether --enable-recvmmsg was given.
-if test "${enable_recvmmsg+set}" = set; then :
- enableval=$enable_recvmmsg; case "${enableval}" in
- yes)
- if test "$ax_cv_have_msg_waitforone" = "yes"; then
+if ac_fn_c_try_link "$LINENO"; then :
-$as_echo "#define ENABLE_RECVMMSG 1" >>confdefs.h
+$as_echo "#define HAVE_RECVMMSG 1" >>confdefs.h
- recvmmsg=true
- else
- recvmmsg=false
- fi
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
;;
no)
- recvmmsg=false
;;
*)
as_fn_error $? "bad value ${enableval} for --enable-recvmmsg" "$LINENO" 5
@@ -13098,14 +13017,35 @@ $as_echo "#define ENABLE_RECVMMSG 1" >>confdefs.h
esac
else
- if test "$ax_cv_have_msg_waitforone" = "yes"; then
+ for ac_func in sendmmsg
+do :
+ ac_fn_c_check_func "$LINENO" "sendmmsg" "ac_cv_func_sendmmsg"
+if test "x$ac_cv_func_sendmmsg" = xyes; then :
+ cat >>confdefs.h <<_ACEOF
+#define HAVE_SENDMMSG 1
+_ACEOF
-$as_echo "#define ENABLE_RECVMMSG 1" >>confdefs.h
+fi
+done
- recvmmsg=true
- else
- recvmmsg=false
- fi
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#include <sys/socket.h>
+int
+main ()
+{
+struct mmsghdr v; recvmmsg(0,0,0,0,0);
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_link "$LINENO"; then :
+
+$as_echo "#define HAVE_RECVMMSG 1" >>confdefs.h
+
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
fi
@@ -14379,7 +14319,7 @@ $as_echo "#define DSFMT_MEXP 521" >>confdefs.h
# Checks for library functions.
-for ac_func in clock_gettime gettimeofday fgetln getline madvise poll posix_memalign pselect pthread_setaffinity_np regcomp select sendmmsg setgroups
+for ac_func in clock_gettime gettimeofday fgetln getline madvise poll posix_memalign pselect pthread_setaffinity_np regcomp select setgroups
do :
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
@@ -14612,6 +14552,14 @@ LIBOBJS=$ac_libobjs
LTLIBOBJS=$ac_ltlibobjs
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
+$as_echo_n "checking that generated files are newer than configure... " >&6; }
+ if test -n "$am_sleep_pid"; then
+ # Hide warnings about reused PIDs.
+ wait $am_sleep_pid 2>/dev/null
+ fi
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
+$as_echo "done" >&6; }
if test -n "$EXEEXT"; then
am__EXEEXT_TRUE=
am__EXEEXT_FALSE='#'
@@ -15029,7 +14977,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by knot $as_me 1.3.0-rc4, which was
+This file was extended by knot $as_me 1.3.0-rc5, which was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -15095,7 +15043,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
-knot config.status 1.3.0-rc4
+knot config.status 1.3.0-rc5
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
@@ -16129,7 +16077,7 @@ $as_echo "$as_me: executing $ac_file commands" >&6;}
# 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
+ # 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.
@@ -16163,21 +16111,19 @@ $as_echo X"$mf" |
continue
fi
# Extract the definition of DEPDIR, am__include, and am__quote
- # from the Makefile without running `make'.
+ # 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
+ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
# Make sure the directory exists.
test -f "$dirpart/$file" && continue
fdir=`$as_dirname -- "$file" ||
diff --git a/configure.ac b/configure.ac
index 770a6fc..5747c8f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,7 @@
# -*- Autoconf -*-
AC_PREREQ([2.60])
-AC_INIT([knot], [1.3.0-rc4], [knot-dns@labs.nic.cz])
+AC_INIT([knot], [1.3.0-rc5], [knot-dns@labs.nic.cz])
AM_INIT_AUTOMAKE([gnits subdir-objects dist-bzip2 dist-xz -Wall -Werror])
AM_SILENT_RULES([yes])
AC_CONFIG_SRCDIR([src/knot/main.c])
@@ -116,32 +116,26 @@ AC_ARG_ENABLE([debuglevel],
;;
esac], [])
-AX_MSG_WAITFORONE
# recvmmsg() (valgrind doesn't support it, so disable for debugging)
+# The check for struct mmsghdr is required when libc doesn't have an API but the function links
AC_ARG_ENABLE([recvmmsg],
AS_HELP_STRING([--enable-recvmmsg=yes|no], [enable recvmmsg() network API under Linux (kernel support required) (set to 'no' if you have trouble running server under valgrind) [default=yes]]),
[case "${enableval}" in
yes)
- if test "$ax_cv_have_msg_waitforone" = "yes"; then
- AC_DEFINE([ENABLE_RECVMMSG], [1], [recvmmsg enabled])
- recvmmsg=true
- else
- recvmmsg=false
- fi
+ AC_CHECK_FUNCS([sendmmsg])
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <sys/socket.h>]], [[struct mmsghdr v; recvmmsg(0,0,0,0,0);]])],
+ [AC_DEFINE(HAVE_RECVMMSG, 1, [Define if struct mmsghdr and recvmmsg() exists.])])
;;
no)
- recvmmsg=false
;;
*)
AC_MSG_ERROR([bad value ${enableval} for --enable-recvmmsg])
;;
- esac], [
- if test "$ax_cv_have_msg_waitforone" = "yes"; then
- AC_DEFINE([ENABLE_RECVMMSG], [1], [recvmmsg enabled])
- recvmmsg=true
- else
- recvmmsg=false
- fi
+ esac],
+ [
+ AC_CHECK_FUNCS([sendmmsg])
+ AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <sys/socket.h>]], [[struct mmsghdr v; recvmmsg(0,0,0,0,0);]])],
+ [AC_DEFINE(HAVE_RECVMMSG, 1, [Define if struct mmsghdr and recvmmsg() exists.])])
])
# Enable integrity check
@@ -302,7 +296,7 @@ AC_TYPE_SSIZE_T
AC_DEFINE([DSFMT_MEXP], [521], [DSFMT parameters])
# Checks for library functions.
-AC_CHECK_FUNCS([clock_gettime gettimeofday fgetln getline madvise poll posix_memalign pselect pthread_setaffinity_np regcomp select sendmmsg setgroups])
+AC_CHECK_FUNCS([clock_gettime gettimeofday fgetln getline madvise poll posix_memalign pselect pthread_setaffinity_np regcomp select setgroups])
# Check for cpu_set_t/cpuset_t compatibility
AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <pthread.h>]], [[cpu_set_t set; CPU_ZERO(&set);]])],
diff --git a/depcomp b/depcomp
index 25a39e6..e1f51f4 100755
--- a/depcomp
+++ b/depcomp
@@ -1,10 +1,9 @@
#! /bin/sh
# depcomp - compile a program generating dependencies as side-effects
-scriptversion=2012-03-27.16; # UTC
+scriptversion=2012-07-12.20; # UTC
-# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009, 2010,
-# 2011, 2012 Free Software Foundation, Inc.
+# Copyright (C) 1999-2012 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -75,6 +74,9 @@ tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`}
rm -f "$tmpdepfile"
+# Avoid interferences from the environment.
+gccflag= dashmflag=
+
# Some modes work just like other modes, but use different flags. We
# parameterize here, but still list the modes in the big case below,
# to make depend.m4 easier to write. Note that we *cannot* use a case
@@ -109,7 +111,7 @@ if test "$depmode" = msvc7msys; then
fi
if test "$depmode" = xlc; then
- # IBM C/C++ Compilers xlc/xlC can output gcc-like dependency informations.
+ # IBM C/C++ Compilers xlc/xlC can output gcc-like dependency information.
gccflag=-qmakedep=gcc,-MF
depmode=gcc
fi
@@ -143,13 +145,17 @@ gcc3)
;;
gcc)
+## Note that this doesn't just cater to obsosete pre-3.x GCC compilers.
+## but also to in-use compilers like IMB xlc/xlC and the HP C compiler.
+## (see the conditional assignment to $gccflag above).
## There are various ways to get dependency output from gcc. Here's
## why we pick this rather obscure method:
## - Don't want to use -MD because we'd like the dependencies to end
## up in a subdir. Having to rename by hand is ugly.
## (We might end up doing this anyway to support other compilers.)
## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like
-## -MM, not -M (despite what the docs say).
+## -MM, not -M (despite what the docs say). Also, it might not be
+## supported by the other compilers which use the 'gcc' depmode.
## - Using -M directly means running the compiler twice (even worse
## than renaming).
if test -z "$gccflag"; then
@@ -335,6 +341,79 @@ icc)
rm -f "$tmpdepfile"
;;
+## The order of this option in the case statement is important, since the
+## shell code in configure will try each of these formats in the order
+## listed in this file. A plain '-MD' option would be understood by many
+## compilers, so we must ensure this comes after the gcc and icc options.
+pgcc)
+ # Portland's C compiler understands '-MD'.
+ # Will always output deps to 'file.d' where file is the root name of the
+ # source file under compilation, even if file resides in a subdirectory.
+ # The object file name does not affect the name of the '.d' file.
+ # pgcc 10.2 will output
+ # foo.o: sub/foo.c sub/foo.h
+ # and will wrap long lines using '\' :
+ # foo.o: sub/foo.c ... \
+ # sub/foo.h ... \
+ # ...
+ dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
+ test "x$dir" = "x$object" && dir=
+ # Use the source, not the object, to determine the base name, since
+ # that's sadly what pgcc will do too.
+ base=`echo "$source" | sed -e 's|^.*/||' -e 's/\.[-_a-zA-Z0-9]*$//'`
+ tmpdepfile="$base.d"
+
+ # For projects that build the same source file twice into different object
+ # files, the pgcc approach of using the *source* file root name can cause
+ # problems in parallel builds. Use a locking strategy to avoid stomping on
+ # the same $tmpdepfile.
+ lockdir="$base.d-lock"
+ trap "echo '$0: caught signal, cleaning up...' >&2; rm -rf $lockdir" 1 2 13 15
+ numtries=100
+ i=$numtries
+ while test $i -gt 0 ; do
+ # mkdir is a portable test-and-set.
+ if mkdir $lockdir 2>/dev/null; then
+ # This process acquired the lock.
+ "$@" -MD
+ stat=$?
+ # Release the lock.
+ rm -rf $lockdir
+ break
+ else
+ ## the lock is being held by a different process,
+ ## wait until the winning process is done or we timeout
+ while test -d $lockdir && test $i -gt 0; do
+ sleep 1
+ i=`expr $i - 1`
+ done
+ fi
+ i=`expr $i - 1`
+ done
+ trap - 1 2 13 15
+ if test $i -le 0; then
+ echo "$0: failed to acquire lock after $numtries attempts" >&2
+ echo "$0: check lockdir '$lockdir'" >&2
+ exit 1
+ fi
+
+ if test $stat -ne 0; then
+ rm -f "$tmpdepfile"
+ exit $stat
+ fi
+ rm -f "$depfile"
+ # Each line is of the form `foo.o: dependent.h',
+ # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'.
+ # Do two passes, one to just change these to
+ # `$object: dependent.h' and one to simply `dependent.h:'.
+ sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile"
+ # Some versions of the HPUX 10.20 sed can't process this invocation
+ # correctly. Breaking it into two sed invocations is a workaround.
+ sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" |
+ sed -e 's/$/ :/' >> "$depfile"
+ rm -f "$tmpdepfile"
+ ;;
+
hp2)
# The "hp" stanza above does not work with aCC (C++) and HP's ia64
# compilers, which have integrated preprocessors. The correct option
diff --git a/doc/Makefile.in b/doc/Makefile.in
index d8e93dd..1a14f1d 100644
--- a/doc/Makefile.in
+++ b/doc/Makefile.in
@@ -1,9 +1,8 @@
-# Makefile.in generated by automake 1.11.6 from Makefile.am.
+# Makefile.in generated by automake 1.12.6 from Makefile.am.
# @configure_input@
-# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
-# Foundation, Inc.
+# Copyright (C) 1994-2012 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.
@@ -58,24 +57,58 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_compile_flag.m4 \
$(top_srcdir)/m4/ax_ext.m4 \
$(top_srcdir)/m4/ax_gcc_x86_cpuid.m4 \
- $(top_srcdir)/m4/ax_recvmmsg.m4 $(top_srcdir)/m4/libtool.m4 \
- $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
- $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
- $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
+ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
+ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/visibility.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/src/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
AM_V_GEN = $(am__v_GEN_@AM_V@)
am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
-am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
AM_V_at = $(am__v_at_@AM_V@)
am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
+am__v_at_1 =
SOURCES =
DIST_SOURCES =
+AM_V_DVIPS = $(am__v_DVIPS_@AM_V@)
+am__v_DVIPS_ = $(am__v_DVIPS_@AM_DEFAULT_V@)
+am__v_DVIPS_0 = @echo " DVIPS " $@;
+am__v_DVIPS_1 =
+AM_V_MAKEINFO = $(am__v_MAKEINFO_@AM_V@)
+am__v_MAKEINFO_ = $(am__v_MAKEINFO_@AM_DEFAULT_V@)
+am__v_MAKEINFO_0 = @echo " MAKEINFO" $@;
+am__v_MAKEINFO_1 =
+AM_V_INFOHTML = $(am__v_INFOHTML_@AM_V@)
+am__v_INFOHTML_ = $(am__v_INFOHTML_@AM_DEFAULT_V@)
+am__v_INFOHTML_0 = @echo " INFOHTML" $@;
+am__v_INFOHTML_1 =
+AM_V_TEXI2DVI = $(am__v_TEXI2DVI_@AM_V@)
+am__v_TEXI2DVI_ = $(am__v_TEXI2DVI_@AM_DEFAULT_V@)
+am__v_TEXI2DVI_0 = @echo " TEXI2DVI" $@;
+am__v_TEXI2DVI_1 =
+AM_V_TEXI2PDF = $(am__v_TEXI2PDF_@AM_V@)
+am__v_TEXI2PDF_ = $(am__v_TEXI2PDF_@AM_DEFAULT_V@)
+am__v_TEXI2PDF_0 = @echo " TEXI2PDF" $@;
+am__v_TEXI2PDF_1 =
+AM_V_texinfo = $(am__v_texinfo_@AM_V@)
+am__v_texinfo_ = $(am__v_texinfo_@AM_DEFAULT_V@)
+am__v_texinfo_0 = -q
+am__v_texinfo_1 =
+AM_V_texidevnull = $(am__v_texidevnull_@AM_V@)
+am__v_texidevnull_ = $(am__v_texidevnull_@AM_DEFAULT_V@)
+am__v_texidevnull_0 = > /dev/null
+am__v_texidevnull_1 =
INFO_DEPS = $(srcdir)/knot.info
am__TEXINFO_TEX_DIR = $(srcdir)
DVIS = knot.dvi
@@ -314,7 +347,7 @@ clean-libtool:
-rm -rf .libs _libs
.texi.info:
- restore=: && backupdir="$(am__leading_dot)am$$$$" && \
+ $(AM_V_MAKEINFO)restore=: && backupdir="$(am__leading_dot)am$$$$" && \
am__cwd=`pwd` && $(am__cd) $(srcdir) && \
rm -rf $$backupdir && mkdir $$backupdir && \
if ($(MAKEINFO) --version) >/dev/null 2>&1; then \
@@ -336,18 +369,18 @@ clean-libtool:
rm -rf $$backupdir; exit $$rc
.texi.dvi:
- TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+ $(AM_V_TEXI2DVI)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I $(srcdir)' \
- $(TEXI2DVI) $<
+ $(TEXI2DVI) $(AM_V_texinfo) --clean $< $(AM_V_texidevnull)
.texi.pdf:
- TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+ $(AM_V_TEXI2PDF)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I $(srcdir)' \
- $(TEXI2PDF) $<
+ $(TEXI2PDF) $(AM_V_texinfo) --clean $< $(AM_V_texidevnull)
.texi.html:
- rm -rf $(@:.html=.htp)
- if $(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) -I $(srcdir) \
+ $(AM_V_MAKEINFO)rm -rf $(@:.html=.htp)
+ $(AM_V_at)if $(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) -I $(srcdir) \
-o $(@:.html=.htp) $<; \
then \
rm -rf $@; \
@@ -382,8 +415,8 @@ mostlyclean-vti:
maintainer-clean-vti:
-rm -f $(srcdir)/stamp-vti $(srcdir)/version.texi
.dvi.ps:
- TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
- $(DVIPS) -o $@ $<
+ $(AM_V_DVIPS)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+ $(DVIPS) $(AM_V_texinfo) -o $@ $<
uninstall-dvi-am:
@$(NORMAL_UNINSTALL)
@@ -482,6 +515,8 @@ TAGS:
ctags: CTAGS
CTAGS:
+cscope cscopelist:
+
distdir: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
diff --git a/doc/configuration.texi b/doc/configuration.texi
index 5dd5549..e6cdf53 100644
--- a/doc/configuration.texi
+++ b/doc/configuration.texi
@@ -274,13 +274,12 @@ Setting to a value greater than @code{0} means that every flow is allowed N resp
It is also possible to configure SLIP interval, which causes every Nth blocked response to be slipped
as a truncated response. Not that some error responses cannot be truncated and are slipped as-is.
For more information, refer to @ref{rate-limit-slip}.
-It is advisable to not set slip interval to a value larger than 2, to allow legitimate clients
-get at least some level of service.
+It is advisable to not set slip interval to a value larger than 1.
Example configuration:
@example
system @{
rate-limit 200; # Each flow is allowed to 200 resp. per second
- rate-limit-slip 2; # Every other response is slipped (default)
+ rate-limit-slip 1; # Every response is slipped (default)
@}
@end example
diff --git a/doc/knot.info b/doc/knot.info
index c2ad015..23137d0 100644
--- a/doc/knot.info
+++ b/doc/knot.info
@@ -1,6 +1,6 @@
-This is knot.info, produced by makeinfo version 4.13 from knot.texi.
+This is ./knot.info, produced by makeinfo version 4.8 from ./knot.texi.
-This manual is for Knot DNS (version 1.3.0-rc4, 9 July 2013), which is
+This manual is for Knot DNS (version 1.3.0-rc5, 29 July 2013), which is
a high-performance authoritative-only DNS server.
Copyright (C) 2012 CZ.NIC, z.s.p.o.
@@ -30,7 +30,7 @@ File: knot.info, Node: Top, Next: Introduction, Prev: (dir), Up: (dir)
Knot DNS
********
-This manual is for Knot DNS (version 1.3.0-rc4, 9 July 2013).
+This manual is for Knot DNS (version 1.3.0-rc5, 29 July 2013).
* Menu:
@@ -502,7 +502,7 @@ For example:
$ ./configure --enable-debug=server,packet --enable-debuglevel=brief
$ ./configure --enable-debug=server,packet --enable-debuglevel=verbose
-For more detailed information, see *note Debug messages::.
+For more detailed information, see *Note Debug messages::.
In most simple case you can just run configure without any options.
@@ -732,14 +732,14 @@ can be used as a base for your Knot DNS setup.
Now let's go step by step through this minimal configuration file:
1. In `system' statement we have configured `storage' directory where
- Knot DNS will store slave zones and journal files. (See *note
- system:: and *note storage::)
+ Knot DNS will store slave zones and journal files. (See *Note
+ system:: and *Note storage::)
2. The `interfaces' statement defines interfaces where Knot DNS will
listen for incoming connections. We have defined two interfaces:
one IPv4 called `my_interface' explicitly listening on port 53 and
second IPv6 called `second_int' also listening on port 53, which
- is the default port for the DNS. See *note interfaces::.
+ is the default port for the DNS. See *Note interfaces::.
3. The `log' statement defines the log facilities for Knot DNS. In
this example we told Knot DNS to send its log messages with the
@@ -747,7 +747,7 @@ Now let's go step by step through this minimal configuration file:
you omit this sections, all severities will printed to either
`stdout' or `stderr', and the severities from the `warning' and
more serious to syslog. You can find all possible combinations in
- the *note log::.
+ the *Note log::.
4. The `zones' statement is probably the most important one, because
it defines the zones that Knot DNS will serve. In its most simple
@@ -766,7 +766,7 @@ the zone master. If `update-in' is set and zone has a master, any
accepted DNS UPDATE will be forwarded to master. Also note that you
need to explicitly allow incoming NOTIFY, otherwise the daemon would
reject them. Also, you can specify paths, relative to the storage
-directory. See *note zones:: and *note storage::. If the zone file
+directory. See *Note zones:: and *Note storage::. If the zone file
doesn't exist and `xfr-in' is set, it will be bootstrapped over AXFR.
remotes {
@@ -788,7 +788,7 @@ configure a TSIG key and assign it to a remote. Supported algorithms
for TSIG key are:
`hmac-md5, hmac-sha1, hmac-sha224, hmac-sha256, hmac-sha384,
hmac-sha512'
-Key secret is written in a base64 encoded format. See *note keys::.
+Key secret is written in a base64 encoded format. See *Note keys::.
keys {
key0 hmac-md5 "Wg=="; # keyname algorithm secret
@@ -929,7 +929,7 @@ File: knot.info, Node: Enabling zone semantic checks, Next: Creating IXFR diff
=================================
You can turn on more detailed semantic checks of zone file in this
-`zones' statement (*note zones::). Refer to *note zones List of zone
+`zones' statement (*note zones::). Refer to *Note zones List of zone
semantic checks:: to see which checks are enabled by default and which
are optional.
@@ -941,9 +941,9 @@ File: knot.info, Node: Creating IXFR differences from zone file changes, Next:
If Knot is being run as a master server, experimental feature
`ixfr-from-differences' can be enabled to create IXFR differences from
-changes made to the master zone file. See *note Controlling running
+changes made to the master zone file. See *Note Controlling running
daemon:: for more information. For more about `zones' statement see
-*note zones::.
+*Note zones::.

File: knot.info, Node: Using Response Rate Limiting, Prev: Creating IXFR differences from zone file changes, Up: Knot DNS Configuration
@@ -959,21 +959,20 @@ could then exploit DNS server responding to every query, potentially
flooding the victim with a large unsolicited DNS responses.
As of Knot DNS version 1.2.0, RRL is compiled in, but disabled by
-default. You can enable it with the *note rate-limit:: option in the
-*note system:: section. Setting to a value greater than `0' means that
+default. You can enable it with the *Note rate-limit:: option in the
+*Note system:: section. Setting to a value greater than `0' means that
every flow is allowed N responses per second, (i.e. `rate-limit 50;'
means `50' responses per second). It is also possible to configure
SLIP interval, which causes every Nth blocked response to be slipped as
a truncated response. Not that some error responses cannot be truncated
-and are slipped as-is. For more information, refer to *note
+and are slipped as-is. For more information, refer to *Note
rate-limit-slip::. It is advisable to not set slip interval to a value
-larger than 2, to allow legitimate clients get at least some level of
-service.
+larger than 1.
Example configuration:
system {
rate-limit 200; # Each flow is allowed to 200 resp. per second
- rate-limit-slip 2; # Every other response is slipped (default)
+ rate-limit-slip 1; # Every response is slipped (default)
}

@@ -1026,8 +1025,6 @@ server daemon. If you want to control the daemon directly, use
-v, --verbose Verbose mode - additional runtime
information.
-V, --version Print knot server version.
- -w, --wait Wait for the server to finish stop
- operations.
-i, --interactive Interactive mode (do not daemonize).
-h, --help Print help and usage.
@@ -1091,7 +1088,7 @@ foreground mode, PID file will be created in `rundir' directory.
$ knotd -d -c slave.conf # start the daemon
$ knotc -c slave.conf stop # stop the daemon
-When the server is running, you can control the daemon, see *note
+When the server is running, you can control the daemon, see *Note
Controlling running daemon::.

@@ -1131,7 +1128,7 @@ restarting the server. This can be done with the `knotc reload' action.
$ knotc -c master.conf reload # reconfigure and load updated zones
If you want _IXFR-out_ differences created from changes you make to a
-zone file, enable *note ixfr-from-differences:: in `zones' statement,
+zone file, enable *Note ixfr-from-differences:: in `zones' statement,
then reload your server as seen above. If _SOA_'s _serial_ is not
changed no differences will be created. Please note that this feature
is in _experimental_ stage and should be used with care. If you
@@ -1662,7 +1659,7 @@ each Nth response as truncated, thus allowing client to reconnect via
TCP for at least some degree of service. It is worth noting, that some
responses can't be truncated (f.e. SERVFAIL).
-Default value: `2'
+Default value: `1'

File: knot.info, Node: system Example, Prev: system Statement Definition and Usage, Up: system
@@ -1671,8 +1668,8 @@ A.1.3 system Example
--------------------
system {
- identity "Knot DNS 1.3.0-rc4";
- version "1.3.0-rc4";
+ identity "Knot DNS 1.3.0-rc5";
+ version "1.3.0-rc5";
nsid "amaterasu";
storage "/var/lib/knot";
rundir "/var/run/knot";
@@ -1974,10 +1971,10 @@ A.5 `groups' Statement
======================
The `groups' statement is used to create groups of remote machines
-defined in *note remotes:: statement. The group can substitute multiple
+defined in *Note remotes:: statement. The group can substitute multiple
machines specification anywhere in the configuration where the list of
-remotes is allowed to be used (namely `allow' in *note control::
-section and ACLs in *note zones:: section).
+remotes is allowed to be used (namely `allow' in *Note control::
+section and ACLs in *Note zones:: section).
The remotes definitions must exist prior to using them in group
definitions. One remote can be a member of multiple groups.
@@ -2025,7 +2022,7 @@ A.5.2.2 `remote_id'
...................
`remote_id' contains a symbolic name for a remote server as specified in
-*note remotes:: section.
+*Note remotes:: section.

File: knot.info, Node: groups Examples, Prev: groups Statement Definition and Grammar, Up: groups
@@ -2094,7 +2091,7 @@ A.6.2 Statement Definition and Grammar
--------------------------------------
Control interface `listen-on' either defines a UNIX socket or an
-IPv4/IPv6 `interface' definition as in *note interfaces::. Default
+IPv4/IPv6 `interface' definition as in *Note interfaces::. Default
port for IPv4/v6 control interface is `5533', however UNIX socket is
preferred. UNIX socket address is relative to `rundir' if not
specified as an absolute path. Without any configuration, the socket
@@ -2266,7 +2263,7 @@ A.7.2.8 semantic-checks
.......................
`semantic-checks' statement turns on optional semantic checks for this
-particular zone. See *note zones List of zone semantic checks:: for
+particular zone. See *Note zones List of zone semantic checks:: for
more information.
Possible values are `on' and `off'. Most checks are disabled by
@@ -2281,7 +2278,7 @@ A.7.2.9 ixfr-from-differences
EXPERIMENTAL: option `ixfr-from-differences' is only relevant if you
are running Knot DNS as a master for this zone. By turning the feature
on you tell Knot to create differences from changes you made to a zone
-file upon server reload. See *note Controlling running daemon:: for
+file upon server reload. See *Note Controlling running daemon:: for
more information.
Possible values are `on' and `off'. Disabled by default.
@@ -2323,7 +2320,7 @@ A.7.2.13 zonefile-sync
`zonefile-sync' is only relevant in a slave server scenario and only
after receiving IXFR. It is a time in seconds after which current zone
-in memory will be synced to its file on a disk (as set in *note
+in memory will be synced to its file on a disk (as set in *Note
file::). Knot DNS will serve the latest zone even after restart, but
zone file on a disk will only be synced after `zonefile-sync' time has
expired. Possible values are 1 to INT_MAX, optionally suffixed by unit
@@ -2593,135 +2590,130 @@ A.9.2 Examples

Tag Table:
-Node: Top1039
-Node: Introduction4047
-Node: What is Knot DNS4345
-Node: Knot DNS features4863
-Node: Scope of this document5884
-Node: Knot DNS Resource Requirements6146
-Node: Hardware requirements6444
-Node: CPU requirements7084
-Node: Memory requirements7469
-Node: Supported operating system8185
-Node: Knot DNS Installation8653
-Node: Required build environment8960
-Node: Required libraries9584
-Node: Userspace RCU10389
-Node: Installation from the sources11341
-Node: Configuring and generating Makefiles11926
-Node: Compilation13584
-Node: Installation14160
-Node: Installation from packages14667
-Node: Installing Knot DNS packages on Debian15191
-Node: Installing Knot DNS packages on Ubuntu16169
-Node: Adding official PPA repository for Knot DNS17083
-Node: Installing Knot DNS packages on Fedora17711
-Node: Installing Knot DNS from ports on FreeBSD19110
-Node: Knot DNS Configuration19457
-Node: Minimal configuration20028
-Node: Slave configuration22041
-Node: Master configuration24037
-Node: Configuring multiple interfaces25083
-Node: Using DNS UPDATE25568
-Node: Remote control interface27135
-Node: Enabling zone semantic checks28227
-Node: Creating IXFR differences from zone file changes28694
-Node: Using Response Rate Limiting29267
-Node: Running Knot DNS30768
-Node: Running a slave server34499
-Node: Running a master server35795
-Node: Controlling running daemon36776
-Node: Troubleshooting37947
-Node: Submitting a bugreport38355
-Node: Generating backtrace39525
-Node: Debug messages40527
-Node: Enabling debug messages in server41197
-Node: Debug messages Example42757
-Node: Statement Index42956
-Node: Knot DNS Configuration Reference46779
-Node: system47145
-Node: system Syntax47506
-Node: system Statement Definition and Usage48385
-Node: identity48818
-Node: version49228
-Node: hostname49662
-Node: nsid50100
-Node: storage50420
-Node: rundir50777
-Node: pidfile51118
-Node: workers51417
-Node: user51802
-Node: max-conn-idle52236
-Node: max-conn-hs52553
-Node: max-conn-reply52914
-Node: transfers53145
-Node: rate-limit53430
-Node: rate-limit-size54172
-Node: rate-limit-slip54843
-Node: system Example55427
-Node: keys55792
-Node: keys Syntax56099
-Node: keys Statement Definition and Usage56328
-Node: key_id56534
-Node: Example57496
-Node: interfaces57730
-Node: interfaces Syntax58065
-Node: interfaces Statement Definition and Usage58403
-Node: interface_id58645
-Node: interfaces Examples59009
-Node: remotes59488
-Node: remotes Syntax60087
-Node: remotes Statement Definition and Grammar60526
-Node: remote_id60796
-Node: address60996
-Node: port61215
-Node: key61469
-Node: via61684
-Node: remotes Examples61914
-Node: groups62440
-Node: groups Syntax63130
-Node: groups Statement Definition and Grammar63348
-Node: group_id63606
-Node: groups_remote_id63813
-Node: groups Examples64060
-Node: control64466
-Node: control Syntax65003
-Node: control Statement Definition and Grammar65371
-Node: control Examples65954
-Node: zones66436
-Node: zones Syntax66780
-Node: zones Statement Definition and Grammar67740
-Node: zone_id68172
-Node: file68560
-Node: xfr-in68904
-Node: xfr-out69243
-Node: notify-in69588
-Node: notify-out69836
-Node: update-in70091
-Node: semantic-checks70434
-Node: ixfr-from-differences70853
-Node: disable-any71410
-Node: notify-timeout71797
-Node: notify-retries72142
-Node: zonefile-sync72461
-Node: ixfr-fslimit73171
-Node: zones Example73577
-Node: zones List of zone semantic checks74399
-Node: log76199
-Node: log Syntax76422
-Node: log Statement Definition and Grammar76746
-Node: log_name77456
-Node: category77785
-Node: severity78252
-Node: log_file78994
-Node: log Example79249
-Node: include79632
-Node: include Syntax80101
-Node: include Examples80239
+Node: Top1043
+Node: Introduction4052
+Node: What is Knot DNS4350
+Node: Knot DNS features4868
+Node: Scope of this document5889
+Node: Knot DNS Resource Requirements6151
+Node: Hardware requirements6449
+Node: CPU requirements7089
+Node: Memory requirements7474
+Node: Supported operating system8190
+Node: Knot DNS Installation8658
+Node: Required build environment8965
+Node: Required libraries9589
+Node: Userspace RCU10394
+Node: Installation from the sources11346
+Node: Configuring and generating Makefiles11931
+Node: Compilation13589
+Node: Installation14165
+Node: Installation from packages14672
+Node: Installing Knot DNS packages on Debian15196
+Node: Installing Knot DNS packages on Ubuntu16174
+Node: Adding official PPA repository for Knot DNS17088
+Node: Installing Knot DNS packages on Fedora17716
+Node: Installing Knot DNS from ports on FreeBSD19115
+Node: Knot DNS Configuration19462
+Node: Minimal configuration20033
+Node: Slave configuration22046
+Node: Master configuration24042
+Node: Configuring multiple interfaces25088
+Node: Using DNS UPDATE25573
+Node: Remote control interface27140
+Node: Enabling zone semantic checks28232
+Node: Creating IXFR differences from zone file changes28699
+Node: Using Response Rate Limiting29272
+Node: Running Knot DNS30703
+Node: Running a slave server34321
+Node: Running a master server35617
+Node: Controlling running daemon36598
+Node: Troubleshooting37769
+Node: Submitting a bugreport38177
+Node: Generating backtrace39347
+Node: Debug messages40349
+Node: Enabling debug messages in server41019
+Node: Debug messages Example42579
+Node: Statement Index42778
+Node: Knot DNS Configuration Reference46601
+Node: system46967
+Node: system Syntax47328
+Node: system Statement Definition and Usage48207
+Node: identity48640
+Node: version49050
+Node: hostname49484
+Node: nsid49922
+Node: storage50242
+Node: rundir50599
+Node: pidfile50940
+Node: workers51239
+Node: user51624
+Node: max-conn-idle52058
+Node: max-conn-hs52375
+Node: max-conn-reply52736
+Node: transfers52967
+Node: rate-limit53252
+Node: rate-limit-size53994
+Node: rate-limit-slip54665
+Node: system Example55249
+Node: keys55614
+Node: keys Syntax55921
+Node: keys Statement Definition and Usage56150
+Node: key_id56356
+Node: Example57318
+Node: interfaces57552
+Node: interfaces Syntax57887
+Node: interfaces Statement Definition and Usage58225
+Node: interface_id58467
+Node: interfaces Examples58831
+Node: remotes59310
+Node: remotes Syntax59909
+Node: remotes Statement Definition and Grammar60348
+Node: remote_id60618
+Node: address60818
+Node: port61037
+Node: key61291
+Node: via61506
+Node: remotes Examples61736
+Node: groups62262
+Node: groups Syntax62952
+Node: groups Statement Definition and Grammar63170
+Node: group_id63428
+Node: groups_remote_id63635
+Node: groups Examples63882
+Node: control64288
+Node: control Syntax64825
+Node: control Statement Definition and Grammar65193
+Node: control Examples65776
+Node: zones66258
+Node: zones Syntax66602
+Node: zones Statement Definition and Grammar67562
+Node: zone_id67994
+Node: file68382
+Node: xfr-in68726
+Node: xfr-out69065
+Node: notify-in69410
+Node: notify-out69658
+Node: update-in69913
+Node: semantic-checks70256
+Node: ixfr-from-differences70675
+Node: disable-any71232
+Node: notify-timeout71619
+Node: notify-retries71964
+Node: zonefile-sync72283
+Node: ixfr-fslimit72993
+Node: zones Example73399
+Node: zones List of zone semantic checks74221
+Node: log76021
+Node: log Syntax76244
+Node: log Statement Definition and Grammar76568
+Node: log_name77278
+Node: category77607
+Node: severity78074
+Node: log_file78816
+Node: log Example79071
+Node: include79454
+Node: include Syntax79923
+Node: include Examples80061

End Tag Table
-
-
-Local Variables:
-coding: utf-8
-End:
diff --git a/doc/mdate-sh b/doc/mdate-sh
index 60dc485..4614441 100755
--- a/doc/mdate-sh
+++ b/doc/mdate-sh
@@ -3,8 +3,7 @@
scriptversion=2010-08-21.06; # UTC
-# Copyright (C) 1995, 1996, 1997, 2003, 2004, 2005, 2007, 2009, 2010
-# Free Software Foundation, Inc.
+# Copyright (C) 1995-2012 Free Software Foundation, Inc.
# written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, June 1995
#
# This program is free software; you can redistribute it and/or modify
@@ -40,7 +39,7 @@ fi
case $1 in
'')
- echo "$0: No file. Try \`$0 --help' for more information." 1>&2
+ echo "$0: No file. Try '$0 --help' for more information." 1>&2
exit 1;
;;
-h | --h*)
@@ -76,7 +75,7 @@ LC_TIME=C
export LC_TIME
# GNU ls changes its time format in response to the TIME_STYLE
-# variable. Since we cannot assume `unset' works, revert this
+# variable. Since we cannot assume 'unset' works, revert this
# variable to its documented default.
if test "${TIME_STYLE+set}" = set; then
TIME_STYLE=posix-long-iso
@@ -96,14 +95,14 @@ if ls -n /dev/null 1>/dev/null 2>&1; then
ls_command="$ls_command -n"
fi
-# A `ls -l' line looks as follows on OS/2.
+# A 'ls -l' line looks as follows on OS/2.
# drwxrwx--- 0 Aug 11 2001 foo
# This differs from Unix, which adds ownership information.
# drwxrwx--- 2 root root 4096 Aug 11 2001 foo
#
# To find the date, we split the line on spaces and iterate on words
# until we find a month. This cannot work with files whose owner is a
-# user named `Jan', or `Feb', etc. However, it's unlikely that `/'
+# user named "Jan", or "Feb", etc. However, it's unlikely that '/'
# will be owned by a user whose name is a month. So we first look at
# the extended ls output of the root directory to decide how many
# words should be skipped to get the date.
@@ -116,7 +115,7 @@ month=
command=
until test $month
do
- test $# -gt 0 || error "failed parsing \`$ls_command /' output"
+ test $# -gt 0 || error "failed parsing '$ls_command /' output"
shift
# Add another shift to the command.
command="$command shift;"
@@ -136,7 +135,7 @@ do
esac
done
-test -n "$month" || error "failed parsing \`$ls_command /' output"
+test -n "$month" || error "failed parsing '$ls_command /' output"
# Get the extended ls output of the file or directory.
set dummy x`eval "$ls_command \"\\\$save_arg1\""`
diff --git a/doc/reference.texi b/doc/reference.texi
index 7344956..04b1fcb 100644
--- a/doc/reference.texi
+++ b/doc/reference.texi
@@ -270,7 +270,7 @@ As attacks using DNS/UDP are usually based on a forged source address, an attack
if all responses would be completely blocked. The idea behind SLIP mechanism is to send each Nth response as truncated, thus allowing
client to reconnect via TCP for at least some degree of service. It is worth noting, that some responses can't be truncated (f.e. SERVFAIL).
-Default value: @kbd{2}
+Default value: @kbd{1}
@node system Example
@subsection system Example
diff --git a/doc/running.texi b/doc/running.texi
index cfa8810..2e26f09 100644
--- a/doc/running.texi
+++ b/doc/running.texi
@@ -48,8 +48,6 @@ Parameters:
-v, --verbose Verbose mode - additional runtime
information.
-V, --version Print knot server version.
- -w, --wait Wait for the server to finish stop
- operations.
-i, --interactive Interactive mode (do not daemonize).
-h, --help Print help and usage.
diff --git a/doc/stamp-vti b/doc/stamp-vti
index b309676..7ad20ef 100644
--- a/doc/stamp-vti
+++ b/doc/stamp-vti
@@ -1,4 +1,4 @@
-@set UPDATED 9 July 2013
+@set UPDATED 29 July 2013
@set UPDATED-MONTH July 2013
-@set EDITION 1.3.0-rc4
-@set VERSION 1.3.0-rc4
+@set EDITION 1.3.0-rc5
+@set VERSION 1.3.0-rc5
diff --git a/doc/texinfo.tex b/doc/texinfo.tex
index 85b68e7..b5f3141 100644
--- a/doc/texinfo.tex
+++ b/doc/texinfo.tex
@@ -3,7 +3,7 @@
% Load plain if necessary, i.e., if running under initex.
\expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
%
-\def\texinfoversion{2012-03-11.15}
+\def\texinfoversion{2012-11-08.11}
%
% Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
% 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
@@ -28,9 +28,9 @@
%
% Please try the latest version of texinfo.tex before submitting bug
% reports; you can get the latest version from:
-% http://www.gnu.org/software/texinfo/ (the Texinfo home page), or
-% ftp://tug.org/tex/texinfo.tex
-% (and all CTAN mirrors, see http://www.ctan.org).
+% http://ftp.gnu.org/gnu/texinfo/ (the Texinfo release area), or
+% http://ftpmirror.gnu.org/texinfo/ (same, via a mirror), or
+% http://www.gnu.org/software/texinfo/ (the Texinfo home page)
% The texinfo.tex in any given distribution could well be out
% of date, so if that's what you're using, please check.
%
@@ -594,7 +594,7 @@
\def\:{\spacefactor=1000 }
% @* forces a line break.
-\def\*{\hfil\break\hbox{}\ignorespaces}
+\def\*{\unskip\hfil\break\hbox{}\ignorespaces}
% @/ allows a line break.
\let\/=\allowbreak
@@ -1117,7 +1117,7 @@ where each line of input produces a line of output.}
% #1 is a control sequence in which to do the replacements,
% which we \xdef.
\def\txiescapepdf#1{%
- \ifx\pdfescapestring\relax
+ \ifx\pdfescapestring\thisisundefined
% No primitive available; should we give a warning or log?
% Many times it won't matter.
\else
@@ -1367,9 +1367,8 @@ output) for that.)}
\def\skipspaces#1{\def\PP{#1}\def\D{|}%
\ifx\PP\D\let\nextsp\relax
\else\let\nextsp\skipspaces
- \ifx\p\space\else\addtokens{\filename}{\PP}%
- \advance\filenamelength by 1
- \fi
+ \addtokens{\filename}{\PP}%
+ \advance\filenamelength by 1
\fi
\nextsp}
\def\getfilename#1{%
@@ -1475,9 +1474,6 @@ output) for that.)}
\def\ttsl{\setfontstyle{ttsl}}
-% Default leading.
-\newdimen\textleading \textleading = 13.2pt
-
% Set the baselineskip to #1, and the lineskip and strut size
% correspondingly. There is no deep meaning behind these magic numbers
% used as factors; they just match (closely enough) what Knuth defined.
@@ -1489,6 +1485,7 @@ output) for that.)}
% can get a sort of poor man's double spacing by redefining this.
\def\baselinefactor{1}
%
+\newdimen\textleading
\def\setleading#1{%
\dimen0 = #1\relax
\normalbaselineskip = \baselinefactor\dimen0
@@ -1761,18 +1758,24 @@ end
\fi\fi
-% Set the font macro #1 to the font named #2, adding on the
-% specified font prefix (normally `cm').
+% Set the font macro #1 to the font named \fontprefix#2.
% #3 is the font's design size, #4 is a scale factor, #5 is the CMap
-% encoding (currently only OT1, OT1IT and OT1TT are allowed, pass
-% empty to omit).
+% encoding (only OT1, OT1IT and OT1TT are allowed, or empty to omit).
+% Example:
+% #1 = \textrm
+% #2 = \rmshape
+% #3 = 10
+% #4 = \mainmagstep
+% #5 = OT1
+%
\def\setfont#1#2#3#4#5{%
\font#1=\fontprefix#2#3 scaled #4
\csname cmap#5\endcsname#1%
}
% This is what gets called when #5 of \setfont is empty.
\let\cmap\gobble
-% emacs-page end of cmaps
+%
+% (end of cmaps)
% Use cm as the default font prefix.
% To specify the font prefix, you must define \fontprefix
@@ -1782,7 +1785,7 @@ end
\fi
% Support font families that don't use the same naming scheme as CM.
\def\rmshape{r}
-\def\rmbshape{bx} %where the normal face is bold
+\def\rmbshape{bx} % where the normal face is bold
\def\bfshape{b}
\def\bxshape{bx}
\def\ttshape{tt}
@@ -1797,8 +1800,7 @@ end
\def\scshape{csc}
\def\scbshape{csc}
-% Definitions for a main text size of 11pt. This is the default in
-% Texinfo.
+% Definitions for a main text size of 11pt. (The default in Texinfo.)
%
\def\definetextfontsizexi{%
% Text fonts (11.2pt, magstep1).
@@ -1923,7 +1925,7 @@ end
\textleading = 13.2pt % line spacing for 11pt CM
\textfonts % reset the current fonts
\rm
-} % end of 11pt text font size definitions
+} % end of 11pt text font size definitions, \definetextfontsizexi
% Definitions to make the main text be 10pt Computer Modern, with
@@ -2055,7 +2057,7 @@ end
\textleading = 12pt % line spacing for 10pt CM
\textfonts % reset the current fonts
\rm
-} % end of 10pt text font size definitions
+} % end of 10pt text font size definitions, \definetextfontsizex
% We provide the user-level command
@@ -2270,8 +2272,6 @@ end
\gdef\markupsetcodequoteleft{\let`\codequoteleft}
\gdef\markupsetcodequoteright{\let'\codequoteright}
-
-\gdef\markupsetnoligaturesquoteleft{\let`\noligaturesquoteleft}
}
\let\markupsetuplqcode \markupsetcodequoteleft
@@ -2280,6 +2280,9 @@ end
\let\markupsetuplqexample \markupsetcodequoteleft
\let\markupsetuprqexample \markupsetcodequoteright
%
+\let\markupsetuplqkbd \markupsetcodequoteleft
+\let\markupsetuprqkbd \markupsetcodequoteright
+%
\let\markupsetuplqsamp \markupsetcodequoteleft
\let\markupsetuprqsamp \markupsetcodequoteright
%
@@ -2289,8 +2292,6 @@ end
\let\markupsetuplqverbatim \markupsetcodequoteleft
\let\markupsetuprqverbatim \markupsetcodequoteright
-\let\markupsetuplqkbd \markupsetnoligaturesquoteleft
-
% Allow an option to not use regular directed right quote/apostrophe
% (char 0x27), but instead the undirected quote from cmtt (char 0x0d).
% The undirected quote is ugly, so don't make it the default, but it
@@ -2380,8 +2381,7 @@ end
\aftersmartic
}
-% like \smartslanted except unconditionally uses \ttsl, and no ic.
-% @var is set to this for defun arguments.
+% Unconditional use \ttsl, and no ic. @var is set to this for defuns.
\def\ttslanted#1{{\ttsl #1}}
% @cite is like \smartslanted except unconditionally use \sl. We never want
@@ -2446,34 +2446,12 @@ end
% @samp.
\def\samp#1{{\setupmarkupstyle{samp}\lq\tclose{#1}\rq\null}}
-% definition of @key that produces a lozenge. Doesn't adjust to text size.
-%\setfont\keyrm\rmshape{8}{1000}{OT1}
-%\font\keysy=cmsy9
-%\def\key#1{{\keyrm\textfont2=\keysy \leavevmode\hbox{%
-% \raise0.4pt\hbox{\angleleft}\kern-.08em\vtop{%
-% \vbox{\hrule\kern-0.4pt
-% \hbox{\raise0.4pt\hbox{\vphantom{\angleleft}}#1}}%
-% \kern-0.4pt\hrule}%
-% \kern-.06em\raise0.4pt\hbox{\angleright}}}}
+% @indicateurl is \samp, that is, with quotes.
+\let\indicateurl=\samp
-% definition of @key with no lozenge. If the current font is already
-% monospace, don't change it; that way, we respect @kbdinputstyle. But
-% if it isn't monospace, then use \tt.
-%
-\def\key#1{{\setupmarkupstyle{key}%
- \nohyphenation
- \ifmonospace\else\tt\fi
- #1}\null}
-
-% ctrl is no longer a Texinfo command.
-\def\ctrl #1{{\tt \rawbackslash \hat}#1}
-
-% @file, @option are the same as @samp.
-\let\file=\samp
-\let\option=\samp
-
-% @code is a modification of @t,
-% which makes spaces the same size as normal in the surrounding text.
+% @code (and similar) prints in typewriter, but with spaces the same
+% size as normal in the surrounding text, without hyphenation, etc.
+% This is a subroutine for that.
\def\tclose#1{%
{%
% Change normal interword space to be same as for the current font.
@@ -2498,7 +2476,7 @@ end
% We *must* turn on hyphenation at `-' and `_' in @code.
% Otherwise, it is too hard to avoid overfull hboxes
% in the Emacs manual, the Library manual, etc.
-
+%
% Unfortunately, TeX uses one parameter (\hyphenchar) to control
% both hyphenation at - and hyphenation within words.
% We must therefore turn them both off (\tclose does that)
@@ -2562,6 +2540,13 @@ end
\fi\fi
}
+% For @command, @env, @file, @option quotes seem unnecessary,
+% so use \code rather than \samp.
+\let\command=\code
+\let\env=\code
+\let\file=\code
+\let\option=\code
+
% @uref (abbreviation for `urlref') takes an optional (comma-separated)
% second argument specifying the text to display and an optional third
% arg as text to display instead of (rather than in addition to) the url
@@ -2708,10 +2693,6 @@ end
\let\email=\uref
\fi
-% @kbd is like @code, except that if the argument is just one @key command,
-% then @kbd has no effect.
-\def\kbd#1{{\setupmarkupstyle{kbd}\def\look{#1}\expandafter\kbdfoo\look??\par}}
-
% @kbdinputstyle -- arg is `distinct' (@kbd uses slanted tty font always),
% `example' (@kbd uses ttsl only inside of @example and friends),
% or `code' (@kbd uses normal tty font always).
@@ -2735,16 +2716,36 @@ end
% Default is `distinct'.
\kbdinputstyle distinct
+% @kbd is like @code, except that if the argument is just one @key command,
+% then @kbd has no effect.
+\def\kbd#1{{\def\look{#1}\expandafter\kbdsub\look??\par}}
+
\def\xkey{\key}
-\def\kbdfoo#1#2#3\par{\def\one{#1}\def\three{#3}\def\threex{??}%
-\ifx\one\xkey\ifx\threex\three \key{#2}%
-\else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi
-\else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi}
+\def\kbdsub#1#2#3\par{%
+ \def\one{#1}\def\three{#3}\def\threex{??}%
+ \ifx\one\xkey\ifx\threex\three \key{#2}%
+ \else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi
+ \else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi
+}
-% For @indicateurl, @env, @command quotes seem unnecessary, so use \code.
-\let\indicateurl=\code
-\let\env=\code
-\let\command=\code
+% definition of @key that produces a lozenge. Doesn't adjust to text size.
+%\setfont\keyrm\rmshape{8}{1000}{OT1}
+%\font\keysy=cmsy9
+%\def\key#1{{\keyrm\textfont2=\keysy \leavevmode\hbox{%
+% \raise0.4pt\hbox{\angleleft}\kern-.08em\vtop{%
+% \vbox{\hrule\kern-0.4pt
+% \hbox{\raise0.4pt\hbox{\vphantom{\angleleft}}#1}}%
+% \kern-0.4pt\hrule}%
+% \kern-.06em\raise0.4pt\hbox{\angleright}}}}
+
+% definition of @key with no lozenge. If the current font is already
+% monospace, don't change it; that way, we respect @kbdinputstyle. But
+% if it isn't monospace, then use \tt.
+%
+\def\key#1{{\setupmarkupstyle{key}%
+ \nohyphenation
+ \ifmonospace\else\tt\fi
+ #1}\null}
% @clicksequence{File @click{} Open ...}
\def\clicksequence#1{\begingroup #1\endgroup}
@@ -2852,6 +2853,9 @@ end
}
}
+% ctrl is no longer a Texinfo command, but leave this definition for fun.
+\def\ctrl #1{{\tt \rawbackslash \hat}#1}
+
% @inlinefmt{FMTNAME,PROCESSED-TEXT} and @inlineraw{FMTNAME,RAW-TEXT}.
% Ignore unless FMTNAME == tex; then it is like @iftex and @tex,
% except specified as a normal braced arg, so no newlines to worry about.
@@ -3142,12 +3146,17 @@ end
% hopefully nobody will notice/care.
\edef\ecsize{\csname\curfontsize ecsize\endcsname}%
\edef\nominalsize{\csname\curfontsize nominalsize\endcsname}%
- \ifx\curfontstyle\bfstylename
- % bold:
- \font\thisecfont = ecb\ifusingit{i}{x}\ecsize \space at \nominalsize
+ \ifmonospace
+ % typewriter:
+ \font\thisecfont = ectt\ecsize \space at \nominalsize
\else
- % regular:
- \font\thisecfont = ec\ifusingit{ti}{rm}\ecsize \space at \nominalsize
+ \ifx\curfontstyle\bfstylename
+ % bold:
+ \font\thisecfont = ecb\ifusingit{i}{x}\ecsize \space at \nominalsize
+ \else
+ % regular:
+ \font\thisecfont = ec\ifusingit{ti}{rm}\ecsize \space at \nominalsize
+ \fi
\fi
\thisecfont
}
@@ -3260,6 +3269,20 @@ end
\finishedtitlepagetrue
}
+% Settings used for typesetting titles: no hyphenation, no indentation,
+% don't worry much about spacing, ragged right. This should be used
+% inside a \vbox, and fonts need to be set appropriately first. Because
+% it is always used for titles, nothing else, we call \rmisbold. \par
+% should be specified before the end of the \vbox, since a vbox is a group.
+%
+\def\raggedtitlesettings{%
+ \rmisbold
+ \hyphenpenalty=10000
+ \parindent=0pt
+ \tolerance=5000
+ \ptexraggedright
+}
+
% Macros to be used within @titlepage:
\let\subtitlerm=\tenrm
@@ -3267,7 +3290,7 @@ end
\parseargdef\title{%
\checkenv\titlepage
- \leftline{\titlefonts\rmisbold #1}
+ \vbox{\titlefonts \raggedtitlesettings #1\par}%
% print a rule at the page bottom also.
\finishedtitlepagefalse
\vskip4pt \hrule height 4pt width \hsize \vskip4pt
@@ -4204,7 +4227,7 @@ end
}
\def\ifsetfail{\doignore{ifset}}
-% @ifclear VAR ... @end ifclear reads the `...' iff VAR has never been
+% @ifclear VAR ... @end executes the `...' iff VAR has never been
% defined with @set, or has been undefined with @clear.
%
% The `\else' inside the `\doifset' parameter is a trick to reuse the
@@ -4215,6 +4238,35 @@ end
\def\ifclear{\parsearg{\doifset{\else \let\next=\ifclearfail}}}
\def\ifclearfail{\doignore{ifclear}}
+% @ifcommandisdefined CMD ... @end executes the `...' if CMD (written
+% without the @) is in fact defined. We can only feasibly check at the
+% TeX level, so something like `mathcode' is going to considered
+% defined even though it is not a Texinfo command.
+%
+\makecond{ifcommanddefined}
+\def\ifcommanddefined{\parsearg{\doifcmddefined{\let\next=\ifcmddefinedfail}}}
+%
+\def\doifcmddefined#1#2{{%
+ \makevalueexpandable
+ \let\next=\empty
+ \expandafter\ifx\csname #2\endcsname\relax
+ #1% If not defined, \let\next as above.
+ \fi
+ \expandafter
+ }\next
+}
+\def\ifcmddefinedfail{\doignore{ifcommanddefined}}
+
+% @ifcommandnotdefined CMD ... handled similar to @ifclear above.
+\makecond{ifcommandnotdefined}
+\def\ifcommandnotdefined{%
+ \parsearg{\doifcmddefined{\else \let\next=\ifcmdnotdefinedfail}}}
+\def\ifcmdnotdefinedfail{\doignore{ifcommandnotdefined}}
+
+% Set the `txicommandconditionals' variable, so documents have a way to
+% test if the @ifcommand...defined conditionals are available.
+\set txicommandconditionals
+
% @dircategory CATEGORY -- specify a category of the dir file
% which this file should belong to. Ignore this in TeX.
\let\dircategory=\comment
@@ -4451,6 +4503,7 @@ end
\definedummyword\guillemetright
\definedummyword\guilsinglleft
\definedummyword\guilsinglright
+ \definedummyword\lbracechar
\definedummyword\leq
\definedummyword\minus
\definedummyword\ogonek
@@ -4463,6 +4516,7 @@ end
\definedummyword\quoteleft
\definedummyword\quoteright
\definedummyword\quotesinglbase
+ \definedummyword\rbracechar
\definedummyword\result
\definedummyword\textdegree
%
@@ -4514,6 +4568,7 @@ end
\definedummyword\t
%
% Commands that take arguments.
+ \definedummyword\abbr
\definedummyword\acronym
\definedummyword\anchor
\definedummyword\cite
@@ -4525,7 +4580,9 @@ end
\definedummyword\emph
\definedummyword\env
\definedummyword\file
+ \definedummyword\image
\definedummyword\indicateurl
+ \definedummyword\inforef
\definedummyword\kbd
\definedummyword\key
\definedummyword\math
@@ -4572,7 +4629,10 @@ end
% content at all. So for index sorting, we map @{ and @} to strings
% starting with |, since that ASCII character is between ASCII { and }.
\def\{{|a}%
+ \def\lbracechar{|a}%
+ %
\def\}{|b}%
+ \def\rbracechar{|b}%
%
% Non-English letters.
\def\AA{AA}%
@@ -5533,14 +5593,6 @@ end
% Define @majorheading, @heading and @subheading
-% NOTE on use of \vbox for chapter headings, section headings, and such:
-% 1) We use \vbox rather than the earlier \line to permit
-% overlong headings to fold.
-% 2) \hyphenpenalty is set to 10000 because hyphenation in a
-% heading is obnoxious; this forbids it.
-% 3) Likewise, headings look best if no \parindent is used, and
-% if justification is not attempted. Hence \raggedright.
-
\def\majorheading{%
{\advance\chapheadingskip by 10pt \chapbreak }%
\parsearg\chapheadingzzz
@@ -5548,10 +5600,8 @@ end
\def\chapheading{\chapbreak \parsearg\chapheadingzzz}
\def\chapheadingzzz#1{%
- {\chapfonts \vbox{\hyphenpenalty=10000\tolerance=5000
- \parindent=0pt\ptexraggedright
- \rmisbold #1\hfill}}%
- \bigskip \par\penalty 200\relax
+ \vbox{\chapfonts \raggedtitlesettings #1\par}%
+ \nobreak\bigskip \nobreak
\suppressfirstparagraphindent
}
@@ -5710,8 +5760,7 @@ end
%
% Typeset the actual heading.
\nobreak % Avoid page breaks at the interline glue.
- \vbox{\hyphenpenalty=10000 \tolerance=5000 \parindent=0pt \ptexraggedright
- \hangindent=\wd0 \centerparametersmaybe
+ \vbox{\raggedtitlesettings \hangindent=\wd0 \centerparametersmaybe
\unhbox0 #1\par}%
}%
\nobreak\bigskip % no page break after a chapter title
@@ -5733,18 +5782,18 @@ end
\def\setchapterstyle #1 {\csname CHAPF#1\endcsname}
%
\def\unnchfopen #1{%
-\chapoddpage {\chapfonts \vbox{\hyphenpenalty=10000\tolerance=5000
- \parindent=0pt\ptexraggedright
- \rmisbold #1\hfill}}\bigskip \par\nobreak
+ \chapoddpage
+ \vbox{\chapfonts \raggedtitlesettings #1\par}%
+ \nobreak\bigskip\nobreak
}
\def\chfopen #1#2{\chapoddpage {\chapfonts
\vbox to 3in{\vfil \hbox to\hsize{\hfil #2} \hbox to\hsize{\hfil #1} \vfil}}%
\par\penalty 5000 %
}
\def\centerchfopen #1{%
-\chapoddpage {\chapfonts \vbox{\hyphenpenalty=10000\tolerance=5000
- \parindent=0pt
- \hfill {\rmisbold #1}\hfill}}\bigskip \par\nobreak
+ \chapoddpage
+ \vbox{\chapfonts \raggedtitlesettings \hfill #1\hfill}%
+ \nobreak\bigskip \nobreak
}
\def\CHAPFopen{%
\global\let\chapmacro=\chfopen
@@ -6510,16 +6559,9 @@ end
\makedispenvdef{quotation}{\quotationstart}
%
\def\quotationstart{%
- {\parskip=0pt \aboveenvbreak}% because \aboveenvbreak inserts \parskip
- \parindent=0pt
- %
- % @cartouche defines \nonarrowing to inhibit narrowing at next level down.
+ \indentedblockstart % same as \indentedblock, but increase right margin too.
\ifx\nonarrowing\relax
- \advance\leftskip by \lispnarrowing
\advance\rightskip by \lispnarrowing
- \exdentamount = \lispnarrowing
- \else
- \let\nonarrowing = \relax
\fi
\parsearg\quotationlabel
}
@@ -6545,6 +6587,32 @@ end
\fi
}
+% @indentedblock is like @quotation, but indents only on the left and
+% has no optional argument.
+%
+\makedispenvdef{indentedblock}{\indentedblockstart}
+%
+\def\indentedblockstart{%
+ {\parskip=0pt \aboveenvbreak}% because \aboveenvbreak inserts \parskip
+ \parindent=0pt
+ %
+ % @cartouche defines \nonarrowing to inhibit narrowing at next level down.
+ \ifx\nonarrowing\relax
+ \advance\leftskip by \lispnarrowing
+ \exdentamount = \lispnarrowing
+ \else
+ \let\nonarrowing = \relax
+ \fi
+}
+
+% Keep a nonzero parskip for the environment, since we're doing normal filling.
+%
+\def\Eindentedblock{%
+ \par
+ {\parskip=0pt \afterenvbreak}%
+}
+\def\Esmallindentedblock{\Eindentedblock}
+
% LaTeX-like @verbatim...@end verbatim and @verb{<char>...<char>}
% If we want to allow any <char> as delimiter,
@@ -7023,7 +7091,10 @@ end
\df \sl \hyphenchar\font=0
%
% On the other hand, if an argument has two dashes (for instance), we
- % want a way to get ttsl. Let's try @var for that.
+ % want a way to get ttsl. We used to recommend @var for that, so
+ % leave the code in, but it's strange for @var to lead to typewriter.
+ % Nowadays we recommend @code, since the difference between a ttsl hyphen
+ % and a tt hyphen is pretty tiny. @code also disables ?` !`.
\def\var##1{{\setupmarkupstyle{var}\ttslanted{##1}}}%
#1%
\sl\hyphenchar\font=45
@@ -7807,7 +7878,7 @@ end
\fi\fi
}
-
+%
% @xref, @pxref, and @ref generate cross-references. For \xrefX, #1 is
% the node name, #2 the name of the Info cross-reference, #3 the printed
% node name, #4 the name of the Info file, #5 the name of the printed
@@ -7817,16 +7888,21 @@ end
\def\xref#1{\putwordSee{} \xrefX[#1,,,,,,,]}
\def\ref#1{\xrefX[#1,,,,,,,]}
%
-\newbox\topbox
+\newbox\toprefbox
\newbox\printedrefnamebox
+\newbox\infofilenamebox
\newbox\printedmanualbox
%
\def\xrefX[#1,#2,#3,#4,#5,#6]{\begingroup
\unsepspaces
%
+ % Get args without leading/trailing spaces.
\def\printedrefname{\ignorespaces #3}%
\setbox\printedrefnamebox = \hbox{\printedrefname\unskip}%
%
+ \def\infofilename{\ignorespaces #4}%
+ \setbox\infofilenamebox = \hbox{\infofilename\unskip}%
+ %
\def\printedmanual{\ignorespaces #5}%
\setbox\printedmanualbox = \hbox{\printedmanual\unskip}%
%
@@ -7861,11 +7937,18 @@ end
\turnoffactive
\makevalueexpandable
% This expands tokens, so do it after making catcode changes, so _
- % etc. don't get their TeX definitions.
+ % etc. don't get their TeX definitions. This ignores all spaces in
+ % #4, including (wrongly) those in the middle of the filename.
\getfilename{#4}%
%
+ % This (wrongly) does not take account of leading or trailing
+ % spaces in #1, which should be ignored.
\edef\pdfxrefdest{#1}%
- \txiescapepdf\pdfxrefdest
+ \ifx\pdfxrefdest\empty
+ \def\pdfxrefdest{Top}% no empty targets
+ \else
+ \txiescapepdf\pdfxrefdest % escape PDF special chars
+ \fi
%
\leavevmode
\startlink attr{/Border [0 0 0]}%
@@ -7898,7 +7981,7 @@ end
\printedrefname
\fi
%
- % if the user also gave the printed manual name (fifth arg), append
+ % If the user also gave the printed manual name (fifth arg), append
% "in MANUALNAME".
\ifdim \wd\printedmanualbox > 0pt
\space \putwordin{} \cite{\printedmanual}%
@@ -7913,32 +7996,20 @@ end
% this is a loss. Therefore, we give the text of the node name
% again, so it is as if TeX is seeing it for the first time.
%
- % Cross-manual reference. Only include the "Section ``foo'' in" if
- % the foo is neither missing or Top. Thus, @xref{,,,foo,The Foo Manual}
- % outputs simply "see The Foo Manual".
\ifdim \wd\printedmanualbox > 0pt
- % What is the 7sp about? The idea is that we also want to omit
- % the Section part if we would be printing "Top", since they are
- % clearly trying to refer to the whole manual. But, this being
- % TeX, we can't easily compare strings while ignoring the possible
- % spaces before and after in the input. By adding the arbitrary
- % 7sp, we make it much less likely that a real node name would
- % happen to have the same width as "Top" (e.g., in a monospaced font).
- % I hope it will never happen in practice.
+ % Cross-manual reference with a printed manual name.
%
- % For the same basic reason, we retypeset the "Top" at every
- % reference, since the current font is indeterminate.
+ \crossmanualxref{\cite{\printedmanual\unskip}}%
+ %
+ \else\ifdim \wd\infofilenamebox > 0pt
+ % Cross-manual reference with only an info filename (arg 4), no
+ % printed manual name (arg 5). This is essentially the same as
+ % the case above; we output the filename, since we have nothing else.
%
- \setbox\topbox = \hbox{Top\kern7sp}%
- \setbox2 = \hbox{\ignorespaces \printedrefname \unskip \kern7sp}%
- \ifdim \wd2 > 7sp
- \ifdim \wd2 = \wd\topbox \else
- \putwordSection{} ``\printedrefname'' \putwordin{}\space
- \fi
- \fi
- \cite{\printedmanual}%
+ \crossmanualxref{\code{\infofilename\unskip}}%
+ %
\else
- % Reference in this manual.
+ % Reference within this manual.
%
% _ (for example) has to be the character _ for the purposes of the
% control sequence corresponding to the node, but it has to expand
@@ -7959,11 +8030,37 @@ end
%
% output the `page 3'.
\turnoffactive \putwordpage\tie\refx{#1-pg}{}%
- \fi
+ \fi\fi
\fi
\endlink
\endgroup}
+% Output a cross-manual xref to #1. Used just above (twice).
+%
+% Only include the text "Section ``foo'' in" if the foo is neither
+% missing or Top. Thus, @xref{,,,foo,The Foo Manual} outputs simply
+% "see The Foo Manual", the idea being to refer to the whole manual.
+%
+% But, this being TeX, we can't easily compare our node name against the
+% string "Top" while ignoring the possible spaces before and after in
+% the input. By adding the arbitrary 7sp below, we make it much less
+% likely that a real node name would have the same width as "Top" (e.g.,
+% in a monospaced font). Hopefully it will never happen in practice.
+%
+% For the same basic reason, we retypeset the "Top" at every
+% reference, since the current font is indeterminate.
+%
+\def\crossmanualxref#1{%
+ \setbox\toprefbox = \hbox{Top\kern7sp}%
+ \setbox2 = \hbox{\ignorespaces \printedrefname \unskip \kern7sp}%
+ \ifdim \wd2 > 7sp % nonempty?
+ \ifdim \wd2 = \wd\toprefbox \else % same as Top?
+ \putwordSection{} ``\printedrefname'' \putwordin{}\space
+ \fi
+ \fi
+ #1%
+}
+
% This macro is called from \xrefX for the `[nodename]' part of xref
% output. It's a separate macro only so it can be changed more easily,
% since square brackets don't work well in some documents. Particularly
diff --git a/doc/version.texi b/doc/version.texi
index b309676..7ad20ef 100644
--- a/doc/version.texi
+++ b/doc/version.texi
@@ -1,4 +1,4 @@
-@set UPDATED 9 July 2013
+@set UPDATED 29 July 2013
@set UPDATED-MONTH July 2013
-@set EDITION 1.3.0-rc4
-@set VERSION 1.3.0-rc4
+@set EDITION 1.3.0-rc5
+@set VERSION 1.3.0-rc5
diff --git a/install-sh b/install-sh
index a9244eb..377bb86 100755
--- a/install-sh
+++ b/install-sh
@@ -1,7 +1,7 @@
#!/bin/sh
# install - install a program, script, or datafile
-scriptversion=2011-01-19.21; # UTC
+scriptversion=2011-11-20.07; # UTC
# This originates from X11R5 (mit/util/scripts/install.sh), which was
# later released in X11R6 (xc/config/util/install.sh) with the
@@ -35,7 +35,7 @@ scriptversion=2011-01-19.21; # UTC
# FSF changes to this file are in the public domain.
#
# Calling this script install-sh is preferred over install.sh, to prevent
-# `make' implicit rules from creating a file called install from it
+# 'make' implicit rules from creating a file called install from it
# when there is no Makefile.
#
# This script is compatible with the BSD install script, but was written
@@ -156,7 +156,7 @@ while test $# -ne 0; do
-s) stripcmd=$stripprog;;
-t) dst_arg=$2
- # Protect names problematic for `test' and other utilities.
+ # Protect names problematic for 'test' and other utilities.
case $dst_arg in
-* | [=\(\)!]) dst_arg=./$dst_arg;;
esac
@@ -190,7 +190,7 @@ if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then
fi
shift # arg
dst_arg=$arg
- # Protect names problematic for `test' and other utilities.
+ # Protect names problematic for 'test' and other utilities.
case $dst_arg in
-* | [=\(\)!]) dst_arg=./$dst_arg;;
esac
@@ -202,7 +202,7 @@ if test $# -eq 0; then
echo "$0: no input file specified." >&2
exit 1
fi
- # It's OK to call `install-sh -d' without argument.
+ # It's OK to call 'install-sh -d' without argument.
# This can happen when creating conditional directories.
exit 0
fi
@@ -240,7 +240,7 @@ fi
for src
do
- # Protect names problematic for `test' and other utilities.
+ # Protect names problematic for 'test' and other utilities.
case $src in
-* | [=\(\)!]) src=./$src;;
esac
@@ -354,7 +354,7 @@ do
if test -z "$dir_arg" || {
# Check for POSIX incompatibilities with -m.
# HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or
- # other-writeable bit of parent directory when it shouldn't.
+ # other-writable bit of parent directory when it shouldn't.
# FreeBSD 6.1 mkdir -m -p sets mode of existing directory.
ls_ld_tmpdir=`ls -ld "$tmpdir"`
case $ls_ld_tmpdir in
diff --git a/ltmain.sh b/ltmain.sh
index 33f642a..16ddbf8 100644
--- a/ltmain.sh
+++ b/ltmain.sh
@@ -70,7 +70,7 @@
# compiler: $LTCC
# compiler flags: $LTCFLAGS
# linker: $LD (gnu? $with_gnu_ld)
-# $progname: (GNU libtool) 2.4.2 Debian-2.4.2-1.1
+# $progname: (GNU libtool) 2.4.2
# automake: $automake_version
# autoconf: $autoconf_version
#
@@ -80,7 +80,7 @@
PROGRAM=libtool
PACKAGE=libtool
-VERSION="2.4.2 Debian-2.4.2-1.1"
+VERSION=2.4.2
TIMESTAMP=""
package_revision=1.3337
@@ -1375,6 +1375,21 @@ func_replace_sysroot ()
func_infer_tag ()
{
$opt_debug
+
+ # FreeBSD-specific: where we install compilers with non-standard names
+ tag_compilers_CC="*cc cc* *gcc gcc* clang"
+ tag_compilers_CXX="*c++ c++* *g++ g++* clang++"
+ base_compiler=`set -- "$@"; echo $1`
+
+ # If $tagname isn't set, then try to infer if the default "CC" tag applies
+ if test -z "$tagname"; then
+ for zp in $tag_compilers_CC; do
+ case $base_compiler in
+ $zp) tagname="CC"; break;;
+ esac
+ done
+ fi
+
if test -n "$available_tags" && test -z "$tagname"; then
CC_quoted=
for arg in $CC; do
@@ -1411,7 +1426,22 @@ func_infer_tag ()
break
;;
esac
- fi
+
+ # FreeBSD-specific: try compilers based on inferred tag
+ if test -z "$tagname"; then
+ eval "tag_compilers=\$tag_compilers_${z}"
+ if test -n "$tag_compilers"; then
+ for zp in $tag_compilers; do
+ case $base_compiler in
+ $zp) tagname=$z; break;;
+ esac
+ done
+ if test -n "$tagname"; then
+ break
+ fi
+ fi
+ fi
+ fi
done
# If $tagname still isn't set, then no tagged configuration
# was found and let the user know that the "--tag" command
@@ -3517,6 +3547,9 @@ static const void *lt_preloaded_setup() {
;;
esac
;;
+ *-*-freebsd*)
+ # FreeBSD doesn't need this...
+ ;;
*)
func_fatal_error "unknown suffix for \`$my_dlsyms'"
;;
@@ -5595,6 +5628,7 @@ func_mode_link ()
esac
;;
esac
+ deplibs="$deplibs $arg"
continue
;;
@@ -6124,10 +6158,7 @@ func_mode_link ()
case $pass in
dlopen) libs="$dlfiles" ;;
dlpreopen) libs="$dlprefiles" ;;
- link)
- libs="$deplibs %DEPLIBS%"
- test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs"
- ;;
+ link) libs="$deplibs %DEPLIBS% $dependency_libs" ;;
esac
fi
if test "$linkmode,$pass" = "lib,dlpreopen"; then
@@ -6170,13 +6201,30 @@ func_mode_link ()
finalize_deplibs="$deplib $finalize_deplibs"
else
func_append compiler_flags " $deplib"
- if test "$linkmode" = lib ; then
- case "$new_inherited_linker_flags " in
- *" $deplib "*) ;;
- * ) func_append new_inherited_linker_flags " $deplib" ;;
- esac
- fi
fi
+
+ case $linkmode in
+ lib)
+ deplibs="$deplib $deplibs"
+ test "$pass" = conv && continue
+ newdependency_libs="$deplib $newdependency_libs"
+ ;;
+ prog)
+ if test "$pass" = conv; then
+ deplibs="$deplib $deplibs"
+ continue
+ fi
+ if test "$pass" = scan; then
+ deplibs="$deplib $deplibs"
+ else
+ compile_deplibs="$deplib $compile_deplibs"
+ finalize_deplibs="$deplib $finalize_deplibs"
+ fi
+ ;;
+ *)
+ ;;
+ esac # linkmode
+
continue
;;
-l*)
@@ -6447,19 +6495,19 @@ func_mode_link ()
# It is a libtool convenience library, so add in its objects.
func_append convenience " $ladir/$objdir/$old_library"
func_append old_convenience " $ladir/$objdir/$old_library"
- tmp_libs=
- for deplib in $dependency_libs; do
- deplibs="$deplib $deplibs"
- if $opt_preserve_dup_deps ; then
- case "$tmp_libs " in
- *" $deplib "*) func_append specialdeplibs " $deplib" ;;
- esac
- fi
- func_append tmp_libs " $deplib"
- done
elif test "$linkmode" != prog && test "$linkmode" != lib; then
func_fatal_error "\`$lib' is not a convenience library"
fi
+ tmp_libs=
+ for deplib in $dependency_libs; do
+ deplibs="$deplib $deplibs"
+ if $opt_preserve_dup_deps ; then
+ case "$tmp_libs " in
+ *" $deplib "*) func_append specialdeplibs " $deplib" ;;
+ esac
+ fi
+ func_append tmp_libs " $deplib"
+ done
continue
fi # $pass = conv
@@ -7352,9 +7400,6 @@ func_mode_link ()
revision="$number_minor"
lt_irix_increment=no
;;
- *)
- func_fatal_configuration "$modename: unknown library version type \`$version_type'"
- ;;
esac
;;
no)
diff --git a/m4/ax_recvmmsg.m4 b/m4/ax_recvmmsg.m4
deleted file mode 100644
index bc7bfe3..0000000
--- a/m4/ax_recvmmsg.m4
+++ /dev/null
@@ -1,96 +0,0 @@
-dnl @synopsis AX_MSG_WAITFORONE
-dnl @summary Test if the libc/kernel have working recvmmsg MSG_WAITFORONE implementation
-dnl @category Misc
-dnl
-dnl We need recvmmsg to support MSG_WAITFORONE. RHEL 6 (and derivates)
-dnl are know for broken implementation
-dnl
-dnl @version 2013-03-12
-dnl @license GPL
-dnl @author Ondřej Surý <ondrej@sury.org> and Marek Vavruša <marek@vavrusa.com>
-
-AC_DEFUN([AX_MSG_WAITFORONE],
-[
- AC_REQUIRE([AC_PROG_CC])
-
- AC_LANG_PUSH([C])
-
- AC_CACHE_CHECK([for recv_mmsg support], [ax_cv_have_msg_waitforone],
- [
- AC_RUN_IFELSE(
- [
- AC_LANG_PROGRAM(
- [[
-#ifndef _GNU_SOURCE
- #define _GNU_SOURCE
-#endif
-#include <sys/types.h>
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
-#include <netinet/ip.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <errno.h>
-#include <signal.h>
-
-volatile int _intr = 0;
-void sighandle(int s) {
- _intr = 1;
-}
- ]],[[
-#ifndef MSG_WAITFORONE
- return 3; /* Not supported. */
-#else
- int port = 35353;
- int fd = socket(AF_INET, SOCK_DGRAM, 0);
- if (fd < 0) return 1;
- struct mmsghdr msgs[2];
- struct iovec iovecs[2];
- char bufs[2][64];
- unsigned i = 0;
- memset(msgs, 0, sizeof(msgs));
- for (i = 0; i < 2; i++) {
- iovecs[i].iov_base = bufs[i];
- iovecs[i].iov_len = 64;
- msgs[i].msg_hdr.msg_iov = &iovecs[i];
- msgs[i].msg_hdr.msg_iovlen = 1;
- }
-
- struct sockaddr_in sa; /* Bind to socket. */
- sa.sin_family = AF_INET;
- sa.sin_addr.s_addr = htonl(INADDR_LOOPBACK);
- sa.sin_port = htons(port); /* Find free port. */
- while (bind(fd, (struct sockaddr *)&sa, sizeof(sa)) == -1) {
- if (errno == EADDRINUSE) sa.sin_port = ++port;
- else break;
- }
-
- int cfd = socket(AF_INET, SOCK_DGRAM, 0); /* Send datagram. */
- char pkt[32] = { '\xdf' };
- sendto(cfd, pkt, sizeof(pkt), 0, (struct sockaddr*)&sa, sizeof(sa));
-
- /* Broken implementation doesn't respect recvmmsg timeout. */
- struct sigaction aset;
- memset(&aset, 0, sizeof(struct sigaction));
- aset.sa_handler = sighandle;
- sigaction(SIGALRM, &aset, NULL);
- alarm(1);
-
- int ret = recvmmsg(fd, msgs, 2, MSG_WAITFORONE, NULL);
- close(cfd);
- close(fd);
- if (ret < 0) { /* Completely failed. */
- return 2;
- }
-
- return _intr; /* OK if not interrupted. */
-#endif
- ]])],
- [ax_cv_have_msg_waitforone=yes],
- [ax_cv_have_msg_waitforone=no],
- [ax_cv_have_msg_waitforone=no])])
-
- AC_LANG_POP([C])
-])
diff --git a/m4/libtool.m4 b/m4/libtool.m4
index 534d1cc..44e0ecf 100644
--- a/m4/libtool.m4
+++ b/m4/libtool.m4
@@ -2512,6 +2512,17 @@ freebsd* | dragonfly*)
esac
;;
+gnu*)
+ version_type=linux # correct to gnu/linux during the next big refactor
+ need_lib_prefix=no
+ need_version=no
+ library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
+ soname_spec='${libname}${release}${shared_ext}$major'
+ shlibpath_var=LD_LIBRARY_PATH
+ shlibpath_overrides_runpath=no
+ hardcode_into_libs=yes
+ ;;
+
haiku*)
version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
@@ -2628,7 +2639,7 @@ linux*oldld* | linux*aout* | linux*coff*)
;;
# This must be glibc/ELF.
-linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
+linux* | k*bsd*-gnu | kopensolaris*-gnu)
version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
@@ -2673,18 +2684,6 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
dynamic_linker='GNU/Linux ld.so'
;;
-netbsdelf*-gnu)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- dynamic_linker='NetBSD ld.elf_so'
- ;;
-
netbsd*)
version_type=sunos
need_lib_prefix=no
@@ -3244,6 +3243,10 @@ freebsd* | dragonfly*)
fi
;;
+gnu*)
+ lt_cv_deplibs_check_method=pass_all
+ ;;
+
haiku*)
lt_cv_deplibs_check_method=pass_all
;;
@@ -3282,11 +3285,11 @@ irix5* | irix6* | nonstopux*)
;;
# This must be glibc/ELF.
-linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
+linux* | k*bsd*-gnu | kopensolaris*-gnu)
lt_cv_deplibs_check_method=pass_all
;;
-netbsd* | netbsdelf*-gnu)
+netbsd*)
if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
else
@@ -4034,7 +4037,7 @@ m4_if([$1], [CXX], [
;;
esac
;;
- linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
case $cc_basename in
KCC*)
# KAI C++ Compiler
@@ -4098,7 +4101,7 @@ m4_if([$1], [CXX], [
;;
esac
;;
- netbsd* | netbsdelf*-gnu)
+ netbsd*)
;;
*qnx* | *nto*)
# QNX uses GNU C++, but need to define -shared option too, otherwise
@@ -4333,7 +4336,7 @@ m4_if([$1], [CXX], [
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
;;
- linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
case $cc_basename in
# old Intel for x86_64 which still supported -KPIC.
ecc*)
@@ -4575,9 +4578,6 @@ m4_if([$1], [CXX], [
;;
esac
;;
- linux* | k*bsd*-gnu | gnu*)
- _LT_TAGVAR(link_all_deplibs, $1)=no
- ;;
*)
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
;;
@@ -4640,9 +4640,6 @@ dnl Note also adjust exclude_expsyms for C++ above.
openbsd*)
with_gnu_ld=no
;;
- linux* | k*bsd*-gnu | gnu*)
- _LT_TAGVAR(link_all_deplibs, $1)=no
- ;;
esac
_LT_TAGVAR(ld_shlibs, $1)=yes
@@ -4864,7 +4861,7 @@ _LT_EOF
fi
;;
- netbsd* | netbsdelf*-gnu)
+ netbsd*)
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
wlarc=
@@ -5041,7 +5038,6 @@ _LT_EOF
if test "$aix_use_runtimelinking" = yes; then
shared_flag="$shared_flag "'${wl}-G'
fi
- _LT_TAGVAR(link_all_deplibs, $1)=no
else
# not using gcc
if test "$host_cpu" = ia64; then
@@ -5346,7 +5342,7 @@ _LT_EOF
_LT_TAGVAR(link_all_deplibs, $1)=yes
;;
- netbsd* | netbsdelf*-gnu)
+ netbsd*)
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
else
@@ -6226,6 +6222,9 @@ if test "$_lt_caught_CXX_error" != yes; then
_LT_TAGVAR(ld_shlibs, $1)=yes
;;
+ gnu*)
+ ;;
+
haiku*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(link_all_deplibs, $1)=yes
@@ -6387,7 +6386,7 @@ if test "$_lt_caught_CXX_error" != yes; then
_LT_TAGVAR(inherit_rpath, $1)=yes
;;
- linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
+ linux* | k*bsd*-gnu | kopensolaris*-gnu)
case $cc_basename in
KCC*)
# Kuck and Associates, Inc. (KAI) C++ Compiler
diff --git a/man/Makefile.in b/man/Makefile.in
index 67abfaa..6a193fb 100644
--- a/man/Makefile.in
+++ b/man/Makefile.in
@@ -1,9 +1,8 @@
-# Makefile.in generated by automake 1.11.6 from Makefile.am.
+# Makefile.in generated by automake 1.12.6 from Makefile.am.
# @configure_input@
-# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
-# Foundation, Inc.
+# Copyright (C) 1994-2012 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.
@@ -59,10 +58,10 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_compile_flag.m4 \
$(top_srcdir)/m4/ax_ext.m4 \
$(top_srcdir)/m4/ax_gcc_x86_cpuid.m4 \
- $(top_srcdir)/m4/ax_recvmmsg.m4 $(top_srcdir)/m4/libtool.m4 \
- $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
- $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
- $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
+ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
+ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/visibility.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
@@ -70,12 +69,18 @@ CONFIG_HEADER = $(top_builddir)/src/config.h
CONFIG_CLEAN_FILES = khost.1 knotc.8 knotd.8 kdig.1 knsupdate.1 \
knot.conf.5
CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
AM_V_GEN = $(am__v_GEN_@AM_V@)
am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
-am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
AM_V_at = $(am__v_at_@AM_V@)
am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
+am__v_at_1 =
SOURCES =
DIST_SOURCES =
am__can_run_installinfo = \
@@ -441,6 +446,8 @@ TAGS:
ctags: CTAGS
CTAGS:
+cscope cscopelist:
+
distdir: $(DISTFILES)
@list='$(MANS)'; if test -n "$$list"; then \
@@ -449,10 +456,10 @@ distdir: $(DISTFILES)
if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \
if test -n "$$list" && \
grep 'ab help2man is required to generate this page' $$list >/dev/null; then \
- echo "error: found man pages containing the \`missing help2man' replacement text:" >&2; \
+ echo "error: found man pages containing the 'missing help2man' replacement text:" >&2; \
grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/ /' >&2; \
echo " to fix them, install help2man, remove and regenerate the man pages;" >&2; \
- echo " typically \`make maintainer-clean' will remove them" >&2; \
+ echo " typically 'make maintainer-clean' will remove them" >&2; \
exit 1; \
else :; fi; \
else :; fi
diff --git a/man/kdig.1 b/man/kdig.1
index 53b0779..840b350 100644
--- a/man/kdig.1
+++ b/man/kdig.1
@@ -1,4 +1,4 @@
-.TH "kdig" "1" "15 July 2013" "CZ.NIC Labs" "Knot DNS, version 1.3.0-rc4"
+.TH "kdig" "1" "29 July 2013" "CZ.NIC Labs" "Knot DNS, version 1.3.0-rc5"
.SH NAME
.TP 5
.B kdig
diff --git a/man/khost.1 b/man/khost.1
index 9d4a2c4..a3d0728 100644
--- a/man/khost.1
+++ b/man/khost.1
@@ -1,4 +1,4 @@
-.TH "khost" "1" "15 July 2013" "CZ.NIC Labs" "Knot DNS, version 1.3.0-rc4"
+.TH "khost" "1" "29 July 2013" "CZ.NIC Labs" "Knot DNS, version 1.3.0-rc5"
.SH NAME
.TP 6
.B khost
diff --git a/man/knot.conf.5 b/man/knot.conf.5
index de5ce64..02db6f3 100644
--- a/man/knot.conf.5
+++ b/man/knot.conf.5
@@ -1,4 +1,4 @@
-.TH "knot.conf" "5" "15 July 2013" "CZ.NIC Labs" "Knot DNS, version 1.3.0-rc4"
+.TH "knot.conf" "5" "29 July 2013" "CZ.NIC Labs" "Knot DNS, version 1.3.0-rc5"
.SH "NAME"
.LP
.B knot.conf
@@ -34,12 +34,12 @@ serves as an example of the configuration for knotc(8) and knotd(8).
# Or hexstring 0x01ab00
nsid "myserver0";
- # Working directory of the server
- # Used to store compiled zones and PID file
- # default: ${sharedstatedir}/knot, configured with --with-storage
+ # This is a default directory to place slave zone files, journals etc.
+ # default: ${localstatedir}/lib/knot, configured with --with-storage
storage "/var/lib/knot";
# Directory for storing run-time data
+ # e.g. PID file and control sockets
# default: ${localstatedir}/run/knot, configured with --with-rundir
rundir "/var/run/knot";
@@ -94,8 +94,8 @@ serves as an example of the configuration for knotc(8) and knotd(8).
# Rate limit SLIP
# Each Nth blocked response will be sent as truncated, this is a way to allow
# legitimate requests to get a chance to reconnect using TCP
- # Default: 2
- rate-limit-slip 2;
+ # Default: 1
+ rate-limit-slip 1;
}
# Includes can be placed anywhere at any level in the configuration file. The
diff --git a/man/knot.conf.5.in b/man/knot.conf.5.in
index 2ccc767..7f85bba 100644
--- a/man/knot.conf.5.in
+++ b/man/knot.conf.5.in
@@ -34,12 +34,12 @@ serves as an example of the configuration for knotc(8) and knotd(8).
# Or hexstring 0x01ab00
nsid "myserver0";
- # Working directory of the server
- # Used to store compiled zones and PID file
- # default: ${sharedstatedir}/knot, configured with --with-storage
+ # This is a default directory to place slave zone files, journals etc.
+ # default: ${localstatedir}/lib/knot, configured with --with-storage
storage "/var/lib/knot";
# Directory for storing run-time data
+ # e.g. PID file and control sockets
# default: ${localstatedir}/run/knot, configured with --with-rundir
rundir "/var/run/knot";
@@ -94,8 +94,8 @@ serves as an example of the configuration for knotc(8) and knotd(8).
# Rate limit SLIP
# Each Nth blocked response will be sent as truncated, this is a way to allow
# legitimate requests to get a chance to reconnect using TCP
- # Default: 2
- rate-limit-slip 2;
+ # Default: 1
+ rate-limit-slip 1;
}
# Includes can be placed anywhere at any level in the configuration file. The
diff --git a/man/knotc.8 b/man/knotc.8
index 3d5c398..b50afbf 100644
--- a/man/knotc.8
+++ b/man/knotc.8
@@ -1,4 +1,4 @@
-.TH knotc "8" "15 July 2013" "CZ.NIC Labs" "Knot DNS, version 1.3.0-rc4"
+.TH knotc "8" "29 July 2013" "CZ.NIC Labs" "Knot DNS, version 1.3.0-rc5"
.SH NAME
.B knotc
\- Knot DNS control utility
@@ -29,9 +29,6 @@ Verbose mode \- additional runtime information.
\fB\-V\fR, \fB\-\-version\fR
Print knot server version.
.TP
-\fB\-w\fR, \fB\-\-wait\fR
-Wait for the server to finish stop operation.
-.TP
\fB\-i\fR, \fB\-\-interactive\fR
Interactive mode (do not daemonize).
.TP
diff --git a/man/knotc.8.in b/man/knotc.8.in
index 343fd02..9717358 100644
--- a/man/knotc.8.in
+++ b/man/knotc.8.in
@@ -29,9 +29,6 @@ Verbose mode \- additional runtime information.
\fB\-V\fR, \fB\-\-version\fR
Print knot server version.
.TP
-\fB\-w\fR, \fB\-\-wait\fR
-Wait for the server to finish stop operation.
-.TP
\fB\-i\fR, \fB\-\-interactive\fR
Interactive mode (do not daemonize).
.TP
diff --git a/man/knotd.8 b/man/knotd.8
index 59ff8b5..105974a 100644
--- a/man/knotd.8
+++ b/man/knotd.8
@@ -1,4 +1,4 @@
-.TH "knotd" "8" "15 July 2013" "CZ.NIC Labs" "Knot DNS, version 1.3.0-rc4"
+.TH "knotd" "8" "29 July 2013" "CZ.NIC Labs" "Knot DNS, version 1.3.0-rc5"
.SH NAME
.B knotd
\- Knot DNS daemon
diff --git a/man/knsupdate.1 b/man/knsupdate.1
index c402b31..1c90320 100644
--- a/man/knsupdate.1
+++ b/man/knsupdate.1
@@ -1,4 +1,4 @@
-.TH "knsupdate" "1" "15 July 2013" "CZ.NIC Labs" "Knot DNS, version 1.3.0-rc4"
+.TH "knsupdate" "1" "29 July 2013" "CZ.NIC Labs" "Knot DNS, version 1.3.0-rc5"
.SH NAME
.TP 10
.B knsupdate
diff --git a/missing b/missing
index 86a8fc3..9a55648 100755
--- a/missing
+++ b/missing
@@ -1,10 +1,9 @@
#! /bin/sh
# Common stub for a few missing GNU programs while installing.
-scriptversion=2012-01-06.13; # UTC
+scriptversion=2012-01-06.18; # UTC
-# Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006,
-# 2008, 2009, 2010, 2011, 2012 Free Software Foundation, Inc.
+# Copyright (C) 1996-2012 Free Software Foundation, Inc.
# Originally by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
# This program is free software; you can redistribute it and/or modify
@@ -26,7 +25,7 @@ scriptversion=2012-01-06.13; # UTC
# the same distribution terms that you use for the rest of that program.
if test $# -eq 0; then
- echo 1>&2 "Try \`$0 --help' for more information"
+ echo 1>&2 "Try '$0 --help' for more information"
exit 1
fi
@@ -34,7 +33,7 @@ run=:
sed_output='s/.* --output[ =]\([^ ]*\).*/\1/p'
sed_minuso='s/.* -o \([^ ]*\).*/\1/p'
-# In the cases where this matters, `missing' is being run in the
+# In the cases where this matters, 'missing' is being run in the
# srcdir already.
if test -f configure.ac; then
configure_ac=configure.ac
@@ -65,7 +64,7 @@ case $1 in
echo "\
$0 [OPTION]... PROGRAM [ARGUMENT]...
-Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an
+Handle 'PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an
error status if there is no known handling for PROGRAM.
Options:
@@ -74,20 +73,20 @@ Options:
--run try to run the given command, and emulate it if it fails
Supported PROGRAM values:
- aclocal touch file \`aclocal.m4'
- autoconf touch file \`configure'
- autoheader touch file \`config.h.in'
+ aclocal touch file 'aclocal.m4'
+ autoconf touch file 'configure'
+ autoheader touch file 'config.h.in'
autom4te touch the output file, or create a stub one
- automake touch all \`Makefile.in' files
- bison create \`y.tab.[ch]', if possible, from existing .[ch]
- flex create \`lex.yy.c', if possible, from existing .c
+ automake touch all 'Makefile.in' files
+ bison create 'y.tab.[ch]', if possible, from existing .[ch]
+ flex create 'lex.yy.c', if possible, from existing .c
help2man touch the output file
- lex create \`lex.yy.c', if possible, from existing .c
+ lex create 'lex.yy.c', if possible, from existing .c
makeinfo touch the output file
- yacc create \`y.tab.[ch]', if possible, from existing .[ch]
+ yacc create 'y.tab.[ch]', if possible, from existing .[ch]
-Version suffixes to PROGRAM as well as the prefixes \`gnu-', \`gnu', and
-\`g' are ignored when checking the name.
+Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and
+'g' are ignored when checking the name.
Send bug reports to <bug-automake@gnu.org>."
exit $?
@@ -99,8 +98,8 @@ Send bug reports to <bug-automake@gnu.org>."
;;
-*)
- echo 1>&2 "$0: Unknown \`$1' option"
- echo 1>&2 "Try \`$0 --help' for more information"
+ echo 1>&2 "$0: Unknown '$1' option"
+ echo 1>&2 "Try '$0 --help' for more information"
exit 1
;;
@@ -127,7 +126,7 @@ case $1 in
exit 1
elif test "x$2" = "x--version" || test "x$2" = "x--help"; then
# Could not run --version or --help. This is probably someone
- # running `$TOOL --version' or `$TOOL --help' to check whether
+ # running '$TOOL --version' or '$TOOL --help' to check whether
# $TOOL exists and not knowing $TOOL uses missing.
exit 1
fi
@@ -139,27 +138,27 @@ esac
case $program in
aclocal*)
echo 1>&2 "\
-WARNING: \`$1' is $msg. You should only need it if
- you modified \`acinclude.m4' or \`${configure_ac}'. You might want
- to install the \`Automake' and \`Perl' packages. Grab them from
+WARNING: '$1' is $msg. You should only need it if
+ you modified 'acinclude.m4' or '${configure_ac}'. You might want
+ to install the Automake and Perl packages. Grab them from
any GNU archive site."
touch aclocal.m4
;;
autoconf*)
echo 1>&2 "\
-WARNING: \`$1' is $msg. You should only need it if
- you modified \`${configure_ac}'. You might want to install the
- \`Autoconf' and \`GNU m4' packages. Grab them from any GNU
+WARNING: '$1' is $msg. You should only need it if
+ you modified '${configure_ac}'. You might want to install the
+ Autoconf and GNU m4 packages. Grab them from any GNU
archive site."
touch configure
;;
autoheader*)
echo 1>&2 "\
-WARNING: \`$1' is $msg. You should only need it if
- you modified \`acconfig.h' or \`${configure_ac}'. You might want
- to install the \`Autoconf' and \`GNU m4' packages. Grab them
+WARNING: '$1' is $msg. You should only need it if
+ you modified 'acconfig.h' or '${configure_ac}'. You might want
+ to install the Autoconf and GNU m4 packages. Grab them
from any GNU archive site."
files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}`
test -z "$files" && files="config.h"
@@ -176,9 +175,9 @@ WARNING: \`$1' is $msg. You should only need it if
automake*)
echo 1>&2 "\
-WARNING: \`$1' is $msg. You should only need it if
- you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'.
- You might want to install the \`Automake' and \`Perl' packages.
+WARNING: '$1' is $msg. You should only need it if
+ you modified 'Makefile.am', 'acinclude.m4' or '${configure_ac}'.
+ You might want to install the Automake and Perl packages.
Grab them from any GNU archive site."
find . -type f -name Makefile.am -print |
sed 's/\.am$/.in/' |
@@ -187,10 +186,10 @@ WARNING: \`$1' is $msg. You should only need it if
autom4te*)
echo 1>&2 "\
-WARNING: \`$1' is needed, but is $msg.
+WARNING: '$1' is needed, but is $msg.
You might have modified some files without having the
proper tools for further handling them.
- You can get \`$1' as part of \`Autoconf' from any GNU
+ You can get '$1' as part of Autoconf from any GNU
archive site."
file=`echo "$*" | sed -n "$sed_output"`
@@ -210,10 +209,10 @@ WARNING: \`$1' is needed, but is $msg.
bison*|yacc*)
echo 1>&2 "\
-WARNING: \`$1' $msg. You should only need it if
- you modified a \`.y' file. You may need the \`Bison' package
+WARNING: '$1' $msg. You should only need it if
+ you modified a '.y' file. You may need the Bison package
in order for those modifications to take effect. You can get
- \`Bison' from any GNU archive site."
+ Bison from any GNU archive site."
rm -f y.tab.c y.tab.h
if test $# -ne 1; then
eval LASTARG=\${$#}
@@ -240,10 +239,10 @@ WARNING: \`$1' $msg. You should only need it if
lex*|flex*)
echo 1>&2 "\
-WARNING: \`$1' is $msg. You should only need it if
- you modified a \`.l' file. You may need the \`Flex' package
+WARNING: '$1' is $msg. You should only need it if
+ you modified a '.l' file. You may need the Flex package
in order for those modifications to take effect. You can get
- \`Flex' from any GNU archive site."
+ Flex from any GNU archive site."
rm -f lex.yy.c
if test $# -ne 1; then
eval LASTARG=\${$#}
@@ -263,10 +262,10 @@ WARNING: \`$1' is $msg. You should only need it if
help2man*)
echo 1>&2 "\
-WARNING: \`$1' is $msg. You should only need it if
+WARNING: '$1' is $msg. You should only need it if
you modified a dependency of a manual page. You may need the
- \`Help2man' package in order for those modifications to take
- effect. You can get \`Help2man' from any GNU archive site."
+ Help2man package in order for those modifications to take
+ effect. You can get Help2man from any GNU archive site."
file=`echo "$*" | sed -n "$sed_output"`
test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"`
@@ -281,12 +280,12 @@ WARNING: \`$1' is $msg. You should only need it if
makeinfo*)
echo 1>&2 "\
-WARNING: \`$1' is $msg. You should only need it if
- you modified a \`.texi' or \`.texinfo' file, or any other file
+WARNING: '$1' is $msg. You should only need it if
+ you modified a '.texi' or '.texinfo' file, or any other file
indirectly affecting the aspect of the manual. The spurious
- call might also be the consequence of using a buggy \`make' (AIX,
- DU, IRIX). You might want to install the \`Texinfo' package or
- the \`GNU make' package. Grab either from any GNU archive site."
+ call might also be the consequence of using a buggy 'make' (AIX,
+ DU, IRIX). You might want to install the Texinfo package or
+ the GNU make package. Grab either from any GNU archive site."
# The file to touch is that specified with -o ...
file=`echo "$*" | sed -n "$sed_output"`
test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"`
@@ -310,12 +309,12 @@ WARNING: \`$1' is $msg. You should only need it if
*)
echo 1>&2 "\
-WARNING: \`$1' is needed, and is $msg.
+WARNING: '$1' is needed, and is $msg.
You might have modified some files without having the
- proper tools for further handling them. Check the \`README' file,
+ proper tools for further handling them. Check the 'README' file,
it often tells you about the needed prerequisites for installing
this package. You may also peek at any GNU archive site, in case
- some other package would contain this missing \`$1' program."
+ some other package would contain this missing '$1' program."
exit 1
;;
esac
diff --git a/samples/Makefile.in b/samples/Makefile.in
index e18846e..2e522cf 100644
--- a/samples/Makefile.in
+++ b/samples/Makefile.in
@@ -1,9 +1,8 @@
-# Makefile.in generated by automake 1.11.6 from Makefile.am.
+# Makefile.in generated by automake 1.12.6 from Makefile.am.
# @configure_input@
-# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
-# Foundation, Inc.
+# Copyright (C) 1994-2012 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.
@@ -56,22 +55,28 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_compile_flag.m4 \
$(top_srcdir)/m4/ax_ext.m4 \
$(top_srcdir)/m4/ax_gcc_x86_cpuid.m4 \
- $(top_srcdir)/m4/ax_recvmmsg.m4 $(top_srcdir)/m4/libtool.m4 \
- $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
- $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
- $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
+ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
+ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/visibility.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/src/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
AM_V_GEN = $(am__v_GEN_@AM_V@)
am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
-am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
AM_V_at = $(am__v_at_@AM_V@)
am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
+am__v_at_1 =
SOURCES =
DIST_SOURCES =
am__can_run_installinfo = \
@@ -271,6 +276,8 @@ TAGS:
ctags: CTAGS
CTAGS:
+cscope cscopelist:
+
distdir: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
diff --git a/samples/knot.full.conf b/samples/knot.full.conf
index 49edf13..815038a 100644
--- a/samples/knot.full.conf
+++ b/samples/knot.full.conf
@@ -88,8 +88,8 @@ system {
# Rate limit SLIP
# Each Nth blocked response will be sent as truncated, this is a way to allow
# legitimate requests to get a chance to reconnect using TCP
- # Default: 2
- rate-limit-slip 2;
+ # Default: 1
+ rate-limit-slip 1;
}
# Includes can be placed anywhere at any level in the configuration file. The
@@ -183,11 +183,11 @@ groups {
# Section 'control' specifies on which interface to listen for RC commands
control {
- # Specifies interface, syntax is exactly the same as in 'interfaces' section
# Default: $(run_dir)/knot.sock
listen-on "knot.sock";
# As an alternative, you can use an IPv4/v6 address and port
+ # Same syntax as for 'interfaces' items
# listen-on { address 127.0.0.1@5533; }
# Specifies ACL list for remote control
diff --git a/samples/knot.sample.conf.in b/samples/knot.sample.conf.in
index a8021c4..5d04c92 100644
--- a/samples/knot.sample.conf.in
+++ b/samples/knot.sample.conf.in
@@ -35,11 +35,11 @@ interfaces {
}
control {
- # Specifies interface, syntax is exactly the same as in 'interfaces' section
# Default: knot.sock (relative to rundir)
listen-on "knot.sock";
# As an alternative, you can use an IPv4/v6 address and port
+ # Same syntax as for 'interfaces' items
# listen-on { address 127.0.0.1@5533; }
# Specifies ACL list for remote control
diff --git a/src/Makefile.in b/src/Makefile.in
index b6494fd..16f757f 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -1,9 +1,8 @@
-# Makefile.in generated by automake 1.11.6 from Makefile.am.
+# Makefile.in generated by automake 1.12.6 from Makefile.am.
# @configure_input@
-# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
-# Foundation, Inc.
+# Copyright (C) 1994-2012 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.
@@ -59,17 +58,18 @@ noinst_PROGRAMS = zscanner-tool$(EXEEXT)
@HAVE_RAGEL_TRUE@am__append_2 = zscanner/scanner.c
subdir = src
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
- $(srcdir)/config.h.in knot/conf/libknotd_la-cf-lex.c \
+ $(srcdir)/config.h.in $(top_srcdir)/depcomp \
+ $(top_srcdir)/ylwrap knot/conf/libknotd_la-cf-lex.c \
knot/conf/libknotd_la-cf-parse.c \
knot/conf/libknotd_la-cf-parse.h
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_compile_flag.m4 \
$(top_srcdir)/m4/ax_ext.m4 \
$(top_srcdir)/m4/ax_gcc_x86_cpuid.m4 \
- $(top_srcdir)/m4/ax_recvmmsg.m4 $(top_srcdir)/m4/libtool.m4 \
- $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
- $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
- $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
+ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
+ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/visibility.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
@@ -97,6 +97,7 @@ libknot_la_OBJECTS = $(am_libknot_la_OBJECTS)
AM_V_lt = $(am__v_lt_@AM_V@)
am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
am__v_lt_0 = --silent
+am__v_lt_1 =
libknotd_la_DEPENDENCIES = libknot.la libknots.la @LIBOBJS@
am_libknotd_la_OBJECTS = knot/stat/gatherer.lo knot/stat/stat.lo \
knot/conf/libknotd_la-cf-lex.lo \
@@ -165,6 +166,18 @@ am_zscanner_tool_OBJECTS = zscanner/test/zscanner-tool.$(OBJEXT) \
zscanner_tool_OBJECTS = $(am_zscanner_tool_OBJECTS)
zscanner_tool_DEPENDENCIES = libknots.la libknot.la libknotd.la \
libzscanner.la @LIBOBJS@
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_@AM_V@)
+am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
+AM_V_at = $(am__v_at_@AM_V@)
+am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 =
DEFAULT_INCLUDES = -I.@am__isrc@
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
@@ -177,33 +190,33 @@ LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
$(AM_CFLAGS) $(CFLAGS)
AM_V_CC = $(am__v_CC_@AM_V@)
am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
-am__v_CC_0 = @echo " CC " $@;
-AM_V_at = $(am__v_at_@AM_V@)
-am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
-am__v_at_0 = @
+am__v_CC_0 = @echo " CC " $@;
+am__v_CC_1 =
CCLD = $(CC)
LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
$(AM_LDFLAGS) $(LDFLAGS) -o $@
AM_V_CCLD = $(am__v_CCLD_@AM_V@)
am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
-am__v_CCLD_0 = @echo " CCLD " $@;
+am__v_CCLD_0 = @echo " CCLD " $@;
+am__v_CCLD_1 =
LEXCOMPILE = $(LEX) $(AM_LFLAGS) $(LFLAGS)
LTLEXCOMPILE = $(LIBTOOL) $(AM_V_lt) $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=compile $(LEX) $(AM_LFLAGS) $(LFLAGS)
AM_V_LEX = $(am__v_LEX_@AM_V@)
am__v_LEX_ = $(am__v_LEX_@AM_DEFAULT_V@)
-am__v_LEX_0 = @echo " LEX " $@;
+am__v_LEX_0 = @echo " LEX " $@;
+am__v_LEX_1 =
YLWRAP = $(top_srcdir)/ylwrap
+am__yacc_c2h = sed -e s/cc$$/hh/ -e s/cpp$$/hpp/ -e s/cxx$$/hxx/ \
+ -e s/c++$$/h++/ -e s/c$$/h/
YACCCOMPILE = $(YACC) $(AM_YFLAGS) $(YFLAGS)
LTYACCCOMPILE = $(LIBTOOL) $(AM_V_lt) $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=compile $(YACC) $(AM_YFLAGS) $(YFLAGS)
AM_V_YACC = $(am__v_YACC_@AM_V@)
am__v_YACC_ = $(am__v_YACC_@AM_DEFAULT_V@)
-am__v_YACC_0 = @echo " YACC " $@;
-AM_V_GEN = $(am__v_GEN_@AM_V@)
-am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
-am__v_GEN_0 = @echo " GEN " $@;
+am__v_YACC_0 = @echo " YACC " $@;
+am__v_YACC_1 =
SOURCES = $(libknot_la_SOURCES) $(libknotd_la_SOURCES) \
$(libknots_la_SOURCES) $(libzscanner_la_SOURCES) \
$(kdig_SOURCES) $(khost_SOURCES) $(knotc_SOURCES) \
@@ -738,12 +751,14 @@ distclean-hdr:
clean-noinstLTLIBRARIES:
-test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES)
- @list='$(noinst_LTLIBRARIES)'; for p in $$list; do \
- dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \
- test "$$dir" != "$$p" || dir=.; \
- echo "rm -f \"$${dir}/so_locations\""; \
- rm -f "$${dir}/so_locations"; \
- done
+ @list='$(noinst_LTLIBRARIES)'; \
+ locs=`for p in $$list; do echo $$p; done | \
+ sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
+ sort -u`; \
+ test -z "$$locs" || { \
+ echo rm -f $${locs}; \
+ rm -f $${locs}; \
+ }
libknot/$(am__dirstamp):
@$(MKDIR_P) libknot
@: > libknot/$(am__dirstamp)
@@ -1251,191 +1266,46 @@ zscanner-tool$(EXEEXT): $(zscanner_tool_OBJECTS) $(zscanner_tool_DEPENDENCIES) $
mostlyclean-compile:
-rm -f *.$(OBJEXT)
- -rm -f common/acl.$(OBJEXT)
- -rm -f common/acl.lo
- -rm -f common/base32hex.$(OBJEXT)
- -rm -f common/base32hex.lo
- -rm -f common/base64.$(OBJEXT)
- -rm -f common/base64.lo
- -rm -f common/dSFMT.$(OBJEXT)
- -rm -f common/dSFMT.lo
- -rm -f common/descriptor.$(OBJEXT)
- -rm -f common/descriptor.lo
- -rm -f common/errcode.$(OBJEXT)
- -rm -f common/errcode.lo
- -rm -f common/errors.$(OBJEXT)
- -rm -f common/errors.lo
- -rm -f common/evqueue.$(OBJEXT)
- -rm -f common/evqueue.lo
- -rm -f common/evsched.$(OBJEXT)
- -rm -f common/evsched.lo
- -rm -f common/fdset.$(OBJEXT)
- -rm -f common/fdset.lo
- -rm -f common/getline.$(OBJEXT)
- -rm -f common/getline.lo
- -rm -f common/hattrie/ahtable.$(OBJEXT)
- -rm -f common/hattrie/ahtable.lo
- -rm -f common/hattrie/hat-trie.$(OBJEXT)
- -rm -f common/hattrie/hat-trie.lo
- -rm -f common/hattrie/murmurhash3.$(OBJEXT)
- -rm -f common/hattrie/murmurhash3.lo
- -rm -f common/heap.$(OBJEXT)
- -rm -f common/heap.lo
- -rm -f common/libtap/tap.$(OBJEXT)
- -rm -f common/libtap/tap.lo
- -rm -f common/lists.$(OBJEXT)
- -rm -f common/lists.lo
- -rm -f common/log.$(OBJEXT)
- -rm -f common/log.lo
- -rm -f common/mempattern.$(OBJEXT)
- -rm -f common/mempattern.lo
- -rm -f common/mempool.$(OBJEXT)
- -rm -f common/mempool.lo
- -rm -f common/print.$(OBJEXT)
- -rm -f common/print.lo
- -rm -f common/prng.$(OBJEXT)
- -rm -f common/prng.lo
- -rm -f common/ref.$(OBJEXT)
- -rm -f common/ref.lo
- -rm -f common/skip-list.$(OBJEXT)
- -rm -f common/skip-list.lo
- -rm -f common/slab/slab.$(OBJEXT)
- -rm -f common/slab/slab.lo
- -rm -f common/sockaddr.$(OBJEXT)
- -rm -f common/sockaddr.lo
- -rm -f knot/conf/conf.$(OBJEXT)
- -rm -f knot/conf/conf.lo
- -rm -f knot/conf/extra.$(OBJEXT)
- -rm -f knot/conf/extra.lo
- -rm -f knot/conf/includes.$(OBJEXT)
- -rm -f knot/conf/includes.lo
- -rm -f knot/conf/libknotd_la-cf-lex.$(OBJEXT)
- -rm -f knot/conf/libknotd_la-cf-lex.lo
- -rm -f knot/conf/libknotd_la-cf-parse.$(OBJEXT)
- -rm -f knot/conf/libknotd_la-cf-parse.lo
- -rm -f knot/conf/logconf.$(OBJEXT)
- -rm -f knot/conf/logconf.lo
- -rm -f knot/ctl/knotc_main.$(OBJEXT)
- -rm -f knot/ctl/process.$(OBJEXT)
- -rm -f knot/ctl/process.lo
- -rm -f knot/ctl/remote.$(OBJEXT)
- -rm -f knot/ctl/remote.lo
- -rm -f knot/main.$(OBJEXT)
- -rm -f knot/server/dthreads.$(OBJEXT)
- -rm -f knot/server/dthreads.lo
- -rm -f knot/server/journal.$(OBJEXT)
- -rm -f knot/server/journal.lo
- -rm -f knot/server/notify.$(OBJEXT)
- -rm -f knot/server/notify.lo
- -rm -f knot/server/rrl.$(OBJEXT)
- -rm -f knot/server/rrl.lo
- -rm -f knot/server/server.$(OBJEXT)
- -rm -f knot/server/server.lo
- -rm -f knot/server/socket.$(OBJEXT)
- -rm -f knot/server/socket.lo
- -rm -f knot/server/tcp-handler.$(OBJEXT)
- -rm -f knot/server/tcp-handler.lo
- -rm -f knot/server/udp-handler.$(OBJEXT)
- -rm -f knot/server/udp-handler.lo
- -rm -f knot/server/xfr-handler.$(OBJEXT)
- -rm -f knot/server/xfr-handler.lo
- -rm -f knot/server/zones.$(OBJEXT)
- -rm -f knot/server/zones.lo
- -rm -f knot/stat/gatherer.$(OBJEXT)
- -rm -f knot/stat/gatherer.lo
- -rm -f knot/stat/stat.$(OBJEXT)
- -rm -f knot/stat/stat.lo
- -rm -f knot/zone/estimator.$(OBJEXT)
- -rm -f knot/zone/estimator.lo
- -rm -f knot/zone/semantic-check.$(OBJEXT)
- -rm -f knot/zone/semantic-check.lo
- -rm -f knot/zone/zone-dump.$(OBJEXT)
- -rm -f knot/zone/zone-dump.lo
- -rm -f knot/zone/zone-load.$(OBJEXT)
- -rm -f knot/zone/zone-load.lo
- -rm -f libknot/binary.$(OBJEXT)
- -rm -f libknot/binary.lo
- -rm -f libknot/consts.$(OBJEXT)
- -rm -f libknot/consts.lo
- -rm -f libknot/dname.$(OBJEXT)
- -rm -f libknot/dname.lo
- -rm -f libknot/edns.$(OBJEXT)
- -rm -f libknot/edns.lo
- -rm -f libknot/nameserver/chaos.$(OBJEXT)
- -rm -f libknot/nameserver/chaos.lo
- -rm -f libknot/nameserver/name-server.$(OBJEXT)
- -rm -f libknot/nameserver/name-server.lo
- -rm -f libknot/nsec3.$(OBJEXT)
- -rm -f libknot/nsec3.lo
- -rm -f libknot/packet/packet.$(OBJEXT)
- -rm -f libknot/packet/packet.lo
- -rm -f libknot/packet/query.$(OBJEXT)
- -rm -f libknot/packet/query.lo
- -rm -f libknot/packet/response.$(OBJEXT)
- -rm -f libknot/packet/response.lo
- -rm -f libknot/rrset-dump.$(OBJEXT)
- -rm -f libknot/rrset-dump.lo
- -rm -f libknot/rrset.$(OBJEXT)
- -rm -f libknot/rrset.lo
- -rm -f libknot/sign/bnutils.$(OBJEXT)
- -rm -f libknot/sign/bnutils.lo
- -rm -f libknot/sign/dnssec.$(OBJEXT)
- -rm -f libknot/sign/dnssec.lo
- -rm -f libknot/sign/key.$(OBJEXT)
- -rm -f libknot/sign/key.lo
- -rm -f libknot/sign/sig0.$(OBJEXT)
- -rm -f libknot/sign/sig0.lo
- -rm -f libknot/tsig-op.$(OBJEXT)
- -rm -f libknot/tsig-op.lo
- -rm -f libknot/tsig.$(OBJEXT)
- -rm -f libknot/tsig.lo
- -rm -f libknot/updates/changesets.$(OBJEXT)
- -rm -f libknot/updates/changesets.lo
- -rm -f libknot/updates/ddns.$(OBJEXT)
- -rm -f libknot/updates/ddns.lo
- -rm -f libknot/updates/xfr-in.$(OBJEXT)
- -rm -f libknot/updates/xfr-in.lo
- -rm -f libknot/util/debug.$(OBJEXT)
- -rm -f libknot/util/debug.lo
- -rm -f libknot/util/tolower.$(OBJEXT)
- -rm -f libknot/util/tolower.lo
- -rm -f libknot/util/utils.$(OBJEXT)
- -rm -f libknot/util/utils.lo
- -rm -f libknot/zone/node.$(OBJEXT)
- -rm -f libknot/zone/node.lo
- -rm -f libknot/zone/zone-contents.$(OBJEXT)
- -rm -f libknot/zone/zone-contents.lo
- -rm -f libknot/zone/zone-diff.$(OBJEXT)
- -rm -f libknot/zone/zone-diff.lo
- -rm -f libknot/zone/zone-tree.$(OBJEXT)
- -rm -f libknot/zone/zone-tree.lo
- -rm -f libknot/zone/zone.$(OBJEXT)
- -rm -f libknot/zone/zone.lo
- -rm -f libknot/zone/zonedb.$(OBJEXT)
- -rm -f libknot/zone/zonedb.lo
- -rm -f utils/common/exec.$(OBJEXT)
- -rm -f utils/common/msg.$(OBJEXT)
- -rm -f utils/common/netio.$(OBJEXT)
- -rm -f utils/common/params.$(OBJEXT)
- -rm -f utils/common/resolv.$(OBJEXT)
- -rm -f utils/common/token.$(OBJEXT)
- -rm -f utils/dig/dig_exec.$(OBJEXT)
- -rm -f utils/dig/dig_main.$(OBJEXT)
- -rm -f utils/dig/dig_params.$(OBJEXT)
- -rm -f utils/host/host_main.$(OBJEXT)
- -rm -f utils/host/host_params.$(OBJEXT)
- -rm -f utils/nsupdate/nsupdate_exec.$(OBJEXT)
- -rm -f utils/nsupdate/nsupdate_main.$(OBJEXT)
- -rm -f utils/nsupdate/nsupdate_params.$(OBJEXT)
- -rm -f zscanner/file_loader.$(OBJEXT)
- -rm -f zscanner/file_loader.lo
- -rm -f zscanner/scanner.$(OBJEXT)
- -rm -f zscanner/scanner.lo
- -rm -f zscanner/scanner_functions.$(OBJEXT)
- -rm -f zscanner/scanner_functions.lo
- -rm -f zscanner/test/processing.$(OBJEXT)
- -rm -f zscanner/test/tests.$(OBJEXT)
- -rm -f zscanner/test/zscanner-tool.$(OBJEXT)
+ -rm -f common/*.$(OBJEXT)
+ -rm -f common/*.lo
+ -rm -f common/hattrie/*.$(OBJEXT)
+ -rm -f common/hattrie/*.lo
+ -rm -f common/libtap/*.$(OBJEXT)
+ -rm -f common/libtap/*.lo
+ -rm -f common/slab/*.$(OBJEXT)
+ -rm -f common/slab/*.lo
+ -rm -f knot/*.$(OBJEXT)
+ -rm -f knot/conf/*.$(OBJEXT)
+ -rm -f knot/conf/*.lo
+ -rm -f knot/ctl/*.$(OBJEXT)
+ -rm -f knot/ctl/*.lo
+ -rm -f knot/server/*.$(OBJEXT)
+ -rm -f knot/server/*.lo
+ -rm -f knot/stat/*.$(OBJEXT)
+ -rm -f knot/stat/*.lo
+ -rm -f knot/zone/*.$(OBJEXT)
+ -rm -f knot/zone/*.lo
+ -rm -f libknot/*.$(OBJEXT)
+ -rm -f libknot/*.lo
+ -rm -f libknot/nameserver/*.$(OBJEXT)
+ -rm -f libknot/nameserver/*.lo
+ -rm -f libknot/packet/*.$(OBJEXT)
+ -rm -f libknot/packet/*.lo
+ -rm -f libknot/sign/*.$(OBJEXT)
+ -rm -f libknot/sign/*.lo
+ -rm -f libknot/updates/*.$(OBJEXT)
+ -rm -f libknot/updates/*.lo
+ -rm -f libknot/util/*.$(OBJEXT)
+ -rm -f libknot/util/*.lo
+ -rm -f libknot/zone/*.$(OBJEXT)
+ -rm -f libknot/zone/*.lo
+ -rm -f utils/common/*.$(OBJEXT)
+ -rm -f utils/dig/*.$(OBJEXT)
+ -rm -f utils/host/*.$(OBJEXT)
+ -rm -f utils/nsupdate/*.$(OBJEXT)
+ -rm -f zscanner/*.$(OBJEXT)
+ -rm -f zscanner/*.lo
+ -rm -f zscanner/test/*.$(OBJEXT)
distclean-compile:
-rm -f *.tab.c
@@ -1576,12 +1446,12 @@ knot/conf/libknotd_la-cf-lex.c: knot/conf/cf-lex.l
$(SHELL) $(YLWRAP) `test -f 'knot/conf/cf-lex.l' || echo '$(srcdir)/'`knot/conf/cf-lex.l $(LEX_OUTPUT_ROOT).c knot/conf/libknotd_la-cf-lex.c -- $(LEX) $(libknotd_la_LFLAGS) $(LFLAGS)
.y.c:
- $(AM_V_YACC)$(am__skipyacc) $(SHELL) $(YLWRAP) $< y.tab.c $@ y.tab.h $*.h y.output $*.output -- $(YACCCOMPILE)
+ $(AM_V_YACC)$(am__skipyacc) $(SHELL) $(YLWRAP) $< y.tab.c $@ y.tab.h `echo $@ | $(am__yacc_c2h)` y.output $*.output -- $(YACCCOMPILE)
knot/conf/libknotd_la-cf-parse.c: knot/conf/cf-parse.y
$(AM_V_YACC) \
$(am__skipyacc) \
- $(SHELL) $(YLWRAP) `test -f 'knot/conf/cf-parse.y' || echo '$(srcdir)/'`knot/conf/cf-parse.y y.tab.c knot/conf/libknotd_la-cf-parse.c y.tab.h knot/conf/libknotd_la-cf-parse.h y.output knot/conf/libknotd_la-cf-parse.output -- $(YACC) $(libknotd_la_YFLAGS) $(YFLAGS)
+ $(SHELL) $(YLWRAP) `test -f 'knot/conf/cf-parse.y' || echo '$(srcdir)/'`knot/conf/cf-parse.y y.tab.c knot/conf/libknotd_la-cf-parse.c y.tab.h `echo knot/conf/libknotd_la-cf-parse.c | $(am__yacc_c2h)` y.output knot/conf/libknotd_la-cf-parse.output -- $(YACC) $(libknotd_la_YFLAGS) $(YFLAGS)
mostlyclean-libtool:
-rm -f *.lo
@@ -1607,12 +1477,12 @@ clean-libtool:
-rm -rf zscanner/.libs zscanner/_libs
# This directory's subdirectories are mostly independent; you can cd
-# into them and run `make' without going through this Makefile.
-# To change the values of `make' variables: instead of editing Makefiles,
-# (1) if the variable is set in `config.status', edit `config.status'
-# (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):
+# into them and run 'make' without going through this Makefile.
+# To change the values of 'make' variables: instead of editing Makefiles,
+# (1) if the variable is set in 'config.status', edit 'config.status'
+# (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) $(RECURSIVE_CLEAN_TARGETS):
@fail= failcom='exit 1'; \
for f in x $$MAKEFLAGS; do \
case $$f in \
@@ -1622,7 +1492,11 @@ $(RECURSIVE_TARGETS):
done; \
dot_seen=no; \
target=`echo $@ | sed s/-recursive//`; \
- list='$(SUBDIRS)'; for subdir in $$list; do \
+ case "$@" in \
+ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
+ *) list='$(SUBDIRS)' ;; \
+ esac; \
+ for subdir in $$list; do \
echo "Making $$target in $$subdir"; \
if test "$$subdir" = "."; then \
dot_seen=yes; \
@@ -1636,37 +1510,6 @@ $(RECURSIVE_TARGETS):
if test "$$dot_seen" = "no"; then \
$(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
fi; test -z "$$fail"
-
-$(RECURSIVE_CLEAN_TARGETS):
- @fail= 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)' ;; \
- *) list='$(SUBDIRS)' ;; \
- esac; \
- rev=''; for subdir in $$list; do \
- if test "$$subdir" = "."; then :; else \
- rev="$$subdir $$rev"; \
- fi; \
- done; \
- rev="$$rev ."; \
- target=`echo $@ | sed s/-recursive//`; \
- for subdir in $$rev; do \
- echo "Making $$target in $$subdir"; \
- if test "$$subdir" = "."; then \
- local_target="$$target-am"; \
- else \
- local_target="$$target"; \
- fi; \
- ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
- || eval $$failcom; \
- done && test -z "$$fail"
tags-recursive:
list='$(SUBDIRS)'; for subdir in $$list; do \
test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
@@ -1675,6 +1518,10 @@ ctags-recursive:
list='$(SUBDIRS)'; for subdir in $$list; do \
test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
done
+cscopelist-recursive:
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) cscopelist); \
+ done
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
@@ -1738,6 +1585,20 @@ GTAGS:
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-recursive $(HEADERS) $(SOURCES) $(LISP)
+ list='$(SOURCES) $(HEADERS) $(LISP)'; \
+ case "$(srcdir)" in \
+ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
+ *) sdir=$(subdir)/$(srcdir) ;; \
+ esac; \
+ for i in $$list; do \
+ if test -f "$$i"; then \
+ echo "$(subdir)/$$i"; \
+ else \
+ echo "$$sdir/$$i"; \
+ fi; \
+ done >> $(top_builddir)/cscope.files
+
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
@@ -1961,14 +1822,15 @@ ps-am:
uninstall-am: uninstall-binPROGRAMS uninstall-sbinPROGRAMS
.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) all check \
- ctags-recursive install install-am install-data-am \
- install-strip tags-recursive
+ cscopelist-recursive ctags-recursive install install-am \
+ install-data-am install-strip tags-recursive
.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
all all-am check check-am clean clean-binPROGRAMS \
clean-generic clean-libtool clean-noinstLTLIBRARIES \
- clean-noinstPROGRAMS clean-sbinPROGRAMS ctags ctags-recursive \
- distclean distclean-compile distclean-generic distclean-hdr \
+ clean-noinstPROGRAMS clean-sbinPROGRAMS cscopelist \
+ cscopelist-recursive ctags ctags-recursive distclean \
+ distclean-compile distclean-generic distclean-hdr \
distclean-libtool distclean-tags distdir dvi dvi-am html \
html-am info info-am install install-am install-binPROGRAMS \
install-data install-data-am install-data-hook install-dvi \
diff --git a/src/common/acl.c b/src/common/acl.c
index 26d3847..fa20d62 100644
--- a/src/common/acl.c
+++ b/src/common/acl.c
@@ -19,88 +19,99 @@
#include <assert.h>
#include <sys/types.h>
#include <sys/socket.h>
+#include <limits.h>
#include "common/acl.h"
+#include "libknot/util/endian.h"
-static inline uint32_t acl_sa_ipv4(sockaddr_t *a) {
+static inline uint32_t ipv4_chunk(sockaddr_t *a)
+{
+ /* Stored as big end first. */
return a->addr4.sin_addr.s_addr;
}
-static inline uint32_t acl_fill_mask32(short c) {
- /*! \todo Consider optimizing using LUT. */
- assert(c >= 0 && c <= 32);
- unsigned r = 0;
- /*! This actually builds big-endian mask
- * as we will match against addresses in
- * network byte-order (big-endian).
- * Otherwise it should be built from
- * HO bit -> LO bit.
- */
- for (char i = 0; i < c; ++i) {
- r |= (1 << i);
- }
- return r;
+static inline uint32_t ipv6_chunk(sockaddr_t *a, uint8_t idx)
+{
+ /* Is byte array, 4x 32bit value. */
+ return ((uint32_t *)&a->addr6.sin6_addr)[idx];
}
-static int acl_compare(void *k1, void *k2)
+static inline uint32_t ip_chunk(sockaddr_t *a, uint8_t idx)
{
- sockaddr_t* a1 = (sockaddr_t *)k1;
- sockaddr_t* a2 = (sockaddr_t *)k2;
+ if (sockaddr_family(a) == AF_INET)
+ return ipv4_chunk(a);
- /* Check different length, IPv4 goes first. */
- int ldiff = a1->len - a2->len;
- if (ldiff != 0) {
- return ldiff < 0 ? -1 : 1;
- }
+ return ipv6_chunk(a, idx);
+}
- /* Compare integers if IPv4. */
- if (sockaddr_family(a1) == AF_INET) {
+/*! \brief Compare chunks using given mask. */
+static int cmp_chunk(sockaddr_t *a, sockaddr_t *b, uint8_t idx, uint32_t mask)
+{
+ const uint32_t c1 = ip_chunk(a, idx) & mask;
+ const uint32_t c2 = ip_chunk(b, idx) & mask;
- /* Compute mask .*/
- uint32_t mask = acl_fill_mask32(a1->prefix);
+ if (c1 > c2)
+ return 1;
+ if (c1 < c2)
+ return -1;
+ return 0;
+}
- /* Compare address. */
- int cmp1 = (acl_sa_ipv4(a1) & mask);
- int cmp2 = (acl_sa_ipv4(a2) & mask);
- if (cmp1 > cmp2) return 1;
- if (cmp1 < cmp2) return -1;
- return 0;
+/*!
+ * \brief Calculate bitmask for byte array from the MSB.
+ *
+ * \note i.e. 8 means top 8 bits set, 11111111000000000000000000000000
+ *
+ * \param nbits number of bits set to 1
+ * \return mask
+ */
+static uint32_t acl_fill_mask32(short nbits)
+{
+ assert(nbits >= 0 && nbits <= 32);
+ uint32_t r = 0;
+ for (char i = 0; i < nbits; ++i) {
+ r |= 1 << (31 - i);
}
- /* IPv6 matching. */
-#ifndef DISABLE_IPV6
- if (sockaddr_family(a1) == AF_INET6) {
-
- /* Get mask .*/
- short chunk = a1->prefix;
-
- /* Compare address by 32bit chunks. */
- uint32_t* a1p = (uint32_t *)(&a1->addr6.sin6_addr);
- uint32_t* a2p = (uint32_t *)(&a2->addr6.sin6_addr);
-
- /* Mask 0 = 0 bits to compare from LO->HO (in big-endian).
- * Mask 128 = 128 bits to compare.
- */
- while (chunk > 0) {
- uint32_t mask = 0xffffffff;
- if ((size_t)chunk > sizeof(mask) << 3) {
- chunk -= sizeof(mask) << 3;
- } else {
- mask = acl_fill_mask32(chunk);
- chunk = 0;
- }
-
- int cmp1 = (*(a1p++) & mask);
- int cmp2 = (*(a2p++) & mask);
- if (cmp1 > cmp2) return 1;
- if (cmp1 < cmp2) return -1;
+ /* Make sure the mask is in network byte order. */
+ return htonl(r);
+}
+
+static int acl_compare(void *k1, void *k2)
+{
+ int ret = 0;
+ sockaddr_t* a1 = (sockaddr_t *)k1;
+ sockaddr_t* a2 = (sockaddr_t *)k2;
+ uint32_t mask = 0xffffffff;
+ short mask_bits = a1->prefix;
+ const short chunk_bits = sizeof(mask) * CHAR_BIT;
+
+ /* Check different length, IPv4 goes first. */
+ if (a1->len != a2->len) {
+ if (a1->len < a2->len)
+ return -1;
+ else
+ return 1;
+ }
+
+ /* At most 4xchunk_bits for IPv6 */
+ unsigned i = 0;
+ while (ret == 0 && mask_bits > 0) {
+ /* Compute mask for current chunk. */
+ if (mask_bits <= chunk_bits) {
+ mask = acl_fill_mask32(mask_bits);
+ mask_bits = 0; /* Last chunk */
+ } else {
+ mask_bits -= chunk_bits;
}
- return 0;
+ /* Empty mask - shortcut, we're done. */
+ if (mask > 0)
+ ret = cmp_chunk(a1, a2, i, mask);
+ ++i;
}
-#endif
- return 0;
+ return ret;
}
acl_t *acl_new(acl_rule_t default_rule, const char *name)
diff --git a/src/common/descriptor.c b/src/common/descriptor.c
index 233a995..5f2af94 100644
--- a/src/common/descriptor.c
+++ b/src/common/descriptor.c
@@ -76,12 +76,12 @@ static const rdata_descriptor_t rdata_descriptors[] = {
KNOT_RDATA_WF_END }, "KEY" },
[KNOT_RRTYPE_AAAA] = { { 16, KNOT_RDATA_WF_END }, "AAAA" },
[KNOT_RRTYPE_LOC] = { { 16, KNOT_RDATA_WF_END }, "LOC" },
- [KNOT_RRTYPE_SRV] = { { 6, KNOT_RDATA_WF_UNCOMPRESSED_DNAME,
+ [KNOT_RRTYPE_SRV] = { { 6, KNOT_RDATA_WF_COMPRESSED_DNAME,
KNOT_RDATA_WF_END }, "SRV" },
[KNOT_RRTYPE_NAPTR] = { { KNOT_RDATA_WF_NAPTR_HEADER,
- KNOT_RDATA_WF_UNCOMPRESSED_DNAME,
+ KNOT_RDATA_WF_COMPRESSED_DNAME,
KNOT_RDATA_WF_END }, "NAPTR" },
- [KNOT_RRTYPE_KX] = { { 2, KNOT_RDATA_WF_COMPRESSED_DNAME,
+ [KNOT_RRTYPE_KX] = { { 2, KNOT_RDATA_WF_UNCOMPRESSED_DNAME,
KNOT_RDATA_WF_END }, "KX" },
[KNOT_RRTYPE_CERT] = { { KNOT_RDATA_WF_REMAINDER,
KNOT_RDATA_WF_END }, "CERT" },
@@ -97,10 +97,10 @@ static const rdata_descriptor_t rdata_descriptors[] = {
KNOT_RDATA_WF_END }, "SSHFP" },
[KNOT_RRTYPE_IPSECKEY] = { { KNOT_RDATA_WF_REMAINDER,
KNOT_RDATA_WF_END }, "IPSECKEY" },
- [KNOT_RRTYPE_RRSIG] = { { 18, KNOT_RDATA_WF_LITERAL_DNAME,
+ [KNOT_RRTYPE_RRSIG] = { { 18, KNOT_RDATA_WF_UNCOMPRESSED_DNAME,
KNOT_RDATA_WF_REMAINDER,
KNOT_RDATA_WF_END }, "RRSIG" },
- [KNOT_RRTYPE_NSEC] = { { KNOT_RDATA_WF_LITERAL_DNAME,
+ [KNOT_RRTYPE_NSEC] = { { KNOT_RDATA_WF_UNCOMPRESSED_DNAME,
KNOT_RDATA_WF_REMAINDER,
KNOT_RDATA_WF_END }, "NSEC" },
[KNOT_RRTYPE_DNSKEY] = { { KNOT_RDATA_WF_REMAINDER,
@@ -118,7 +118,7 @@ static const rdata_descriptor_t rdata_descriptors[] = {
[KNOT_RRTYPE_NID] = { { 10 }, "NID" },
[KNOT_RRTYPE_L32] = { { 6 }, "L32" },
[KNOT_RRTYPE_L64] = { { 10 }, "L64" },
- [KNOT_RRTYPE_LP] = { { 2, KNOT_RDATA_WF_COMPRESSED_DNAME },
+ [KNOT_RRTYPE_LP] = { { 2, KNOT_RDATA_WF_UNCOMPRESSED_DNAME },
"LP" },
[KNOT_RRTYPE_EUI48] = { { 6, KNOT_RDATA_WF_END }, "EUI48" },
[KNOT_RRTYPE_EUI64] = { { 8, KNOT_RDATA_WF_END }, "EUI64" },
@@ -136,6 +136,30 @@ static const rdata_descriptor_t rdata_descriptors[] = {
KNOT_RDATA_WF_END }, "ANY" },
};
+/*!
+ * \brief Some (OBSOLETE) RR type descriptors.
+ */
+static const rdata_descriptor_t obsolete_rdata_descriptors[] = {
+ [0] = { { KNOT_RDATA_WF_REMAINDER,
+ KNOT_RDATA_WF_END }, NULL },
+ [KNOT_RRTYPE_MD] = { { KNOT_RDATA_WF_COMPRESSED_DNAME,
+ KNOT_RDATA_WF_END }, "MD" },
+ [KNOT_RRTYPE_MF] = { { KNOT_RDATA_WF_COMPRESSED_DNAME,
+ KNOT_RDATA_WF_END }, "MF" },
+ [KNOT_RRTYPE_MB] = { { KNOT_RDATA_WF_COMPRESSED_DNAME,
+ KNOT_RDATA_WF_END }, "MB" },
+ [KNOT_RRTYPE_MG] = { { KNOT_RDATA_WF_COMPRESSED_DNAME,
+ KNOT_RDATA_WF_END }, "MG" },
+ [KNOT_RRTYPE_MR] = { { KNOT_RDATA_WF_COMPRESSED_DNAME,
+ KNOT_RDATA_WF_END }, "MR" },
+ [KNOT_RRTYPE_PX] = { { 2, KNOT_RDATA_WF_COMPRESSED_DNAME,
+ KNOT_RDATA_WF_COMPRESSED_DNAME,
+ KNOT_RDATA_WF_END }, "PX" },
+ [KNOT_RRTYPE_NXT] = { { KNOT_RDATA_WF_COMPRESSED_DNAME,
+ KNOT_RDATA_WF_REMAINDER,
+ KNOT_RDATA_WF_END }, "NXT" },
+};
+
const rdata_descriptor_t *get_rdata_descriptor(const uint16_t type)
{
if (type <= KNOT_RRTYPE_ANY && rdata_descriptors[type].type_name != 0) {
@@ -145,6 +169,16 @@ const rdata_descriptor_t *get_rdata_descriptor(const uint16_t type)
}
}
+const rdata_descriptor_t *get_obsolete_rdata_descriptor(const uint16_t type)
+{
+ if (type <= KNOT_RRTYPE_NXT &&
+ obsolete_rdata_descriptors[type].type_name != 0) {
+ return &obsolete_rdata_descriptors[type];
+ } else {
+ return &obsolete_rdata_descriptors[0];
+ }
+}
+
int knot_rrtype_to_string(const uint16_t rrtype,
char *out,
const size_t out_len)
@@ -251,8 +285,7 @@ int knot_rrclass_from_string(const char *name, uint16_t *num)
int descriptor_item_is_dname(const int item)
{
- return item == KNOT_RDATA_WF_LITERAL_DNAME ||
- item == KNOT_RDATA_WF_COMPRESSED_DNAME ||
+ return item == KNOT_RDATA_WF_COMPRESSED_DNAME ||
item == KNOT_RDATA_WF_UNCOMPRESSED_DNAME;
}
diff --git a/src/common/descriptor.h b/src/common/descriptor.h
index d7938cb..f7c2327 100644
--- a/src/common/descriptor.h
+++ b/src/common/descriptor.h
@@ -110,6 +110,25 @@ enum knot_rr_type {
};
/*!
+ * \brief Some (OBSOLETE) resource record type constants.
+ *
+ * http://www.iana.org/assignments/dns-parameters/dns-parameters.xml
+ *
+ * \note These records can contain compressed domain name in rdata so
+ * it is important to know the position of it during transfers.
+ * See RFC 3597#4.
+ */
+enum knot_obsolete_rr_type {
+ KNOT_RRTYPE_MD = 3,
+ KNOT_RRTYPE_MF = 4,
+ KNOT_RRTYPE_MB = 7,
+ KNOT_RRTYPE_MG = 8,
+ KNOT_RRTYPE_MR = 9,
+ KNOT_RRTYPE_PX = 26,
+ KNOT_RRTYPE_NXT = 30
+};
+
+/*!
* \brief Constants characterising the wire format of RDATA items.
*/
enum knot_rdata_wireformat {
@@ -117,8 +136,6 @@ enum knot_rdata_wireformat {
KNOT_RDATA_WF_COMPRESSED_DNAME = -10,
/*!< Uncompressed dname. */
KNOT_RDATA_WF_UNCOMPRESSED_DNAME,
- /*!< Dname with preserved letter cases. */
- KNOT_RDATA_WF_LITERAL_DNAME,
/*!< Initial part of NAPTR record before dname. */
KNOT_RDATA_WF_NAPTR_HEADER,
/*!< Uninteresting final part of a record. */
@@ -140,7 +157,7 @@ typedef struct {
/*!
* \brief Gets rdata descriptor for given RR name.
*
- * \param name Mnemonic of RR type whose descriptor should be retvaled.
+ * \param name Mnemonic of RR type whose descriptor should be returned.
*
* \retval RR descriptor for given name, NULL descriptor if
* unknown type.
@@ -148,6 +165,16 @@ typedef struct {
const rdata_descriptor_t *get_rdata_descriptor(const uint16_t type);
/*!
+ * \brief Gets rdata descriptor for given RR name (obsolete version).
+ *
+ * \param name Mnemonic of RR type whose descriptor should be returned.
+ *
+ * \retval RR descriptor for given name, NULL descriptor if
+ * unknown type.
+ */
+const rdata_descriptor_t *get_obsolete_rdata_descriptor(const uint16_t type);
+
+/*!
* \brief Converts numeric type representation to mnemonic string.
*
* \param rrtype Type RR type code to be converted.
diff --git a/src/common/errcode.c b/src/common/errcode.c
index b555805..50b37dd 100644
--- a/src/common/errcode.c
+++ b/src/common/errcode.c
@@ -52,7 +52,7 @@ const error_table_t knot_error_msgs[] = {
{ KNOT_ECRYPTO, "Error in crypto library." },
{ KNOT_ENSEC3PAR, "Missing or wrong NSEC3PARAM record." },
{ KNOT_ENSEC3CHAIN, "Missing or wrong NSEC3 chain in the zone." },
- { KNOT_EBADZONE, "Name does not belong to the zone." },
+ { KNOT_EOUTOFZONE, "Name does not belong to the zone." },
{ KNOT_EHASH, "Error in hash table." },
{ KNOT_EZONEINVAL, "Invalid zone file." },
{ KNOT_ENOZONE, "No such zone found." },
diff --git a/src/common/errcode.h b/src/common/errcode.h
index 69f6ed5..c29a433 100644
--- a/src/common/errcode.h
+++ b/src/common/errcode.h
@@ -71,7 +71,7 @@ enum knot_error {
KNOT_ECRYPTO, /*!< Error in crypto library. */
KNOT_ENSEC3PAR, /*!< Missing or wrong NSEC3PARAM record. */
KNOT_ENSEC3CHAIN, /*!< Missing or wrong NSEC3 chain in the zone. */
- KNOT_EBADZONE, /*!< Domain name does not belong to the zone. */
+ KNOT_EOUTOFZONE, /*!< Domain name does not belong to the zone. */
KNOT_EHASH, /*!< Error in hash table. */
KNOT_EZONEINVAL, /*!< Invalid zone file. */
KNOT_ENOZONE, /*!< No such zone found. */
diff --git a/src/config.h.in b/src/config.h.in
index 73c4e3f..763a1a5 100644
--- a/src/config.h.in
+++ b/src/config.h.in
@@ -15,9 +15,6 @@
/* microseconds in log messages */
#undef ENABLE_MICROSECONDS_LOG
-/* recvmmsg enabled */
-#undef ENABLE_RECVMMSG
-
/* Define to 1 if you have the <arpa/nameser.h> header file. */
#undef HAVE_ARPA_NAMESER_H
@@ -84,6 +81,9 @@
/* Define to 1 if you have the `pthread_setaffinity_np' function. */
#undef HAVE_PTHREAD_SETAFFINITY_NP
+/* Define if struct mmsghdr and recvmmsg() exists. */
+#undef HAVE_RECVMMSG
+
/* Define to 1 if you have the `regcomp' function. */
#undef HAVE_REGCOMP
diff --git a/src/knot/conf/conf.c b/src/knot/conf/conf.c
index 9830c04..fae998b 100644
--- a/src/knot/conf/conf.c
+++ b/src/knot/conf/conf.c
@@ -37,7 +37,7 @@
/*! \brief Default config paths. */
static const char *DEFAULT_CONFIG[] = {
- SYSCONFDIR "/" "knot.conf",
+ CONFIG_DIR "/" "knot.conf",
};
#define DEFAULT_CONF_COUNT 1 /*!< \brief Number of default config paths. */
@@ -295,7 +295,7 @@ static int conf_process(conf_t *conf)
// Default zone file
if (zone->file == NULL) {
- zone->file = strcdup(zone->name, ".zone");
+ zone->file = strcdup(zone->name, "zone");
if (!zone->file) {
ret = KNOT_ENOMEM;
continue;
diff --git a/src/knot/conf/conf.h b/src/knot/conf/conf.h
index 30075c3..dd61e52 100644
--- a/src/knot/conf/conf.h
+++ b/src/knot/conf/conf.h
@@ -50,7 +50,7 @@
#define CONFIG_REPLY_WD 10 /*!< SOA/NOTIFY query timeout [s]. */
#define CONFIG_HANDSHAKE_WD 10 /*!< [secs] for connection to make a request.*/
#define CONFIG_IDLE_WD 60 /*!< [secs] of allowed inactivity between requests */
-#define CONFIG_RRL_SLIP 2 /*!< Default slip value. */
+#define CONFIG_RRL_SLIP 1 /*!< Default slip value. */
#define CONFIG_RRL_SIZE 393241 /*!< Htable default size. */
#define CONFIG_XFERS 10
diff --git a/src/knot/conf/libknotd_la-cf-lex.c b/src/knot/conf/libknotd_la-cf-lex.c
index d3683ec..cf3e9b0 100644
--- a/src/knot/conf/libknotd_la-cf-lex.c
+++ b/src/knot/conf/libknotd_la-cf-lex.c
@@ -9,7 +9,7 @@
#define FLEX_SCANNER
#define YY_FLEX_MAJOR_VERSION 2
#define YY_FLEX_MINOR_VERSION 5
-#define YY_FLEX_SUBMINOR_VERSION 35
+#define YY_FLEX_SUBMINOR_VERSION 37
#if YY_FLEX_SUBMINOR_VERSION > 0
#define FLEX_BETA
#endif
@@ -159,15 +159,7 @@ typedef void* yyscan_t;
/* Size of default input buffer. */
#ifndef YY_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k.
- * Moreover, YY_BUF_SIZE is 2*YY_READ_BUF_SIZE in the general case.
- * Ditto for the __ia64__ case accordingly.
- */
-#define YY_BUF_SIZE 32768
-#else
#define YY_BUF_SIZE 16384
-#endif /* __ia64__ */
#endif
/* The state buf must be large enough to hold one state per character in the main buffer.
@@ -179,6 +171,11 @@ typedef void* yyscan_t;
typedef struct yy_buffer_state *YY_BUFFER_STATE;
#endif
+#ifndef YY_TYPEDEF_YY_SIZE_T
+#define YY_TYPEDEF_YY_SIZE_T
+typedef size_t yy_size_t;
+#endif
+
#define EOB_ACT_CONTINUE_SCAN 0
#define EOB_ACT_END_OF_FILE 1
#define EOB_ACT_LAST_MATCH 2
@@ -214,11 +211,6 @@ typedef struct yy_buffer_state *YY_BUFFER_STATE;
#define unput(c) yyunput( c, yyg->yytext_ptr , yyscanner )
-#ifndef YY_TYPEDEF_YY_SIZE_T
-#define YY_TYPEDEF_YY_SIZE_T
-typedef size_t yy_size_t;
-#endif
-
#ifndef YY_STRUCT_YY_BUFFER_STATE
#define YY_STRUCT_YY_BUFFER_STATE
struct yy_buffer_state
@@ -236,7 +228,7 @@ struct yy_buffer_state
/* Number of characters read into yy_ch_buf, not including EOB
* characters.
*/
- int yy_n_chars;
+ yy_size_t yy_n_chars;
/* Whether we "own" the buffer - i.e., we know we created it,
* and can realloc() it to grow it, and should free() it to
@@ -315,7 +307,7 @@ static void cf__init_buffer (YY_BUFFER_STATE b,FILE *file ,yyscan_t yyscanner );
YY_BUFFER_STATE cf__scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner );
YY_BUFFER_STATE cf__scan_string (yyconst char *yy_str ,yyscan_t yyscanner );
-YY_BUFFER_STATE cf__scan_bytes (yyconst char *bytes,int len ,yyscan_t yyscanner );
+YY_BUFFER_STATE cf__scan_bytes (yyconst char *bytes,yy_size_t len ,yyscan_t yyscanner );
void *cf_alloc (yy_size_t ,yyscan_t yyscanner );
void *cf_realloc (void *,yy_size_t ,yyscan_t yyscanner );
@@ -347,7 +339,7 @@ void cf_free (void * ,yyscan_t yyscanner );
/* Begin user sect3 */
-#define cf_wrap(n) 1
+#define cf_wrap(yyscanner) 1
#define YY_SKIP_YYWRAP
typedef unsigned char YY_CHAR;
@@ -768,7 +760,7 @@ static yyconst flex_int32_t yy_rule_can_match_eol[84] =
#define yymore() yymore_used_but_not_detected
#define YY_MORE_ADJ 0
#define YY_RESTORE_YY_MORE_OFFSET
-#line 1 "cf-lex.l"
+#line 1 "knot/conf/cf-lex.l"
/* Copyright (C) 2011 CZ.NIC, z.s.p.o. <knot-dns@labs.nic.cz>
This program is free software: you can redistribute it and/or modify
@@ -793,7 +785,7 @@ static yyconst flex_int32_t yy_rule_can_match_eol[84] =
*
* IP address conversions from BIRD, (c) 1998--2000 Martin Mares <mj@ucw.cz>
*/
-#line 26 "cf-lex.l"
+#line 26 "knot/conf/cf-lex.l"
#include <config.h>
#include <errno.h>
@@ -836,7 +828,7 @@ int hex2bin(const char* src, char *dst, size_t len) {
#define YY_NO_INPUT 1
-#line 840 "knot/conf/libknotd_la-cf-lex.c"
+#line 832 "knot/conf/libknotd_la-cf-lex.c"
#define INITIAL 0
#define include 1
@@ -864,8 +856,8 @@ struct yyguts_t
size_t yy_buffer_stack_max; /**< capacity of stack. */
YY_BUFFER_STATE * yy_buffer_stack; /**< Stack as an array. */
char yy_hold_char;
- int yy_n_chars;
- int yyleng_r;
+ yy_size_t yy_n_chars;
+ yy_size_t yyleng_r;
char *yy_c_buf_p;
int yy_init;
int yy_start;
@@ -918,7 +910,7 @@ FILE *cf_get_out (yyscan_t yyscanner );
void cf_set_out (FILE * out_str ,yyscan_t yyscanner );
-int cf_get_leng (yyscan_t yyscanner );
+yy_size_t cf_get_leng (yyscan_t yyscanner );
char *cf_get_text (yyscan_t yyscanner );
@@ -966,12 +958,7 @@ static int input (yyscan_t yyscanner );
/* Amount of stuff to slurp up with each read. */
#ifndef YY_READ_BUF_SIZE
-#ifdef __ia64__
-/* On IA-64, the buffer size is 16k, not 8k */
-#define YY_READ_BUF_SIZE 16384
-#else
#define YY_READ_BUF_SIZE 8192
-#endif /* __ia64__ */
#endif
/* Copy whatever the last rule matched to the standard output. */
@@ -1075,9 +1062,9 @@ YY_DECL
register int yy_act;
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
-#line 87 "cf-lex.l"
+#line 87 "knot/conf/cf-lex.l"
-#line 1081 "knot/conf/libknotd_la-cf-lex.c"
+#line 1068 "knot/conf/libknotd_la-cf-lex.c"
yylval = yylval_param;
@@ -1177,303 +1164,303 @@ do_action: /* This label is used only to access EOF actions. */
case 1:
/* rule 1 can match eol */
YY_RULE_SETUP
-#line 88 "cf-lex.l"
+#line 88 "knot/conf/cf-lex.l"
/* Ignore comments */;
YY_BREAK
case 2:
/* rule 2 can match eol */
YY_RULE_SETUP
-#line 89 "cf-lex.l"
+#line 89 "knot/conf/cf-lex.l"
/* Ignore whitespace */;
YY_BREAK
case 3:
YY_RULE_SETUP
-#line 90 "cf-lex.l"
+#line 90 "knot/conf/cf-lex.l"
{ return yytext[0]; }
YY_BREAK
case 4:
YY_RULE_SETUP
-#line 91 "cf-lex.l"
+#line 91 "knot/conf/cf-lex.l"
{ lval.t = yytext; return SYSTEM; }
YY_BREAK
case 5:
YY_RULE_SETUP
-#line 92 "cf-lex.l"
+#line 92 "knot/conf/cf-lex.l"
{ lval.t = yytext; return IDENTITY; }
YY_BREAK
case 6:
YY_RULE_SETUP
-#line 93 "cf-lex.l"
+#line 93 "knot/conf/cf-lex.l"
{ lval.t = yytext; return HOSTNAME; }
YY_BREAK
case 7:
YY_RULE_SETUP
-#line 94 "cf-lex.l"
+#line 94 "knot/conf/cf-lex.l"
{ lval.t = yytext; return SVERSION; }
YY_BREAK
case 8:
YY_RULE_SETUP
-#line 95 "cf-lex.l"
+#line 95 "knot/conf/cf-lex.l"
{ lval.t = yytext; return NSID; }
YY_BREAK
case 9:
YY_RULE_SETUP
-#line 96 "cf-lex.l"
+#line 96 "knot/conf/cf-lex.l"
{ lval.t = yytext; return STORAGE; }
YY_BREAK
case 10:
YY_RULE_SETUP
-#line 97 "cf-lex.l"
+#line 97 "knot/conf/cf-lex.l"
{ lval.t = yytext; return KEY; }
YY_BREAK
case 11:
YY_RULE_SETUP
-#line 98 "cf-lex.l"
+#line 98 "knot/conf/cf-lex.l"
{ lval.t = yytext; return KEYS; }
YY_BREAK
case 12:
YY_RULE_SETUP
-#line 99 "cf-lex.l"
+#line 99 "knot/conf/cf-lex.l"
{ lval.t = yytext; return REMOTES; }
YY_BREAK
case 13:
YY_RULE_SETUP
-#line 100 "cf-lex.l"
+#line 100 "knot/conf/cf-lex.l"
{ lval.t = yytext; return GROUPS; }
YY_BREAK
case 14:
YY_RULE_SETUP
-#line 102 "cf-lex.l"
+#line 102 "knot/conf/cf-lex.l"
{ lval.t = yytext; return ZONES; }
YY_BREAK
case 15:
YY_RULE_SETUP
-#line 103 "cf-lex.l"
+#line 103 "knot/conf/cf-lex.l"
{ lval.t = yytext; return FILENAME; }
YY_BREAK
case 16:
YY_RULE_SETUP
-#line 104 "cf-lex.l"
+#line 104 "knot/conf/cf-lex.l"
{ lval.t = yytext; return DISABLE_ANY; }
YY_BREAK
case 17:
YY_RULE_SETUP
-#line 105 "cf-lex.l"
+#line 105 "knot/conf/cf-lex.l"
{ lval.t = yytext; return SEMANTIC_CHECKS; }
YY_BREAK
case 18:
YY_RULE_SETUP
-#line 106 "cf-lex.l"
+#line 106 "knot/conf/cf-lex.l"
{ lval.t = yytext; return NOTIFY_RETRIES; }
YY_BREAK
case 19:
YY_RULE_SETUP
-#line 107 "cf-lex.l"
+#line 107 "knot/conf/cf-lex.l"
{ lval.t = yytext; return NOTIFY_TIMEOUT; }
YY_BREAK
case 20:
YY_RULE_SETUP
-#line 108 "cf-lex.l"
+#line 108 "knot/conf/cf-lex.l"
{ lval.t = yytext; return DBSYNC_TIMEOUT; }
YY_BREAK
case 21:
YY_RULE_SETUP
-#line 109 "cf-lex.l"
+#line 109 "knot/conf/cf-lex.l"
{ lval.t = yytext; return IXFR_FSLIMIT; }
YY_BREAK
case 22:
YY_RULE_SETUP
-#line 110 "cf-lex.l"
+#line 110 "knot/conf/cf-lex.l"
{ lval.t = yytext; return XFR_IN; }
YY_BREAK
case 23:
YY_RULE_SETUP
-#line 111 "cf-lex.l"
+#line 111 "knot/conf/cf-lex.l"
{ lval.t = yytext; return XFR_OUT; }
YY_BREAK
case 24:
YY_RULE_SETUP
-#line 112 "cf-lex.l"
+#line 112 "knot/conf/cf-lex.l"
{ lval.t = yytext; return UPDATE_IN; }
YY_BREAK
case 25:
YY_RULE_SETUP
-#line 113 "cf-lex.l"
+#line 113 "knot/conf/cf-lex.l"
{ lval.t = yytext; return NOTIFY_IN; }
YY_BREAK
case 26:
YY_RULE_SETUP
-#line 114 "cf-lex.l"
+#line 114 "knot/conf/cf-lex.l"
{ lval.t = yytext; return NOTIFY_OUT; }
YY_BREAK
case 27:
YY_RULE_SETUP
-#line 115 "cf-lex.l"
+#line 115 "knot/conf/cf-lex.l"
{ lval.t = yytext; return WORKERS; }
YY_BREAK
case 28:
YY_RULE_SETUP
-#line 116 "cf-lex.l"
+#line 116 "knot/conf/cf-lex.l"
{ lval.t = yytext; return USER; }
YY_BREAK
case 29:
YY_RULE_SETUP
-#line 117 "cf-lex.l"
+#line 117 "knot/conf/cf-lex.l"
{ lval.t = yytext; return PIDFILE; }
YY_BREAK
case 30:
YY_RULE_SETUP
-#line 118 "cf-lex.l"
+#line 118 "knot/conf/cf-lex.l"
{ lval.t = yytext; return RUNDIR; }
YY_BREAK
case 31:
YY_RULE_SETUP
-#line 119 "cf-lex.l"
+#line 119 "knot/conf/cf-lex.l"
{ lval.t = yytext; return BUILD_DIFFS; }
YY_BREAK
case 32:
YY_RULE_SETUP
-#line 120 "cf-lex.l"
+#line 120 "knot/conf/cf-lex.l"
{ lval.t = yytext; return MAX_CONN_IDLE; }
YY_BREAK
case 33:
YY_RULE_SETUP
-#line 121 "cf-lex.l"
+#line 121 "knot/conf/cf-lex.l"
{ lval.t = yytext; return MAX_CONN_HS; }
YY_BREAK
case 34:
YY_RULE_SETUP
-#line 122 "cf-lex.l"
+#line 122 "knot/conf/cf-lex.l"
{ lval.t = yytext; return MAX_CONN_REPLY; }
YY_BREAK
case 35:
YY_RULE_SETUP
-#line 123 "cf-lex.l"
+#line 123 "knot/conf/cf-lex.l"
{ lval.t = yytext; return RATE_LIMIT; }
YY_BREAK
case 36:
YY_RULE_SETUP
-#line 124 "cf-lex.l"
+#line 124 "knot/conf/cf-lex.l"
{ lval.t = yytext; return RATE_LIMIT_SIZE; }
YY_BREAK
case 37:
YY_RULE_SETUP
-#line 125 "cf-lex.l"
+#line 125 "knot/conf/cf-lex.l"
{ lval.t = yytext; return RATE_LIMIT_SLIP; }
YY_BREAK
case 38:
YY_RULE_SETUP
-#line 126 "cf-lex.l"
+#line 126 "knot/conf/cf-lex.l"
{ lval.t = yytext; return TRANSFERS; }
YY_BREAK
case 39:
YY_RULE_SETUP
-#line 128 "cf-lex.l"
+#line 128 "knot/conf/cf-lex.l"
{ lval.t = yytext; return INTERFACES; }
YY_BREAK
case 40:
YY_RULE_SETUP
-#line 129 "cf-lex.l"
+#line 129 "knot/conf/cf-lex.l"
{ lval.t = yytext; return ADDRESS; }
YY_BREAK
case 41:
YY_RULE_SETUP
-#line 130 "cf-lex.l"
+#line 130 "knot/conf/cf-lex.l"
{ lval.t = yytext; return PORT; }
YY_BREAK
case 42:
YY_RULE_SETUP
-#line 131 "cf-lex.l"
+#line 131 "knot/conf/cf-lex.l"
{ lval.t = yytext; return VIA; }
YY_BREAK
case 43:
YY_RULE_SETUP
-#line 133 "cf-lex.l"
+#line 133 "knot/conf/cf-lex.l"
{ lval.t = yytext; return CONTROL; }
YY_BREAK
case 44:
YY_RULE_SETUP
-#line 134 "cf-lex.l"
+#line 134 "knot/conf/cf-lex.l"
{ lval.t = yytext; return ALLOW; }
YY_BREAK
case 45:
YY_RULE_SETUP
-#line 135 "cf-lex.l"
+#line 135 "knot/conf/cf-lex.l"
{ lval.t = yytext; return LISTEN_ON; }
YY_BREAK
case 46:
YY_RULE_SETUP
-#line 137 "cf-lex.l"
+#line 137 "knot/conf/cf-lex.l"
{ lval.t = yytext; return LOG; }
YY_BREAK
case 47:
YY_RULE_SETUP
-#line 139 "cf-lex.l"
+#line 139 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOG_ANY; return LOG_SRC; }
YY_BREAK
case 48:
YY_RULE_SETUP
-#line 140 "cf-lex.l"
+#line 140 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOG_SERVER; return LOG_SRC; }
YY_BREAK
case 49:
YY_RULE_SETUP
-#line 141 "cf-lex.l"
+#line 141 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOG_ANSWER; return LOG_SRC; }
YY_BREAK
case 50:
YY_RULE_SETUP
-#line 142 "cf-lex.l"
+#line 142 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOG_ZONE; return LOG_SRC; }
YY_BREAK
case 51:
YY_RULE_SETUP
-#line 143 "cf-lex.l"
+#line 143 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOGT_STDOUT; return LOG_DEST; }
YY_BREAK
case 52:
YY_RULE_SETUP
-#line 144 "cf-lex.l"
+#line 144 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOGT_STDERR; return LOG_DEST; }
YY_BREAK
case 53:
YY_RULE_SETUP
-#line 145 "cf-lex.l"
+#line 145 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOGT_SYSLOG; return LOG_DEST; }
YY_BREAK
case 54:
YY_RULE_SETUP
-#line 146 "cf-lex.l"
+#line 146 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOG_UPTO(LOG_DEBUG); return LOG_LEVEL; }
YY_BREAK
case 55:
YY_RULE_SETUP
-#line 147 "cf-lex.l"
+#line 147 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOG_MASK(LOG_DEBUG); return LOG_LEVEL; }
YY_BREAK
case 56:
YY_RULE_SETUP
-#line 148 "cf-lex.l"
+#line 148 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOG_MASK(LOG_INFO); return LOG_LEVEL; }
YY_BREAK
case 57:
YY_RULE_SETUP
-#line 149 "cf-lex.l"
+#line 149 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOG_MASK(LOG_NOTICE); return LOG_LEVEL; }
YY_BREAK
case 58:
YY_RULE_SETUP
-#line 150 "cf-lex.l"
+#line 150 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOG_MASK(LOG_WARNING); return LOG_LEVEL; }
YY_BREAK
case 59:
YY_RULE_SETUP
-#line 151 "cf-lex.l"
+#line 151 "knot/conf/cf-lex.l"
{ lval.t = yytext; lval.i = LOG_MASK(LOG_ERR); return LOG_LEVEL; }
YY_BREAK
case 60:
YY_RULE_SETUP
-#line 153 "cf-lex.l"
+#line 153 "knot/conf/cf-lex.l"
{
lval.t = yytext;
lval.i = 0;
@@ -1485,12 +1472,12 @@ YY_RULE_SETUP
YY_BREAK
case 61:
YY_RULE_SETUP
-#line 162 "cf-lex.l"
+#line 162 "knot/conf/cf-lex.l"
BEGIN(include);
YY_BREAK
case 62:
YY_RULE_SETUP
-#line 164 "cf-lex.l"
+#line 164 "knot/conf/cf-lex.l"
{
size_t mpos = strlen(yytext) - 1;
char multiplier = yytext[mpos];
@@ -1515,7 +1502,7 @@ YY_RULE_SETUP
YY_BREAK
case 63:
YY_RULE_SETUP
-#line 186 "cf-lex.l"
+#line 186 "knot/conf/cf-lex.l"
{
size_t mpos = strlen(yytext) - 1;
char multiplier = yytext[mpos];
@@ -1539,7 +1526,7 @@ YY_RULE_SETUP
YY_BREAK
case 64:
YY_RULE_SETUP
-#line 207 "cf-lex.l"
+#line 207 "knot/conf/cf-lex.l"
{
lval.i = atol(yytext);
return NUM;
@@ -1547,7 +1534,7 @@ YY_RULE_SETUP
YY_BREAK
case 65:
YY_RULE_SETUP
-#line 212 "cf-lex.l"
+#line 212 "knot/conf/cf-lex.l"
{
unsigned char buf[sizeof(struct in_addr)];
if (inet_pton(AF_INET, yytext, buf)) {
@@ -1559,7 +1546,7 @@ YY_RULE_SETUP
YY_BREAK
case 66:
YY_RULE_SETUP
-#line 221 "cf-lex.l"
+#line 221 "knot/conf/cf-lex.l"
{
#ifdef DISABLE_IPV6
lval.t = strdup(yytext);
@@ -1578,7 +1565,7 @@ YY_RULE_SETUP
YY_BREAK
case 67:
YY_RULE_SETUP
-#line 237 "cf-lex.l"
+#line 237 "knot/conf/cf-lex.l"
{
#ifdef DISABLE_IPV6
lval.t = strdup(yytext);
@@ -1596,7 +1583,7 @@ YY_RULE_SETUP
YY_BREAK
case 68:
YY_RULE_SETUP
-#line 252 "cf-lex.l"
+#line 252 "knot/conf/cf-lex.l"
{
lval.t = NULL;
lval.l = 0;
@@ -1624,42 +1611,42 @@ YY_RULE_SETUP
YY_BREAK
case 69:
YY_RULE_SETUP
-#line 277 "cf-lex.l"
+#line 277 "knot/conf/cf-lex.l"
{ lval.alg = KNOT_TSIG_ALG_GSS_TSIG; return TSIG_ALGO_NAME; }
YY_BREAK
case 70:
YY_RULE_SETUP
-#line 278 "cf-lex.l"
+#line 278 "knot/conf/cf-lex.l"
{ lval.alg = KNOT_TSIG_ALG_HMAC_MD5; return TSIG_ALGO_NAME; }
YY_BREAK
case 71:
YY_RULE_SETUP
-#line 279 "cf-lex.l"
+#line 279 "knot/conf/cf-lex.l"
{ lval.alg = KNOT_TSIG_ALG_HMAC_SHA1; return TSIG_ALGO_NAME; }
YY_BREAK
case 72:
YY_RULE_SETUP
-#line 280 "cf-lex.l"
+#line 280 "knot/conf/cf-lex.l"
{ lval.alg = KNOT_TSIG_ALG_HMAC_SHA224; return TSIG_ALGO_NAME; }
YY_BREAK
case 73:
YY_RULE_SETUP
-#line 281 "cf-lex.l"
+#line 281 "knot/conf/cf-lex.l"
{ lval.alg = KNOT_TSIG_ALG_HMAC_SHA256; return TSIG_ALGO_NAME; }
YY_BREAK
case 74:
YY_RULE_SETUP
-#line 282 "cf-lex.l"
+#line 282 "knot/conf/cf-lex.l"
{ lval.alg = KNOT_TSIG_ALG_HMAC_SHA384; return TSIG_ALGO_NAME; }
YY_BREAK
case 75:
YY_RULE_SETUP
-#line 283 "cf-lex.l"
+#line 283 "knot/conf/cf-lex.l"
{ lval.alg = KNOT_TSIG_ALG_HMAC_SHA512; return TSIG_ALGO_NAME; }
YY_BREAK
case 76:
YY_RULE_SETUP
-#line 285 "cf-lex.l"
+#line 285 "knot/conf/cf-lex.l"
{
yytext[yyleng-1] = 0;
lval.t = strdup(yytext + 1);
@@ -1669,12 +1656,12 @@ YY_RULE_SETUP
case 77:
/* rule 77 can match eol */
YY_RULE_SETUP
-#line 291 "cf-lex.l"
+#line 291 "knot/conf/cf-lex.l"
cf_error(yyscanner, "Unterminated string.");
YY_BREAK
case 78:
YY_RULE_SETUP
-#line 293 "cf-lex.l"
+#line 293 "knot/conf/cf-lex.l"
{
lval.t = strdup(yytext);
return TEXT /* Last resort, alphanumeric word. */;
@@ -1682,12 +1669,12 @@ YY_RULE_SETUP
YY_BREAK
case 79:
YY_RULE_SETUP
-#line 298 "cf-lex.l"
+#line 298 "knot/conf/cf-lex.l"
/* Optional : in assignments. */;
YY_BREAK
case YY_STATE_EOF(INITIAL):
case YY_STATE_EOF(include):
-#line 300 "cf-lex.l"
+#line 300 "knot/conf/cf-lex.l"
{
char *name = conf_includes_pop(yyextra->includes);
free(name);
@@ -1699,12 +1686,12 @@ case YY_STATE_EOF(include):
case 80:
/* rule 80 can match eol */
YY_RULE_SETUP
-#line 308 "cf-lex.l"
+#line 308 "knot/conf/cf-lex.l"
YY_BREAK
case 81:
YY_RULE_SETUP
-#line 309 "cf-lex.l"
+#line 309 "knot/conf/cf-lex.l"
{
BEGIN(INITIAL);
@@ -1741,15 +1728,15 @@ YY_RULE_SETUP
case 82:
/* rule 82 can match eol */
YY_RULE_SETUP
-#line 342 "cf-lex.l"
+#line 342 "knot/conf/cf-lex.l"
cf_error(yyscanner, "Unterminated string.");
YY_BREAK
case 83:
YY_RULE_SETUP
-#line 344 "cf-lex.l"
+#line 344 "knot/conf/cf-lex.l"
ECHO;
YY_BREAK
-#line 1753 "knot/conf/libknotd_la-cf-lex.c"
+#line 1740 "knot/conf/libknotd_la-cf-lex.c"
case YY_END_OF_BUFFER:
{
@@ -1934,21 +1921,21 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
else
{
- int num_to_read =
+ yy_size_t num_to_read =
YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1;
while ( num_to_read <= 0 )
{ /* Not enough room in the buffer - grow it. */
/* just a shorter name for the current buffer */
- YY_BUFFER_STATE b = YY_CURRENT_BUFFER;
+ YY_BUFFER_STATE b = YY_CURRENT_BUFFER_LVALUE;
int yy_c_buf_p_offset =
(int) (yyg->yy_c_buf_p - b->yy_ch_buf);
if ( b->yy_is_our_buffer )
{
- int new_size = b->yy_buf_size * 2;
+ yy_size_t new_size = b->yy_buf_size * 2;
if ( new_size <= 0 )
b->yy_buf_size += b->yy_buf_size / 8;
@@ -1979,7 +1966,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
/* Read in more data. */
YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]),
- yyg->yy_n_chars, (size_t) num_to_read );
+ yyg->yy_n_chars, num_to_read );
YY_CURRENT_BUFFER_LVALUE->yy_n_chars = yyg->yy_n_chars;
}
@@ -2076,6 +2063,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
yy_is_jam = (yy_current_state == 445);
+ (void)yyg;
return yy_is_jam ? 0 : yy_current_state;
}
@@ -2104,7 +2092,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
else
{ /* need more input */
- int offset = yyg->yy_c_buf_p - yyg->yytext_ptr;
+ yy_size_t offset = yyg->yy_c_buf_p - yyg->yytext_ptr;
++yyg->yy_c_buf_p;
switch ( yy_get_next_buffer( yyscanner ) )
@@ -2275,10 +2263,6 @@ static void cf__load_buffer_state (yyscan_t yyscanner)
cf_free((void *) b ,yyscanner );
}
-#ifndef __cplusplus
-extern int isatty (int );
-#endif /* __cplusplus */
-
/* Initializes or reinitializes a buffer.
* This function is sometimes called more than once on the same buffer,
* such as during a cf_restart() or at EOF.
@@ -2395,7 +2379,7 @@ void cf_pop_buffer_state (yyscan_t yyscanner)
*/
static void cf_ensure_buffer_stack (yyscan_t yyscanner)
{
- int num_to_alloc;
+ yy_size_t num_to_alloc;
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
if (!yyg->yy_buffer_stack) {
@@ -2493,7 +2477,7 @@ YY_BUFFER_STATE cf__scan_string (yyconst char * yystr , yyscan_t yyscanner)
* @param yyscanner The scanner object.
* @return the newly allocated buffer state object.
*/
-YY_BUFFER_STATE cf__scan_bytes (yyconst char * yybytes, int _yybytes_len , yyscan_t yyscanner)
+YY_BUFFER_STATE cf__scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len , yyscan_t yyscanner)
{
YY_BUFFER_STATE b;
char *buf;
@@ -2608,7 +2592,7 @@ FILE *cf_get_out (yyscan_t yyscanner)
/** Get the length of the current token.
* @param yyscanner The scanner object.
*/
-int cf_get_leng (yyscan_t yyscanner)
+yy_size_t cf_get_leng (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
return yyleng;
@@ -2644,7 +2628,7 @@ void cf_set_lineno (int line_number , yyscan_t yyscanner)
/* lineno is only valid if an input buffer exists. */
if (! YY_CURRENT_BUFFER )
- yy_fatal_error( "cf_set_lineno called with no buffer" , yyscanner);
+ YY_FATAL_ERROR( "cf_set_lineno called with no buffer" );
yylineno = line_number;
}
@@ -2659,7 +2643,7 @@ void cf_set_column (int column_no , yyscan_t yyscanner)
/* column is only valid if an input buffer exists. */
if (! YY_CURRENT_BUFFER )
- yy_fatal_error( "cf_set_column called with no buffer" , yyscanner);
+ YY_FATAL_ERROR( "cf_set_column called with no buffer" );
yycolumn = column_no;
}
@@ -2883,7 +2867,7 @@ void cf_free (void * ptr , yyscan_t yyscanner)
#define YYTABLES_NAME "yytables"
-#line 344 "cf-lex.l"
+#line 344 "knot/conf/cf-lex.l"
diff --git a/src/knot/conf/libknotd_la-cf-parse.c b/src/knot/conf/libknotd_la-cf-parse.c
index 2cea00d..53a29a6 100644
--- a/src/knot/conf/libknotd_la-cf-parse.c
+++ b/src/knot/conf/libknotd_la-cf-parse.c
@@ -1,8 +1,8 @@
-/* A Bison parser, made by GNU Bison 2.5. */
+/* A Bison parser, made by GNU Bison 2.7.12-4996. */
/* Bison implementation for Yacc-like parsers in C
- Copyright (C) 1984, 1989-1990, 2000-2011 Free Software Foundation, Inc.
+ Copyright (C) 1984, 1989-1990, 2000-2013 Free Software Foundation, Inc.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -44,7 +44,7 @@
#define YYBISON 1
/* Bison version. */
-#define YYBISON_VERSION "2.5"
+#define YYBISON_VERSION "2.7.12-4996"
/* Skeleton name. */
#define YYSKELETON_NAME "yacc.c"
@@ -58,8 +58,6 @@
/* Pull parsers. */
#define YYPULL 1
-/* Using locations. */
-#define YYLSP_NEEDED 0
/* Substitute the variable and function names. */
#define yyparse cf_parse
@@ -70,11 +68,9 @@
#define yydebug cf_debug
#define yynerrs cf_nerrs
-
/* Copy the first part of user declarations. */
-
-/* Line 268 of yacc.c */
-#line 23 "cf-parse.y"
+/* Line 371 of yacc.c */
+#line 23 "knot/conf/cf-parse.y"
/* Headers */
#include <config.h>
@@ -432,14 +428,16 @@ static int conf_mask(void* scanner, int nval, int prefixlen) {
}
+/* Line 371 of yacc.c */
+#line 433 "knot/conf/libknotd_la-cf-parse.c"
-/* Line 268 of yacc.c */
-#line 438 "knot/conf/libknotd_la-cf-parse.c"
-
-/* Enabling traces. */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
+# ifndef YY_NULL
+# if defined __cplusplus && 201103L <= __cplusplus
+# define YY_NULL nullptr
+# else
+# define YY_NULL 0
+# endif
+# endif
/* Enabling verbose error messages. */
#ifdef YYERROR_VERBOSE
@@ -449,11 +447,17 @@ static int conf_mask(void* scanner, int nval, int prefixlen) {
# define YYERROR_VERBOSE 0
#endif
-/* Enabling the token table. */
-#ifndef YYTOKEN_TABLE
-# define YYTOKEN_TABLE 0
+/* In a future release of Bison, this section will be replaced
+ by #include "y.tab.h". */
+#ifndef YY_CF_Y_TAB_H_INCLUDED
+# define YY_CF_Y_TAB_H_INCLUDED
+/* Enabling traces. */
+#ifndef YYDEBUG
+# define YYDEBUG 0
+#endif
+#if YYDEBUG
+extern int cf_debug;
#endif
-
/* Tokens. */
#ifndef YYTOKENTYPE
@@ -581,13 +585,11 @@ static int conf_mask(void* scanner, int nval, int prefixlen) {
-
#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
typedef union YYSTYPE
{
-
-/* Line 293 of yacc.c */
-#line 386 "cf-parse.y"
+/* Line 387 of yacc.c */
+#line 386 "knot/conf/cf-parse.y"
struct {
char *t;
@@ -597,9 +599,8 @@ typedef union YYSTYPE
} tok;
-
-/* Line 293 of yacc.c */
-#line 603 "knot/conf/libknotd_la-cf-parse.c"
+/* Line 387 of yacc.c */
+#line 604 "knot/conf/libknotd_la-cf-parse.c"
} YYSTYPE;
# define YYSTYPE_IS_TRIVIAL 1
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
@@ -607,11 +608,26 @@ typedef union YYSTYPE
#endif
-/* Copy the second part of user declarations. */
+#ifdef YYPARSE_PARAM
+#if defined __STDC__ || defined __cplusplus
+int cf_parse (void *YYPARSE_PARAM);
+#else
+int cf_parse ();
+#endif
+#else /* ! YYPARSE_PARAM */
+#if defined __STDC__ || defined __cplusplus
+int cf_parse (void *scanner);
+#else
+int cf_parse ();
+#endif
+#endif /* ! YYPARSE_PARAM */
+
+#endif /* !YY_CF_Y_TAB_H_INCLUDED */
+/* Copy the second part of user declarations. */
-/* Line 343 of yacc.c */
-#line 615 "knot/conf/libknotd_la-cf-parse.c"
+/* Line 390 of yacc.c */
+#line 631 "knot/conf/libknotd_la-cf-parse.c"
#ifdef short
# undef short
@@ -664,24 +680,33 @@ typedef short int yytype_int16;
# if defined YYENABLE_NLS && YYENABLE_NLS
# if ENABLE_NLS
# include <libintl.h> /* INFRINGES ON USER NAME SPACE */
-# define YY_(msgid) dgettext ("bison-runtime", msgid)
+# define YY_(Msgid) dgettext ("bison-runtime", Msgid)
# endif
# endif
# ifndef YY_
-# define YY_(msgid) msgid
+# define YY_(Msgid) Msgid
+# endif
+#endif
+
+#ifndef __attribute__
+/* This feature is available in gcc versions 2.5 and later. */
+# if (! defined __GNUC__ || __GNUC__ < 2 \
+ || (__GNUC__ == 2 && __GNUC_MINOR__ < 5))
+# define __attribute__(Spec) /* empty */
# endif
#endif
/* Suppress unused-variable warnings by "using" E. */
#if ! defined lint || defined __GNUC__
-# define YYUSE(e) ((void) (e))
+# define YYUSE(E) ((void) (E))
#else
-# define YYUSE(e) /* empty */
+# define YYUSE(E) /* empty */
#endif
+
/* Identity function, used to suppress warnings about constant conditions. */
#ifndef lint
-# define YYID(n) (n)
+# define YYID(N) (N)
#else
#if (defined __STDC__ || defined __C99__FUNC__ \
|| defined __cplusplus || defined _MSC_VER)
@@ -717,6 +742,7 @@ YYID (yyi)
# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \
|| defined __cplusplus || defined _MSC_VER)
# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
+ /* Use EXIT_SUCCESS as a witness for stdlib.h. */
# ifndef EXIT_SUCCESS
# define EXIT_SUCCESS 0
# endif
@@ -808,20 +834,20 @@ union yyalloc
#endif
#if defined YYCOPY_NEEDED && YYCOPY_NEEDED
-/* Copy COUNT objects from FROM to TO. The source and destination do
+/* Copy COUNT objects from SRC to DST. The source and destination do
not overlap. */
# ifndef YYCOPY
# if defined __GNUC__ && 1 < __GNUC__
-# define YYCOPY(To, From, Count) \
- __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
+# define YYCOPY(Dst, Src, Count) \
+ __builtin_memcpy (Dst, Src, (Count) * sizeof (*(Src)))
# else
-# define YYCOPY(To, From, Count) \
- do \
- { \
- YYSIZE_T yyi; \
- for (yyi = 0; yyi < (Count); yyi++) \
- (To)[yyi] = (From)[yyi]; \
- } \
+# define YYCOPY(Dst, Src, Count) \
+ do \
+ { \
+ YYSIZE_T yyi; \
+ for (yyi = 0; yyi < (Count); yyi++) \
+ (Dst)[yyi] = (Src)[yyi]; \
+ } \
while (YYID (0))
# endif
# endif
@@ -987,7 +1013,7 @@ static const yytype_uint16 yyrline[] =
};
#endif
-#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
+#if YYDEBUG || YYERROR_VERBOSE || 0
/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
First, the terminals, then, starting at YYNTOKENS, nonterminals. */
static const char *const yytname[] =
@@ -1009,7 +1035,7 @@ static const char *const yytname[] =
"zone_acl_item", "zone_acl_list", "zone_acl", "zone_start", "zone",
"zones", "log_prios_start", "log_prios", "log_src", "log_dest",
"log_file", "log_end", "log_start", "log", "$@1", "ctl_listen_start",
- "ctl_allow_start", "control", "conf", 0
+ "ctl_allow_start", "control", "conf", YY_NULL
};
#endif
@@ -1197,10 +1223,10 @@ static const yytype_int16 yytable[] =
286, 287
};
-#define yypact_value_is_default(yystate) \
- ((yystate) == (-47))
+#define yypact_value_is_default(Yystate) \
+ (!!((Yystate) == (-47)))
-#define yytable_value_is_error(yytable_value) \
+#define yytable_value_is_error(Yytable_value) \
YYID (0)
static const yytype_int16 yycheck[] =
@@ -1299,62 +1325,35 @@ static const yytype_uint8 yystos[] =
#define YYRECOVERING() (!!yyerrstatus)
-#define YYBACKUP(Token, Value) \
-do \
- if (yychar == YYEMPTY && yylen == 1) \
- { \
- yychar = (Token); \
- yylval = (Value); \
- YYPOPSTACK (1); \
- goto yybackup; \
- } \
- else \
- { \
+#define YYBACKUP(Token, Value) \
+do \
+ if (yychar == YYEMPTY) \
+ { \
+ yychar = (Token); \
+ yylval = (Value); \
+ YYPOPSTACK (yylen); \
+ yystate = *yyssp; \
+ goto yybackup; \
+ } \
+ else \
+ { \
yyerror (scanner, YY_("syntax error: cannot back up")); \
YYERROR; \
} \
while (YYID (0))
-
+/* Error token number */
#define YYTERROR 1
#define YYERRCODE 256
-/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
- If N is 0, then set CURRENT to the empty location which ends
- the previous symbol: RHS[0] (always defined). */
-
-#define YYRHSLOC(Rhs, K) ((Rhs)[K])
-#ifndef YYLLOC_DEFAULT
-# define YYLLOC_DEFAULT(Current, Rhs, N) \
- do \
- if (YYID (N)) \
- { \
- (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \
- (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \
- (Current).last_line = YYRHSLOC (Rhs, N).last_line; \
- (Current).last_column = YYRHSLOC (Rhs, N).last_column; \
- } \
- else \
- { \
- (Current).first_line = (Current).last_line = \
- YYRHSLOC (Rhs, 0).last_line; \
- (Current).first_column = (Current).last_column = \
- YYRHSLOC (Rhs, 0).last_column; \
- } \
- while (YYID (0))
-#endif
-
-
/* This macro is provided for backward compatibility. */
-
#ifndef YY_LOCATION_PRINT
# define YY_LOCATION_PRINT(File, Loc) ((void) 0)
#endif
/* YYLEX -- calling `yylex' with the right arguments. */
-
#ifdef YYLEX_PARAM
# define YYLEX yylex (&yylval, YYLEX_PARAM)
#else
@@ -1405,6 +1404,8 @@ yy_symbol_value_print (yyoutput, yytype, yyvaluep, scanner)
void *scanner;
#endif
{
+ FILE *yyo = yyoutput;
+ YYUSE (yyo);
if (!yyvaluep)
return;
YYUSE (scanner);
@@ -1414,11 +1415,7 @@ yy_symbol_value_print (yyoutput, yytype, yyvaluep, scanner)
# else
YYUSE (yyoutput);
# endif
- switch (yytype)
- {
- default:
- break;
- }
+ YYUSE (yytype);
}
@@ -1659,12 +1656,11 @@ static int
yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
yytype_int16 *yyssp, int yytoken)
{
- YYSIZE_T yysize0 = yytnamerr (0, yytname[yytoken]);
+ YYSIZE_T yysize0 = yytnamerr (YY_NULL, yytname[yytoken]);
YYSIZE_T yysize = yysize0;
- YYSIZE_T yysize1;
enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
/* Internationalized format string. */
- const char *yyformat = 0;
+ const char *yyformat = YY_NULL;
/* Arguments of yyformat. */
char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
/* Number of reported tokens (one for the "unexpected", one per
@@ -1724,11 +1720,13 @@ yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
break;
}
yyarg[yycount++] = yytname[yyx];
- yysize1 = yysize + yytnamerr (0, yytname[yyx]);
- if (! (yysize <= yysize1
- && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
- return 2;
- yysize = yysize1;
+ {
+ YYSIZE_T yysize1 = yysize + yytnamerr (YY_NULL, yytname[yyx]);
+ if (! (yysize <= yysize1
+ && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
+ return 2;
+ yysize = yysize1;
+ }
}
}
}
@@ -1748,10 +1746,12 @@ yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg,
# undef YYCASE_
}
- yysize1 = yysize + yystrlen (yyformat);
- if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
- return 2;
- yysize = yysize1;
+ {
+ YYSIZE_T yysize1 = yysize + yystrlen (yyformat);
+ if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM))
+ return 2;
+ yysize = yysize1;
+ }
if (*yymsg_alloc < yysize)
{
@@ -1809,29 +1809,10 @@ yydestruct (yymsg, yytype, yyvaluep, scanner)
yymsg = "Deleting";
YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
- switch (yytype)
- {
-
- default:
- break;
- }
+ YYUSE (yytype);
}
-/* Prevent warnings from -Wmissing-prototypes. */
-#ifdef YYPARSE_PARAM
-#if defined __STDC__ || defined __cplusplus
-int yyparse (void *YYPARSE_PARAM);
-#else
-int yyparse ();
-#endif
-#else /* ! YYPARSE_PARAM */
-#if defined __STDC__ || defined __cplusplus
-int yyparse (void *scanner);
-#else
-int yyparse ();
-#endif
-#endif /* ! YYPARSE_PARAM */
/*----------.
@@ -1863,8 +1844,31 @@ yyparse (scanner)
/* The lookahead symbol. */
int yychar;
+
+#if defined __GNUC__ && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
+/* Suppress an incorrect diagnostic about yylval being uninitialized. */
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"")\
+ _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
+# define YY_IGNORE_MAYBE_UNINITIALIZED_END \
+ _Pragma ("GCC diagnostic pop")
+#else
+/* Default value used for initialization, for pacifying older GCCs
+ or non-GCC compilers. */
+static YYSTYPE yyval_default;
+# define YY_INITIAL_VALUE(Value) = Value
+#endif
+#ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
+# define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
+# define YY_IGNORE_MAYBE_UNINITIALIZED_END
+#endif
+#ifndef YY_INITIAL_VALUE
+# define YY_INITIAL_VALUE(Value) /* Nothing. */
+#endif
+
/* The semantic value of the lookahead symbol. */
-YYSTYPE yylval;
+YYSTYPE yylval YY_INITIAL_VALUE(yyval_default);
/* Number of syntax errors so far. */
int yynerrs;
@@ -1877,7 +1881,7 @@ YYSTYPE yylval;
`yyss': related to states.
`yyvs': related to semantic values.
- Refer to the stacks thru separate pointers, to allow yyoverflow
+ Refer to the stacks through separate pointers, to allow yyoverflow
to reallocate them elsewhere. */
/* The state stack. */
@@ -1895,7 +1899,7 @@ YYSTYPE yylval;
int yyn;
int yyresult;
/* Lookahead token as an internal (translated) token number. */
- int yytoken;
+ int yytoken = 0;
/* The variables used to return semantic value and location from the
action routines. */
YYSTYPE yyval;
@@ -1913,9 +1917,8 @@ YYSTYPE yylval;
Keep to zero when no symbol should be popped. */
int yylen = 0;
- yytoken = 0;
- yyss = yyssa;
- yyvs = yyvsa;
+ yyssp = yyss = yyssa;
+ yyvsp = yyvs = yyvsa;
yystacksize = YYINITDEPTH;
YYDPRINTF ((stderr, "Starting parse\n"));
@@ -1924,14 +1927,6 @@ YYSTYPE yylval;
yyerrstatus = 0;
yynerrs = 0;
yychar = YYEMPTY; /* Cause a token to be read. */
-
- /* Initialize stack pointers.
- Waste one element of value and location stack
- so that they stay on the same level as the state stack.
- The wasted elements are never initialized. */
- yyssp = yyss;
- yyvsp = yyvs;
-
goto yysetstate;
/*------------------------------------------------------------.
@@ -2072,7 +2067,9 @@ yybackup:
yychar = YYEMPTY;
yystate = yyn;
+ YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
*++yyvsp = yylval;
+ YY_IGNORE_MAYBE_UNINITIALIZED_END
goto yynewstate;
@@ -2109,58 +2106,50 @@ yyreduce:
switch (yyn)
{
case 2:
-
-/* Line 1806 of yacc.c */
-#line 448 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 448 "knot/conf/cf-parse.y"
{ return 0; }
break;
case 6:
-
-/* Line 1806 of yacc.c */
-#line 456 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 456 "knot/conf/cf-parse.y"
{ conf_start_iface(scanner, (yyvsp[(1) - (1)].tok).t); }
break;
case 7:
-
-/* Line 1806 of yacc.c */
-#line 457 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 457 "knot/conf/cf-parse.y"
{ conf_start_iface(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 8:
-
-/* Line 1806 of yacc.c */
-#line 458 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 458 "knot/conf/cf-parse.y"
{ conf_start_iface(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 9:
-
-/* Line 1806 of yacc.c */
-#line 459 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 459 "knot/conf/cf-parse.y"
{ conf_start_iface(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 10:
-
-/* Line 1806 of yacc.c */
-#line 460 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 460 "knot/conf/cf-parse.y"
{ conf_start_iface(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 11:
-
-/* Line 1806 of yacc.c */
-#line 461 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 461 "knot/conf/cf-parse.y"
{ conf_start_iface(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 13:
-
-/* Line 1806 of yacc.c */
-#line 465 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 465 "knot/conf/cf-parse.y"
{
if (this_iface->port > 0) {
cf_error(scanner, "only one port definition is allowed in interface section\n");
@@ -2171,9 +2160,8 @@ yyreduce:
break;
case 14:
-
-/* Line 1806 of yacc.c */
-#line 472 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 472 "knot/conf/cf-parse.y"
{
if (this_iface->address != 0) {
cf_error(scanner, "only one address is allowed in interface section\n");
@@ -2185,9 +2173,8 @@ yyreduce:
break;
case 15:
-
-/* Line 1806 of yacc.c */
-#line 480 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 480 "knot/conf/cf-parse.y"
{
if (this_iface->address != 0) {
cf_error(scanner, "only one address is allowed in interface section\n");
@@ -2204,9 +2191,8 @@ yyreduce:
break;
case 16:
-
-/* Line 1806 of yacc.c */
-#line 493 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 493 "knot/conf/cf-parse.y"
{
if (this_iface->address != 0) {
cf_error(scanner, "only one address is allowed in interface section\n");
@@ -2218,9 +2204,8 @@ yyreduce:
break;
case 17:
-
-/* Line 1806 of yacc.c */
-#line 501 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 501 "knot/conf/cf-parse.y"
{
if (this_iface->address != 0) {
cf_error(scanner, "only one address is allowed in interface section\n");
@@ -2237,9 +2222,8 @@ yyreduce:
break;
case 19:
-
-/* Line 1806 of yacc.c */
-#line 518 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 518 "knot/conf/cf-parse.y"
{
if (this_iface->address == 0) {
cf_error(scanner, "interface '%s' has no defined address", this_iface->name);
@@ -2248,65 +2232,56 @@ yyreduce:
break;
case 21:
-
-/* Line 1806 of yacc.c */
-#line 527 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 527 "knot/conf/cf-parse.y"
{ new_config->version = (yyvsp[(3) - (4)].tok).t; }
break;
case 22:
-
-/* Line 1806 of yacc.c */
-#line 528 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 528 "knot/conf/cf-parse.y"
{ new_config->identity = (yyvsp[(3) - (4)].tok).t; }
break;
case 23:
-
-/* Line 1806 of yacc.c */
-#line 529 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 529 "knot/conf/cf-parse.y"
{ new_config->hostname = (yyvsp[(3) - (4)].tok).t; }
break;
case 24:
-
-/* Line 1806 of yacc.c */
-#line 530 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 530 "knot/conf/cf-parse.y"
{ new_config->nsid = (yyvsp[(3) - (4)].tok).t; new_config->nsid_len = (yyvsp[(3) - (4)].tok).l; }
break;
case 25:
-
-/* Line 1806 of yacc.c */
-#line 531 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 531 "knot/conf/cf-parse.y"
{ new_config->nsid = (yyvsp[(3) - (4)].tok).t; new_config->nsid_len = strlen(new_config->nsid); }
break;
case 26:
-
-/* Line 1806 of yacc.c */
-#line 532 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 532 "knot/conf/cf-parse.y"
{ new_config->storage = (yyvsp[(3) - (4)].tok).t; }
break;
case 27:
-
-/* Line 1806 of yacc.c */
-#line 533 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 533 "knot/conf/cf-parse.y"
{ new_config->rundir = (yyvsp[(3) - (4)].tok).t; }
break;
case 28:
-
-/* Line 1806 of yacc.c */
-#line 534 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 534 "knot/conf/cf-parse.y"
{ new_config->pidfile = (yyvsp[(3) - (4)].tok).t; }
break;
case 29:
-
-/* Line 1806 of yacc.c */
-#line 535 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 535 "knot/conf/cf-parse.y"
{
fprintf(stderr, "warning: Config option 'system.key' is deprecated "
"and has no effect.\n");
@@ -2315,9 +2290,8 @@ yyreduce:
break;
case 30:
-
-/* Line 1806 of yacc.c */
-#line 540 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 540 "knot/conf/cf-parse.y"
{
if ((yyvsp[(3) - (4)].tok).i <= 0) {
cf_error(scanner, "worker count must be greater than 0\n");
@@ -2328,9 +2302,8 @@ yyreduce:
break;
case 31:
-
-/* Line 1806 of yacc.c */
-#line 547 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 547 "knot/conf/cf-parse.y"
{
new_config->uid = new_config->gid = -1; // Invalidate
char* dpos = strchr((yyvsp[(3) - (4)].tok).t, '.'); // Find uid.gid format
@@ -2355,65 +2328,56 @@ yyreduce:
break;
case 32:
-
-/* Line 1806 of yacc.c */
-#line 568 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 568 "knot/conf/cf-parse.y"
{ new_config->max_conn_idle = (yyvsp[(3) - (4)].tok).i; }
break;
case 33:
-
-/* Line 1806 of yacc.c */
-#line 569 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 569 "knot/conf/cf-parse.y"
{ new_config->max_conn_hs = (yyvsp[(3) - (4)].tok).i; }
break;
case 34:
-
-/* Line 1806 of yacc.c */
-#line 570 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 570 "knot/conf/cf-parse.y"
{ new_config->max_conn_reply = (yyvsp[(3) - (4)].tok).i; }
break;
case 35:
-
-/* Line 1806 of yacc.c */
-#line 571 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 571 "knot/conf/cf-parse.y"
{ new_config->rrl = (yyvsp[(3) - (4)].tok).i; }
break;
case 36:
-
-/* Line 1806 of yacc.c */
-#line 572 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 572 "knot/conf/cf-parse.y"
{ new_config->rrl_size = (yyvsp[(3) - (4)].tok).l; }
break;
case 37:
-
-/* Line 1806 of yacc.c */
-#line 573 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 573 "knot/conf/cf-parse.y"
{ new_config->rrl_size = (yyvsp[(3) - (4)].tok).i; }
break;
case 38:
-
-/* Line 1806 of yacc.c */
-#line 574 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 574 "knot/conf/cf-parse.y"
{ new_config->rrl_slip = (yyvsp[(3) - (4)].tok).i; }
break;
case 39:
-
-/* Line 1806 of yacc.c */
-#line 575 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 575 "knot/conf/cf-parse.y"
{ new_config->xfers = (yyvsp[(3) - (4)].tok).i; }
break;
case 41:
-
-/* Line 1806 of yacc.c */
-#line 580 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 580 "knot/conf/cf-parse.y"
{
/* Check algorithm length. */
if (knot_tsig_digest_length((yyvsp[(3) - (5)].tok).alg) == 0) {
@@ -2467,44 +2431,38 @@ yyreduce:
break;
case 43:
-
-/* Line 1806 of yacc.c */
-#line 632 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 632 "knot/conf/cf-parse.y"
{ conf_start_remote(scanner, (yyvsp[(1) - (1)].tok).t); }
break;
case 44:
-
-/* Line 1806 of yacc.c */
-#line 633 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 633 "knot/conf/cf-parse.y"
{ conf_start_remote(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 45:
-
-/* Line 1806 of yacc.c */
-#line 634 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 634 "knot/conf/cf-parse.y"
{ conf_start_remote(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 46:
-
-/* Line 1806 of yacc.c */
-#line 635 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 635 "knot/conf/cf-parse.y"
{ conf_start_remote(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 47:
-
-/* Line 1806 of yacc.c */
-#line 636 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 636 "knot/conf/cf-parse.y"
{ conf_start_remote(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 49:
-
-/* Line 1806 of yacc.c */
-#line 640 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 640 "knot/conf/cf-parse.y"
{
if (this_remote->port != 0) {
cf_error(scanner, "only one port definition is allowed in remote section\n");
@@ -2515,9 +2473,8 @@ yyreduce:
break;
case 50:
-
-/* Line 1806 of yacc.c */
-#line 647 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 647 "knot/conf/cf-parse.y"
{
if (this_remote->address != 0) {
cf_error(scanner, "only one address is allowed in remote section\n");
@@ -2530,9 +2487,8 @@ yyreduce:
break;
case 51:
-
-/* Line 1806 of yacc.c */
-#line 656 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 656 "knot/conf/cf-parse.y"
{
if (this_remote->address != 0) {
cf_error(scanner, "only one address is allowed in remote section\n");
@@ -2545,9 +2501,8 @@ yyreduce:
break;
case 52:
-
-/* Line 1806 of yacc.c */
-#line 665 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 665 "knot/conf/cf-parse.y"
{
if (this_remote->address != 0) {
cf_error(scanner, "only one address is allowed in remote section\n");
@@ -2565,9 +2520,8 @@ yyreduce:
break;
case 53:
-
-/* Line 1806 of yacc.c */
-#line 679 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 679 "knot/conf/cf-parse.y"
{
if (this_remote->address != 0) {
cf_error(scanner, "only one address is allowed in remote section\n");
@@ -2580,9 +2534,8 @@ yyreduce:
break;
case 54:
-
-/* Line 1806 of yacc.c */
-#line 688 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 688 "knot/conf/cf-parse.y"
{
if (this_remote->address != 0) {
cf_error(scanner, "only one address is allowed in remote section\n");
@@ -2595,9 +2548,8 @@ yyreduce:
break;
case 55:
-
-/* Line 1806 of yacc.c */
-#line 697 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 697 "knot/conf/cf-parse.y"
{
if (this_remote->address != 0) {
cf_error(scanner, "only one address is allowed in remote section\n");
@@ -2615,9 +2567,8 @@ yyreduce:
break;
case 56:
-
-/* Line 1806 of yacc.c */
-#line 711 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 711 "knot/conf/cf-parse.y"
{
if (this_remote->key != 0) {
cf_error(scanner, "only one TSIG key definition is allowed in remote section\n");
@@ -2629,9 +2580,8 @@ yyreduce:
break;
case 57:
-
-/* Line 1806 of yacc.c */
-#line 719 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 719 "knot/conf/cf-parse.y"
{
sockaddr_set(&this_remote->via, AF_INET, (yyvsp[(3) - (4)].tok).t, 0);
free((yyvsp[(3) - (4)].tok).t);
@@ -2639,9 +2589,8 @@ yyreduce:
break;
case 58:
-
-/* Line 1806 of yacc.c */
-#line 723 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 723 "knot/conf/cf-parse.y"
{
sockaddr_set(&this_remote->via, AF_INET6, (yyvsp[(3) - (4)].tok).t, 0);
free((yyvsp[(3) - (4)].tok).t);
@@ -2649,9 +2598,8 @@ yyreduce:
break;
case 59:
-
-/* Line 1806 of yacc.c */
-#line 727 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 727 "knot/conf/cf-parse.y"
{
conf_remote_set_via(scanner, (yyvsp[(3) - (4)].tok).t);
free((yyvsp[(3) - (4)].tok).t);
@@ -2659,9 +2607,8 @@ yyreduce:
break;
case 61:
-
-/* Line 1806 of yacc.c */
-#line 735 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 735 "knot/conf/cf-parse.y"
{
if (this_remote->address == 0) {
cf_error(scanner, "remote '%s' has no defined address", this_remote->name);
@@ -2670,103 +2617,90 @@ yyreduce:
break;
case 62:
-
-/* Line 1806 of yacc.c */
-#line 743 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 743 "knot/conf/cf-parse.y"
{ conf_add_member_into_group(scanner, (yyvsp[(1) - (1)].tok).t); }
break;
case 66:
-
-/* Line 1806 of yacc.c */
-#line 753 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 753 "knot/conf/cf-parse.y"
{ conf_start_group(scanner, (yyvsp[(1) - (1)].tok).t); }
break;
case 69:
-
-/* Line 1806 of yacc.c */
-#line 762 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 762 "knot/conf/cf-parse.y"
{
this_list = &this_zone->acl.xfr_in;
}
break;
case 70:
-
-/* Line 1806 of yacc.c */
-#line 765 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 765 "knot/conf/cf-parse.y"
{
this_list = &this_zone->acl.xfr_out;
}
break;
case 71:
-
-/* Line 1806 of yacc.c */
-#line 768 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 768 "knot/conf/cf-parse.y"
{
this_list = &this_zone->acl.notify_in;
}
break;
case 72:
-
-/* Line 1806 of yacc.c */
-#line 771 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 771 "knot/conf/cf-parse.y"
{
this_list = &this_zone->acl.notify_out;
}
break;
case 73:
-
-/* Line 1806 of yacc.c */
-#line 774 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 774 "knot/conf/cf-parse.y"
{
this_list = &this_zone->acl.update_in;
}
break;
case 75:
-
-/* Line 1806 of yacc.c */
-#line 780 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 780 "knot/conf/cf-parse.y"
{ conf_acl_item(scanner, (yyvsp[(1) - (1)].tok).t); }
break;
case 76:
-
-/* Line 1806 of yacc.c */
-#line 781 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 781 "knot/conf/cf-parse.y"
{ conf_acl_item(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 77:
-
-/* Line 1806 of yacc.c */
-#line 782 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 782 "knot/conf/cf-parse.y"
{ conf_acl_item(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 78:
-
-/* Line 1806 of yacc.c */
-#line 783 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 783 "knot/conf/cf-parse.y"
{ conf_acl_item(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 79:
-
-/* Line 1806 of yacc.c */
-#line 784 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 784 "knot/conf/cf-parse.y"
{ conf_acl_item(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 84:
-
-/* Line 1806 of yacc.c */
-#line 793 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 793 "knot/conf/cf-parse.y"
{
/* Find existing node in remotes. */
node* r = 0; conf_iface_t* found = 0;
@@ -2796,51 +2730,44 @@ yyreduce:
break;
case 86:
-
-/* Line 1806 of yacc.c */
-#line 822 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 822 "knot/conf/cf-parse.y"
{ conf_zone_start(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 87:
-
-/* Line 1806 of yacc.c */
-#line 823 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 823 "knot/conf/cf-parse.y"
{ conf_zone_start(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 88:
-
-/* Line 1806 of yacc.c */
-#line 824 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 824 "knot/conf/cf-parse.y"
{ conf_zone_start(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 89:
-
-/* Line 1806 of yacc.c */
-#line 825 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 825 "knot/conf/cf-parse.y"
{ conf_zone_start(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 90:
-
-/* Line 1806 of yacc.c */
-#line 826 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 826 "knot/conf/cf-parse.y"
{ conf_zone_start(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 91:
-
-/* Line 1806 of yacc.c */
-#line 827 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 827 "knot/conf/cf-parse.y"
{ conf_zone_start(scanner, strdup((yyvsp[(1) - (1)].tok).t)); }
break;
case 92:
-
-/* Line 1806 of yacc.c */
-#line 828 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 828 "knot/conf/cf-parse.y"
{
if ((yyvsp[(1) - (3)].tok).i < 0 || (yyvsp[(1) - (3)].tok).i > 255) {
cf_error(scanner, "rfc2317 origin prefix '%ld' out of bounds", (yyvsp[(1) - (3)].tok).i);
@@ -2861,72 +2788,62 @@ yyreduce:
break;
case 93:
-
-/* Line 1806 of yacc.c */
-#line 845 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 845 "knot/conf/cf-parse.y"
{ conf_zone_start(scanner, (yyvsp[(1) - (1)].tok).t); }
break;
case 97:
-
-/* Line 1806 of yacc.c */
-#line 852 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 852 "knot/conf/cf-parse.y"
{ this_zone->file = (yyvsp[(3) - (4)].tok).t; }
break;
case 98:
-
-/* Line 1806 of yacc.c */
-#line 853 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 853 "knot/conf/cf-parse.y"
{ this_zone->build_diffs = (yyvsp[(3) - (4)].tok).i; }
break;
case 99:
-
-/* Line 1806 of yacc.c */
-#line 854 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 854 "knot/conf/cf-parse.y"
{ this_zone->enable_checks = (yyvsp[(3) - (4)].tok).i; }
break;
case 100:
-
-/* Line 1806 of yacc.c */
-#line 855 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 855 "knot/conf/cf-parse.y"
{ this_zone->disable_any = (yyvsp[(3) - (4)].tok).i; }
break;
case 101:
-
-/* Line 1806 of yacc.c */
-#line 856 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 856 "knot/conf/cf-parse.y"
{ this_zone->dbsync_timeout = (yyvsp[(3) - (4)].tok).i; }
break;
case 102:
-
-/* Line 1806 of yacc.c */
-#line 857 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 857 "knot/conf/cf-parse.y"
{ this_zone->dbsync_timeout = (yyvsp[(3) - (4)].tok).i; }
break;
case 103:
-
-/* Line 1806 of yacc.c */
-#line 858 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 858 "knot/conf/cf-parse.y"
{ new_config->ixfr_fslimit = (yyvsp[(3) - (4)].tok).l; }
break;
case 104:
-
-/* Line 1806 of yacc.c */
-#line 859 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 859 "knot/conf/cf-parse.y"
{ this_zone->ixfr_fslimit = (yyvsp[(3) - (4)].tok).i; }
break;
case 105:
-
-/* Line 1806 of yacc.c */
-#line 860 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 860 "knot/conf/cf-parse.y"
{
if ((yyvsp[(3) - (4)].tok).i < 1) {
cf_error(scanner, "notify retries must be positive integer");
@@ -2937,9 +2854,8 @@ yyreduce:
break;
case 106:
-
-/* Line 1806 of yacc.c */
-#line 867 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 867 "knot/conf/cf-parse.y"
{
if ((yyvsp[(3) - (4)].tok).i < 1) {
cf_error(scanner, "notify timeout must be positive integer");
@@ -2950,44 +2866,38 @@ yyreduce:
break;
case 109:
-
-/* Line 1806 of yacc.c */
-#line 879 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 879 "knot/conf/cf-parse.y"
{ new_config->disable_any = (yyvsp[(3) - (4)].tok).i; }
break;
case 110:
-
-/* Line 1806 of yacc.c */
-#line 880 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 880 "knot/conf/cf-parse.y"
{ new_config->build_diffs = (yyvsp[(3) - (4)].tok).i; }
break;
case 111:
-
-/* Line 1806 of yacc.c */
-#line 881 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 881 "knot/conf/cf-parse.y"
{ new_config->zone_checks = (yyvsp[(3) - (4)].tok).i; }
break;
case 112:
-
-/* Line 1806 of yacc.c */
-#line 882 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 882 "knot/conf/cf-parse.y"
{ new_config->ixfr_fslimit = (yyvsp[(3) - (4)].tok).l; }
break;
case 113:
-
-/* Line 1806 of yacc.c */
-#line 883 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 883 "knot/conf/cf-parse.y"
{ new_config->ixfr_fslimit = (yyvsp[(3) - (4)].tok).i; }
break;
case 114:
-
-/* Line 1806 of yacc.c */
-#line 884 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 884 "knot/conf/cf-parse.y"
{
if ((yyvsp[(3) - (4)].tok).i < 1) {
cf_error(scanner, "notify retries must be positive integer");
@@ -2998,9 +2908,8 @@ yyreduce:
break;
case 115:
-
-/* Line 1806 of yacc.c */
-#line 891 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 891 "knot/conf/cf-parse.y"
{
if ((yyvsp[(3) - (4)].tok).i < 1) {
cf_error(scanner, "notify timeout must be positive integer");
@@ -3011,9 +2920,8 @@ yyreduce:
break;
case 116:
-
-/* Line 1806 of yacc.c */
-#line 898 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 898 "knot/conf/cf-parse.y"
{
if ((yyvsp[(3) - (4)].tok).i < 1) {
cf_error(scanner, "zonefile sync timeout must be positive integer");
@@ -3024,16 +2932,14 @@ yyreduce:
break;
case 117:
-
-/* Line 1806 of yacc.c */
-#line 905 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 905 "knot/conf/cf-parse.y"
{ new_config->dbsync_timeout = (yyvsp[(3) - (4)].tok).i; }
break;
case 118:
-
-/* Line 1806 of yacc.c */
-#line 908 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 908 "knot/conf/cf-parse.y"
{
this_logmap = malloc(sizeof(conf_log_map_t));
this_logmap->source = 0;
@@ -3043,23 +2949,20 @@ yyreduce:
break;
case 120:
-
-/* Line 1806 of yacc.c */
-#line 918 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 918 "knot/conf/cf-parse.y"
{ this_logmap->prios |= (yyvsp[(2) - (3)].tok).i; }
break;
case 121:
-
-/* Line 1806 of yacc.c */
-#line 919 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 919 "knot/conf/cf-parse.y"
{ this_logmap->prios |= (yyvsp[(2) - (3)].tok).i; }
break;
case 123:
-
-/* Line 1806 of yacc.c */
-#line 923 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 923 "knot/conf/cf-parse.y"
{
this_logmap->source = (yyvsp[(2) - (3)].tok).i;
this_logmap = 0;
@@ -3067,9 +2970,8 @@ yyreduce:
break;
case 124:
-
-/* Line 1806 of yacc.c */
-#line 929 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 929 "knot/conf/cf-parse.y"
{
/* Find already existing rule. */
this_log = 0;
@@ -3094,9 +2996,8 @@ yyreduce:
break;
case 125:
-
-/* Line 1806 of yacc.c */
-#line 952 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 952 "knot/conf/cf-parse.y"
{
/* Find already existing rule. */
this_log = 0;
@@ -3125,47 +3026,41 @@ yyreduce:
break;
case 126:
-
-/* Line 1806 of yacc.c */
-#line 979 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 979 "knot/conf/cf-parse.y"
{
}
break;
case 130:
-
-/* Line 1806 of yacc.c */
-#line 988 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 988 "knot/conf/cf-parse.y"
{ new_config->logs_count = 0; }
break;
case 132:
-
-/* Line 1806 of yacc.c */
-#line 992 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 992 "knot/conf/cf-parse.y"
{ conf_init_iface(scanner, NULL, -1); }
break;
case 133:
-
-/* Line 1806 of yacc.c */
-#line 996 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 996 "knot/conf/cf-parse.y"
{
this_list = &new_config->ctl.allow;
}
break;
case 134:
-
-/* Line 1806 of yacc.c */
-#line 1002 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 1002 "knot/conf/cf-parse.y"
{ new_config->ctl.have = true; }
break;
case 135:
-
-/* Line 1806 of yacc.c */
-#line 1003 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 1003 "knot/conf/cf-parse.y"
{
if (this_iface->address == 0) {
cf_error(scanner, "control interface has no defined address");
@@ -3176,9 +3071,8 @@ yyreduce:
break;
case 136:
-
-/* Line 1806 of yacc.c */
-#line 1010 "cf-parse.y"
+/* Line 1787 of yacc.c */
+#line 1010 "knot/conf/cf-parse.y"
{
this_iface->address = (yyvsp[(3) - (4)].tok).t;
this_iface->family = AF_UNIX;
@@ -3188,9 +3082,8 @@ yyreduce:
break;
-
-/* Line 1806 of yacc.c */
-#line 3194 "knot/conf/libknotd_la-cf-parse.c"
+/* Line 1787 of yacc.c */
+#line 3087 "knot/conf/libknotd_la-cf-parse.c"
default: break;
}
/* User semantic actions sometimes alter yychar, and that requires
@@ -3353,7 +3246,9 @@ yyerrlab1:
YY_STACK_PRINT (yyss, yyssp);
}
+ YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
*++yyvsp = yylval;
+ YY_IGNORE_MAYBE_UNINITIALIZED_END
/* Shift the error token. */
@@ -3377,7 +3272,7 @@ yyabortlab:
yyresult = 1;
goto yyreturn;
-#if !defined(yyoverflow) || YYERROR_VERBOSE
+#if !defined yyoverflow || YYERROR_VERBOSE
/*-------------------------------------------------.
| yyexhaustedlab -- memory exhaustion comes here. |
`-------------------------------------------------*/
@@ -3419,8 +3314,6 @@ yyreturn:
}
-
-/* Line 2067 of yacc.c */
-#line 1022 "cf-parse.y"
-
+/* Line 2050 of yacc.c */
+#line 1022 "knot/conf/cf-parse.y"
diff --git a/src/knot/conf/libknotd_la-cf-parse.h b/src/knot/conf/libknotd_la-cf-parse.h
index d95ad8c..b90709e 100644
--- a/src/knot/conf/libknotd_la-cf-parse.h
+++ b/src/knot/conf/libknotd_la-cf-parse.h
@@ -1,8 +1,8 @@
-/* A Bison parser, made by GNU Bison 2.5. */
+/* A Bison parser, made by GNU Bison 2.7.12-4996. */
/* Bison interface for Yacc-like parsers in C
- Copyright (C) 1984, 1989-1990, 2000-2011 Free Software Foundation, Inc.
+ Copyright (C) 1984, 1989-1990, 2000-2013 Free Software Foundation, Inc.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -30,6 +30,15 @@
This special exception was added by the Free Software Foundation in
version 2.2 of Bison. */
+#ifndef YY_CF_Y_TAB_H_INCLUDED
+# define YY_CF_Y_TAB_H_INCLUDED
+/* Enabling traces. */
+#ifndef YYDEBUG
+# define YYDEBUG 0
+#endif
+#if YYDEBUG
+extern int cf_debug;
+#endif
/* Tokens. */
#ifndef YYTOKENTYPE
@@ -157,13 +166,11 @@
-
#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
typedef union YYSTYPE
{
-
-/* Line 2068 of yacc.c */
-#line 386 "cf-parse.y"
+/* Line 2053 of yacc.c */
+#line 386 "knot/conf/cf-parse.y"
struct {
char *t;
@@ -173,9 +180,8 @@ typedef union YYSTYPE
} tok;
-
-/* Line 2068 of yacc.c */
-#line 179 "knot/conf/libknotd_la-cf-parse.h"
+/* Line 2053 of yacc.c */
+#line 185 "knot/conf/libknotd_la-cf-parse.h"
} YYSTYPE;
# define YYSTYPE_IS_TRIVIAL 1
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
@@ -183,5 +189,18 @@ typedef union YYSTYPE
#endif
+#ifdef YYPARSE_PARAM
+#if defined __STDC__ || defined __cplusplus
+int cf_parse (void *YYPARSE_PARAM);
+#else
+int cf_parse ();
+#endif
+#else /* ! YYPARSE_PARAM */
+#if defined __STDC__ || defined __cplusplus
+int cf_parse (void *scanner);
+#else
+int cf_parse ();
+#endif
+#endif /* ! YYPARSE_PARAM */
-
+#endif /* !YY_CF_Y_TAB_H_INCLUDED */
diff --git a/src/knot/ctl/knotc_main.c b/src/knot/ctl/knotc_main.c
index e2c42a1..23d49ee 100644
--- a/src/knot/ctl/knotc_main.c
+++ b/src/knot/ctl/knotc_main.c
@@ -25,12 +25,6 @@
#ifdef HAVE_SYS_STAT_H
#include <sys/stat.h>
#endif
-#ifdef HAVE_SYS_SELECT_H
-#include <sys/select.h>
-#endif
-#ifdef HAVE_SYS_WAIT_H
-#include <sys/wait.h>
-#endif
#include "knot/knot.h"
#include "common/descriptor.h"
@@ -51,9 +45,7 @@ enum knotc_flag_t {
F_NULL = 0 << 0,
F_FORCE = 1 << 0,
F_VERBOSE = 1 << 1,
- F_WAIT = 1 << 2,
F_INTERACTIVE = 1 << 3,
- F_AUTO = 1 << 4,
F_UNPRIVILEGED = 1 << 5,
F_NOCONF = 1 << 6,
F_DRYRUN = 1 << 7
@@ -415,7 +407,6 @@ int main(int argc, char **argv)
/* Long options. */
struct option opts[] = {
- {"wait", no_argument, 0, 'w'},
{"force", no_argument, 0, 'f'},
{"config", required_argument, 0, 'c'},
{"verbose", no_argument, 0, 'v'},
@@ -429,7 +420,7 @@ int main(int argc, char **argv)
{0, 0, 0, 0}
};
- while ((c = getopt_long(argc, argv, "s:p:y:k:wfc:viVh", opts, &li)) != -1) {
+ while ((c = getopt_long(argc, argv, "s:p:y:k:fc:viVh", opts, &li)) != -1) {
switch (c) {
case 's':
r_addr = optarg;
@@ -453,9 +444,6 @@ int main(int argc, char **argv)
goto exit;
}
break;
- case 'w':
- flags |= F_WAIT;
- break;
case 'f':
flags |= F_FORCE;
break;
diff --git a/src/knot/server/dthreads.c b/src/knot/server/dthreads.c
index 759faf2..0f9235f 100644
--- a/src/knot/server/dthreads.c
+++ b/src/knot/server/dthreads.c
@@ -88,7 +88,6 @@ static inline int dt_update_thread(dthread_t *thread, int state)
unlock_thread_rw(thread);
// Notify thread
- dt_signalize(thread, SIGALRM);
pthread_cond_broadcast(&unit->_notify);
pthread_mutex_unlock(&unit->_notify_mx);
} else {
@@ -134,7 +133,7 @@ static void *thread_ep(void *data)
sigaddset(&ignset, SIGHUP);
sigaddset(&ignset, SIGPIPE);
sigaddset(&ignset, SIGUSR1);
- pthread_sigmask(SIG_BLOCK, &ignset, 0); /*! \todo Review under BSD (issue #1441). */
+ pthread_sigmask(SIG_BLOCK, &ignset, 0);
rcu_register_thread();
dbg_dt("dthreads: [%p] entered ep\n", thread);
diff --git a/src/knot/server/server.c b/src/knot/server/server.c
index 7244d3c..2e9b4c5 100644
--- a/src/knot/server/server.c
+++ b/src/knot/server/server.c
@@ -592,7 +592,10 @@ int server_conf_hook(const struct conf_t *conf, void *data)
if (udp_size < 2) udp_size = 2;
dt_unit_t *tu = dt_create_coherent(udp_size, &udp_master, NULL);
server_init_handler(server->h + IO_UDP, server, tu, NULL);
- tu = dt_create(tu_size * 2);
+
+ /* Create at least CONFIG_XFERS threads for TCP for faster
+ * processing of massive bootstrap queries. */
+ tu = dt_create(MAX(tu_size * 2, CONFIG_XFERS));
server_init_handler(server->h + IO_TCP, server, tu, NULL);
tcp_loop_unit(server->h + IO_TCP, tu);
if (server->state & ServerRunning) {
diff --git a/src/knot/server/tcp-handler.c b/src/knot/server/tcp-handler.c
index 1f18abf..3ebdfe4 100644
--- a/src/knot/server/tcp-handler.c
+++ b/src/knot/server/tcp-handler.c
@@ -25,6 +25,9 @@
#include <netinet/in.h>
#include <stdio.h>
#include <stdlib.h>
+#ifdef HAVE_SYS_UIO_H // struct iovec (OpenBSD)
+#include <sys/uio.h>
+#endif // HAVE_SYS_UIO_H
#ifdef HAVE_CAP_NG_H
#include <cap-ng.h>
#endif /* HAVE_CAP_NG_H */
@@ -403,44 +406,22 @@ static void tcp_loop_free(void *data)
int tcp_send(int fd, uint8_t *msg, size_t msglen)
{
-
- /*! \brief TCP corking.
- * \see http://vger.kernel.org/~acme/unbehaved.txt
- */
-#ifdef TCP_CORK
- int cork = 1;
- int uncork = setsockopt(fd, SOL_TCP, TCP_CORK, &cork, sizeof(cork));
-#endif
-
- /* Flags. */
- int flags = 0;
-#ifdef MSG_NOSIGNAL
- flags |= MSG_NOSIGNAL;
-#endif
-
- /* Send message size. */
- unsigned short pktsize = htons(msglen);
- int sent = send(fd, &pktsize, sizeof(pktsize), flags);
- if (sent < 0) {
- return KNOT_ERROR;
- }
-
- /* Send message data. */
- sent = send(fd, msg, msglen, flags);
- if (sent < 0) {
+ /* Create iovec for gathered write. */
+ struct iovec iov[2];
+ uint16_t pktsize = htons(msglen);
+ iov[0].iov_base = &pktsize;
+ iov[0].iov_len = sizeof(uint16_t);
+ iov[1].iov_base = msg;
+ iov[1].iov_len = msglen;
+
+ /* Send. */
+ int total_len = iov[0].iov_len + iov[1].iov_len;
+ int sent = writev(fd, iov, 2);
+ if (sent != total_len) {
return KNOT_ERROR;
}
-#ifdef TCP_CORK
- /* Uncork only if corked successfuly. */
- if (uncork == 0) {
- cork = 0;
- if (setsockopt(fd, SOL_TCP, TCP_CORK, &cork, sizeof(cork)) < 0) {
- dbg_net("tcp: failed to uncork socket\n");
- }
- }
-#endif
- return sent;
+ return msglen; /* Do not count the size prefix. */
}
int tcp_recv(int fd, uint8_t *buf, size_t len, sockaddr_t *addr)
@@ -543,7 +524,16 @@ int tcp_loop_master(dthread_t *thread)
}
for (unsigned i = 0; nfds > 0 && i < set.n; ++i) {
- /* Skip inactive. */
+
+ /* Error events. */
+ if (set.pfd[i].revents & (POLLERR|POLLHUP|POLLNVAL)) {
+ socket_close(set.pfd[i].fd);
+ fdset_remove(&set, i);
+ --nfds; /* Treat error event as activity. */
+ continue; /* Stay on the same index. */
+ }
+
+ /* Accept POLLIN events. */
if (!(set.pfd[i].revents & POLLIN))
continue;
@@ -611,6 +601,15 @@ int tcp_loop_worker(dthread_t *thread)
unsigned i = 0;
while (nfds > 0 && i < set->n) {
+ /* Terminate faulty connections. */
+ int fd = set->pfd[i].fd;
+ if (set->pfd[i].revents & (POLLERR|POLLHUP|POLLNVAL)) {
+ fdset_remove(set, i);
+ close(fd);
+ --nfds; /* Treat error event as activity. */
+ continue; /* Stay on the same index. */
+ }
+
if (!(set->pfd[i].revents & set->pfd[i].events)) {
/* Skip inactive. */
++i;
@@ -621,7 +620,6 @@ int tcp_loop_worker(dthread_t *thread)
}
/* Register new TCP client or process a query. */
- int fd = set->pfd[i].fd;
if (fd == w->pipe[0]) {
tcp_loop_assign(fd, set);
} else {
diff --git a/src/knot/server/udp-handler.c b/src/knot/server/udp-handler.c
index 259ac5a..b57f902 100644
--- a/src/knot/server/udp-handler.c
+++ b/src/knot/server/udp-handler.c
@@ -340,7 +340,7 @@ static int udp_recvfrom_send(void *d)
return 0;
}
-#ifdef ENABLE_RECVMMSG
+#ifdef HAVE_RECVMMSG
/*! \brief Pointer to selected UDP send implementation. */
static int (*_send_mmsg)(int, sockaddr_t *, struct mmsghdr *, size_t) = 0;
@@ -370,7 +370,7 @@ static inline int sendmmsg(int fd, struct mmsghdr *mmsg, unsigned vlen,
{
return syscall(SYS_sendmmsg, fd, mmsg, vlen, flags, NULL);
}
-#endif
+#endif /* HAVE_SENDMMSG */
/*!
* \brief Send multiple packets.
@@ -382,7 +382,7 @@ int udp_sendmmsg(int sock, sockaddr_t *_, struct mmsghdr *msgs, size_t count)
UNUSED(_);
return sendmmsg(sock, msgs, count, 0);
}
-#endif
+#endif /* ENABLE_SENDMMSG */
/* UDP recvmmsg() request struct. */
struct udp_recvmmsg {
@@ -483,7 +483,7 @@ static int udp_recvmmsg_send(void *d)
}
return rc;
}
-#endif
+#endif /* HAVE_RECVMMSG */
/*! \brief Initialize UDP master routine on run-time. */
void __attribute__ ((constructor)) udp_master_init()
@@ -496,7 +496,7 @@ void __attribute__ ((constructor)) udp_master_init()
_udp_handle = udp_recvfrom_handle;
/* Optimized functions. */
-#ifdef ENABLE_RECVMMSG
+#ifdef HAVE_RECVMMSG
/* Check for recvmmsg() support. */
if (dlsym(RTLD_DEFAULT, "recvmmsg") != 0) {
recvmmsg(0, NULL, 0, 0, 0);
@@ -517,7 +517,7 @@ void __attribute__ ((constructor)) udp_master_init()
_send_mmsg = udp_sendmmsg;
}
#endif /* ENABLE_SENDMMSG */
-#endif /* ENABLE_RECVMMSG */
+#endif /* HAVE_RECVMMSG */
}
int udp_reader(iohandler_t *h, dthread_t *thread)
diff --git a/src/knot/server/xfr-handler.c b/src/knot/server/xfr-handler.c
index 90b0a42..04a0669 100644
--- a/src/knot/server/xfr-handler.c
+++ b/src/knot/server/xfr-handler.c
@@ -1101,21 +1101,19 @@ int xfr_worker(dthread_t *thread)
unsigned i = 0;
while (nfds > 0 && i < set.n && !dt_is_cancelled(thread)) {
- if (!(set.pfd[i].revents & set.pfd[i].events)) {
- /* Skip inactive. */
- ++i;
- continue;
- } else {
+ knot_ns_xfr_t *rq = (knot_ns_xfr_t *)set.ctx[i];
+ if (set.pfd[i].revents & (POLLERR|POLLHUP|POLLNVAL)) {
+ /* Error events. */
+ --nfds; /* Treat error event as activity. */
+ ret = KNOT_ECONN; /* Force disconnect */
+ } else if (set.pfd[i].revents & set.pfd[i].events) {
/* One less active event. */
--nfds;
- }
-
- /* Process pending tasks. */
- knot_ns_xfr_t *rq = (knot_ns_xfr_t *)set.ctx[i];
- if (rq->flags & XFR_FLAG_CONNECTING) {
- ret = xfr_async_finish(&set, i);
- } else {
- ret = xfr_process_event(w, rq);
+ /* Process pending tasks. */
+ if (rq->flags & XFR_FLAG_CONNECTING)
+ ret = xfr_async_finish(&set, i);
+ else
+ ret = xfr_process_event(w, rq);
}
/* Check task state. */
@@ -1126,6 +1124,9 @@ int xfr_worker(dthread_t *thread)
socket_close(set.pfd[i].fd);
fdset_remove(&set, i);
continue; /* Stay on the same index. */
+ } else {
+ /* Connection is active, update watchdog. */
+ fdset_set_watchdog(&set, i, conf()->max_conn_idle);
}
/* Next active. */
diff --git a/src/knot/zone/semantic-check.c b/src/knot/zone/semantic-check.c
index efbe953..8a043d0 100644
--- a/src/knot/zone/semantic-check.c
+++ b/src/knot/zone/semantic-check.c
@@ -42,6 +42,8 @@ static char *error_messages[(-ZC_ERR_UNKNOWN) + 1] = {
"RRSIG: Type covered rdata field is wrong!",
[-ZC_ERR_RRSIG_RDATA_TTL] =
"RRSIG: TTL rdata field is wrong!",
+ [-ZC_ERR_RRSIG_RDATA_EXPIRATION] =
+ "RRSIG: Expired signature!",
[-ZC_ERR_RRSIG_RDATA_LABELS] =
"RRSIG: Labels rdata field is wrong!",
[-ZC_ERR_RRSIG_RDATA_DNSKEY_OWNER] =
@@ -289,9 +291,17 @@ static int check_rrsig_rdata(err_handler_t *handler,
const knot_rrset_t *rrset,
const knot_rrset_t *dnskey_rrset)
{
+ /* Prepare additional info string. */
+ char info_str[50];
+ int ret = snprintf(info_str, sizeof(info_str), "Record type: %d.",
+ knot_rrset_type(rrset));
+ if (ret < 0 || ret >= sizeof(info_str)) {
+ return KNOT_ENOMEM;
+ }
+
if (knot_rrset_rdata_rr_count(rrsig) == 0) {
err_handler_handle_error(handler, node, ZC_ERR_RRSIG_NO_RRSIG,
- NULL);
+ info_str);
return KNOT_EOK;
}
@@ -302,7 +312,7 @@ static int check_rrsig_rdata(err_handler_t *handler,
*/
err_handler_handle_error(handler, node,
ZC_ERR_RRSIG_RDATA_TYPE_COVERED,
- NULL);
+ info_str);
}
/* label number at the 2nd index should be same as owner's */
@@ -316,12 +326,12 @@ static int check_rrsig_rdata(err_handler_t *handler,
if (!knot_dname_is_wildcard(knot_rrset_owner(rrset))) {
err_handler_handle_error(handler, node,
ZC_ERR_RRSIG_RDATA_LABELS,
- NULL);
+ info_str);
} else {
if (abs(tmp) != 1) {
err_handler_handle_error(handler, node,
ZC_ERR_RRSIG_RDATA_LABELS,
- NULL);
+ info_str);
}
}
}
@@ -332,7 +342,14 @@ static int check_rrsig_rdata(err_handler_t *handler,
if (original_ttl != knot_rrset_ttl(rrset)) {
err_handler_handle_error(handler, node, ZC_ERR_RRSIG_RDATA_TTL,
- NULL);
+ info_str);
+ }
+
+ /* Check for expired signature. */
+ if (knot_rrset_rdata_rrsig_sig_expiration(rrsig, rr_pos) < time(NULL)) {
+ err_handler_handle_error(handler, node,
+ ZC_ERR_RRSIG_RDATA_EXPIRATION,
+ info_str);
}
/* signer's name is same as in the zone apex */
@@ -344,7 +361,7 @@ static int check_rrsig_rdata(err_handler_t *handler,
knot_rrset_owner(dnskey_rrset)) != 0) {
err_handler_handle_error(handler, node,
ZC_ERR_RRSIG_RDATA_DNSKEY_OWNER,
- NULL);
+ info_str);
}
/* Compare algorithm, key tag and signer's name with DNSKEY rrset
@@ -381,14 +398,6 @@ static int check_rrsig_rdata(err_handler_t *handler,
}
if (!match) {
- /* Prepare additional info string. */
- char info_str[50];
- int ret = snprintf(info_str, sizeof(info_str),
- "Record type: %d.",
- knot_rrset_type(rrset));
- if (ret < 0 || ret >= sizeof(info_str)) {
- return KNOT_ENOMEM;
- }
err_handler_handle_error(handler, node, ZC_ERR_RRSIG_NO_RRSIG,
info_str);
}
@@ -410,8 +419,7 @@ static int check_rrsig_rdata(err_handler_t *handler,
static int check_rrsig_in_rrset(err_handler_t *handler,
const knot_node_t *node,
const knot_rrset_t *rrset,
- const knot_rrset_t *dnskey_rrset,
- char nsec3)
+ const knot_rrset_t *dnskey_rrset)
{
if (handler == NULL || node == NULL || rrset == NULL ||
dnskey_rrset == NULL) {
@@ -460,7 +468,7 @@ static int check_rrsig_in_rrset(err_handler_t *handler,
info_str);
}
- if (knot_rrset_ttl(rrset) != knot_rrset_ttl(rrset)) {
+ if (knot_rrset_ttl(rrset) != knot_rrset_ttl(rrsigs)) {
err_handler_handle_error(handler, node,
ZC_ERR_RRSIG_TTL,
info_str);
@@ -985,11 +993,10 @@ int sem_check_node_plain(knot_zone_contents_t *zone,
}
/*!
- * \brief Run semantic checks for node without DNSSEC-related types.
+ * \brief Run semantic checks for node with DNSSEC-related types.
*
* \param zone Current zone.
* \param node Node to be checked.
- * \param first_node First node in canonical order.
* \param last_node Last node in canonical order.
* \param handler Error handler.
* \param nsec3 NSEC3 used.
@@ -1000,7 +1007,6 @@ int sem_check_node_plain(knot_zone_contents_t *zone,
*/
static int semantic_checks_dnssec(knot_zone_contents_t *zone,
knot_node_t *node,
- knot_node_t *first_node,
knot_node_t **last_node,
err_handler_t *handler,
char nsec3)
@@ -1021,8 +1027,7 @@ static int semantic_checks_dnssec(knot_zone_contents_t *zone,
const knot_rrset_t *rrset = rrsets[i];
if (auth && !deleg &&
(ret = check_rrsig_in_rrset(handler, node,
- rrset, dnskey_rrset,
- nsec3)) != 0) {
+ rrset, dnskey_rrset)) != 0) {
err_handler_handle_error(handler, node, ret, NULL);
}
@@ -1148,7 +1153,6 @@ static void do_checks_in_tree(knot_node_t *node, void *data)
assert(zone);
- knot_node_t *first_node = (knot_node_t *)args->arg4;
knot_node_t **last_node = (knot_node_t **)args->arg5;
err_handler_t *handler = (err_handler_t *)args->arg6;
@@ -1170,7 +1174,7 @@ static void do_checks_in_tree(knot_node_t *node, void *data)
}
if (do_checks > 1) {
- semantic_checks_dnssec(zone, node, first_node, last_node,
+ semantic_checks_dnssec(zone, node, last_node,
handler, do_checks == 3);
}
@@ -1188,7 +1192,7 @@ int zone_do_sem_checks(knot_zone_contents_t *zone, int do_checks,
arg_t arguments;
arguments.arg1 = zone;
arguments.arg3 = &do_checks;
- arguments.arg4 = NULL;
+ arguments.arg4 = NULL; // UNUSED
arguments.arg5 = &last_node;
arguments.arg6 = handler;
int fatal_error = 0;
diff --git a/src/knot/zone/semantic-check.h b/src/knot/zone/semantic-check.h
index 819c9ff..53c2589 100644
--- a/src/knot/zone/semantic-check.h
+++ b/src/knot/zone/semantic-check.h
@@ -44,6 +44,7 @@ enum zonechecks_errors {
ZC_ERR_RRSIG_RDATA_TYPE_COVERED,
ZC_ERR_RRSIG_RDATA_TTL,
+ ZC_ERR_RRSIG_RDATA_EXPIRATION,
ZC_ERR_RRSIG_RDATA_LABELS,
ZC_ERR_RRSIG_RDATA_DNSKEY_OWNER,
ZC_ERR_RRSIG_RDATA_SIGNED_WRONG,
diff --git a/src/knot/zone/zone-load.c b/src/knot/zone/zone-load.c
index ec8375a..8f45798 100644
--- a/src/knot/zone/zone-load.c
+++ b/src/knot/zone/zone-load.c
@@ -395,7 +395,7 @@ static void process_rr(const scanner_t *scanner)
return;
} else {
log_zone_warning("encountered identical "
- "extra SOA record");
+ "extra SOA record\n");
knot_rrset_deep_free(&current_rrset, 1, 1);
parser->ret = KNOT_EOK;
return;
@@ -411,7 +411,7 @@ static void process_rr(const scanner_t *scanner)
"in config! \n");
/* Such SOA cannot even be added, because
* it would not be in the zone apex. */
- parser->ret = KNOT_EBADZONE;
+ parser->ret = KNOT_EOUTOFZONE;
return;
}
}
diff --git a/src/libknot/nameserver/name-server.c b/src/libknot/nameserver/name-server.c
index ee956e7..db42d9a 100644
--- a/src/libknot/nameserver/name-server.c
+++ b/src/libknot/nameserver/name-server.c
@@ -2180,7 +2180,7 @@ dbg_ns_exec_verb(
dbg_ns_verb(" and previous node: (nil).\n");
}
);
- if (find_ret == KNOT_EBADZONE) {
+ if (find_ret == KNOT_EOUTOFZONE) {
// possible only if we followed CNAME or DNAME
assert(cname != 0);
knot_response_set_rcode(resp, KNOT_RCODE_NOERROR);
diff --git a/src/libknot/rrset.c b/src/libknot/rrset.c
index 24ddb88..74b9158 100644
--- a/src/libknot/rrset.c
+++ b/src/libknot/rrset.c
@@ -1144,6 +1144,8 @@ int knot_rrset_rdata_from_wire_one(knot_rrset_t *rrset,
const uint8_t *wire, size_t *pos,
size_t total_size, size_t rdlength)
{
+ int obsolete = 0;
+
/* [code-review] Missing parameter checks. */
if (rdlength == 0) {
@@ -1158,15 +1160,24 @@ int knot_rrset_rdata_from_wire_one(knot_rrset_t *rrset,
size_t extra_dname_size = 0;
const rdata_descriptor_t *desc = get_rdata_descriptor(rrset->type);
+ /* Check for obsolete record. */
+ if (desc->type_name == NULL) {
+ desc = get_obsolete_rdata_descriptor(rrset->type);
+ if (desc->type_name != NULL) {
+ obsolete = 1;
+ }
+ }
+
for (int i = 0; desc->block_types[i] != KNOT_RDATA_WF_END; ++i) {
if (descriptor_item_is_dname(desc->block_types[i])) {
- extra_dname_size += sizeof(knot_dname_t *) - 1;
+ if (obsolete) {
+ extra_dname_size += KNOT_MAX_DNAME_LENGTH;
+ } else {
+ extra_dname_size += sizeof(knot_dname_t *);
+ }
}
}
- /* [code-review] Isn't this invalid? You cannot do static allocation
- * with dynamic data (parameter, local variable).
- */
uint8_t rdata_buffer[rdlength + extra_dname_size];
memset(rdata_buffer, 0, rdlength + extra_dname_size);
dbg_rrset_detail("rr: parse_rdata_wire: Added %zu bytes to buffer to "
@@ -1188,9 +1199,7 @@ int knot_rrset_rdata_from_wire_one(knot_rrset_t *rrset,
return KNOT_EMALF;
}
knot_dname_to_lower(dname);
- memcpy(rdata_buffer + offset, &dname,
- sizeof(knot_dname_t *));
- parsed += pos2 - *pos;
+
dbg_rrset_detail("rr: parse_rdata_wire: Parsed DNAME, "
"length=%zu.\n", pos2 - *pos);
dbg_rrset_exec_detail(
@@ -1199,8 +1208,19 @@ dbg_rrset_exec_detail(
"DNAME=%s\n", name);
free(name);
);
+ if (obsolete) {
+ memcpy(rdata_buffer + offset,
+ knot_dname_name(dname),
+ knot_dname_size(dname));
+ offset += knot_dname_size(dname);
+ knot_dname_free(&dname);
+ } else {
+ memcpy(rdata_buffer + offset, &dname,
+ sizeof(knot_dname_t *));
+ offset += sizeof(knot_dname_t *);
+ }
+ parsed += pos2 - *pos;
*pos = pos2;
- offset += sizeof(knot_dname_t *);
} else if (descriptor_item_is_fixed(item)) {
dbg_rrset_detail("rr: parse_rdata_wire: Saving static "
"chunk of size=%u\n", item);
@@ -1605,6 +1625,19 @@ dbg_rrset_exec_detail(
/*----------------------------------------------------------------------------*/
+bool knot_rrset_is_nsec3rel(const knot_rrset_t *rr)
+{
+ assert(rr != NULL);
+
+ /* Is NSEC3 or non-empty RRSIG covering NSEC3. */
+ return ((knot_rrset_type(rr) == KNOT_RRTYPE_NSEC3)
+ || (knot_rrset_type(rr) == KNOT_RRTYPE_RRSIG
+ && knot_rrset_rdata_rrsig_type_covered(rr)
+ == KNOT_RRTYPE_NSEC3));
+}
+
+/*----------------------------------------------------------------------------*/
+
const knot_dname_t *knot_rrset_rdata_cname_name(const knot_rrset_t *rrset)
{
if (rrset == NULL) {
diff --git a/src/libknot/rrset.h b/src/libknot/rrset.h
index 2b0cb6b..05deb37 100644
--- a/src/libknot/rrset.h
+++ b/src/libknot/rrset.h
@@ -29,6 +29,7 @@
#define _KNOT_RRSET_H_
#include <stdint.h>
+#include <stdbool.h>
#include "dname.h"
@@ -361,6 +362,13 @@ int knot_rrset_merge(knot_rrset_t *rrset1, const knot_rrset_t *rrset2);
*/
int knot_rrset_merge_no_dupl(knot_rrset_t *rrset1, const knot_rrset_t *rrset2, int *merged, int *deleted_rrs);
+/*!
+ * \brief Return true if the RRSet is an NSEC3 related type.
+ *
+ * \param rr RRSet.
+ */
+bool knot_rrset_is_nsec3rel(const knot_rrset_t *rr);
+
//TODO test
const knot_dname_t *knot_rrset_rdata_cname_name(const knot_rrset_t *rrset);
diff --git a/src/libknot/updates/ddns.c b/src/libknot/updates/ddns.c
index 7f4f14f..93ec342 100644
--- a/src/libknot/updates/ddns.c
+++ b/src/libknot/updates/ddns.c
@@ -322,7 +322,7 @@ static int knot_ddns_check_exist(const knot_zone_contents_t *zone,
if (!knot_dname_is_subdomain(knot_rrset_owner(rrset),
knot_node_owner(knot_zone_contents_apex(zone)))) {
*rcode = KNOT_RCODE_NOTZONE;
- return KNOT_EBADZONE;
+ return KNOT_EOUTOFZONE;
}
const knot_node_t *node;
@@ -355,7 +355,7 @@ static int knot_ddns_check_exist_full(const knot_zone_contents_t *zone,
if (!knot_dname_is_subdomain(knot_rrset_owner(rrset),
knot_node_owner(knot_zone_contents_apex(zone)))) {
*rcode = KNOT_RCODE_NOTZONE;
- return KNOT_EBADZONE;
+ return KNOT_EOUTOFZONE;
}
const knot_node_t *node;
@@ -400,7 +400,7 @@ static int knot_ddns_check_not_exist(const knot_zone_contents_t *zone,
if (!knot_dname_is_subdomain(knot_rrset_owner(rrset),
knot_node_owner(knot_zone_contents_apex(zone)))) {
*rcode = KNOT_RCODE_NOTZONE;
- return KNOT_EBADZONE;
+ return KNOT_EOUTOFZONE;
}
const knot_node_t *node;
@@ -431,7 +431,7 @@ static int knot_ddns_check_in_use(const knot_zone_contents_t *zone,
if (!knot_dname_is_subdomain(dname,
knot_node_owner(knot_zone_contents_apex(zone)))) {
*rcode = KNOT_RCODE_NOTZONE;
- return KNOT_EBADZONE;
+ return KNOT_EOUTOFZONE;
}
const knot_node_t *node;
@@ -461,7 +461,7 @@ static int knot_ddns_check_not_in_use(const knot_zone_contents_t *zone,
if (!knot_dname_is_subdomain(dname,
knot_node_owner(knot_zone_contents_apex(zone)))) {
*rcode = KNOT_RCODE_NOTZONE;
- return KNOT_EBADZONE;
+ return KNOT_EOUTOFZONE;
}
const knot_node_t *node;
@@ -618,7 +618,7 @@ static int knot_ddns_check_update(const knot_rrset_t *rrset,
int is_sub = knot_dname_is_subdomain(owner, qname);
if (!is_sub && knot_dname_compare(owner, qname) != 0) {
*rcode = KNOT_RCODE_NOTZONE;
- return KNOT_EBADZONE;
+ return KNOT_EOUTOFZONE;
}
if (knot_rrset_class(rrset) == knot_packet_qclass(query)) {
@@ -897,65 +897,6 @@ static void knot_ddns_check_add_rr(knot_changeset_t *changeset,
/*----------------------------------------------------------------------------*/
-static int knot_ddns_rr_is_nsec3(const knot_rrset_t *rr)
-{
- assert(rr != NULL);
-
- if ((knot_rrset_type(rr) == KNOT_RRTYPE_NSEC3)
- || (knot_rrset_type(rr) == KNOT_RRTYPE_RRSIG
- && knot_rrset_rdata_rr_count(rr)
- && knot_rrset_rdata_rrsig_type_covered(rr)
- == KNOT_RRTYPE_NSEC3))
- {
- dbg_ddns_detail("This is NSEC3-related RRSet.\n");
- return 1;
- } else {
- return 0;
- }
-}
-
-/*----------------------------------------------------------------------------*/
-/*! \note Copied from xfrin_add_new_node(). */
-static knot_node_t *knot_ddns_add_new_node(knot_zone_contents_t *zone,
- knot_dname_t *owner, int is_nsec3)
-{
- assert(zone != NULL);
- assert(owner != NULL);
-
- knot_node_t *node = knot_node_new(owner, NULL, 0);
- if (node == NULL) {
- dbg_xfrin("Failed to create a new node.\n");
- return NULL;
- }
-
- int ret = 0;
-
- // insert the node into zone structures and create parents if
- // necessary
- if (is_nsec3) {
- ret = knot_zone_contents_add_nsec3_node(zone, node, 1, 0);
- } else {
- ret = knot_zone_contents_add_node(zone, node, 1, 0);
- }
- if (ret != KNOT_EOK) {
- dbg_xfrin("Failed to add new node to zone contents.\n");
- knot_node_free(&node);
- return NULL;
- }
-
- /*!
- * \note It is not needed to set the previous node, we will do this
- * in adjusting after the transfer.
- */
- assert(zone->zone != NULL);
- //knot_node_set_zone(node, zone->zone);
- assert(node->zone == zone->zone);
-
- return node;
-}
-
-/*----------------------------------------------------------------------------*/
-
static knot_node_t *knot_ddns_get_node(knot_zone_contents_t *zone,
const knot_rrset_t *rr)
{
@@ -966,7 +907,7 @@ static knot_node_t *knot_ddns_get_node(knot_zone_contents_t *zone,
knot_dname_t *owner = knot_rrset_get_owner(rr);
dbg_ddns_detail("Searching for node...\n");
- if (knot_ddns_rr_is_nsec3(rr)) {
+ if (knot_rrset_is_nsec3rel(rr)) {
node = knot_zone_contents_get_nsec3_node(zone, owner);
} else {
node = knot_zone_contents_get_node(zone, owner);
@@ -1548,14 +1489,12 @@ static int knot_ddns_process_add(const knot_rrset_t *rr,
dbg_ddns_verb("Adding RR.\n");
if (node == NULL) {
- // create new node, connect it properly to the
- // zone nodes
+ // create new node, connect it to the zone nodes
dbg_ddns_detail("Node not found. Creating new.\n");
- node = knot_ddns_add_new_node(zone, knot_rrset_get_owner(rr),
- knot_ddns_rr_is_nsec3(rr));
- if (node == NULL) {
+ int ret = knot_zone_contents_create_node(zone, rr, &node);
+ if (ret != KNOT_EOK) {
dbg_xfrin("Failed to create new node in zone.\n");
- return KNOT_ERROR;
+ return ret;
}
}
diff --git a/src/libknot/updates/xfr-in.c b/src/libknot/updates/xfr-in.c
index 78d12a9..ac70be0 100644
--- a/src/libknot/updates/xfr-in.c
+++ b/src/libknot/updates/xfr-in.c
@@ -321,6 +321,28 @@ static int xfrin_insert_rrset_dnames_to_table(knot_rrset_t *rrset,
return KNOT_EOK;
}
+static void xfrin_log_error(const knot_dname_t *zone_owner,
+ const knot_dname_t *rr_owner,
+ int ret)
+{
+ char *zonename = knot_dname_to_str(zone_owner);
+ if (ret == KNOT_EOUTOFZONE) {
+ // Out-of-zone data, ignore
+ char *rrname = knot_dname_to_str(rr_owner);
+ log_zone_warning("Zone %s: Ignoring "
+ "out-of-zone RR owned by %s\n",
+ zonename, rrname);
+ free(zonename);
+ free(rrname);
+ } else {
+ log_zone_error("Zone %s: Failed to process "
+ "incoming RR, transfer "
+ "is probably malformed. (Reason: %s)\n",
+ zonename, knot_strerror(ret));
+ free(zonename);
+ }
+}
+
void xfrin_free_orphan_rrsigs(xfrin_orphan_rrsig_t **rrsigs)
{
xfrin_orphan_rrsig_t *r = *rrsigs;
@@ -479,7 +501,7 @@ int xfrin_process_axfr_packet(knot_ns_xfr_t *xfr)
/*! \todo Cleanup. */
return KNOT_EMALF;
}
-
+
if (rr == NULL) {
dbg_xfrin("No RRs in the packet.\n");
knot_packet_free(&packet);
@@ -525,8 +547,8 @@ int xfrin_process_axfr_packet(knot_ns_xfr_t *xfr)
return KNOT_EOK;
}
- if (knot_dname_compare(knot_rrset_owner(rr),
- knot_packet_qname(packet)) != 0) {
+ if (knot_dname_compare_non_canon(knot_rrset_owner(rr),
+ knot_packet_qname(packet)) != 0) {
dbg_xfrin_exec(
char *rr_owner =
knot_dname_to_str(knot_rrset_owner(rr));
@@ -613,6 +635,15 @@ dbg_xfrin_exec(
while (ret == KNOT_EOK && rr != NULL) {
// process the parsed RR
+ if (!knot_dname_is_subdomain(rr->owner, xfr->zone->name) &&
+ knot_dname_compare_non_canon(rr->owner, xfr->zone->name) != 0) {
+ // Out-of-zone data
+ xfrin_log_error(xfr->zone->name, rr->owner,
+ KNOT_EOUTOFZONE);
+ knot_rrset_deep_free(&rr, 1, 1);
+ ret = knot_packet_parse_next_rr_answer(packet, &rr);
+ continue;
+ }
dbg_rrset_detail("\nNext RR:\n\n");
knot_rrset_dump(rr);
@@ -799,14 +830,12 @@ dbg_xfrin_exec_verb(
ret = add_node(zone, node, 1, 0);
assert(node != NULL);
if (ret != KNOT_EOK) {
- dbg_xfrin("Failed to add node to zone (%s).\n",
- knot_strerror(ret));
+ // Fatal error, free packet
knot_packet_free(&packet);
- knot_node_free(&node); // ???
knot_rrset_deep_free(&rr, 1, 1);
- return KNOT_ERROR;
+ knot_node_free(&node);
+ return ret;
}
-
in_zone = 1;
} else {
assert(in_zone);
@@ -822,7 +851,6 @@ dbg_xfrin_exec_verb(
// merged, free the RRSet
knot_rrset_deep_free(&rr, 1, 0);
}
-
}
rr = NULL;
@@ -856,9 +884,10 @@ dbg_xfrin_exec_verb(
if (ret != KNOT_EOK) {
dbg_xfrin("Failed to add last node into zone (%s).\n",
knot_strerror(ret));
- knot_packet_free(&packet);
- knot_node_free(&node);
- return KNOT_ERROR; /*! \todo Other error */
+ knot_packet_free(&packet);
+ knot_node_free(&node);
+ knot_rrset_deep_free(&rr, 1, 1);
+ return ret;
}
}
@@ -1096,6 +1125,20 @@ dbg_xfrin_exec_verb(
knot_rrset_type(rr));
free(name);
);
+ if (!knot_dname_is_subdomain(rr->owner, xfr->zone->name) &&
+ knot_dname_compare_non_canon(rr->owner, xfr->zone->name) != 0) {
+ // out-of-zone domain
+ xfrin_log_error(xfr->zone->name, rr->owner,
+ KNOT_EOUTOFZONE);
+ knot_rrset_deep_free(&rr, 1, 1);
+ // Skip this rr
+ ret = knot_packet_parse_next_rr_answer(packet, &rr);
+ continue;
+ }
+
+ // Handle duplications
+ xfrin_insert_rrset_dnames_to_table(rr, xfr->lookup_tree);
+
switch (state) {
case -1:
// a SOA is expected
@@ -1833,43 +1876,6 @@ dbg_xfrin_exec_verb(
/*----------------------------------------------------------------------------*/
-static knot_node_t *xfrin_add_new_node(knot_zone_contents_t *contents,
- knot_rrset_t *rrset, int is_nsec3)
-{
- knot_node_t *node = knot_node_new(knot_rrset_get_owner(rrset),
- NULL, 0);
- if (node == NULL) {
- dbg_xfrin("Failed to create a new node.\n");
- return NULL;
- }
-
- int ret = 0;
-
- // insert the node into zone structures and create parents if
- // necessary
- if (is_nsec3) {
- ret = knot_zone_contents_add_nsec3_node(contents, node, 1, 0);
- } else {
- ret = knot_zone_contents_add_node(contents, node, 1, 0);
- }
- if (ret != KNOT_EOK) {
- dbg_xfrin("Failed to add new node to zone contents.\n");
- return NULL;
- }
-
- /*!
- * \note It is not needed to set the previous node, we will do this
- * in adjusting after the transfer.
- */
-
- assert(contents->zone != NULL);
- knot_node_set_zone(node, contents->zone);
-
- return node;
-}
-
-/*----------------------------------------------------------------------------*/
-
int xfrin_replace_rrset_in_node(knot_node_t *node,
knot_rrset_t *rrset_new,
knot_changes_t *changes,
@@ -2563,8 +2569,6 @@ static int xfrin_apply_remove(knot_zone_contents_t *contents,
knot_node_t *node = NULL;
knot_rrset_t *rrset = NULL, *rrsigs = NULL;
- int is_nsec3 = 0;
-
for (int i = 0; i < chset->remove_count; ++i) {
dbg_xfrin_exec_verb(
char *name = knot_dname_to_str(
@@ -2577,17 +2581,8 @@ dbg_xfrin_exec_detail(
knot_rrset_dump(chset->remove[i]);
);
- is_nsec3 = 0;
-
// check if the RRSet belongs to the NSEC3 tree
- if ((knot_rrset_type(chset->remove[i]) == KNOT_RRTYPE_NSEC3)
- || (knot_rrset_type(chset->remove[i]) == KNOT_RRTYPE_RRSIG
- && knot_rrset_rdata_rrsig_type_covered(chset->remove[i])
- == KNOT_RRTYPE_NSEC3))
- {
- dbg_xfrin_verb("Removed RRSet belongs to NSEC3 tree.\n");
- is_nsec3 = 1;
- }
+ int is_nsec3 = knot_rrset_is_nsec3rel(chset->remove[i]);
// check if the old node is not the one we should use
dbg_xfrin_verb("Node:%p Owner: %p Node owner: %p\n",
@@ -2656,8 +2651,6 @@ static int xfrin_apply_add(knot_zone_contents_t *contents,
knot_rrset_t *rrset = NULL;
knot_rrset_t *rrsigs = NULL;
- int is_nsec3 = 0;
-
for (int i = 0; i < chset->add_count; ++i) {
dbg_xfrin_exec_verb(
char *name = knot_dname_to_str(
@@ -2670,17 +2663,8 @@ dbg_xfrin_exec_detail(
knot_rrset_dump(chset->add[i]);
);
- is_nsec3 = 0;
-
// check if the RRSet belongs to the NSEC3 tree
- if ((knot_rrset_type(chset->add[i]) == KNOT_RRTYPE_NSEC3)
- || (knot_rrset_type(chset->add[i]) == KNOT_RRTYPE_RRSIG
- && knot_rrset_rdata_rrsig_type_covered(chset->add[i])
- == KNOT_RRTYPE_NSEC3))
- {
- dbg_xfrin_detail("This is NSEC3-related RRSet.\n");
- is_nsec3 = 1;
- }
+ int is_nsec3 = knot_rrset_is_nsec3rel(chset->add[i]);
// check if the old node is not the one we should use
if (!node || knot_rrset_owner(chset->add[i])
@@ -2699,13 +2683,13 @@ dbg_xfrin_exec_detail(
// zone nodes
dbg_xfrin_detail("Node not found. Creating new."
"\n");
- node = xfrin_add_new_node(contents,
- chset->add[i],
- is_nsec3);
- if (node == NULL) {
+ ret = knot_zone_contents_create_node(contents,
+ chset->add[i],
+ &node);
+ if (ret != KNOT_EOK) {
dbg_xfrin("Failed to create new node "
"in zone.\n");
- return KNOT_ERROR;
+ return ret;
}
}
}
diff --git a/src/libknot/zone/zone-contents.c b/src/libknot/zone/zone-contents.c
index fbf4ab3..584e6cb 100644
--- a/src/libknot/zone/zone-contents.c
+++ b/src/libknot/zone/zone-contents.c
@@ -78,7 +78,7 @@ static void tree_apply_cb(knot_node_t **node,
* \retval KNOT_EOK if both arguments are non-NULL and the node belongs to the
* zone.
* \retval KNOT_EINVAL if either of the arguments is NULL.
- * \retval KNOT_EBADZONE if the node does not belong to the zone.
+ * \retval KNOT_EOUTOFZONE if the node does not belong to the zone.
*/
static int knot_zone_contents_check_node(
const knot_zone_contents_t *contents, const knot_node_t *node)
@@ -101,7 +101,7 @@ dbg_zone_exec(
free(node_owner);
free(apex_owner);
);
- return KNOT_EBADZONE;
+ return KNOT_EOUTOFZONE;
}
return KNOT_EOK;
}
@@ -240,7 +240,7 @@ static void knot_zone_contents_adjust_rdata_dname(knot_zone_contents_t *zone,
int ret = knot_zone_contents_find_dname(zone, dname, &n,
&closest_encloser, &prev);
- if (ret == KNOT_EINVAL || ret == KNOT_EBADZONE) {
+ if (ret == KNOT_EINVAL || ret == KNOT_EOUTOFZONE) {
// TODO: do some cleanup if needed
dbg_zone_detail("Failed to find the name in zone: %s\n",
knot_strerror(ret));
@@ -1036,6 +1036,38 @@ dbg_zone_exec_detail(
/*----------------------------------------------------------------------------*/
+int knot_zone_contents_create_node(knot_zone_contents_t *contents,
+ const knot_rrset_t *rr,
+ knot_node_t **node)
+{
+ if (contents == NULL || rr == NULL || node == NULL) {
+ return KNOT_EINVAL;
+ }
+
+ *node = knot_node_new(rr->owner, NULL, 0);
+ if (*node == NULL) {
+ return KNOT_ENOMEM;
+ }
+
+ /* Add to the proper tree. */
+ int ret = KNOT_EOK;
+ if (knot_rrset_is_nsec3rel(rr)) {
+ ret = knot_zone_contents_add_nsec3_node(contents, *node, 1, 0);
+ } else {
+ ret = knot_zone_contents_add_node(contents, *node, 1, 0);
+ }
+
+ if (ret != KNOT_EOK) {
+ dbg_xfrin("Failed to add new node to zone contents.\n");
+ knot_node_free(node);
+ return ret;
+ }
+
+ return ret;
+}
+
+/*----------------------------------------------------------------------------*/
+
int knot_zone_contents_add_rrset(knot_zone_contents_t *zone,
knot_rrset_t *rrset, knot_node_t **node,
knot_rrset_dupl_handling_t dupl)
@@ -1057,7 +1089,7 @@ dbg_zone_exec_detail(
zone->apex->owner) != 0
&& !knot_dname_is_subdomain(knot_rrset_owner(rrset),
zone->apex->owner)) {
- return KNOT_EBADZONE;
+ return KNOT_EOUTOFZONE;
}
if ((*node) == NULL
@@ -1121,7 +1153,7 @@ dbg_zone_exec(
zone->apex->owner) != 0
&& !knot_dname_is_subdomain(knot_rrset_owner(*rrset),
zone->apex->owner)) {
- return KNOT_EBADZONE;
+ return KNOT_EOUTOFZONE;
}
// check if the RRSIGs belong to the RRSet
@@ -1238,7 +1270,7 @@ int knot_zone_contents_add_nsec3_rrset(knot_zone_contents_t *zone,
zone->apex->owner) != 0
&& !knot_dname_is_subdomain(knot_rrset_owner(rrset),
zone->apex->owner)) {
- return KNOT_EBADZONE;
+ return KNOT_EOUTOFZONE;
}
if ((*node) == NULL
@@ -1395,7 +1427,7 @@ dbg_zone_exec_verb(
if (!knot_dname_is_subdomain(name, zone->apex->owner)) {
*node = NULL;
*closest_encloser = NULL;
- return KNOT_EBADZONE;
+ return KNOT_EOUTOFZONE;
}
knot_node_t *found = NULL, *prev = NULL;
@@ -1425,7 +1457,7 @@ dbg_zone_detail("Search function returned %d, node %s (%p) and prev: %s (%p)\n",
// there must be at least one node with domain name less or equal to
// the searched name if the name belongs to the zone (the root)
if (*node == NULL && *previous == NULL) {
- return KNOT_EBADZONE;
+ return KNOT_EOUTOFZONE;
}
/* This function was quite out of date. The find_in_tree() function
diff --git a/src/libknot/zone/zone-contents.h b/src/libknot/zone/zone-contents.h
index 19ba512..ab33d5f 100644
--- a/src/libknot/zone/zone-contents.h
+++ b/src/libknot/zone/zone-contents.h
@@ -110,7 +110,7 @@ uint16_t knot_zone_contents_class(const knot_zone_contents_t *contents);
*
* \retval KNOT_EOK
* \retval KNOT_EINVAL
- * \retval KNOT_EBADZONE
+ * \retval KNOT_EOUTOFZONE
* \retval KNOT_EHASH
*/
int knot_zone_contents_add_node(knot_zone_contents_t *contents,
@@ -118,6 +118,18 @@ int knot_zone_contents_add_node(knot_zone_contents_t *contents,
uint8_t flags);
/*!
+ * \brief Create new node in the zone contents for given RRSet.
+ *
+ * \param contents Zone to add the node into.
+ * \param rr Given RRSet.
+ * \param node Returns created node.
+ * \return
+ */
+int knot_zone_contents_create_node(knot_zone_contents_t *contents,
+ const knot_rrset_t *rr,
+ knot_node_t **node);
+
+/*!
* \brief Adds a RRSet to the given zone.
*
* Checks if the RRSet belongs to the zone, i.e. if its owner is a subdomain of
@@ -137,7 +149,7 @@ int knot_zone_contents_add_node(knot_zone_contents_t *contents,
*
* \retval KNOT_EOK
* \retval KNOT_EINVAL
- * \retval KNOT_EBADZONE
+ * \retval KNOT_EOUTOFZONE
*/
int knot_zone_contents_add_rrset(knot_zone_contents_t *contents,
knot_rrset_t *rrset,
@@ -162,7 +174,7 @@ int knot_zone_contents_add_rrsigs(knot_zone_contents_t *contents,
*
* \retval KNOT_EOK
* \retval KNOT_EINVAL
- * \retval KNOT_EBADZONE
+ * \retval KNOT_EOUTOFZONE
*/
int knot_zone_contents_add_nsec3_node(knot_zone_contents_t *contents,
knot_node_t *node, int create_parents,
@@ -229,7 +241,7 @@ const knot_node_t *knot_zone_contents_find_node(
* \retval KNOT_ZONE_NAME_FOUND if node with owner \a name was found.
* \retval KNOT_ZONE_NAME_NOT_FOUND if it was not found.
* \retval KNOT_EINVAL
- * \retval KNOT_EBADZONE
+ * \retval KNOT_EOUTOFZONE
*/
int knot_zone_contents_find_dname(const knot_zone_contents_t *contents,
const knot_dname_t *name,
diff --git a/src/tests/Makefile.in b/src/tests/Makefile.in
index fefb224..1f0e87d 100644
--- a/src/tests/Makefile.in
+++ b/src/tests/Makefile.in
@@ -1,9 +1,8 @@
-# Makefile.in generated by automake 1.11.6 from Makefile.am.
+# Makefile.in generated by automake 1.12.6 from Makefile.am.
# @configure_input@
-# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
-# Foundation, Inc.
+# Copyright (C) 1994-2012 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.
@@ -53,15 +52,16 @@ host_triplet = @host@
check_PROGRAMS = unittests$(EXEEXT)
TESTS = unittests$(EXEEXT)
subdir = src/tests
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
+DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+ $(top_srcdir)/depcomp
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_compile_flag.m4 \
$(top_srcdir)/m4/ax_ext.m4 \
$(top_srcdir)/m4/ax_gcc_x86_cpuid.m4 \
- $(top_srcdir)/m4/ax_recvmmsg.m4 $(top_srcdir)/m4/libtool.m4 \
- $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
- $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
- $(top_srcdir)/m4/visibility.m4 $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
+ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
+ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/visibility.m4 \
+ $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
@@ -88,6 +88,19 @@ unittests_DEPENDENCIES = ../libknotd.la ../libknots.la @LIBOBJS@
AM_V_lt = $(am__v_lt_@AM_V@)
am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
am__v_lt_0 = --silent
+am__v_lt_1 =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_@AM_V@)
+am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
+AM_V_at = $(am__v_at_@AM_V@)
+am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 =
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/src
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
@@ -100,20 +113,16 @@ LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
$(AM_CFLAGS) $(CFLAGS)
AM_V_CC = $(am__v_CC_@AM_V@)
am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
-am__v_CC_0 = @echo " CC " $@;
-AM_V_at = $(am__v_at_@AM_V@)
-am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
-am__v_at_0 = @
+am__v_CC_0 = @echo " CC " $@;
+am__v_CC_1 =
CCLD = $(CC)
LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
$(AM_LDFLAGS) $(LDFLAGS) -o $@
AM_V_CCLD = $(am__v_CCLD_@AM_V@)
am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
-am__v_CCLD_0 = @echo " CCLD " $@;
-AM_V_GEN = $(am__v_GEN_@AM_V@)
-am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
-am__v_GEN_0 = @echo " GEN " $@;
+am__v_CCLD_0 = @echo " CCLD " $@;
+am__v_CCLD_1 =
SOURCES = $(unittests_SOURCES) $(nodist_unittests_SOURCES)
DIST_SOURCES = $(unittests_SOURCES)
am__can_run_installinfo = \
@@ -123,8 +132,10 @@ am__can_run_installinfo = \
esac
ETAGS = etags
CTAGS = ctags
-am__tty_colors = \
-red=; grn=; lgn=; blu=; std=
+am__tty_colors_dummy = \
+ mgn= red= grn= lgn= blu= brg= std=; \
+ am__color_tests=no
+am__tty_colors = $(am__tty_colors_dummy)
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
@@ -433,26 +444,10 @@ unittests$(EXEEXT): $(unittests_OBJECTS) $(unittests_DEPENDENCIES) $(EXTRA_unitt
mostlyclean-compile:
-rm -f *.$(OBJEXT)
- -rm -f common/acl_tests.$(OBJEXT)
- -rm -f common/base32hex_tests.$(OBJEXT)
- -rm -f common/base64_tests.$(OBJEXT)
- -rm -f common/descriptor_tests.$(OBJEXT)
- -rm -f common/events_tests.$(OBJEXT)
- -rm -f common/fdset_tests.$(OBJEXT)
- -rm -f common/hattrie_tests.$(OBJEXT)
- -rm -f common/skiplist_tests.$(OBJEXT)
- -rm -f common/slab_tests.$(OBJEXT)
- -rm -f knot/conf_tests.$(OBJEXT)
- -rm -f knot/dthreads_tests.$(OBJEXT)
- -rm -f knot/journal_tests.$(OBJEXT)
- -rm -f knot/rrl_tests.$(OBJEXT)
- -rm -f knot/server_tests.$(OBJEXT)
- -rm -f libknot/dname_tests.$(OBJEXT)
- -rm -f libknot/rrset_tests.$(OBJEXT)
- -rm -f libknot/sign_tests.$(OBJEXT)
- -rm -f libknot/wire_tests.$(OBJEXT)
- -rm -f libknot/ztree_tests.$(OBJEXT)
- -rm -f zscanner/zscanner_tests.$(OBJEXT)
+ -rm -f common/*.$(OBJEXT)
+ -rm -f knot/*.$(OBJEXT)
+ -rm -f libknot/*.$(OBJEXT)
+ -rm -f zscanner/*.$(OBJEXT)
distclean-compile:
-rm -f *.tab.c
@@ -558,6 +553,20 @@ GTAGS:
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: $(HEADERS) $(SOURCES) $(LISP)
+ list='$(SOURCES) $(HEADERS) $(LISP)'; \
+ case "$(srcdir)" in \
+ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
+ *) sdir=$(subdir)/$(srcdir) ;; \
+ esac; \
+ for i in $$list; do \
+ if test -f "$$i"; then \
+ echo "$(subdir)/$$i"; \
+ else \
+ echo "$$sdir/$$i"; \
+ fi; \
+ done >> $(top_builddir)/cscope.files
+
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
@@ -571,7 +580,7 @@ check-TESTS: $(TESTS)
if test -f ./$$tst; then dir=./; \
elif test -f $$tst; then dir=; \
else dir="$(srcdir)/"; fi; \
- if $(TESTS_ENVIRONMENT) $${dir}$$tst; then \
+ if $(TESTS_ENVIRONMENT) $${dir}$$tst $(AM_TESTS_FD_REDIRECT); then \
all=`expr $$all + 1`; \
case " $(XFAIL_TESTS) " in \
*[\ \ ]$$tst[\ \ ]*) \
@@ -806,8 +815,8 @@ uninstall-am:
.MAKE: all check check-am install install-am install-strip
.PHONY: CTAGS GTAGS all all-am check check-TESTS check-am clean \
- clean-checkPROGRAMS clean-generic clean-libtool ctags \
- distclean distclean-compile distclean-generic \
+ clean-checkPROGRAMS clean-generic clean-libtool cscopelist \
+ ctags distclean distclean-compile distclean-generic \
distclean-libtool distclean-tags 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 \
diff --git a/src/tests/common/acl_tests.c b/src/tests/common/acl_tests.c
index f8ab106..e115dc4 100644
--- a/src/tests/common/acl_tests.c
+++ b/src/tests/common/acl_tests.c
@@ -145,7 +145,7 @@ static int acl_tests_run(int argc, char *argv[])
acl_create(acl, &match_pf4, ACL_ACCEPT, 0, 0); /* Make decoy. */
acl_key_t *rval = NULL;
ret = acl_match(acl, &test_pf4, &rval);
- ok(rval->val == sval, "acl: search for preferred node");
+ ok(rval && rval->val == sval, "acl: search for preferred node");
// 19. Scenario after truncating
ok(acl_truncate(acl) == ACL_ACCEPT, "acl: truncate");
diff --git a/src/tests/common/descriptor_tests.c b/src/tests/common/descriptor_tests.c
index 9d752f5..4f1fb6c 100644
--- a/src/tests/common/descriptor_tests.c
+++ b/src/tests/common/descriptor_tests.c
@@ -36,7 +36,7 @@ unit_api descriptor_tests_api = {
static int descriptor_tests_count(int argc, char *argv[])
{
- return 68;
+ return 81;
}
static int descriptor_tests_run(int argc, char *argv[])
@@ -230,5 +230,40 @@ static int descriptor_tests_run(int argc, char *argv[])
ret = knot_rrclass_from_string("CLASS65536", &num);
cmp_ok(ret, "==", -1, "get CLASS65536 num ret");
+ // Get obsolete descriptor:
+ // 30. TYPE0
+ descr = get_obsolete_rdata_descriptor(0);
+ ok(descr->type_name == 0, "get TYPE0 descriptor name");
+ cmp_ok(descr->block_types[0], "==", KNOT_RDATA_WF_REMAINDER,
+ "get TYPE0 descriptor 1. item type");
+ cmp_ok(descr->block_types[1], "==", KNOT_RDATA_WF_END,
+ "get TYPE0 descriptor 2. item type");
+
+ // 31. MD
+ descr = get_obsolete_rdata_descriptor(3);
+ ok(strcmp(descr->type_name, "MD") == 0, "get MD descriptor name");
+ cmp_ok(descr->block_types[0], "==", KNOT_RDATA_WF_COMPRESSED_DNAME,
+ "get A descriptor 1. item type");
+ cmp_ok(descr->block_types[1], "==", KNOT_RDATA_WF_END,
+ "get A descriptor 2. item type");
+
+ // 32. NXT
+ descr = get_obsolete_rdata_descriptor(30);
+ ok(strcmp(descr->type_name, "NXT") == 0, "get NXT descriptor name");
+ cmp_ok(descr->block_types[0], "==", KNOT_RDATA_WF_COMPRESSED_DNAME,
+ "get CNAME descriptor 1. item type");
+ cmp_ok(descr->block_types[1], "==", KNOT_RDATA_WF_REMAINDER,
+ "get CNAME descriptor 2. item type");
+ cmp_ok(descr->block_types[2], "==", KNOT_RDATA_WF_END,
+ "get CNAME descriptor 3. item type");
+
+ // 33. TYPE38 (A6)
+ descr = get_obsolete_rdata_descriptor(38);
+ ok(descr->type_name == 0, "get TYPE38 descriptor name");
+ cmp_ok(descr->block_types[0], "==", KNOT_RDATA_WF_REMAINDER,
+ "get TYPE38 descriptor 1. item type");
+ cmp_ok(descr->block_types[1], "==", KNOT_RDATA_WF_END,
+ "get TYPE38 descriptor 2. item type");
+
return 0;
}
diff --git a/src/tests/common/events_tests.c b/src/tests/common/events_tests.c
index 713bb5a..6ceb17a 100644
--- a/src/tests/common/events_tests.c
+++ b/src/tests/common/events_tests.c
@@ -51,7 +51,11 @@ void* term_thr(void *arg)
static int events_tests_count(int argc, char *argv[])
{
- return 9 + 11;
+ int count = 9 + 10;
+#ifdef ENABLE_TIMED_TESTS
+ count += 1;
+#endif
+ return count;
}
static int events_tests_run(int argc, char *argv[])
@@ -137,6 +141,7 @@ static int events_tests_run(int argc, char *argv[])
gettimeofday(&rt, 0);
ok(e != 0, "evsched: received valid event");
+#ifdef ENABLE_TIMED_TESTS
// 4. Check receive time
double passed = (rt.tv_sec - st.tv_sec) * 1000;
passed += (rt.tv_usec - st.tv_usec) / 1000;
@@ -145,6 +150,7 @@ static int events_tests_run(int argc, char *argv[])
int in_bounds = (passed >= lb) && (passed <= ub);
ok(in_bounds, "evsched: receive time %.1lfms is in <%.1lf,%.1lf>",
passed, lb, ub);
+#endif
// 5. Check data
ok(e->data == (void*)0xcafe, "evsched: received data is valid");
diff --git a/src/tests/common/fdset_tests.c b/src/tests/common/fdset_tests.c
index e8b9d73..f5d351c 100644
--- a/src/tests/common/fdset_tests.c
+++ b/src/tests/common/fdset_tests.c
@@ -121,12 +121,11 @@ static int fdset_tests_run(int argc, char *argv[])
pthread_create(&t, 0, thr_action, &fds[1]);
/* 4. Watch fdset. */
- int nfds = poll(set.pfd, set.n, 2000);
+ int nfds = poll(set.pfd, set.n, 60 * 1000);
gettimeofday(&te, 0);
size_t diff = timeval_diff(&ts, &te);
- ok(nfds > 0 && diff > 99 && diff < 10000,
- "fdset: poll returned %d events in %zu ms", nfds, diff);
+ ok(nfds > 0, "fdset: poll returned %d events in %zu ms", nfds, diff);
/* 5. Prepare event set. */
ok(set.pfd[0].revents & POLLIN, "fdset: pipe is active");
diff --git a/src/tests/knot/dthreads_tests.c b/src/tests/knot/dthreads_tests.c
index 247f66e..e562648 100644
--- a/src/tests/knot/dthreads_tests.c
+++ b/src/tests/knot/dthreads_tests.c
@@ -107,7 +107,9 @@ static inline int dt_test_repurpose(dt_unit_t *unit, int id)
/*! \brief Cancel single thread. */
static inline int dt_test_cancel(dt_unit_t *unit, int id)
{
- return dt_cancel(unit->threads[id]) == 0;
+ int ret = dt_cancel(unit->threads[id]);
+ ret |= dt_signalize(unit->threads[id], SIGALRM);
+ return ret == 0; /* Both succeeded. */
}
/*! \brief Reanimate dead threads. */
diff --git a/src/zscanner/scanner_functions.c b/src/zscanner/scanner_functions.c
index 94a42da..7c68348 100644
--- a/src/zscanner/scanner_functions.c
+++ b/src/zscanner/scanner_functions.c
@@ -920,7 +920,6 @@ static int32_t get_block_length(const uint8_t *data,
switch (type) {
case KNOT_RDATA_WF_COMPRESSED_DNAME:
case KNOT_RDATA_WF_UNCOMPRESSED_DNAME:
- case KNOT_RDATA_WF_LITERAL_DNAME:
ret = get_dname_length(data + offset, data_len - offset);
if (ret > 0) {
diff --git a/src/zscanner/test/cases/06-0_INCLUDE.in b/src/zscanner/test/cases/06-0_INCLUDE.in
index d8f4d27..2b85692 100644
--- a/src/zscanner/test/cases/06-0_INCLUDE.in
+++ b/src/zscanner/test/cases/06-0_INCLUDE.in
@@ -19,10 +19,10 @@ $INCLUDE \./includes/include2 _a_.-b-c-./d/. ; Slashed character in file name,
$INCLUDE ./includes/include2 \0320\ \\\"\.\@\*.tld. ; Origin with special chars
5. NS @
-$INCLUDE /home/ondrej/Projects/knot/src/zscanner/test/cases/includes/include2 ; Absolute path without origin
+$INCLUDE /home/vavrusam/knot/src/zscanner/test/cases/includes/include2 ; Absolute path without origin
6. NS @
-$INCLUDE /home/ondrej/Projects/knot/src/zscanner/test/cases/includes/include2 tld. ; Absolute path with origin
+$INCLUDE /home/vavrusam/knot/src/zscanner/test/cases/includes/include2 tld. ; Absolute path with origin
7. NS @
; KO
diff --git a/src/zscanner/test/cases/06-3_INCLUDE.in b/src/zscanner/test/cases/06-3_INCLUDE.in
index 3dc9ba8..0f59e45 100644
--- a/src/zscanner/test/cases/06-3_INCLUDE.in
+++ b/src/zscanner/test/cases/06-3_INCLUDE.in
@@ -2,4 +2,4 @@ $ORIGIN .
$TTL 1
; KO
-$INCLUDE /home/ondrej/Projects/knot/src/zscanner/test/cases/ ; Given file is a directory
+$INCLUDE /home/vavrusam/knot/src/zscanner/test/cases/ ; Given file is a directory
diff --git a/src/zscanner/test/cases/06-4_INCLUDE.in b/src/zscanner/test/cases/06-4_INCLUDE.in
index f4e3c51..80b9ef1 100644
--- a/src/zscanner/test/cases/06-4_INCLUDE.in
+++ b/src/zscanner/test/cases/06-4_INCLUDE.in
@@ -2,4 +2,4 @@ $ORIGIN .
$TTL 1
; KO
-$INCLUDE /home/ondrej/Projects/knot/src/zscanner/test/cases/zscanner_tests/file-doesnt-exist ; File doesn't exist
+$INCLUDE /home/vavrusam/knot/src/zscanner/test/cases/zscanner_tests/file-doesnt-exist ; File doesn't exist
diff --git a/src/zscanner/test/run_tests.sh b/src/zscanner/test/run_tests.sh
index ccac549..682d50a 100644
--- a/src/zscanner/test/run_tests.sh
+++ b/src/zscanner/test/run_tests.sh
@@ -1,7 +1,7 @@
#!/bin/sh
-TESTS_DIR="/home/ondrej/Projects/knot/src/zscanner/test/cases"
-OUTS_DIR="/home/ondrej/Projects/knot/src/zscanner/test/.out"
+TESTS_DIR="/home/vavrusam/knot/src/zscanner/test/cases"
+OUTS_DIR="/home/vavrusam/knot/src/zscanner/test/.out"
TEST_BIN="./../zscanner-tool -m 2"
# Delete temporary output directory at exit.
diff --git a/ylwrap b/ylwrap
index 9253635..7befa46 100755
--- a/ylwrap
+++ b/ylwrap
@@ -1,10 +1,9 @@
#! /bin/sh
# ylwrap - wrapper for lex/yacc invocations.
-scriptversion=2011-08-25.18; # UTC
+scriptversion=2012-07-14.08; # UTC
-# Copyright (C) 1996, 1997, 1998, 1999, 2001, 2002, 2003, 2004, 2005,
-# 2007, 2009, 2010, 2011 Free Software Foundation, Inc.
+# Copyright (C) 1996-2012 Free Software Foundation, Inc.
#
# Written by Tom Tromey <tromey@cygnus.com>.
#
@@ -30,9 +29,40 @@ scriptversion=2011-08-25.18; # UTC
# bugs to <bug-automake@gnu.org> or send patches to
# <automake-patches@gnu.org>.
+get_dirname ()
+{
+ case $1 in
+ */*|*\\*) printf '%s\n' "$1" | sed -e 's|\([\\/]\)[^\\/]*$|\1|';;
+ # Otherwise, we want the empty string (not ".").
+ esac
+}
+
+# guard FILE
+# ----------
+# The CPP macro used to guard inclusion of FILE.
+guard()
+{
+ printf '%s\n' "$from" \
+ | sed \
+ -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'\
+ -e 's/[^ABCDEFGHIJKLMNOPQRSTUVWXYZ]/_/g'
+}
+
+# quote_for_sed [STRING]
+# ----------------------
+# Return STRING (or stdin) quoted to be used as a sed pattern.
+quote_for_sed ()
+{
+ case $# in
+ 0) cat;;
+ 1) printf '%s\n' "$1";;
+ esac \
+ | sed -e 's|[][\\.*]|\\&|g'
+}
+
case "$1" in
'')
- echo "$0: No files given. Try \`$0 --help' for more information." 1>&2
+ echo "$0: No files given. Try '$0 --help' for more information." 1>&2
exit 1
;;
--basedir)
@@ -67,6 +97,8 @@ esac
# The input.
input="$1"
shift
+# We'll later need for a correct munging of "#line" directives.
+input_sub_rx=`get_dirname "$input" | quote_for_sed`
case "$input" in
[\\/]* | ?:[\\/]*)
# Absolute path; do nothing.
@@ -76,15 +108,40 @@ case "$input" in
input="`pwd`/$input"
;;
esac
+input_rx=`get_dirname "$input" | quote_for_sed`
+
+# Since DOS filename conventions don't allow two dots,
+# the DOS version of Bison writes out y_tab.c instead of y.tab.c
+# and y_tab.h instead of y.tab.h. Test to see if this is the case.
+y_tab_nodot=false
+if test -f y_tab.c || test -f y_tab.h; then
+ y_tab_nodot=true
+fi
-pairlist=
+# The parser itself, the first file, is the destination of the .y.c
+# rule in the Makefile.
+parser=$1
+# A sed program to s/FROM/TO/g for all the FROM/TO so that, for
+# instance, we rename #include "y.tab.h" into #include "parse.h"
+# during the conversion from y.tab.c to parse.c.
+rename_sed=
while test "$#" -ne 0; do
if test "$1" = "--"; then
shift
break
fi
- pairlist="$pairlist $1"
+ from=$1
+ # Handle y_tab.c and y_tab.h output by DOS
+ if $y_tab_nodot; then
+ case $from in
+ "y.tab.c") from=y_tab.c;;
+ "y.tab.h") from=y_tab.h;;
+ esac
+ fi
+ shift
+ to=$1
shift
+ rename_sed="${rename_sed}s|"`quote_for_sed "$from"`"|$to|g;"
done
# The program to run.
@@ -115,98 +172,55 @@ esac
ret=$?
if test $ret -eq 0; then
- set X $pairlist
- shift
- first=yes
- # Since DOS filename conventions don't allow two dots,
- # the DOS version of Bison writes out y_tab.c instead of y.tab.c
- # and y_tab.h instead of y.tab.h. Test to see if this is the case.
- y_tab_nodot="no"
- if test -f y_tab.c || test -f y_tab.h; then
- y_tab_nodot="yes"
- fi
-
- # The directory holding the input.
- input_dir=`echo "$input" | sed -e 's,\([\\/]\)[^\\/]*$,\1,'`
- # Quote $INPUT_DIR so we can use it in a regexp.
- # FIXME: really we should care about more than `.' and `\'.
- input_rx=`echo "$input_dir" | sed 's,\\\\,\\\\\\\\,g;s,\\.,\\\\.,g'`
-
- while test "$#" -ne 0; do
- from="$1"
- # Handle y_tab.c and y_tab.h output by DOS
- if test $y_tab_nodot = "yes"; then
- if test $from = "y.tab.c"; then
- from="y_tab.c"
- else
- if test $from = "y.tab.h"; then
- from="y_tab.h"
- fi
- fi
- fi
+ for from in *
+ do
+ to=`printf '%s\n' "$from" | sed "$rename_sed"`
if test -f "$from"; then
# If $2 is an absolute path name, then just use that,
- # otherwise prepend `../'.
- case "$2" in
- [\\/]* | ?:[\\/]*) target="$2";;
- *) target="../$2";;
+ # otherwise prepend '../'.
+ case $to in
+ [\\/]* | ?:[\\/]*) target=$to;;
+ *) target="../$to";;
esac
- # We do not want to overwrite a header file if it hasn't
- # changed. This avoid useless recompilations. However the
- # parser itself (the first file) should always be updated,
- # because it is the destination of the .y.c rule in the
- # Makefile. Divert the output of all other files to a temporary
- # file so we can compare them to existing versions.
- if test $first = no; then
+ # Do not overwrite unchanged header files to avoid useless
+ # recompilations. Always update the parser itself: it is the
+ # destination of the .y.c rule in the Makefile. Divert the
+ # output of all other files to a temporary file so we can
+ # compare them to existing versions.
+ if test $from != $parser; then
realtarget="$target"
- target="tmp-`echo $target | sed s/.*[\\/]//g`"
+ target=tmp-`printf '%s\n' "$target" | sed 's|.*[\\/]||g'`
fi
- # Edit out `#line' or `#' directives.
- #
- # We don't want the resulting debug information to point at
- # an absolute srcdir; it is better for it to just mention the
- # .y file with no path.
- #
- # We want to use the real output file name, not yy.lex.c for
- # instance.
- #
- # We want the include guards to be adjusted too.
- FROM=`echo "$from" | sed \
- -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'\
- -e 's/[^ABCDEFGHIJKLMNOPQRSTUVWXYZ]/_/g'`
- TARGET=`echo "$2" | sed \
- -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'\
- -e 's/[^ABCDEFGHIJKLMNOPQRSTUVWXYZ]/_/g'`
-
- sed -e "/^#/!b" -e "s,$input_rx,," -e "s,$from,$2," \
- -e "s,$FROM,$TARGET," "$from" >"$target" || ret=$?
-
- # Check whether header files must be updated.
- if test $first = no; then
+
+ # Munge "#line" or "#" directives. Don't let the resulting
+ # debug information point at an absolute srcdir. Use the real
+ # output file name, not yy.lex.c for instance. Adjust the
+ # include guards too.
+ FROM=`guard "$from"`
+ TARGET=`guard "$to"`
+ sed -e "/^#/!b" -e "s|$input_rx|$input_sub_rx|" -e "$rename_sed" \
+ -e "s|$FROM|$TARGET|" "$from" >"$target" || ret=$?
+
+ # Check whether files must be updated.
+ if test "$from" != "$parser"; then
if test -f "$realtarget" && cmp -s "$realtarget" "$target"; then
- echo "$2" is unchanged
+ echo "$to is unchanged"
rm -f "$target"
else
- echo updating "$2"
+ echo "updating $to"
mv -f "$target" "$realtarget"
fi
fi
else
- # A missing file is only an error for the first file. This
- # is a blatant hack to let us support using "yacc -d". If -d
- # is not specified, we don't want an error when the header
- # file is "missing".
- if test $first = yes; then
+ # A missing file is only an error for the parser. This is a
+ # blatant hack to let us support using "yacc -d". If -d is not
+ # specified, don't fail when the header file is "missing".
+ if test "$from" = "$parser"; then
ret=1
fi
fi
- shift
- shift
- first=no
done
-else
- ret=$?
fi
# Remove the directory.