diff --git a/0001-bash-Don-t-define-bashcompdir-twice.patch b/0001-bash-Don-t-define-bashcompdir-twice.patch new file mode 100644 index 0000000..00fd704 --- /dev/null +++ b/0001-bash-Don-t-define-bashcompdir-twice.patch @@ -0,0 +1,24 @@ +From ef13e7db5d9d8e5ff6977821c3e798bb6c7725d9 Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Tue, 10 Jul 2018 10:28:44 +0100 +Subject: [PATCH 01/10] bash: Don't define bashcompdir twice. + +--- + bash/Makefile.am | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/bash/Makefile.am b/bash/Makefile.am +index f38b7a1..e46784c 100644 +--- a/bash/Makefile.am ++++ b/bash/Makefile.am +@@ -36,7 +36,6 @@ EXTRA_DIST = README + + if HAVE_BASH_COMPLETION + +-bashcompdir = @bashcompdir@ + dist_bashcomp_DATA = nbdkit + + endif +-- +2.17.1 + diff --git a/0002-xz-Minor-rewrites-to-improve-the-flow-of-the-man-pag.patch b/0002-xz-Minor-rewrites-to-improve-the-flow-of-the-man-pag.patch new file mode 100644 index 0000000..ee26f6e --- /dev/null +++ b/0002-xz-Minor-rewrites-to-improve-the-flow-of-the-man-pag.patch @@ -0,0 +1,60 @@ +From 9fb8c7b550cddb6504386a8776e0abaeac4c1f20 Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Sat, 14 Jul 2018 21:25:13 +0100 +Subject: [PATCH 02/10] xz: Minor rewrites to improve the flow of the man page. + +--- + plugins/xz/nbdkit-xz-plugin.pod | 26 ++++++++++++++------------ + 1 file changed, 14 insertions(+), 12 deletions(-) + +diff --git a/plugins/xz/nbdkit-xz-plugin.pod b/plugins/xz/nbdkit-xz-plugin.pod +index 75cb881..7d8332a 100644 +--- a/plugins/xz/nbdkit-xz-plugin.pod ++++ b/plugins/xz/nbdkit-xz-plugin.pod +@@ -24,29 +24,31 @@ find out how many streams and blocks are in an xz file by doing: + $ xz --list winxp.img.xz + Strms Blocks Compressed Uncompressed Ratio Check Filename + 1 1 2,100.0 MiB 6,144.0 MiB 0.342 CRC64 winxp.img.xz +- ============= ++ ↑↑↑ ↑↑↑ ++ streams blocks + + xz files are seekable on block boundaries only. Seeking is done by +-seeking directly to the lower block boundary, then (slowly) +-uncompressing data until the precise byte is reached. +- +-B + +-To do this, use the I<--block-size> option with a small-ish block +-size. For example the same image as above compressed with a 16 MB +-block size: ++Use the I<--block-size> option with a small-ish block size. For ++example this is the same image compressed with a 16 MB block size: + + $ xz --best --block-size=16777216 winxp.img ++ ───────────────────── + $ xz --list winxp.img.xz + Strms Blocks Compressed Uncompressed Ratio Check Filename + 1 384 2,120.1 MiB 6,144.0 MiB 0.345 CRC64 winxp.img.xz ++ ↑↑↑ ++ blocks + +-This file can be accessed randomly, and at most 16 MB of compressed +-data will have to be uncompressed to seek to any byte. ++This file can be accessed randomly. At most 16 MB will have to be ++uncompressed to seek to any byte. + +-Note as you would expect, xz cannot compress quite as efficiently when +-using a small block size. The space penalty in the above example is ++As you would expect, xz cannot compress as efficiently when using a ++smaller block size. The space penalty in the above example is + S 1%> of the compressed file size. + + =head1 PARAMETERS +-- +2.17.1 + diff --git a/0003-streaming-Add-illustrations-to-the-man-page.patch b/0003-streaming-Add-illustrations-to-the-man-page.patch new file mode 100644 index 0000000..0f8d30d --- /dev/null +++ b/0003-streaming-Add-illustrations-to-the-man-page.patch @@ -0,0 +1,56 @@ +From 166be40fa335649caf2615b384cc006d92bc5170 Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Sun, 15 Jul 2018 11:14:49 +0100 +Subject: [PATCH 03/10] streaming: Add illustrations to the man page. + +Also improve the flow of the language and provide cross-reference to +captive nbdkit. +--- + plugins/streaming/nbdkit-streaming-plugin.pod | 25 ++++++++++++++++--- + 1 file changed, 21 insertions(+), 4 deletions(-) + +diff --git a/plugins/streaming/nbdkit-streaming-plugin.pod b/plugins/streaming/nbdkit-streaming-plugin.pod +index a4a9714..98e8337 100644 +--- a/plugins/streaming/nbdkit-streaming-plugin.pod ++++ b/plugins/streaming/nbdkit-streaming-plugin.pod +@@ -18,16 +18,33 @@ end of the disk without seeking backwards, then this plugin will turn + the resulting disk image into a stream of data which is written to the + named C parameter. + +-Typical usage is with qemu tools. For example: ++ ┌───────────┐ ++ client │ nbdkit │ plugin streams ++ writes ──────▶│ streaming │──────▶ data to pipe ++ │ plugin │ ++ └───────────┘ + +- qemu-img convert input -O raw output ++Typical usage is with qemu tools. The following command will I ++work because the output is a pipe or socket: + +-does I work if C is a pipe. However this does: ++ qemu-img convert input -O raw pipe + +- nbdkit -U /tmp/nbd.sock streaming pipe=output --run ' ++However this will work: ++ ++ nbdkit -U - streaming pipe=pipe --run ' + qemu-img convert -n input -O raw $nbd + ' + ++ ┌───────────┐ ┌───────────┐ ++ reads │ qemu-img │ │ nbdkit │ plugin streams ++ input ──────▶│ convert │──────▶│ streaming │──────▶ data to pipe ++ file │ command │ │ plugin │ ++ └───────────┘ ↑└───────────┘ ++ Unix domain socket (-U -) ++ ++For use of the I<--run> and I<-U -> options, see ++L. ++ + =head1 PARAMETERS + + =over 4 +-- +2.17.1 + diff --git a/0004-tests-Put-test.lua-into-alphabetical-order-in-the-li.patch b/0004-tests-Put-test.lua-into-alphabetical-order-in-the-li.patch new file mode 100644 index 0000000..7a43b0a --- /dev/null +++ b/0004-tests-Put-test.lua-into-alphabetical-order-in-the-li.patch @@ -0,0 +1,28 @@ +From bc3b8c27b40165af6d7dcca15dfae98cbf7566e8 Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Sun, 15 Jul 2018 11:51:39 +0100 +Subject: [PATCH 04/10] tests: Put test.lua into alphabetical order in the + list. + +Fixes commit ff2b304e9c5ddef01081b9aef113bf0cf6dfabac. +--- + tests/Makefile.am | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tests/Makefile.am b/tests/Makefile.am +index 58d24fc..5f21e75 100644 +--- a/tests/Makefile.am ++++ b/tests/Makefile.am +@@ -57,8 +57,8 @@ EXTRA_DIST = \ + test-help-plugin.sh \ + test-ip.sh \ + test-log.sh \ +- test-nozero.sh \ + test.lua \ ++ test-nozero.sh \ + test_ocaml_plugin.ml \ + test-ocaml.c \ + test-parallel-file.sh \ +-- +2.17.1 + diff --git a/0005-Add-pattern-plugin.patch b/0005-Add-pattern-plugin.patch new file mode 100644 index 0000000..22fff7c --- /dev/null +++ b/0005-Add-pattern-plugin.patch @@ -0,0 +1,548 @@ +From 0a9205dc8c3b5d5703bd71bc58db503c05b0063b Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Sat, 7 Jul 2018 13:30:32 +0100 +Subject: [PATCH 05/10] Add pattern plugin. + +This generates a simple, fixed test pattern which can be used to test +nbdkit filters (especially nbdkit-offset-filter), and also NBD +clients. +--- + common-rules.mk | 1 + + configure.ac | 1 + + plugins/null/nbdkit-null-plugin.pod | 1 + + plugins/pattern/Makefile.am | 60 ++++++++++ + plugins/pattern/nbdkit-pattern-plugin.pod | 99 ++++++++++++++++ + plugins/pattern/pattern.c | 134 ++++++++++++++++++++++ + plugins/random/nbdkit-random-plugin.pod | 1 + + plugins/zero/nbdkit-zero-plugin.pod | 1 + + tests/Makefile.am | 4 + + tests/test-pattern.sh | 121 +++++++++++++++++++ + 10 files changed, 423 insertions(+) + create mode 100644 plugins/pattern/Makefile.am + create mode 100644 plugins/pattern/nbdkit-pattern-plugin.pod + create mode 100644 plugins/pattern/pattern.c + create mode 100755 tests/test-pattern.sh + +diff --git a/common-rules.mk b/common-rules.mk +index 5877907..01beff5 100644 +--- a/common-rules.mk ++++ b/common-rules.mk +@@ -46,6 +46,7 @@ plugins = \ + nbd \ + null \ + ocaml \ ++ pattern \ + perl \ + python \ + random \ +diff --git a/configure.ac b/configure.ac +index 6e8d3e2..6304ac8 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -610,6 +610,7 @@ AC_CONFIG_FILES([Makefile + plugins/nbd/Makefile + plugins/null/Makefile + plugins/ocaml/Makefile ++ plugins/pattern/Makefile + plugins/perl/Makefile + plugins/python/Makefile + plugins/random/Makefile +diff --git a/plugins/null/nbdkit-null-plugin.pod b/plugins/null/nbdkit-null-plugin.pod +index 7bd7278..55affb8 100644 +--- a/plugins/null/nbdkit-null-plugin.pod ++++ b/plugins/null/nbdkit-null-plugin.pod +@@ -33,6 +33,7 @@ This parameter is required. + + L, + L, ++L, + L. + L. + +diff --git a/plugins/pattern/Makefile.am b/plugins/pattern/Makefile.am +new file mode 100644 +index 0000000..da092db +--- /dev/null ++++ b/plugins/pattern/Makefile.am +@@ -0,0 +1,60 @@ ++# nbdkit ++# Copyright (C) 2017-2018 Red Hat Inc. ++# All rights reserved. ++# ++# Redistribution and use in source and binary forms, with or without ++# modification, are permitted provided that the following conditions are ++# met: ++# ++# * Redistributions of source code must retain the above copyright ++# notice, this list of conditions and the following disclaimer. ++# ++# * Redistributions in binary form must reproduce the above copyright ++# notice, this list of conditions and the following disclaimer in the ++# documentation and/or other materials provided with the distribution. ++# ++# * Neither the name of Red Hat nor the names of its contributors may be ++# used to endorse or promote products derived from this software without ++# specific prior written permission. ++# ++# THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND ++# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, ++# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A ++# PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR ++# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, ++# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF ++# USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ++# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, ++# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT ++# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ++# SUCH DAMAGE. ++ ++include $(top_srcdir)/common-rules.mk ++ ++EXTRA_DIST = nbdkit-pattern-plugin.pod ++ ++plugin_LTLIBRARIES = nbdkit-pattern-plugin.la ++ ++nbdkit_pattern_plugin_la_SOURCES = \ ++ pattern.c \ ++ $(top_srcdir)/include/nbdkit-plugin.h ++ ++nbdkit_pattern_plugin_la_CPPFLAGS = \ ++ -I$(top_srcdir)/include ++nbdkit_pattern_plugin_la_CFLAGS = \ ++ $(WARNINGS_CFLAGS) ++nbdkit_pattern_plugin_la_LDFLAGS = \ ++ -module -avoid-version -shared ++ ++if HAVE_POD2MAN ++ ++man_MANS = nbdkit-pattern-plugin.1 ++CLEANFILES += $(man_MANS) ++ ++nbdkit-pattern-plugin.1: nbdkit-pattern-plugin.pod ++ $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ ++ if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ ++ mv $@.t $@ ++ ++endif +diff --git a/plugins/pattern/nbdkit-pattern-plugin.pod b/plugins/pattern/nbdkit-pattern-plugin.pod +new file mode 100644 +index 0000000..7a6b498 +--- /dev/null ++++ b/plugins/pattern/nbdkit-pattern-plugin.pod +@@ -0,0 +1,99 @@ ++=encoding utf8 ++ ++=head1 NAME ++ ++nbdkit-pattern-plugin - plugin to serve a fixed pattern of data for testing ++ ++=head1 SYNOPSIS ++ ++ nbdkit pattern size=SIZE ++ ++=head1 DESCRIPTION ++ ++C is a plugin for L which serves a ++fixed pattern of data, read only. This is used for testing nbdkit ++filters and NBD clients. ++ ++The fixed pattern is the offset, as a 64 bit big endian integer, every ++8 bytes. In hexadecimal this looks like: ++ ++ offset data ++ 0000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 08 ++ 0010: 00 00 00 00 00 00 00 10 00 00 00 00 00 00 00 18 ++ 0020: 00 00 00 00 00 00 00 20 00 00 00 00 00 00 00 28 ++ └──────────┬──────────┘ ++ 64 bit big endian int which encodes the offset of ++ the first byte of this int in the file ++ ++The size of the virtual disk must be specified using the C ++parameter. If the size is not a multiple of 8 then the last 8 byte ++offset in the pattern is truncated. ++ ++=head1 PARAMETERS ++ ++=over 4 ++ ++=item B ++ ++Specify the virtual size of the disk image. ++ ++This parameter is required. ++ ++=back ++ ++=head1 SEE ALSO ++ ++L, ++L, ++L, ++L, ++L, ++L. ++ ++=head1 AUTHORS ++ ++Richard W.M. Jones ++ ++=head1 COPYRIGHT ++ ++Copyright (C) 2018 Red Hat Inc. ++ ++=head1 LICENSE ++ ++Redistribution and use in source and binary forms, with or without ++modification, are permitted provided that the following conditions are ++met: ++ ++=over 4 ++ ++=item * ++ ++Redistributions of source code must retain the above copyright ++notice, this list of conditions and the following disclaimer. ++ ++=item * ++ ++Redistributions in binary form must reproduce the above copyright ++notice, this list of conditions and the following disclaimer in the ++documentation and/or other materials provided with the distribution. ++ ++=item * ++ ++Neither the name of Red Hat nor the names of its contributors may be ++used to endorse or promote products derived from this software without ++specific prior written permission. ++ ++=back ++ ++THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND ++ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, ++THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A ++PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR ++CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, ++SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF ++USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ++ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, ++OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT ++OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ++SUCH DAMAGE. +diff --git a/plugins/pattern/pattern.c b/plugins/pattern/pattern.c +new file mode 100644 +index 0000000..e1dc798 +--- /dev/null ++++ b/plugins/pattern/pattern.c +@@ -0,0 +1,134 @@ ++/* nbdkit ++ * Copyright (C) 2017-2018 Red Hat Inc. ++ * All rights reserved. ++ * ++ * Redistribution and use in source and binary forms, with or without ++ * modification, are permitted provided that the following conditions are ++ * met: ++ * ++ * * Redistributions of source code must retain the above copyright ++ * notice, this list of conditions and the following disclaimer. ++ * ++ * * Redistributions in binary form must reproduce the above copyright ++ * notice, this list of conditions and the following disclaimer in the ++ * documentation and/or other materials provided with the distribution. ++ * ++ * * Neither the name of Red Hat nor the names of its contributors may be ++ * used to endorse or promote products derived from this software without ++ * specific prior written permission. ++ * ++ * THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND ++ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, ++ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A ++ * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR ++ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, ++ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF ++ * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ++ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, ++ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT ++ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ++ * SUCH DAMAGE. ++ */ ++ ++#include ++ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++ ++#define NBDKIT_API_VERSION 2 ++#include ++ ++/* The size of disk in bytes (initialized by size= parameter). */ ++static size_t size = 0; ++ ++static int ++pattern_config (const char *key, const char *value) ++{ ++ int64_t r; ++ ++ if (strcmp (key, "size") == 0) { ++ r = nbdkit_parse_size (value); ++ if (r == -1) ++ return -1; ++ if (r > SIZE_MAX) { ++ nbdkit_error ("size > SIZE_MAX"); ++ return -1; ++ } ++ size = (ssize_t) r; ++ } ++ else { ++ nbdkit_error ("unknown parameter '%s'", key); ++ return -1; ++ } ++ ++ return 0; ++} ++ ++#define pattern_config_help \ ++ "size= (required) Size of the backing disk" ++ ++#define THREAD_MODEL NBDKIT_THREAD_MODEL_PARALLEL ++ ++/* No meaning, just used as the address for the handle. */ ++static int ph; ++ ++/* Create the per-connection handle. */ ++static void * ++pattern_open (int readonly) ++{ ++ return &ph; ++} ++ ++/* Get the disk size. */ ++static int64_t ++pattern_get_size (void *handle) ++{ ++ return (int64_t) size; ++} ++ ++#define MIN(a, b) ((a) < (b) ? (a) : (b)) ++ ++/* Read data. */ ++static int ++pattern_pread (void *handle, void *buf, uint32_t count, uint64_t offset, ++ uint32_t flags) ++{ ++ char *b = buf; ++ uint64_t d; ++ uint64_t o; ++ size_t n; ++ ++ while (count > 0) { ++ d = htobe64 (offset & ~7); ++ o = offset & 7; ++ n = MIN (count, 8-o); ++ memcpy (b, (char *)&d + o, n); ++ b += 8-o; ++ offset += 8-o; ++ count -= n; ++ } ++ ++ return 0; ++} ++ ++static struct nbdkit_plugin plugin = { ++ .name = "pattern", ++ .version = PACKAGE_VERSION, ++ .config = pattern_config, ++ .config_help = pattern_config_help, ++ .open = pattern_open, ++ .get_size = pattern_get_size, ++ .pread = pattern_pread, ++ /* In this plugin, errno is preserved properly along error return ++ * paths from failed system calls. ++ */ ++ .errno_is_preserved = 1, ++}; ++ ++NBDKIT_REGISTER_PLUGIN(plugin) +diff --git a/plugins/random/nbdkit-random-plugin.pod b/plugins/random/nbdkit-random-plugin.pod +index e746699..6539d61 100644 +--- a/plugins/random/nbdkit-random-plugin.pod ++++ b/plugins/random/nbdkit-random-plugin.pod +@@ -44,6 +44,7 @@ If not specified then a random seed is chosen. + L, + L, + L, ++L, + L. + + =head1 AUTHORS +diff --git a/plugins/zero/nbdkit-zero-plugin.pod b/plugins/zero/nbdkit-zero-plugin.pod +index 67763da..015c70a 100644 +--- a/plugins/zero/nbdkit-zero-plugin.pod ++++ b/plugins/zero/nbdkit-zero-plugin.pod +@@ -21,6 +21,7 @@ protocol and NBD clients. + L, + L, + L, ++L, + L. + + =head1 AUTHORS +diff --git a/tests/Makefile.am b/tests/Makefile.am +index 5f21e75..354c12c 100644 +--- a/tests/Makefile.am ++++ b/tests/Makefile.am +@@ -63,6 +63,7 @@ EXTRA_DIST = \ + test-ocaml.c \ + test-parallel-file.sh \ + test-parallel-nbd.sh \ ++ test-pattern.sh \ + test-python-exception.sh \ + test.pl \ + test.py \ +@@ -315,6 +316,9 @@ test_memory_SOURCES = test-memory.c test.h + test_memory_CFLAGS = $(WARNINGS_CFLAGS) $(LIBGUESTFS_CFLAGS) + test_memory_LDADD = libtest.la $(LIBGUESTFS_LIBS) + ++# pattern plugin test. ++TESTS += test-pattern.sh ++ + # nbd plugin test. + LIBGUESTFS_TESTS += test-nbd + +diff --git a/tests/test-pattern.sh b/tests/test-pattern.sh +new file mode 100755 +index 0000000..2db4e0c +--- /dev/null ++++ b/tests/test-pattern.sh +@@ -0,0 +1,121 @@ ++#!/bin/bash - ++# nbdkit ++# Copyright (C) 2018 Red Hat Inc. ++# All rights reserved. ++# ++# Redistribution and use in source and binary forms, with or without ++# modification, are permitted provided that the following conditions are ++# met: ++# ++# * Redistributions of source code must retain the above copyright ++# notice, this list of conditions and the following disclaimer. ++# ++# * Redistributions in binary form must reproduce the above copyright ++# notice, this list of conditions and the following disclaimer in the ++# documentation and/or other materials provided with the distribution. ++# ++# * Neither the name of Red Hat nor the names of its contributors may be ++# used to endorse or promote products derived from this software without ++# specific prior written permission. ++# ++# THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND ++# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, ++# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A ++# PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR ++# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, ++# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF ++# USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ++# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, ++# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT ++# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ++# SUCH DAMAGE. ++ ++# Test the pattern plugin. ++# ++# Note we don't have any client which can issue misaligned NBD ++# requests. qemu-io will issue 512-byte aligned requests no matter ++# what read parameters we give it. Hence these tests are rather ++# limited. (XXX) ++ ++set -e ++ ++files="pattern.out pattern.pid pattern.sock" ++rm -f $files ++ ++# Test that qemu-io works ++if ! qemu-io --help >/dev/null; then ++ echo "$0: missing or broken qemu-io" ++ exit 77 ++fi ++ ++# Run nbdkit with pattern plugin. ++nbdkit -P pattern.pid -U pattern.sock pattern size=1G ++ ++# We may have to wait a short time for the pid file to appear. ++for i in `seq 1 10`; do ++ if test -f pattern.pid; then ++ break ++ fi ++ sleep 1 ++done ++if ! test -f pattern.pid; then ++ echo "$0: PID file was not created" ++ exit 1 ++fi ++ ++pid="$(cat pattern.pid)" ++ ++# Kill the nbdkit process on exit. ++cleanup () ++{ ++ status=$? ++ ++ kill $pid ++ rm -f $files ++ ++ exit $status ++} ++trap cleanup INT QUIT TERM EXIT ERR ++ ++qemu-io -r -f raw 'nbd+unix://?socket=pattern.sock' \ ++ -c 'r -v 0 512' | grep -E '^[[:xdigit:]]+:' > pattern.out ++if [ "$(cat pattern.out)" != "00000000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 08 ................ ++00000010: 00 00 00 00 00 00 00 10 00 00 00 00 00 00 00 18 ................ ++00000020: 00 00 00 00 00 00 00 20 00 00 00 00 00 00 00 28 ................ ++00000030: 00 00 00 00 00 00 00 30 00 00 00 00 00 00 00 38 .......0.......8 ++00000040: 00 00 00 00 00 00 00 40 00 00 00 00 00 00 00 48 ...............H ++00000050: 00 00 00 00 00 00 00 50 00 00 00 00 00 00 00 58 .......P.......X ++00000060: 00 00 00 00 00 00 00 60 00 00 00 00 00 00 00 68 ...............h ++00000070: 00 00 00 00 00 00 00 70 00 00 00 00 00 00 00 78 .......p.......x ++00000080: 00 00 00 00 00 00 00 80 00 00 00 00 00 00 00 88 ................ ++00000090: 00 00 00 00 00 00 00 90 00 00 00 00 00 00 00 98 ................ ++000000a0: 00 00 00 00 00 00 00 a0 00 00 00 00 00 00 00 a8 ................ ++000000b0: 00 00 00 00 00 00 00 b0 00 00 00 00 00 00 00 b8 ................ ++000000c0: 00 00 00 00 00 00 00 c0 00 00 00 00 00 00 00 c8 ................ ++000000d0: 00 00 00 00 00 00 00 d0 00 00 00 00 00 00 00 d8 ................ ++000000e0: 00 00 00 00 00 00 00 e0 00 00 00 00 00 00 00 e8 ................ ++000000f0: 00 00 00 00 00 00 00 f0 00 00 00 00 00 00 00 f8 ................ ++00000100: 00 00 00 00 00 00 01 00 00 00 00 00 00 00 01 08 ................ ++00000110: 00 00 00 00 00 00 01 10 00 00 00 00 00 00 01 18 ................ ++00000120: 00 00 00 00 00 00 01 20 00 00 00 00 00 00 01 28 ................ ++00000130: 00 00 00 00 00 00 01 30 00 00 00 00 00 00 01 38 .......0.......8 ++00000140: 00 00 00 00 00 00 01 40 00 00 00 00 00 00 01 48 ...............H ++00000150: 00 00 00 00 00 00 01 50 00 00 00 00 00 00 01 58 .......P.......X ++00000160: 00 00 00 00 00 00 01 60 00 00 00 00 00 00 01 68 ...............h ++00000170: 00 00 00 00 00 00 01 70 00 00 00 00 00 00 01 78 .......p.......x ++00000180: 00 00 00 00 00 00 01 80 00 00 00 00 00 00 01 88 ................ ++00000190: 00 00 00 00 00 00 01 90 00 00 00 00 00 00 01 98 ................ ++000001a0: 00 00 00 00 00 00 01 a0 00 00 00 00 00 00 01 a8 ................ ++000001b0: 00 00 00 00 00 00 01 b0 00 00 00 00 00 00 01 b8 ................ ++000001c0: 00 00 00 00 00 00 01 c0 00 00 00 00 00 00 01 c8 ................ ++000001d0: 00 00 00 00 00 00 01 d0 00 00 00 00 00 00 01 d8 ................ ++000001e0: 00 00 00 00 00 00 01 e0 00 00 00 00 00 00 01 e8 ................ ++000001f0: 00 00 00 00 00 00 01 f0 00 00 00 00 00 00 01 f8 ................" ] ++then ++ echo "$0: unexpected pattern:" ++ cat pattern.out ++ exit 1 ++fi ++ ++# The cleanup() function is called implicitly on exit. +-- +2.17.1 + diff --git a/0006-tests-Add-a-second-test-of-the-offset-filter.patch b/0006-tests-Add-a-second-test-of-the-offset-filter.patch new file mode 100644 index 0000000..e5de95a --- /dev/null +++ b/0006-tests-Add-a-second-test-of-the-offset-filter.patch @@ -0,0 +1,166 @@ +From 97a5e57037aa0130a1e46aa6162171d941a58d62 Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Sat, 7 Jul 2018 14:10:11 +0100 +Subject: [PATCH 06/10] tests: Add a second test of the offset filter. + +This tests that the offset filter works for non-aligned offsets and +that nbdkit can handle virtual disks which are ~ 2^63 bits in size. + +Implemented using the pattern plugin. +--- + tests/Makefile.am | 3 ++ + tests/test-offset2.sh | 121 ++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 124 insertions(+) + create mode 100755 tests/test-offset2.sh + +diff --git a/tests/Makefile.am b/tests/Makefile.am +index 354c12c..6c3a5a6 100644 +--- a/tests/Makefile.am ++++ b/tests/Makefile.am +@@ -61,6 +61,7 @@ EXTRA_DIST = \ + test-nozero.sh \ + test_ocaml_plugin.ml \ + test-ocaml.c \ ++ test-offset2.sh \ + test-parallel-file.sh \ + test-parallel-nbd.sh \ + test-pattern.sh \ +@@ -539,6 +540,8 @@ test_offset_SOURCES = test-offset.c test.h + test_offset_CFLAGS = $(WARNINGS_CFLAGS) $(LIBGUESTFS_CFLAGS) + test_offset_LDADD = libtest.la $(LIBGUESTFS_LIBS) + ++TESTS += test-offset2.sh ++ + # partition filter test. + LIBGUESTFS_TESTS += test-partition + +diff --git a/tests/test-offset2.sh b/tests/test-offset2.sh +new file mode 100755 +index 0000000..a4f44cc +--- /dev/null ++++ b/tests/test-offset2.sh +@@ -0,0 +1,121 @@ ++#!/bin/bash - ++# nbdkit ++# Copyright (C) 2018 Red Hat Inc. ++# All rights reserved. ++# ++# Redistribution and use in source and binary forms, with or without ++# modification, are permitted provided that the following conditions are ++# met: ++# ++# * Redistributions of source code must retain the above copyright ++# notice, this list of conditions and the following disclaimer. ++# ++# * Redistributions in binary form must reproduce the above copyright ++# notice, this list of conditions and the following disclaimer in the ++# documentation and/or other materials provided with the distribution. ++# ++# * Neither the name of Red Hat nor the names of its contributors may be ++# used to endorse or promote products derived from this software without ++# specific prior written permission. ++# ++# THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND ++# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, ++# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A ++# PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR ++# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, ++# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF ++# USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ++# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, ++# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT ++# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ++# SUCH DAMAGE. ++ ++# Additional test of the offset filter using the pattern plugin. ++ ++set -e ++set -x ++ ++files="offset2.out offset2.pid offset2.sock" ++rm -f $files ++ ++# Test that qemu-io works ++if ! qemu-io --help >/dev/null; then ++ echo "$0: missing or broken qemu-io" ++ exit 77 ++fi ++ ++# Run nbdkit with pattern plugin and offset filter in front. ++# 8070450532247927809 = 7E - 1023 ++nbdkit -P offset2.pid -U offset2.sock \ ++ --filter=offset \ ++ pattern size=7E \ ++ offset=8070450532247927809 range=512 ++ ++# We may have to wait a short time for the pid file to appear. ++for i in `seq 1 10`; do ++ if test -f offset2.pid; then ++ break ++ fi ++ sleep 1 ++done ++if ! test -f offset2.pid; then ++ echo "$0: PID file was not created" ++ exit 1 ++fi ++ ++pid="$(cat offset2.pid)" ++ ++# Kill the nbdkit process on exit. ++cleanup () ++{ ++ status=$? ++ ++ kill $pid ++ rm -f $files ++ ++ exit $status ++} ++trap cleanup INT QUIT TERM EXIT ERR ++ ++qemu-io -r -f raw 'nbd+unix://?socket=offset2.sock' \ ++ -c 'r -v 0 512' | grep -E '^[[:xdigit:]]+:' > offset2.out ++if [ "$(cat offset2.out)" != "00000000: ff ff ff ff ff fc 00 6f ff ff ff ff ff fc 08 6f .......o.......o ++00000010: ff ff ff ff ff fc 10 6f ff ff ff ff ff fc 18 6f .......o.......o ++00000020: ff ff ff ff ff fc 20 6f ff ff ff ff ff fc 28 6f .......o.......o ++00000030: ff ff ff ff ff fc 30 6f ff ff ff ff ff fc 38 6f ......0o......8o ++00000040: ff ff ff ff ff fc 40 6f ff ff ff ff ff fc 48 6f .......o......Ho ++00000050: ff ff ff ff ff fc 50 6f ff ff ff ff ff fc 58 6f ......Po......Xo ++00000060: ff ff ff ff ff fc 60 6f ff ff ff ff ff fc 68 6f .......o......ho ++00000070: ff ff ff ff ff fc 70 6f ff ff ff ff ff fc 78 6f ......po......xo ++00000080: ff ff ff ff ff fc 80 6f ff ff ff ff ff fc 88 6f .......o.......o ++00000090: ff ff ff ff ff fc 90 6f ff ff ff ff ff fc 98 6f .......o.......o ++000000a0: ff ff ff ff ff fc a0 6f ff ff ff ff ff fc a8 6f .......o.......o ++000000b0: ff ff ff ff ff fc b0 6f ff ff ff ff ff fc b8 6f .......o.......o ++000000c0: ff ff ff ff ff fc c0 6f ff ff ff ff ff fc c8 6f .......o.......o ++000000d0: ff ff ff ff ff fc d0 6f ff ff ff ff ff fc d8 6f .......o.......o ++000000e0: ff ff ff ff ff fc e0 6f ff ff ff ff ff fc e8 6f .......o.......o ++000000f0: ff ff ff ff ff fc f0 6f ff ff ff ff ff fc f8 6f .......o.......o ++00000100: ff ff ff ff ff fd 00 6f ff ff ff ff ff fd 08 6f .......o.......o ++00000110: ff ff ff ff ff fd 10 6f ff ff ff ff ff fd 18 6f .......o.......o ++00000120: ff ff ff ff ff fd 20 6f ff ff ff ff ff fd 28 6f .......o.......o ++00000130: ff ff ff ff ff fd 30 6f ff ff ff ff ff fd 38 6f ......0o......8o ++00000140: ff ff ff ff ff fd 40 6f ff ff ff ff ff fd 48 6f .......o......Ho ++00000150: ff ff ff ff ff fd 50 6f ff ff ff ff ff fd 58 6f ......Po......Xo ++00000160: ff ff ff ff ff fd 60 6f ff ff ff ff ff fd 68 6f .......o......ho ++00000170: ff ff ff ff ff fd 70 6f ff ff ff ff ff fd 78 6f ......po......xo ++00000180: ff ff ff ff ff fd 80 6f ff ff ff ff ff fd 88 6f .......o.......o ++00000190: ff ff ff ff ff fd 90 6f ff ff ff ff ff fd 98 6f .......o.......o ++000001a0: ff ff ff ff ff fd a0 6f ff ff ff ff ff fd a8 6f .......o.......o ++000001b0: ff ff ff ff ff fd b0 6f ff ff ff ff ff fd b8 6f .......o.......o ++000001c0: ff ff ff ff ff fd c0 6f ff ff ff ff ff fd c8 6f .......o.......o ++000001d0: ff ff ff ff ff fd d0 6f ff ff ff ff ff fd d8 6f .......o.......o ++000001e0: ff ff ff ff ff fd e0 6f ff ff ff ff ff fd e8 6f .......o.......o ++000001f0: ff ff ff ff ff fd f0 6f ff ff ff ff ff fd f8 6f .......o.......o" ] ++then ++ echo "$0: unexpected pattern:" ++ cat offset2.out ++ exit 1 ++fi ++ ++# The cleanup() function is called implicitly on exit. +-- +2.17.1 + diff --git a/0007-tests-Test-largest-possible-plugin-size.patch b/0007-tests-Test-largest-possible-plugin-size.patch new file mode 100644 index 0000000..8b7971c --- /dev/null +++ b/0007-tests-Test-largest-possible-plugin-size.patch @@ -0,0 +1,169 @@ +From 4e1a521228115c04cc7c5a2f625218a9bbd5101f Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Sun, 15 Jul 2018 11:46:12 +0100 +Subject: [PATCH 07/10] tests: Test largest possible plugin size. + +This test is incomplete because it is too large for qemu to open. +However at least we are testing that nbdkit works. + +Implemented using the pattern plugin. +--- + plugins/pattern/nbdkit-pattern-plugin.pod | 13 +++ + tests/Makefile.am | 3 +- + tests/test-pattern-largest.sh | 99 +++++++++++++++++++++++ + 3 files changed, 114 insertions(+), 1 deletion(-) + create mode 100755 tests/test-pattern-largest.sh + +diff --git a/plugins/pattern/nbdkit-pattern-plugin.pod b/plugins/pattern/nbdkit-pattern-plugin.pod +index 7a6b498..425cae6 100644 +--- a/plugins/pattern/nbdkit-pattern-plugin.pod ++++ b/plugins/pattern/nbdkit-pattern-plugin.pod +@@ -29,6 +29,19 @@ The size of the virtual disk must be specified using the C + parameter. If the size is not a multiple of 8 then the last 8 byte + offset in the pattern is truncated. + ++=head2 Largest possible size ++ ++nbdkit itself limits plugins to S<2⁶³-1> bytes ++(S, ++S). ++ ++To test if NBD clients are free of bugs (not to mention nbdkit itself) ++you can use: ++ ++ nbdkit pattern size=9223372036854775807 ++ ++Note this is too large for qemu to open. ++ + =head1 PARAMETERS + + =over 4 +diff --git a/tests/Makefile.am b/tests/Makefile.am +index 6c3a5a6..9dd451d 100644 +--- a/tests/Makefile.am ++++ b/tests/Makefile.am +@@ -65,6 +65,7 @@ EXTRA_DIST = \ + test-parallel-file.sh \ + test-parallel-nbd.sh \ + test-pattern.sh \ ++ test-pattern-largest.sh \ + test-python-exception.sh \ + test.pl \ + test.py \ +@@ -318,7 +319,7 @@ test_memory_CFLAGS = $(WARNINGS_CFLAGS) $(LIBGUESTFS_CFLAGS) + test_memory_LDADD = libtest.la $(LIBGUESTFS_LIBS) + + # pattern plugin test. +-TESTS += test-pattern.sh ++TESTS += test-pattern.sh test-pattern-largest.sh + + # nbd plugin test. + LIBGUESTFS_TESTS += test-nbd +diff --git a/tests/test-pattern-largest.sh b/tests/test-pattern-largest.sh +new file mode 100755 +index 0000000..5ff891f +--- /dev/null ++++ b/tests/test-pattern-largest.sh +@@ -0,0 +1,99 @@ ++#!/bin/bash - ++# nbdkit ++# Copyright (C) 2018 Red Hat Inc. ++# All rights reserved. ++# ++# Redistribution and use in source and binary forms, with or without ++# modification, are permitted provided that the following conditions are ++# met: ++# ++# * Redistributions of source code must retain the above copyright ++# notice, this list of conditions and the following disclaimer. ++# ++# * Redistributions in binary form must reproduce the above copyright ++# notice, this list of conditions and the following disclaimer in the ++# documentation and/or other materials provided with the distribution. ++# ++# * Neither the name of Red Hat nor the names of its contributors may be ++# used to endorse or promote products derived from this software without ++# specific prior written permission. ++# ++# THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND ++# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, ++# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A ++# PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR ++# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, ++# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF ++# USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ++# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, ++# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT ++# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ++# SUCH DAMAGE. ++ ++# Test the pattern plugin with the largest possible size supported ++# by nbdkit. ++ ++set -e ++ ++files="pattern-largest.out pattern-largest.pid pattern-largest.sock" ++rm -f $files ++ ++# Test that qemu-io works ++if ! qemu-io --help >/dev/null; then ++ echo "$0: missing or broken qemu-io" ++ exit 77 ++fi ++ ++# Run nbdkit with pattern plugin. ++# size = 2^63-1 ++nbdkit -P pattern-largest.pid -U pattern-largest.sock \ ++ pattern size=9223372036854775807 ++ ++# We may have to wait a short time for the pid file to appear. ++for i in `seq 1 10`; do ++ if test -f pattern-largest.pid; then ++ break ++ fi ++ sleep 1 ++done ++if ! test -f pattern-largest.pid; then ++ echo "$0: PID file was not created" ++ exit 1 ++fi ++ ++pid="$(cat pattern-largest.pid)" ++ ++# Kill the nbdkit process on exit. ++cleanup () ++{ ++ status=$? ++ ++ kill $pid ++ rm -f $files ++ ++ exit $status ++} ++trap cleanup INT QUIT TERM EXIT ERR ++ ++# qemu cannot open this image! ++# ++# can't open device nbd+unix://?socket=pattern-largest.sock: Could not get image size: File too large ++# ++# Therefore we skip the remainder of this test (in effect, testing ++# only that nbdkit can create the file). ++exit 77 ++ ++# XXX Unfortunately qemu-io can only issue 512-byte aligned requests, ++# and the final block is only 511 bytes, so we have to request the 512 ++# bytes before that block. ++qemu-io -r -f raw 'nbd+unix://?socket=pattern-largest.sock' \ ++ -c 'r -v 9223372036854774784 512' | grep -E '^[[:xdigit:]]+:' > pattern-largest.out ++if [ "$(cat pattern-largest.out)" != "XXX EXPECTED PATTERN HERE" ] ++then ++ echo "$0: unexpected pattern:" ++ cat pattern-largest.out ++ exit 1 ++fi ++ ++# The cleanup() function is called implicitly on exit. +-- +2.17.1 + diff --git a/0008-docs-Fix-broken-cross-reference-in-man-page.patch b/0008-docs-Fix-broken-cross-reference-in-man-page.patch new file mode 100644 index 0000000..dd2fdc9 --- /dev/null +++ b/0008-docs-Fix-broken-cross-reference-in-man-page.patch @@ -0,0 +1,25 @@ +From 4c3ea9514184958c356ff6f613d43b896cb26b0e Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Sun, 15 Jul 2018 15:15:44 +0100 +Subject: [PATCH 08/10] docs: Fix broken cross-reference in man page. + +--- + docs/nbdkit-filter.pod.in | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/docs/nbdkit-filter.pod.in b/docs/nbdkit-filter.pod.in +index 4621106..16be2c7 100644 +--- a/docs/nbdkit-filter.pod.in ++++ b/docs/nbdkit-filter.pod.in +@@ -591,7 +591,7 @@ which defines C<$(NBDKIT_FILTERDIR)> in automake-generated Makefiles. + =head1 SEE ALSO + + L, +-L. ++L. + + Standard filters provided by nbdkit: + +-- +2.17.1 + diff --git a/0009-docs-Break-up-some-over-long-lines-in-documentation.patch b/0009-docs-Break-up-some-over-long-lines-in-documentation.patch new file mode 100644 index 0000000..53dacc1 --- /dev/null +++ b/0009-docs-Break-up-some-over-long-lines-in-documentation.patch @@ -0,0 +1,103 @@ +From cf495ffb975d4557a6092a19f382a9a69b457300 Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Sun, 15 Jul 2018 16:26:18 +0100 +Subject: [PATCH 09/10] docs: Break up some over-long lines in documentation. + +We will enforce a limit of 76 chars (in most cases) in a future +commit. +--- + plugins/ext2/nbdkit-ext2-plugin.pod | 3 ++- + plugins/lua/nbdkit-lua-plugin.pod | 3 ++- + plugins/perl/nbdkit-perl-plugin.pod | 3 ++- + plugins/python/nbdkit-python-plugin.pod | 3 ++- + plugins/ruby/nbdkit-ruby-plugin.pod | 3 ++- + plugins/tcl/nbdkit-tcl-plugin.pod | 3 ++- + 6 files changed, 12 insertions(+), 6 deletions(-) + +diff --git a/plugins/ext2/nbdkit-ext2-plugin.pod b/plugins/ext2/nbdkit-ext2-plugin.pod +index 29c76aa..7479ebe 100644 +--- a/plugins/ext2/nbdkit-ext2-plugin.pod ++++ b/plugins/ext2/nbdkit-ext2-plugin.pod +@@ -2,7 +2,8 @@ + + =head1 NAME + +-nbdkit-ext2-plugin - Read and write files inside ext2, ext3 or ext4 filesystems ++nbdkit-ext2-plugin - Read and write files inside ext2, ext3 or ++ext4 filesystems + + =head1 SYNOPSIS + +diff --git a/plugins/lua/nbdkit-lua-plugin.pod b/plugins/lua/nbdkit-lua-plugin.pod +index 385a0e4..dfeef4f 100644 +--- a/plugins/lua/nbdkit-lua-plugin.pod ++++ b/plugins/lua/nbdkit-lua-plugin.pod +@@ -260,7 +260,8 @@ partial, your function should call C. + + =over 4 + +-=item Missing: C, C, C, C, C, C, C, C, C ++=item Missing: C, C, C, C, C, ++C, C, C, C + + These are not yet supported. + +diff --git a/plugins/perl/nbdkit-perl-plugin.pod b/plugins/perl/nbdkit-perl-plugin.pod +index 0fc7f93..ce8bb51 100644 +--- a/plugins/perl/nbdkit-perl-plugin.pod ++++ b/plugins/perl/nbdkit-perl-plugin.pod +@@ -339,7 +339,8 @@ C. + These are not needed because you can just use regular Perl C + and C constructs. + +-=item Missing: C, C, C, C, C ++=item Missing: C, C, C, C, ++C + + These are not yet supported. + +diff --git a/plugins/python/nbdkit-python-plugin.pod b/plugins/python/nbdkit-python-plugin.pod +index e54df1f..c80af9b 100644 +--- a/plugins/python/nbdkit-python-plugin.pod ++++ b/plugins/python/nbdkit-python-plugin.pod +@@ -258,7 +258,8 @@ use C. + These are not needed because you can just use ordinary Python + constructs. + +-=item Missing: C, C, C, C, C ++=item Missing: C, C, C, C, ++C + + These are not yet supported. + +diff --git a/plugins/ruby/nbdkit-ruby-plugin.pod b/plugins/ruby/nbdkit-ruby-plugin.pod +index 505af69..29d072a 100644 +--- a/plugins/ruby/nbdkit-ruby-plugin.pod ++++ b/plugins/ruby/nbdkit-ruby-plugin.pod +@@ -273,7 +273,8 @@ use C. + These are not needed because you can just use ordinary Ruby + constructs. + +-=item Missing: C, C, C, C, C ++=item Missing: C, C, C, C, ++C + + These are not yet supported. + +diff --git a/plugins/tcl/nbdkit-tcl-plugin.pod b/plugins/tcl/nbdkit-tcl-plugin.pod +index 434233d..17b5c5f 100644 +--- a/plugins/tcl/nbdkit-tcl-plugin.pod ++++ b/plugins/tcl/nbdkit-tcl-plugin.pod +@@ -266,7 +266,8 @@ partial, your function should call C. + + =over 4 + +-=item Missing: C, C, C, C, C, C, C, C, C ++=item Missing: C, C, C, C, C, ++C, C, C, C + + These are not yet supported. + +-- +2.17.1 + diff --git a/0010-docs-Add-podwrapper-from-libguestfs.patch b/0010-docs-Add-podwrapper-from-libguestfs.patch new file mode 100644 index 0000000..fc6e859 --- /dev/null +++ b/0010-docs-Add-podwrapper-from-libguestfs.patch @@ -0,0 +1,3976 @@ +From 24a0a8ced608395b614ad42ae550588e08d3c636 Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Sun, 15 Jul 2018 14:13:53 +0100 +Subject: [PATCH 10/10] docs: Add podwrapper from libguestfs. + +Use podwrapper from libguestfs to generate man pages instead of +pod2man. This allows finer control over how man pages are generated, +lets us add standard sections, lets us perform more checks on the POD, +and lets us generate HTML. + +Note I have relicensed my code under a BSD license for nbdkit. +--- + .gitignore | 7 +- + Makefile.am | 1 + + README | 6 +- + configure.ac | 31 +- + docs/Makefile.am | 54 +- + ...nbdkit-filter.pod.in => nbdkit-filter.pod} | 42 -- + ...nbdkit-plugin.pod.in => nbdkit-plugin.pod} | 42 -- + docs/{nbdkit.pod.in => nbdkit.pod} | 42 -- + filters/blocksize/Makefile.am | 10 +- + filters/blocksize/nbdkit-blocksize-filter.pod | 42 -- + filters/cache/Makefile.am | 10 +- + filters/cache/nbdkit-cache-filter.pod | 42 -- + filters/cow/Makefile.am | 10 +- + filters/cow/nbdkit-cow-filter.pod | 42 -- + filters/delay/Makefile.am | 10 +- + filters/delay/nbdkit-delay-filter.pod | 42 -- + filters/fua/Makefile.am | 10 +- + filters/fua/nbdkit-fua-filter.pod | 42 -- + filters/log/Makefile.am | 10 +- + filters/log/nbdkit-log-filter.pod | 42 -- + filters/nozero/Makefile.am | 10 +- + filters/nozero/nbdkit-nozero-filter.pod | 42 -- + filters/offset/Makefile.am | 10 +- + filters/offset/nbdkit-offset-filter.pod | 42 -- + filters/partition/Makefile.am | 10 +- + filters/partition/nbdkit-partition-filter.pod | 42 -- + html/pod.css | 155 ++++++ + plugins/curl/Makefile.am | 10 +- + plugins/curl/nbdkit-curl-plugin.pod | 42 -- + plugins/example1/Makefile.am | 10 +- + plugins/example1/nbdkit-example1-plugin.pod | 42 -- + plugins/example2/Makefile.am | 10 +- + plugins/example2/nbdkit-example2-plugin.pod | 42 -- + plugins/example3/Makefile.am | 10 +- + plugins/example3/nbdkit-example3-plugin.pod | 42 -- + plugins/example4/Makefile.am | 10 +- + plugins/example4/example4.pl | 42 -- + plugins/ext2/Makefile.am | 10 +- + plugins/ext2/nbdkit-ext2-plugin.pod | 42 -- + plugins/file/Makefile.am | 10 +- + plugins/file/nbdkit-file-plugin.pod | 42 -- + plugins/guestfs/Makefile.am | 10 +- + plugins/guestfs/nbdkit-guestfs-plugin.pod | 42 -- + plugins/gzip/Makefile.am | 10 +- + plugins/gzip/nbdkit-gzip-plugin.pod | 42 -- + plugins/libvirt/Makefile.am | 10 +- + plugins/libvirt/nbdkit-libvirt-plugin.pod | 42 -- + plugins/lua/Makefile.am | 10 +- + plugins/lua/nbdkit-lua-plugin.pod | 42 -- + plugins/memory/Makefile.am | 10 +- + plugins/memory/nbdkit-memory-plugin.pod | 42 -- + plugins/nbd/Makefile.am | 10 +- + plugins/nbd/nbdkit-nbd-plugin.pod | 42 -- + plugins/null/Makefile.am | 10 +- + plugins/null/nbdkit-null-plugin.pod | 42 -- + plugins/ocaml/Makefile.am | 10 +- + plugins/ocaml/nbdkit-ocaml-plugin.pod | 42 -- + plugins/pattern/Makefile.am | 10 +- + plugins/pattern/nbdkit-pattern-plugin.pod | 42 -- + plugins/perl/Makefile.am | 10 +- + plugins/perl/nbdkit-perl-plugin.pod | 42 -- + plugins/python/Makefile.am | 10 +- + plugins/python/nbdkit-python-plugin.pod | 42 -- + plugins/random/Makefile.am | 10 +- + plugins/random/nbdkit-random-plugin.pod | 42 -- + plugins/ruby/Makefile.am | 10 +- + plugins/ruby/nbdkit-ruby-plugin.pod | 42 -- + plugins/split/Makefile.am | 10 +- + plugins/split/nbdkit-split-plugin.pod | 42 -- + plugins/streaming/Makefile.am | 10 +- + plugins/streaming/nbdkit-streaming-plugin.pod | 42 -- + plugins/tar/Makefile.am | 10 +- + plugins/tar/tar.pl | 42 -- + plugins/tcl/Makefile.am | 10 +- + plugins/tcl/nbdkit-tcl-plugin.pod | 42 -- + plugins/vddk/Makefile.am | 10 +- + plugins/vddk/nbdkit-vddk-plugin.pod | 42 -- + plugins/xz/Makefile.am | 10 +- + plugins/xz/nbdkit-xz-plugin.pod | 42 -- + plugins/zero/Makefile.am | 10 +- + plugins/zero/nbdkit-zero-plugin.pod | 42 -- + podwrapper.pl.in | 496 ++++++++++++++++++ + 82 files changed, 889 insertions(+), 1859 deletions(-) + rename docs/{nbdkit-filter.pod.in => nbdkit-filter.pod} (93%) + rename docs/{nbdkit-plugin.pod.in => nbdkit-plugin.pod} (95%) + rename docs/{nbdkit.pod.in => nbdkit.pod} (95%) + create mode 100644 html/pod.css + create mode 100755 podwrapper.pl.in + +diff --git a/.gitignore b/.gitignore +index 2692542..a84ad9a 100644 +--- a/.gitignore ++++ b/.gitignore +@@ -32,9 +32,9 @@ Makefile.in + /config.sub + /configure + /depcomp +-/docs/nbdkit-filter.pod +-/docs/nbdkit-plugin.pod +-/docs/nbdkit.pod ++/docs/filter-links.pod ++/docs/plugin-links.pod ++/html/*.html + /INSTALL + /install-sh + /libtool +@@ -43,6 +43,7 @@ Makefile.in + /nbdkit + /plugins/example4/nbdkit-example4-plugin + /plugins/tar/nbdkit-tar-plugin ++/podwrapper.pl + /src/nbdkit + /src/nbdkit.pc + /src/test-utils +diff --git a/Makefile.am b/Makefile.am +index fc4d750..6a3a377 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -37,6 +37,7 @@ ACLOCAL_AMFLAGS = -I m4 + EXTRA_DIST = \ + .dir-locals.el \ + .gitignore \ ++ html/pod.css \ + LICENSE \ + nbdkit.in \ + OTHER_PLUGINS \ +diff --git a/README b/README +index 9642579..685b41f 100644 +--- a/README ++++ b/README +@@ -32,9 +32,11 @@ Building from source + + By default nbdkit needs nothing except Linux and reasonably recent gcc. + +-To build the man pages, you will need to install: ++To build the man pages, you will optionally need to install: + +- - pod2man (included with perl) ++ - perl ++ ++ - Pod::Man and Pod::Simple (perl library) + + There are some *optional* libraries you may want to install for + plugins or extra features. +diff --git a/configure.ac b/configure.ac +index 6304ac8..9fe147c 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -197,28 +197,31 @@ PKG_CHECK_MODULES([BASH_COMPLETION], [bash-completion >= 2.0], [ + ]) + AM_CONDITIONAL([HAVE_BASH_COMPLETION],[test "x$bash_completion" = "xyes"]) + +-dnl Check for Perl POD. +-AC_CHECK_PROG([POD2MAN], [pod2man], [pod2man], [no]) +-AS_IF([test "x$POD2MAN" != "xno"],[ +- POD2MAN_ARGS="--center=nbdkit --release=nbdkit" +- # Check whether pod2man supports --utf8, and if so add it to $POD2MAN_ARGS. +- AC_MSG_CHECKING([if $POD2MAN supports --utf8]) +- AS_IF([$POD2MAN --help 2>&1 | grep -s -q -- --utf8],[ +- AC_MSG_RESULT([yes]) +- POD2MAN_ARGS="$POD2MAN_ARGS --utf8" ++dnl Check we have enough to run podwrapper. ++AC_CHECK_PROG([PERL],[perl],[perl],[no]) ++AS_IF([test "x$PERL" != "xno"],[ ++ AC_MSG_CHECKING([if we have perl Pod::Man and Pod::Simple]) ++ AS_IF([$PERL -MPod::Man -MPod::Simple -e 1 >&AS_MESSAGE_LOG_FD 2>&1],[ ++ enable_pod=yes + ],[ +- AC_MSG_RESULT([no]) ++ enable_pod=no + ]) +- AC_SUBST([POD2MAN_ARGS]) ++ AC_MSG_RESULT([$enable_pod]) + ]) +-AM_CONDITIONAL([HAVE_POD2MAN], [test "x$POD2MAN" != "xno"]) ++AM_CONDITIONAL([HAVE_POD], ++ [test "x$PERL" != "xno" && test "x$enable_pod" = "xyes"]) + ++dnl Define the path to the podwrapper program. ++PODWRAPPER="$PERL $(pwd)/podwrapper.pl" ++AC_SUBST([PODWRAPPER]) ++ ++dnl Allow all plugins and filters to be disabled. + AC_ARG_ENABLE([plugins], + [AS_HELP_STRING([--disable-plugins], [disable all bundled plugins and filters])]) + AM_CONDITIONAL([HAVE_PLUGINS], [test "x$enable_plugins" != "xno"]) + + dnl Check for Perl, for embedding in the perl plugin. +-AC_CHECK_PROG([PERL],[perl],[perl],[no]) ++dnl Note that the perl binary is checked above. + AC_ARG_ENABLE([perl], + AS_HELP_STRING([--disable-perl], [disable Perl embed plugin]), + [], +@@ -590,6 +593,8 @@ dnl Produce output files. + AC_CONFIG_HEADERS([config.h]) + AC_CONFIG_FILES([nbdkit], + [chmod +x,-w nbdkit]) ++AC_CONFIG_FILES([podwrapper.pl], ++ [chmod +x,-w podwrapper.pl]) + AC_CONFIG_FILES([Makefile + bash/Makefile + docs/Makefile +diff --git a/docs/Makefile.am b/docs/Makefile.am +index a3d7071..2c1243a 100644 +--- a/docs/Makefile.am ++++ b/docs/Makefile.am +@@ -34,11 +34,11 @@ include $(top_srcdir)/common-rules.mk + + EXTRA_DIST = \ + make-links.sh \ +- nbdkit.pod.in \ +- nbdkit-plugin.pod.in \ +- nbdkit-filter.pod.in ++ nbdkit.pod \ ++ nbdkit-plugin.pod \ ++ nbdkit-filter.pod + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = \ + nbdkit.1 \ +@@ -46,28 +46,36 @@ man_MANS = \ + nbdkit-filter.3 + CLEANFILES += $(man_MANS) + +-nbdkit.1: nbdkit.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=nbdkit $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++nbdkit.1: nbdkit.pod plugin-links.pod filter-links.pod ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ --insert plugin-links.pod:__PLUGIN_LINKS__ \ ++ --insert filter-links.pod:__FILTER_LINKS__ \ ++ $< + +-nbdkit-plugin.3: nbdkit-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=3 --name=nbdkit-plugin $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++nbdkit-plugin.3: nbdkit-plugin.pod plugin-links.pod ++ $(PODWRAPPER) --section=3 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ --insert plugin-links.pod:__PLUGIN_LINKS__ \ ++ $< + +-nbdkit-filter.3: nbdkit-filter.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=3 --name=nbdkit-filter $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++nbdkit-filter.3: nbdkit-filter.pod filter-links.pod ++ $(PODWRAPPER) --section=3 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ --insert filter-links.pod:__FILTER_LINKS__ \ ++ $< + +-%.pod: %.pod.in ++endif HAVE_POD ++ ++# XXX Language links are broken - they link to section 1 instead of section 3. ++plugin-links.pod: $(top_srcdir)/common-rules.mk ++ rm -f $@ $@-t ++ $(srcdir)/make-links.sh plugin 1 $(plugins) > $@-t ++ mv $@-t $@ ++ ++filter-links.pod: $(top_srcdir)/common-rules.mk + rm -f $@ $@-t +- $(SED) \ +- -e 's/__PLUGIN_LINKS__/$(shell $(srcdir)/make-links.sh plugin 1 $(plugins))/' \ +- -e 's/__FILTER_LINKS__/$(shell $(srcdir)/make-links.sh filter 1 $(filters))/' \ +- $< > $@-t +- chmod -w $@-t ++ $(srcdir)/make-links.sh filter 1 $(filters) > $@-t + mv $@-t $@ + +-endif ++MAINTAINERCLEANFILES = plugin-links.pod filter-links.pod +diff --git a/docs/nbdkit-filter.pod.in b/docs/nbdkit-filter.pod +similarity index 93% +rename from docs/nbdkit-filter.pod.in +rename to docs/nbdkit-filter.pod +index 16be2c7..77a5e79 100644 +--- a/docs/nbdkit-filter.pod.in ++++ b/docs/nbdkit-filter.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-filter - How to write nbdkit filters +@@ -604,43 +602,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013-2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/docs/nbdkit-plugin.pod.in b/docs/nbdkit-plugin.pod +similarity index 95% +rename from docs/nbdkit-plugin.pod.in +rename to docs/nbdkit-plugin.pod +index f32d1af..fb43f8c 100644 +--- a/docs/nbdkit-plugin.pod.in ++++ b/docs/nbdkit-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-plugin - How to write nbdkit plugins +@@ -897,43 +895,3 @@ Pino Toscano + =head1 COPYRIGHT + + Copyright (C) 2013-2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/docs/nbdkit.pod.in b/docs/nbdkit.pod +similarity index 95% +rename from docs/nbdkit.pod.in +rename to docs/nbdkit.pod +index bfd9da9..be69619 100644 +--- a/docs/nbdkit.pod.in ++++ b/docs/nbdkit.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit - A toolkit for creating NBD servers +@@ -1023,43 +1021,3 @@ Pino Toscano + =head1 COPYRIGHT + + Copyright (C) 2013-2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/filters/blocksize/Makefile.am b/filters/blocksize/Makefile.am +index bd09a2d..02db7bb 100644 +--- a/filters/blocksize/Makefile.am ++++ b/filters/blocksize/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_blocksize_filter_la_CFLAGS = \ + nbdkit_blocksize_filter_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-blocksize-filter.1 + CLEANFILES += $(man_MANS) + + nbdkit-blocksize-filter.1: nbdkit-blocksize-filter.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/filters/blocksize/nbdkit-blocksize-filter.pod b/filters/blocksize/nbdkit-blocksize-filter.pod +index 39a2ffc..d271aba 100644 +--- a/filters/blocksize/nbdkit-blocksize-filter.pod ++++ b/filters/blocksize/nbdkit-blocksize-filter.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-blocksize-filter - nbdkit blocksize filter +@@ -99,43 +97,3 @@ Eric Blake + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/filters/cache/Makefile.am b/filters/cache/Makefile.am +index 1e932e8..867812e 100644 +--- a/filters/cache/Makefile.am ++++ b/filters/cache/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_cache_filter_la_CFLAGS = \ + nbdkit_cache_filter_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-cache-filter.1 + CLEANFILES += $(man_MANS) + + nbdkit-cache-filter.1: nbdkit-cache-filter.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/filters/cache/nbdkit-cache-filter.pod b/filters/cache/nbdkit-cache-filter.pod +index a59c54e..ed9df19 100644 +--- a/filters/cache/nbdkit-cache-filter.pod ++++ b/filters/cache/nbdkit-cache-filter.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-cache-filter - nbdkit caching filter +@@ -80,43 +78,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/filters/cow/Makefile.am b/filters/cow/Makefile.am +index 3b83142..778df1e 100644 +--- a/filters/cow/Makefile.am ++++ b/filters/cow/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_cow_filter_la_CFLAGS = \ + nbdkit_cow_filter_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-cow-filter.1 + CLEANFILES += $(man_MANS) + + nbdkit-cow-filter.1: nbdkit-cow-filter.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/filters/cow/nbdkit-cow-filter.pod b/filters/cow/nbdkit-cow-filter.pod +index accf81c..a4b8d72 100644 +--- a/filters/cow/nbdkit-cow-filter.pod ++++ b/filters/cow/nbdkit-cow-filter.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-cow-filter - nbdkit copy-on-write (COW) filter +@@ -120,43 +118,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/filters/delay/Makefile.am b/filters/delay/Makefile.am +index a907ea6..17bec3b 100644 +--- a/filters/delay/Makefile.am ++++ b/filters/delay/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_delay_filter_la_CFLAGS = \ + nbdkit_delay_filter_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-delay-filter.1 + CLEANFILES += $(man_MANS) + + nbdkit-delay-filter.1: nbdkit-delay-filter.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/filters/delay/nbdkit-delay-filter.pod b/filters/delay/nbdkit-delay-filter.pod +index 10aba94..32e29d7 100644 +--- a/filters/delay/nbdkit-delay-filter.pod ++++ b/filters/delay/nbdkit-delay-filter.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-delay-filter - nbdkit delay filter +@@ -46,43 +44,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/filters/fua/Makefile.am b/filters/fua/Makefile.am +index 557e585..d4af39a 100644 +--- a/filters/fua/Makefile.am ++++ b/filters/fua/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_fua_filter_la_CFLAGS = \ + nbdkit_fua_filter_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-fua-filter.1 + CLEANFILES += $(man_MANS) + + nbdkit-fua-filter.1: nbdkit-fua-filter.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/filters/fua/nbdkit-fua-filter.pod b/filters/fua/nbdkit-fua-filter.pod +index cec54d5..601e308 100644 +--- a/filters/fua/nbdkit-fua-filter.pod ++++ b/filters/fua/nbdkit-fua-filter.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-fua-filter - nbdkit FUA filter +@@ -77,43 +75,3 @@ Eric Blake + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/filters/log/Makefile.am b/filters/log/Makefile.am +index 95bce2b..b9b661e 100644 +--- a/filters/log/Makefile.am ++++ b/filters/log/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_log_filter_la_CFLAGS = \ + nbdkit_log_filter_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-log-filter.1 + CLEANFILES += $(man_MANS) + + nbdkit-log-filter.1: nbdkit-log-filter.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/filters/log/nbdkit-log-filter.pod b/filters/log/nbdkit-log-filter.pod +index b011624..89ea551 100644 +--- a/filters/log/nbdkit-log-filter.pod ++++ b/filters/log/nbdkit-log-filter.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-log-filter - nbdkit log filter +@@ -75,43 +73,3 @@ Eric Blake + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/filters/nozero/Makefile.am b/filters/nozero/Makefile.am +index 3e2eebc..f0cc2c6 100644 +--- a/filters/nozero/Makefile.am ++++ b/filters/nozero/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_nozero_filter_la_CFLAGS = \ + nbdkit_nozero_filter_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-nozero-filter.1 + CLEANFILES += $(man_MANS) + + nbdkit-nozero-filter.1: nbdkit-nozero-filter.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/filters/nozero/nbdkit-nozero-filter.pod b/filters/nozero/nbdkit-nozero-filter.pod +index 4065302..bb8743c 100644 +--- a/filters/nozero/nbdkit-nozero-filter.pod ++++ b/filters/nozero/nbdkit-nozero-filter.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-nozero-filter - nbdkit nozero filter +@@ -57,43 +55,3 @@ Eric Blake + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/filters/offset/Makefile.am b/filters/offset/Makefile.am +index e055ed4..0fe9106 100644 +--- a/filters/offset/Makefile.am ++++ b/filters/offset/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_offset_filter_la_CFLAGS = \ + nbdkit_offset_filter_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-offset-filter.1 + CLEANFILES += $(man_MANS) + + nbdkit-offset-filter.1: nbdkit-offset-filter.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/filters/offset/nbdkit-offset-filter.pod b/filters/offset/nbdkit-offset-filter.pod +index 7579d9f..ee8061b 100644 +--- a/filters/offset/nbdkit-offset-filter.pod ++++ b/filters/offset/nbdkit-offset-filter.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-offset-filter - nbdkit offset filter +@@ -76,43 +74,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/filters/partition/Makefile.am b/filters/partition/Makefile.am +index a1bb0d9..9ab8730 100644 +--- a/filters/partition/Makefile.am ++++ b/filters/partition/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_partition_filter_la_CFLAGS = \ + nbdkit_partition_filter_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-partition-filter.1 + CLEANFILES += $(man_MANS) + + nbdkit-partition-filter.1: nbdkit-partition-filter.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/filters/partition/nbdkit-partition-filter.pod b/filters/partition/nbdkit-partition-filter.pod +index 0b78d6b..bc5f346 100644 +--- a/filters/partition/nbdkit-partition-filter.pod ++++ b/filters/partition/nbdkit-partition-filter.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-partition-filter - nbdkit partition filter +@@ -57,43 +55,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/html/pod.css b/html/pod.css +new file mode 100644 +index 0000000..1c07ec8 +--- /dev/null ++++ b/html/pod.css +@@ -0,0 +1,155 @@ ++/* CSS to make pod2html files look a little bit better. */ ++ ++body { ++ margin-left: 4em; ++} ++ ++body p, body ul, ol, body dl { ++ margin-left: 2em; ++ width: 31em; ++} ++ ++pre { ++ width: 31em; ++} ++ ++li { ++ padding-bottom: 0.5em; ++} ++ ++/* Code sections. */ ++ ++pre { ++ background-color: #f8f8f8; ++ color: rgb(204,0,0); ++ font-weight: 550; ++ border-left: 6px solid rgb(204,64,64); ++ padding: 6px; ++ margin-left: 1em; ++ font-size: 120%; ++} ++ ++/* Bold, italic in man pages. */ ++b, strong { ++ color: rgb(204,0,0); ++} ++ ++i, em { ++ color: rgb(204,0,0); ++} ++ ++/* Name heading. */ ++ ++body > h1:first-of-type { ++ display: none; ++} ++ ++body > h1:first-of-type + p { ++ font-size: 125%; ++ font-weight: bold; ++ color: rgb(204,0,0); ++ margin-left: -32px; ++} ++ ++/* Warning heading in man pages. */ ++a[name="warning"] { ++ -moz-border-radius-topleft: 5px; ++ -moz-border-radius-topright: 5px; ++ border-radius-topleft: 5px; ++ border-radius-topright: 5px; ++ ++ color: white; ++ background-color: rgb(204,0,0); ++} ++a[name="warning"]:before { ++ content: "\00a0\00a0\00a0"; ++} ++a[name="warning"]:after { ++ content: "\00a0\00a0\00a0"; ++} ++ ++/* Put the index on the right hand side in a floating box. */ ++ul[id="index"] { ++ float: right; ++ width: 18em; ++ border-left: 3em solid white; ++ background-color: #fcfcfc; ++ margin-top: 32px; ++ padding-top: 0px; ++ margin-left: 1em; ++ padding-left: 1em; ++ padding-right: 1em; ++ font-size: 90%; ++} ++ ++ul[id="index"] a[href] { ++ text-decoration: none; ++} ++ ++ul[id="index"] a[href]:hover { ++ text-decoration: underline; ++} ++ ++ul[id="index"] a[href]:before { ++ content: '#\00a0'; ++ color: rgb(204,0,0); ++ font-size: x-small; ++} ++ ++ul[id="index"] { ++ width: 17em; ++ list-style: none; ++ margin-left: 0px; ++ margin-right: 0px; ++ padding-left: 0px; ++ padding-right: 0px; ++} ++ ++ul[id="index"] > li { ++ margin-bottom: 0.5em; ++} ++ ++ul[id="index"] > li ul { ++ width: 16em; ++ list-style: none; ++ margin-left: 0px; ++ margin-right: 0px; ++ padding-left: 0px; ++ padding-right: 0px; ++ margin-bottom: 0.5em; ++} ++ ++ul[id="index"] > li ul li { ++ display: inline; ++ margin-right: 1em; ++} ++ ++/* ++ul[id="index"] > li ul li:after { ++ color: #ccc; ++ content: '\2014'; ++} ++*/ ++ ++/* Get rid of those horrible
's :-( */ ++hr { display: none; } ++ ++/* Demote

's and set rest of headers relative. */ ++h1 { ++ font-size: 100%; ++ color: black; ++ border-bottom: solid 1px rgb(204,0,0); ++} ++ ++h2 { ++ font-size: 95%; ++ border-bottom: none; ++} ++ ++h3 { ++ font-size: 90%; ++} ++ ++h4 { ++ font-size: 85%; ++} +diff --git a/plugins/curl/Makefile.am b/plugins/curl/Makefile.am +index 91a3a3a..b58b40c 100644 +--- a/plugins/curl/Makefile.am ++++ b/plugins/curl/Makefile.am +@@ -52,16 +52,16 @@ nbdkit_curl_plugin_la_LIBADD = \ + nbdkit_curl_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-curl-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-curl-plugin.1: nbdkit-curl-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/curl/nbdkit-curl-plugin.pod b/plugins/curl/nbdkit-curl-plugin.pod +index 30e2949..9bbd285 100644 +--- a/plugins/curl/nbdkit-curl-plugin.pod ++++ b/plugins/curl/nbdkit-curl-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-curl-plugin - nbdkit curl plugin (HTTP, FTP, SSH and other protocols) +@@ -122,43 +120,3 @@ Parts derived from Alexander Graf's "QEMU Block driver for CURL images". + =head1 COPYRIGHT + + Copyright (C) 2014 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/example1/Makefile.am b/plugins/example1/Makefile.am +index 8c66bbb..e324dd8 100644 +--- a/plugins/example1/Makefile.am ++++ b/plugins/example1/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_example1_plugin_la_CFLAGS = \ + nbdkit_example1_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-example1-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-example1-plugin.1: nbdkit-example1-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/plugins/example1/nbdkit-example1-plugin.pod b/plugins/example1/nbdkit-example1-plugin.pod +index a28e5f2..81a80de 100644 +--- a/plugins/example1/nbdkit-example1-plugin.pod ++++ b/plugins/example1/nbdkit-example1-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-example1-plugin - A minimal nbdkit plugin +@@ -32,43 +30,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/example2/Makefile.am b/plugins/example2/Makefile.am +index 810d735..3125b8e 100644 +--- a/plugins/example2/Makefile.am ++++ b/plugins/example2/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_example2_plugin_la_CFLAGS = \ + nbdkit_example2_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-example2-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-example2-plugin.1: nbdkit-example2-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/plugins/example2/nbdkit-example2-plugin.pod b/plugins/example2/nbdkit-example2-plugin.pod +index 1a22bc6..dc16260 100644 +--- a/plugins/example2/nbdkit-example2-plugin.pod ++++ b/plugins/example2/nbdkit-example2-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-example2-plugin - An example nbdkit plugin +@@ -30,43 +28,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/example3/Makefile.am b/plugins/example3/Makefile.am +index 5ca25ad..f4a423d 100644 +--- a/plugins/example3/Makefile.am ++++ b/plugins/example3/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_example3_plugin_la_CFLAGS = \ + nbdkit_example3_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-example3-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-example3-plugin.1: nbdkit-example3-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/plugins/example3/nbdkit-example3-plugin.pod b/plugins/example3/nbdkit-example3-plugin.pod +index 11dfc99..5c51f83 100644 +--- a/plugins/example3/nbdkit-example3-plugin.pod ++++ b/plugins/example3/nbdkit-example3-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-example3-plugin - An example nbdkit plugin +@@ -40,43 +38,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/example4/Makefile.am b/plugins/example4/Makefile.am +index cf9f687..589b3f5 100644 +--- a/plugins/example4/Makefile.am ++++ b/plugins/example4/Makefile.am +@@ -48,16 +48,16 @@ nbdkit-example4-plugin: $(source) + mv $@-t $@ + chmod 0555 $@ + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-example4-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-example4-plugin.1: $(source) +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --name nbdkit-example4-plugin --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/example4/example4.pl b/plugins/example4/example4.pl +index b0086ac..0f0baa8 100644 +--- a/plugins/example4/example4.pl ++++ b/plugins/example4/example4.pl +@@ -3,8 +3,6 @@ + + =pod + +-=encoding utf8 +- + =head1 NAME + + nbdkit-example4-plugin - An example nbdkit plugin written in Perl +@@ -48,46 +46,6 @@ Richard W.M. Jones + + Copyright (C) 2017 Red Hat Inc. + +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +- + =cut + + use strict; +diff --git a/plugins/ext2/Makefile.am b/plugins/ext2/Makefile.am +index b644451..da92c1b 100644 +--- a/plugins/ext2/Makefile.am ++++ b/plugins/ext2/Makefile.am +@@ -52,15 +52,15 @@ nbdkit_ext2_plugin_la_LIBADD = \ + nbdkit_ext2_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-ext2-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-ext2-plugin.1: nbdkit-ext2-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + endif +diff --git a/plugins/ext2/nbdkit-ext2-plugin.pod b/plugins/ext2/nbdkit-ext2-plugin.pod +index 7479ebe..5cdda06 100644 +--- a/plugins/ext2/nbdkit-ext2-plugin.pod ++++ b/plugins/ext2/nbdkit-ext2-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-ext2-plugin - Read and write files inside ext2, ext3 or +@@ -89,43 +87,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/file/Makefile.am b/plugins/file/Makefile.am +index 7500438..00eaf59 100644 +--- a/plugins/file/Makefile.am ++++ b/plugins/file/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_file_plugin_la_CFLAGS = \ + nbdkit_file_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-file-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-file-plugin.1: nbdkit-file-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/plugins/file/nbdkit-file-plugin.pod b/plugins/file/nbdkit-file-plugin.pod +index 016513a..824058e 100644 +--- a/plugins/file/nbdkit-file-plugin.pod ++++ b/plugins/file/nbdkit-file-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-file-plugin - nbdkit file plugin +@@ -54,43 +52,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/guestfs/Makefile.am b/plugins/guestfs/Makefile.am +index 79b97c5..19fe31a 100644 +--- a/plugins/guestfs/Makefile.am ++++ b/plugins/guestfs/Makefile.am +@@ -52,16 +52,16 @@ nbdkit_guestfs_plugin_la_LIBADD = \ + nbdkit_guestfs_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-guestfs-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-guestfs-plugin.1: nbdkit-guestfs-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/guestfs/nbdkit-guestfs-plugin.pod b/plugins/guestfs/nbdkit-guestfs-plugin.pod +index 9fde4b4..4bdb7ab 100644 +--- a/plugins/guestfs/nbdkit-guestfs-plugin.pod ++++ b/plugins/guestfs/nbdkit-guestfs-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-guestfs-plugin - nbdkit libguestfs plugin +@@ -201,43 +199,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/gzip/Makefile.am b/plugins/gzip/Makefile.am +index 6e95a66..b1e42c7 100644 +--- a/plugins/gzip/Makefile.am ++++ b/plugins/gzip/Makefile.am +@@ -52,16 +52,16 @@ nbdkit_gzip_plugin_la_LIBADD = \ + nbdkit_gzip_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-gzip-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-gzip-plugin.1: nbdkit-gzip-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/gzip/nbdkit-gzip-plugin.pod b/plugins/gzip/nbdkit-gzip-plugin.pod +index 7959329..a5f6b79 100644 +--- a/plugins/gzip/nbdkit-gzip-plugin.pod ++++ b/plugins/gzip/nbdkit-gzip-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-gzip-plugin - nbdkit gzip plugin +@@ -33,43 +31,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/libvirt/Makefile.am b/plugins/libvirt/Makefile.am +index 1f53cbc..f7ab44a 100644 +--- a/plugins/libvirt/Makefile.am ++++ b/plugins/libvirt/Makefile.am +@@ -52,16 +52,16 @@ nbdkit_libvirt_plugin_la_LIBADD = \ + nbdkit_libvirt_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-libvirt-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-libvirt-plugin.1: nbdkit-libvirt-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/libvirt/nbdkit-libvirt-plugin.pod b/plugins/libvirt/nbdkit-libvirt-plugin.pod +index 2ee18cc..4bfa972 100644 +--- a/plugins/libvirt/nbdkit-libvirt-plugin.pod ++++ b/plugins/libvirt/nbdkit-libvirt-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-libvirt-plugin - nbdkit libvirt plugin using virDomainBlockPeek +@@ -62,43 +60,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013-2017 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/lua/Makefile.am b/plugins/lua/Makefile.am +index 91d0395..9135b88 100644 +--- a/plugins/lua/Makefile.am ++++ b/plugins/lua/Makefile.am +@@ -53,16 +53,16 @@ nbdkit_lua_plugin_la_LDFLAGS = \ + -module -avoid-version -shared \ + $(LUA_LIBS) + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-lua-plugin.3 + CLEANFILES += $(man_MANS) + + nbdkit-lua-plugin.3: nbdkit-lua-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=3 --name=`basename $@ .3` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=3 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/lua/nbdkit-lua-plugin.pod b/plugins/lua/nbdkit-lua-plugin.pod +index dfeef4f..9ebebab 100644 +--- a/plugins/lua/nbdkit-lua-plugin.pod ++++ b/plugins/lua/nbdkit-lua-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-lua-plugin - nbdkit Lua plugin +@@ -286,43 +284,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/memory/Makefile.am b/plugins/memory/Makefile.am +index 8bd3949..3eaedca 100644 +--- a/plugins/memory/Makefile.am ++++ b/plugins/memory/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_memory_plugin_la_CFLAGS = \ + nbdkit_memory_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-memory-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-memory-plugin.1: nbdkit-memory-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/plugins/memory/nbdkit-memory-plugin.pod b/plugins/memory/nbdkit-memory-plugin.pod +index 6f7fc46..5d11d86 100644 +--- a/plugins/memory/nbdkit-memory-plugin.pod ++++ b/plugins/memory/nbdkit-memory-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-memory-plugin - nbdkit virtual memory plugin +@@ -50,43 +48,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2017 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/nbd/Makefile.am b/plugins/nbd/Makefile.am +index b4a0d94..f930b26 100644 +--- a/plugins/nbd/Makefile.am ++++ b/plugins/nbd/Makefile.am +@@ -48,14 +48,14 @@ nbdkit_nbd_plugin_la_CFLAGS = \ + nbdkit_nbd_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-nbd-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-nbd-plugin.1: nbdkit-nbd-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/plugins/nbd/nbdkit-nbd-plugin.pod b/plugins/nbd/nbdkit-nbd-plugin.pod +index 2b3a054..74df7ed 100644 +--- a/plugins/nbd/nbdkit-nbd-plugin.pod ++++ b/plugins/nbd/nbdkit-nbd-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-nbd-plugin - nbdkit nbd plugin +@@ -54,43 +52,3 @@ Eric Blake + =head1 COPYRIGHT + + Copyright (C) 2017 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/null/Makefile.am b/plugins/null/Makefile.am +index f37e1ba..b98b041 100644 +--- a/plugins/null/Makefile.am ++++ b/plugins/null/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_null_plugin_la_CFLAGS = \ + nbdkit_null_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-null-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-null-plugin.1: nbdkit-null-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/plugins/null/nbdkit-null-plugin.pod b/plugins/null/nbdkit-null-plugin.pod +index 55affb8..fd6f4d6 100644 +--- a/plugins/null/nbdkit-null-plugin.pod ++++ b/plugins/null/nbdkit-null-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-null-plugin - nbdkit bitbucket plugin +@@ -44,43 +42,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2017 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/ocaml/Makefile.am b/plugins/ocaml/Makefile.am +index 22970f9..484d041 100644 +--- a/plugins/ocaml/Makefile.am ++++ b/plugins/ocaml/Makefile.am +@@ -67,16 +67,16 @@ libnbdkitocaml_la_CFLAGS = \ + $(WARNINGS_CFLAGS) \ + -fPIC + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-ocaml-plugin.3 + CLEANFILES += $(man_MANS) + + nbdkit-ocaml-plugin.3: nbdkit-ocaml-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=3 --name=`basename $@ .3` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=3 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/ocaml/nbdkit-ocaml-plugin.pod b/plugins/ocaml/nbdkit-ocaml-plugin.pod +index 8f67d9b..80af5bb 100644 +--- a/plugins/ocaml/nbdkit-ocaml-plugin.pod ++++ b/plugins/ocaml/nbdkit-ocaml-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-ocaml-plugin - writing nbdkit plugins in OCaml +@@ -122,43 +120,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2014 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/pattern/Makefile.am b/plugins/pattern/Makefile.am +index da092db..f5b99a2 100644 +--- a/plugins/pattern/Makefile.am ++++ b/plugins/pattern/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_pattern_plugin_la_CFLAGS = \ + nbdkit_pattern_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-pattern-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-pattern-plugin.1: nbdkit-pattern-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/plugins/pattern/nbdkit-pattern-plugin.pod b/plugins/pattern/nbdkit-pattern-plugin.pod +index 425cae6..1b22f39 100644 +--- a/plugins/pattern/nbdkit-pattern-plugin.pod ++++ b/plugins/pattern/nbdkit-pattern-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-pattern-plugin - plugin to serve a fixed pattern of data for testing +@@ -70,43 +68,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/perl/Makefile.am b/plugins/perl/Makefile.am +index 293d059..1b792a2 100644 +--- a/plugins/perl/Makefile.am ++++ b/plugins/perl/Makefile.am +@@ -54,16 +54,16 @@ nbdkit_perl_plugin_la_LDFLAGS = \ + -module -avoid-version -shared \ + $(PERL_LDOPTS) + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-perl-plugin.3 + CLEANFILES += $(man_MANS) + + nbdkit-perl-plugin.3: nbdkit-perl-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=3 --name=`basename $@ .3` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=3 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/perl/nbdkit-perl-plugin.pod b/plugins/perl/nbdkit-perl-plugin.pod +index ce8bb51..1ddd6b6 100644 +--- a/plugins/perl/nbdkit-perl-plugin.pod ++++ b/plugins/perl/nbdkit-perl-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-perl-plugin - nbdkit perl plugin +@@ -366,43 +364,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013-2014 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/python/Makefile.am b/plugins/python/Makefile.am +index bcd102f..292d30b 100644 +--- a/plugins/python/Makefile.am ++++ b/plugins/python/Makefile.am +@@ -55,16 +55,16 @@ nbdkit_python_plugin_la_LDFLAGS = \ + -module -avoid-version -shared \ + $(PYTHON_LDFLAGS) + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-python-plugin.3 + CLEANFILES += $(man_MANS) + + nbdkit-python-plugin.3: nbdkit-python-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=3 --name=`basename $@ .3` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=3 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/python/nbdkit-python-plugin.pod b/plugins/python/nbdkit-python-plugin.pod +index c80af9b..f6ada4d 100644 +--- a/plugins/python/nbdkit-python-plugin.pod ++++ b/plugins/python/nbdkit-python-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-python-plugin - nbdkit python plugin +@@ -285,43 +283,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013-2014 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/random/Makefile.am b/plugins/random/Makefile.am +index fac200d..d990158 100644 +--- a/plugins/random/Makefile.am ++++ b/plugins/random/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_random_plugin_la_CFLAGS = \ + nbdkit_random_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-random-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-random-plugin.1: nbdkit-random-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/plugins/random/nbdkit-random-plugin.pod b/plugins/random/nbdkit-random-plugin.pod +index 6539d61..9967f5b 100644 +--- a/plugins/random/nbdkit-random-plugin.pod ++++ b/plugins/random/nbdkit-random-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-random-plugin - plugin to serve random data +@@ -54,43 +52,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/ruby/Makefile.am b/plugins/ruby/Makefile.am +index 092f9e6..c5af56d 100644 +--- a/plugins/ruby/Makefile.am ++++ b/plugins/ruby/Makefile.am +@@ -55,16 +55,16 @@ nbdkit_ruby_plugin_la_LDFLAGS = \ + -module -avoid-version -shared \ + $(RUBY_LDFLAGS) + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-ruby-plugin.3 + CLEANFILES += $(man_MANS) + + nbdkit-ruby-plugin.3: nbdkit-ruby-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=3 --name=`basename $@ .3` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=3 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/ruby/nbdkit-ruby-plugin.pod b/plugins/ruby/nbdkit-ruby-plugin.pod +index 29d072a..fab816f 100644 +--- a/plugins/ruby/nbdkit-ruby-plugin.pod ++++ b/plugins/ruby/nbdkit-ruby-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-ruby-plugin - nbdkit ruby plugin +@@ -300,43 +298,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013-2016 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/split/Makefile.am b/plugins/split/Makefile.am +index 42b9bfd..49c13f4 100644 +--- a/plugins/split/Makefile.am ++++ b/plugins/split/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_split_plugin_la_CFLAGS = \ + nbdkit_split_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-split-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-split-plugin.1: nbdkit-split-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/plugins/split/nbdkit-split-plugin.pod b/plugins/split/nbdkit-split-plugin.pod +index fb47faf..a7cb5ff 100644 +--- a/plugins/split/nbdkit-split-plugin.pod ++++ b/plugins/split/nbdkit-split-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-split-plugin - nbdkit plugin to concatenate split files into one disk +@@ -79,43 +77,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2017 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/streaming/Makefile.am b/plugins/streaming/Makefile.am +index ea64109..5443c4b 100644 +--- a/plugins/streaming/Makefile.am ++++ b/plugins/streaming/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_streaming_plugin_la_CFLAGS = \ + nbdkit_streaming_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-streaming-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-streaming-plugin.1: nbdkit-streaming-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/plugins/streaming/nbdkit-streaming-plugin.pod b/plugins/streaming/nbdkit-streaming-plugin.pod +index 98e8337..b33f756 100644 +--- a/plugins/streaming/nbdkit-streaming-plugin.pod ++++ b/plugins/streaming/nbdkit-streaming-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-streaming-plugin - nbdkit streaming plugin +@@ -81,43 +79,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2014 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/tar/Makefile.am b/plugins/tar/Makefile.am +index d65ebf7..c4872d4 100644 +--- a/plugins/tar/Makefile.am ++++ b/plugins/tar/Makefile.am +@@ -48,16 +48,16 @@ nbdkit-tar-plugin: $(source) + mv $@-t $@ + chmod 0555 $@ + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-tar-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-tar-plugin.1: $(source) +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --name nbdkit-tar-plugin --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/tar/tar.pl b/plugins/tar/tar.pl +index 69f693e..e92f748 100644 +--- a/plugins/tar/tar.pl ++++ b/plugins/tar/tar.pl +@@ -3,8 +3,6 @@ + + =pod + +-=encoding utf8 +- + =head1 NAME + + nbdkit-tar-plugin - Read and write files inside tar files without unpacking. +@@ -72,46 +70,6 @@ Based on the virt-v2v OVA importer written by Tomáš Golembiovský. + + Copyright (C) 2017 Red Hat Inc. + +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +- + =cut + + use strict; +diff --git a/plugins/tcl/Makefile.am b/plugins/tcl/Makefile.am +index fb21481..befaf07 100644 +--- a/plugins/tcl/Makefile.am ++++ b/plugins/tcl/Makefile.am +@@ -53,16 +53,16 @@ nbdkit_tcl_plugin_la_LDFLAGS = \ + -module -avoid-version -shared \ + $(TCL_LIBS) + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-tcl-plugin.3 + CLEANFILES += $(man_MANS) + + nbdkit-tcl-plugin.3: nbdkit-tcl-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=3 --name=`basename $@ .3` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=3 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/tcl/nbdkit-tcl-plugin.pod b/plugins/tcl/nbdkit-tcl-plugin.pod +index 17b5c5f..2d40ba1 100644 +--- a/plugins/tcl/nbdkit-tcl-plugin.pod ++++ b/plugins/tcl/nbdkit-tcl-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-tcl-plugin - nbdkit Tcl plugin +@@ -292,43 +290,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/vddk/Makefile.am b/plugins/vddk/Makefile.am +index 3b3e8aa..5d5762f 100644 +--- a/plugins/vddk/Makefile.am ++++ b/plugins/vddk/Makefile.am +@@ -54,16 +54,16 @@ nbdkit_vddk_plugin_la_LIBADD = \ + nbdkit_vddk_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-vddk-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-vddk-plugin.1: nbdkit-vddk-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/vddk/nbdkit-vddk-plugin.pod b/plugins/vddk/nbdkit-vddk-plugin.pod +index 241a992..25e78ff 100644 +--- a/plugins/vddk/nbdkit-vddk-plugin.pod ++++ b/plugins/vddk/nbdkit-vddk-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-vddk-plugin - VMware VDDK plugin for nbdkit +@@ -328,43 +326,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013-2017 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/xz/Makefile.am b/plugins/xz/Makefile.am +index 39baef8..9b20718 100644 +--- a/plugins/xz/Makefile.am ++++ b/plugins/xz/Makefile.am +@@ -56,16 +56,16 @@ nbdkit_xz_plugin_la_LIBADD = \ + nbdkit_xz_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-xz-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-xz-plugin.1: nbdkit-xz-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD + + endif +diff --git a/plugins/xz/nbdkit-xz-plugin.pod b/plugins/xz/nbdkit-xz-plugin.pod +index 7d8332a..e5e708f 100644 +--- a/plugins/xz/nbdkit-xz-plugin.pod ++++ b/plugins/xz/nbdkit-xz-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-xz-plugin - nbdkit xz plugin +@@ -96,43 +94,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2013 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/plugins/zero/Makefile.am b/plugins/zero/Makefile.am +index 11ccce0..0dcbbf0 100644 +--- a/plugins/zero/Makefile.am ++++ b/plugins/zero/Makefile.am +@@ -47,14 +47,14 @@ nbdkit_zero_plugin_la_CFLAGS = \ + nbdkit_zero_plugin_la_LDFLAGS = \ + -module -avoid-version -shared + +-if HAVE_POD2MAN ++if HAVE_POD + + man_MANS = nbdkit-zero-plugin.1 + CLEANFILES += $(man_MANS) + + nbdkit-zero-plugin.1: nbdkit-zero-plugin.pod +- $(POD2MAN) $(POD2MAN_ARGS) --section=1 --name=`basename $@ .1` $< $@.t && \ +- if grep 'POD ERROR' $@.t; then rm $@.t; exit 1; fi && \ +- mv $@.t $@ ++ $(PODWRAPPER) --section=1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< + +-endif ++endif HAVE_POD +diff --git a/plugins/zero/nbdkit-zero-plugin.pod b/plugins/zero/nbdkit-zero-plugin.pod +index 015c70a..72bb1aa 100644 +--- a/plugins/zero/nbdkit-zero-plugin.pod ++++ b/plugins/zero/nbdkit-zero-plugin.pod +@@ -1,5 +1,3 @@ +-=encoding utf8 +- + =head1 NAME + + nbdkit-zero-plugin - nbdkit zero length plugin +@@ -31,43 +29,3 @@ Richard W.M. Jones + =head1 COPYRIGHT + + Copyright (C) 2018 Red Hat Inc. +- +-=head1 LICENSE +- +-Redistribution and use in source and binary forms, with or without +-modification, are permitted provided that the following conditions are +-met: +- +-=over 4 +- +-=item * +- +-Redistributions of source code must retain the above copyright +-notice, this list of conditions and the following disclaimer. +- +-=item * +- +-Redistributions in binary form must reproduce the above copyright +-notice, this list of conditions and the following disclaimer in the +-documentation and/or other materials provided with the distribution. +- +-=item * +- +-Neither the name of Red Hat nor the names of its contributors may be +-used to endorse or promote products derived from this software without +-specific prior written permission. +- +-=back +- +-THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND +-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, +-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +-PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR +-CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +-SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +-LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF +-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +-OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +-SUCH DAMAGE. +diff --git a/podwrapper.pl.in b/podwrapper.pl.in +new file mode 100755 +index 0000000..6518b4b +--- /dev/null ++++ b/podwrapper.pl.in +@@ -0,0 +1,496 @@ ++#!/usr/bin/env perl ++# podwrapper.pl ++# @configure_input@ ++# Copyright (C) 2010-2018 Red Hat Inc. ++# All rights reserved. ++# ++# Redistribution and use in source and binary forms, with or without ++# modification, are permitted provided that the following conditions are ++# met: ++# ++# * Redistributions of source code must retain the above copyright ++# notice, this list of conditions and the following disclaimer. ++# ++# * Redistributions in binary form must reproduce the above copyright ++# notice, this list of conditions and the following disclaimer in the ++# documentation and/or other materials provided with the distribution. ++# ++# * Neither the name of Red Hat nor the names of its contributors may be ++# used to endorse or promote products derived from this software without ++# specific prior written permission. ++# ++# THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND ++# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, ++# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A ++# PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR ++# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, ++# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF ++# USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ++# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, ++# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT ++# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ++# SUCH DAMAGE. ++ ++use warnings; ++use strict; ++ ++use Pod::Usage; ++use Getopt::Long; ++use Pod::Man; ++use Pod::Simple; ++use Pod::Simple::Text; ++use Pod::Simple::XHTML; ++use File::Basename; ++ ++# https://www.redhat.com/archives/libguestfs/2013-May/thread.html#00088 ++eval { $Text::Wrap::huge = "overflow" }; ++ ++=head1 NAME ++ ++podwrapper.pl - Generate documentation from POD input files ++ ++=head1 SYNOPSIS ++ ++ EXTRA_DIST = foo.pod ++ ++ if HAVE_POD ++ ++ man_MANS = foo.1 ++ CLEANFILES += $(man_MANS) ++ ++ foo.1: foo.pod ++ $(PODWRAPPER) --section 1 --man $@ \ ++ --html $(top_builddir)/html/$@.html \ ++ $< ++ ++ endif HAVE_POD ++ ++=head1 DESCRIPTION ++ ++podwrapper.pl is a Perl script that generates various output formats ++from POD input files that nbdkit uses for most documentation. ++ ++You must specify one input file, and one or more output formats. The ++output options are I<--man>, I<--html> and I<--text> (see below). ++ ++In C files, use a variation of the boilerplate shown in ++the L section above. ++ ++For information about the POD format, see L. ++ ++=head1 OPTIONS ++ ++=over 4 ++ ++=cut ++ ++my $help; ++ ++=item B<--help> ++ ++Display brief help. ++ ++=cut ++ ++my $html; ++ ++=item B<--html output.html> ++ ++Write a web page to C. If this option is not ++given, then no web page output is produced. ++ ++=cut ++ ++my @inserts; ++ ++=item B<--insert filename:__PATTERN__> ++ ++In the input file, replace the literal text C<__PATTERN__> with the ++replacement file C. You can give this option multiple ++times. ++ ++The contents of C are treated as POD. ++Compare and contrast with I<--verbatim>. ++ ++Although it is conventional to use C<__...__> (double underscores) for ++patterns, in fact you can use any string as the pattern. ++ ++=cut ++ ++my $man; ++ ++=item B<--man output.n> ++ ++Write a man page to C (C is the manual section number). ++If this option is not given, then no man page output is produced. ++ ++=cut ++ ++my $name; ++ ++=item B<--name name> ++ ++Set the name of the man page. If not set, defaults to the basename ++of the input file. ++ ++=cut ++ ++my $section; ++ ++=item B<--section N> ++ ++Set the section of the man page (a number such as C<1> for ++command line utilities or C<3> for C API documentation). If ++not set, defaults to C<1>. ++ ++=cut ++ ++my $text; ++ ++=item B<--text output.txt> ++ ++Write a text file to C. If this option is not ++given, then no text output is produced. ++ ++=cut ++ ++my @verbatims; ++ ++=item B<--verbatim filename:__PATTERN__> ++ ++In the input file, replace the literal text C<__PATTERN__> with the ++replacement file C. You can give this option multiple ++times. ++ ++The contents of C are inserted as verbatim text, and ++are I interpreted as POD. ++Compare and contrast with I<--insert>. ++ ++Although it is conventional to use C<__...__> (double underscores) for ++patterns, in fact you can use any string as the pattern. ++ ++=cut ++ ++# Clean up the program name. ++my $progname = $0; ++$progname =~ s{.*/}{}; ++ ++# Parse options. ++GetOptions ("help|?" => \$help, ++ "html=s" => \$html, ++ "insert=s" => \@inserts, ++ "man=s" => \$man, ++ "name=s" => \$name, ++ "section=s" => \$section, ++ "text=s" => \$text, ++ "verbatim=s" => \@verbatims, ++ ) or pod2usage (2); ++pod2usage (1) if $help; ++ ++die "$progname: missing argument: podwrapper input.pod\n" unless @ARGV == 1; ++my $input = $ARGV[0]; ++ ++# There should be at least one output. ++die "$progname: $input: no output format specified. Use --man and/or --html and/or --text.\n" ++ unless defined $man || defined $html || defined $text; ++ ++# Default for $name and $section. ++$name = basename ($input, ".pod") unless defined $name; ++$section = 1 unless defined $section; ++ ++# Note that these @...@ are substituted by ./configure. ++my $abs_top_srcdir = "@abs_top_srcdir@"; ++my $abs_top_builddir = "@abs_top_builddir@"; ++my $package_name = "@PACKAGE_NAME@"; ++my $package_version = "@PACKAGE_VERSION@"; ++ ++die "$progname: ./configure substitutions were not performed" ++ unless $abs_top_srcdir && $abs_top_builddir && ++ $package_name && $package_version; ++ ++# Create a stable date (thanks Hilko Bengen). ++my $date; ++my $filename = "$abs_top_srcdir/.git"; ++if (!$date && -d $filename) { ++ local $ENV{GIT_DIR} = $filename; ++ $_ = `git show -s --format=%ci`; ++ $date = $1 if /^(\d+-\d+-\d+)\s/; ++} ++if (!$date) { ++ my ($day, $month, $year) = (localtime)[3,4,5]; ++ $date = sprintf ("%04d-%02d-%02d", $year+1900, $month+1, $day); ++} ++ ++# Create a release string. ++my $release = "$package_name-$package_version"; ++ ++#print "input=$input\n"; ++#print "name=$name\n"; ++#print "section=$section\n"; ++#print "date=$date\n"; ++ ++# Read the input. ++my $content = read_whole_file ($input); ++ ++# Perform @inserts. ++foreach (@inserts) { ++ my @a = split /:/, $_, 2; ++ die "$progname: $input: no colon in parameter of --insert\n" unless @a >= 2; ++ my $replacement = read_whole_file ($a[0]); ++ my $oldcontent = $content; ++ $content =~ s/$a[1]/$replacement/ge; ++ die "$progname: $input: could not find pattern '$a[1]' in input file\n" ++ if $content eq $oldcontent; ++} ++ ++# Turn external links to this man page into simple cross-section links. ++$content =~ s,\QL<$name($section)/\E,L= 2; ++ my $replacement = read_verbatim_file ($a[0]); ++ my $oldcontent = $content; ++ $content =~ s/$a[1]/$replacement/ge; ++ die "$progname: $input: could not find pattern '$a[1]' in input file\n" ++ if $content eq $oldcontent; ++} ++ ++# There should be no =encoding line present in the content (we will add one). ++die "$progname: $input: =encoding must not be present in input\n" ++ if $content =~ /^=encoding/m; ++ ++$content =~ s/^=(.*)/\n=encoding utf8\n\n=$1/m; ++ ++# Verify sections present / not present. ++die "$progname: $input: missing DESCRIPTION section\n" ++ if $content !~ /^=head1 DESCRIPTION/m; ++die "$progname: $input: missing AUTHOR or AUTHORS section\n" ++ unless $content =~ /^=head1 AUTHOR/m; ++die "$progname: $input: missing SEE ALSO section\n" ++ unless $content =~ /^=head1 SEE ALSO/m; ++die "$progname: $input: missing COPYRIGHT section\n" ++ unless $content =~ /^=head1 COPYRIGHT/m; ++die "$progname: $input: BUGS is now added automatically, do not add it to the POD file\n" ++ if $content =~ /^=head1 (REPORTING )?BUGS/m; ++die "$progname: $input: LICENSE is now added automatically, do not add it to the POD file\n" ++ if $content =~ /^=head1 LICENSE/m; ++ ++# Add standard LICENSE section at the end. ++$content .= ++" ++ ++=head1 LICENSE ++ ++Redistribution and use in source and binary forms, with or without ++modification, are permitted provided that the following conditions are ++met: ++ ++=over 4 ++ ++=item * ++ ++Redistributions of source code must retain the above copyright ++notice, this list of conditions and the following disclaimer. ++ ++=item * ++ ++Redistributions in binary form must reproduce the above copyright ++notice, this list of conditions and the following disclaimer in the ++documentation and/or other materials provided with the distribution. ++ ++=item * ++ ++Neither the name of Red Hat nor the names of its contributors may be ++used to endorse or promote products derived from this software without ++specific prior written permission. ++ ++=back ++ ++THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND ++ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, ++THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A ++PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR ++CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, ++SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT ++LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF ++USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ++ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, ++OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT ++OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF ++SUCH DAMAGE. ++"; ++ ++# Check no over-long lines in the input. (As a special exception this ++# is permitted in verbatim sections or if the line contains a URL). ++my @lines = split /\n/, $content; ++foreach (@lines) { ++ die "$progname: $input: line too long:\n$_\n" ++ if length $_ > 76 && ++ substr ($_, 0, 1) ne ' ' && ++ ! m/https?:/; ++} ++ ++# Output man page. ++SUBMAN: { ++ package Podwrapper::Man; ++ ++ use vars qw(@ISA $VERSION); ++ @ISA = qw(Pod::Man); ++ $VERSION = $package_version; ++ ++ # Override the L<> method. ++ sub cmd_l ++ { ++ my ($self, $attrs, $text) = @_; ++ return $text; ++ } ++} ++ ++if ($man) { ++ my $parser = Podwrapper::Man->new ( ++ name => $name, ++ release => $release, section => $section, ++ center => "Virtualization Support", ++ date => $date, ++ stderr => 1, utf8 => 1 ++ ); ++ my $output; ++ $parser->no_errata_section (1); ++ $parser->complain_stderr (1); ++ $parser->output_string (\$output); ++ $parser->parse_string_document ($content) ++ or die "$progname: could not parse input document"; ++ open OUT, ">$man" or die "$progname: $man: $!"; ++ print OUT $output or die "$progname: $man: $!"; ++ close OUT or die "$progname: $man: $!"; ++ if ($parser->any_errata_seen) { ++ unlink $man; ++ die "$input: errors or warnings in this POD file, see messages above\n" ++ } ++ #print "$progname: wrote $man\n"; ++} ++ ++# Output HTML. ++SUBHTML: { ++ # Subclass Pod::Simple::XHTML. See the documentation. ++ package Podwrapper::XHTML; ++ ++ use vars qw(@ISA $VERSION); ++ @ISA = qw(Pod::Simple::XHTML); ++ $VERSION = $package_version; ++ ++ sub is_an_nbdkit_page ++ { ++ local $_ = shift; ++ ++ return 1 if /^nbdkit/; ++ return 0; ++ } ++ ++ sub resolve_man_page_link ++ { ++ my $self = shift; ++ my $name = $_[0]; # eg. "nbdkit(1)", can be undef ++ my $anchor = $_[1]; # eg. "SYNOPSIS", can be undef ++ my $r = ""; ++ if (defined $name) { ++ return $self->SUPER::resolve_man_page_link (@_) ++ unless is_an_nbdkit_page ($name); ++ $name =~ s/\((.*)\)$/.$1/; ++ $r .= "$name.html"; ++ } ++ $r .= "#" . $self->idify ($anchor, 1) if defined $anchor; ++ $r; ++ } ++ ++ # For some reason Pod::Simple::XHTML usually cannot find a ++ # title for the page. This defaults the HTML field ++ # to the same as the man page name. ++ sub default_title { $name } ++} ++ ++if ($html) { ++ mkdir "$abs_top_builddir/html"; ++ ++ my $parser = Podwrapper::XHTML->new; ++ my $output; ++ $parser->no_errata_section (1); ++ $parser->complain_stderr (1); ++ $parser->output_string (\$output); ++ # Added in Pod::Simple 3.16, 2011-03-14. ++ eval { $parser->html_charset ("UTF-8") }; ++ $parser->html_css ("pod.css"); ++ $parser->index (1); ++ $parser->parse_string_document ($content); ++ ++ # Hack for Perl 5.16. ++ $output =~ s{/>pod.css<}{/>\n<}; ++ ++ open OUT, ">$html" or die "$progname: $html: $!"; ++ print OUT $output or die "$progname: $html: $!"; ++ close OUT or die "$progname: $html: $!"; ++ if ($parser->any_errata_seen) { ++ unlink $html; ++ die "$input: errors or warnings in this POD file, see messages above\n" ++ } ++ #print "$progname: wrote $html\n"; ++} ++ ++# Output text. ++if ($text) { ++ my $parser = Pod::Simple::Text->new; ++ my $output; ++ $parser->no_errata_section (1); ++ $parser->complain_stderr (1); ++ $parser->output_string (\$output); ++ $parser->parse_string_document ($content); ++ open OUT, ">$text" or die "$progname: $text: $!"; ++ binmode OUT, ":utf8"; ++ print OUT $output or die "$progname: $text: $!"; ++ close OUT or die "$progname: $text: $!"; ++ if ($parser->any_errata_seen) { ++ unlink $text; ++ die "$input: errors or warnings in this POD file, see messages above\n" ++ } ++ #print "$progname: wrote $text\n"; ++} ++ ++sub read_whole_file ++{ ++ my $input = shift; ++ local $/ = undef; ++ ++ open FILE, "<:encoding(UTF-8)", $input or die "$progname: $input: $!"; ++ $_ = <FILE>; ++ close FILE; ++ $_; ++} ++ ++sub read_verbatim_file ++{ ++ my $input = shift; ++ my $r = ""; ++ ++ open FILE, "<:encoding(UTF-8)", $input or die "$progname: $input: $!"; ++ while (<FILE>) { ++ $r .= " $_"; ++ } ++ close FILE; ++ $r; ++} ++ ++=head1 SEE ALSO ++ ++L<perlpod(1)>, ++L<Pod::Simple(3pm)>. ++ ++=head1 AUTHOR ++ ++Richard W.M. Jones. ++ ++=head1 COPYRIGHT ++ ++Copyright (C) 2012-2018 Red Hat Inc. +-- +2.17.1 + diff --git a/nbdkit.spec b/nbdkit.spec index b7ef724..aafa58f 100644 --- a/nbdkit.spec +++ b/nbdkit.spec @@ -21,7 +21,7 @@ Name: nbdkit Version: 1.5.0 -Release: 2%{?dist} +Release: 3%{?dist} Summary: NBD server License: BSD @@ -34,7 +34,18 @@ Source1: http://libguestfs.org/download/nbdkit/1.5-development/%{name}-%{ Source2: libguestfs.keyring %endif -%global patches_touch_autotools 0 +Patch0001: 0001-bash-Don-t-define-bashcompdir-twice.patch +Patch0002: 0002-xz-Minor-rewrites-to-improve-the-flow-of-the-man-pag.patch +Patch0003: 0003-streaming-Add-illustrations-to-the-man-page.patch +Patch0004: 0004-tests-Put-test.lua-into-alphabetical-order-in-the-li.patch +Patch0005: 0005-Add-pattern-plugin.patch +Patch0006: 0006-tests-Add-a-second-test-of-the-offset-filter.patch +Patch0007: 0007-tests-Test-largest-possible-plugin-size.patch +Patch0008: 0008-docs-Fix-broken-cross-reference-in-man-page.patch +Patch0009: 0009-docs-Break-up-some-over-long-lines-in-documentation.patch +Patch0010: 0010-docs-Add-podwrapper-from-libguestfs.patch + +%global patches_touch_autotools 1 %if 0%{patches_touch_autotools} BuildRequires: autoconf, automake, libtool %endif @@ -150,6 +161,10 @@ trivial dependencies. A null (bitbucket) plugin. +* nbdkit-pattern-plugin + + Fixed test pattern. + * nbdkit-random-plugin Random content plugin for testing. @@ -578,6 +593,7 @@ popd %{_libdir}/%{name}/plugins/nbdkit-memory-plugin.so %{_libdir}/%{name}/plugins/nbdkit-nbd-plugin.so %{_libdir}/%{name}/plugins/nbdkit-null-plugin.so +%{_libdir}/%{name}/plugins/nbdkit-pattern-plugin.so %{_libdir}/%{name}/plugins/nbdkit-random-plugin.so %{_libdir}/%{name}/plugins/nbdkit-split-plugin.so %{_libdir}/%{name}/plugins/nbdkit-streaming-plugin.so @@ -586,6 +602,7 @@ popd %{_mandir}/man1/nbdkit-memory-plugin.1* %{_mandir}/man1/nbdkit-nbd-plugin.1* %{_mandir}/man1/nbdkit-null-plugin.1* +%{_mandir}/man1/nbdkit-pattern-plugin.1* %{_mandir}/man1/nbdkit-random-plugin.1* %{_mandir}/man1/nbdkit-split-plugin.1* %{_mandir}/man1/nbdkit-streaming-plugin.1* @@ -758,6 +775,10 @@ popd %changelog +* Sun Jul 15 2018 Richard W.M. Jones <rjones@redhat.com> - 1.5.0-3 +- Add all upstream patches since 1.5.0. +- New pattern plugin. + * Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild