Eric Blake
2022-Oct-20 20:31 UTC
[Libguestfs] [nbdkit PATCH 00/10] Various CI improvements
This thread is more for reference, since I've already pushed these to see if it helps turn more of the CI green - although at the moment debian-sid is not playing nice. I'm still not sure how to add a VPATH build to the CI tools; what's more, while I am now getting a native VPATH 'make' to work on Fedora, 'make check' still hits lots of errors (probably where we need more $builddir references). Eric Blake (10): ci: Update with lcitool build: Fix VPATH build of protostrings.c mingw: Avoid broken gnutls/socket.h header build: Fix VPATH build when nbdkit not installed golang: Attempt VPATH builds build: Only attempt to build vddk on Linux rust: Skip building in VPATH mingw: Provide nbdkit_debug() in Windows replacements perl: Auto-disable on mingw ci: Fix typo in last patch configure.ac | 27 +++++-- common/allocators/Makefile.am | 3 +- common/bitmap/Makefile.am | 3 +- common/protocol/Makefile.am | 4 +- common/regions/Makefile.am | 3 +- common/replacements/Makefile.am | 7 +- common/utils/Makefile.am | 3 +- filters/blocksize-policy/Makefile.am | 5 +- filters/blocksize/Makefile.am | 3 +- filters/cache/Makefile.am | 1 + filters/cacheextents/Makefile.am | 3 +- filters/checkwrite/Makefile.am | 3 +- filters/cow/Makefile.am | 3 +- filters/ddrescue/Makefile.am | 3 +- filters/delay/Makefile.am | 3 +- filters/error/Makefile.am | 3 +- filters/exitlast/Makefile.am | 7 +- filters/exitwhen/Makefile.am | 5 +- filters/exportname/Makefile.am | 3 +- filters/ext2/Makefile.am | 5 +- filters/extentlist/Makefile.am | 3 +- filters/fua/Makefile.am | 3 +- filters/gzip/Makefile.am | 3 +- filters/ip/Makefile.am | 3 +- filters/limit/Makefile.am | 5 +- filters/log/Makefile.am | 5 +- filters/luks/Makefile.am | 1 + filters/multi-conn/Makefile.am | 3 +- filters/nocache/Makefile.am | 3 +- filters/noextents/Makefile.am | 3 +- filters/nofilter/Makefile.am | 3 +- filters/noparallel/Makefile.am | 3 +- filters/nozero/Makefile.am | 3 +- filters/offset/Makefile.am | 5 +- filters/partition/Makefile.am | 3 +- filters/pause/Makefile.am | 3 +- filters/protect/Makefile.am | 3 +- filters/rate/Makefile.am | 3 +- filters/readahead/Makefile.am | 3 +- filters/retry-request/Makefile.am | 3 +- filters/retry/Makefile.am | 3 +- filters/scan/Makefile.am | 3 +- filters/stats/Makefile.am | 3 +- filters/swab/Makefile.am | 3 +- filters/tar/Makefile.am | 3 +- filters/tls-fallback/Makefile.am | 3 +- filters/truncate/Makefile.am | 3 +- filters/xz/Makefile.am | 5 +- plugins/cc/Makefile.am | 5 +- plugins/cdi/Makefile.am | 5 +- plugins/curl/Makefile.am | 3 +- plugins/data/Makefile.am | 3 +- plugins/eval/Makefile.am | 5 +- plugins/example1/Makefile.am | 3 +- plugins/example2/Makefile.am | 3 +- plugins/example3/Makefile.am | 3 +- plugins/file/Makefile.am | 3 +- plugins/floppy/Makefile.am | 3 +- plugins/full/Makefile.am | 3 +- plugins/golang/Makefile.am | 18 ++--- plugins/guestfs/Makefile.am | 3 +- plugins/info/Makefile.am | 3 +- plugins/iso/Makefile.am | 5 +- plugins/libvirt/Makefile.am | 3 +- plugins/linuxdisk/Makefile.am | 5 +- plugins/lua/Makefile.am | 3 +- plugins/memory/Makefile.am | 5 +- plugins/nbd/Makefile.am | 3 +- plugins/null/Makefile.am | 3 +- plugins/ocaml/Makefile.am | 3 +- plugins/ondemand/Makefile.am | 5 +- plugins/partitioning/Makefile.am | 3 +- plugins/pattern/Makefile.am | 3 +- plugins/perl/Makefile.am | 5 +- plugins/python/Makefile.am | 5 +- plugins/random/Makefile.am | 5 +- plugins/ruby/Makefile.am | 3 +- plugins/sh/Makefile.am | 3 +- plugins/sparse-random/Makefile.am | 5 +- plugins/split/Makefile.am | 5 +- plugins/ssh/Makefile.am | 3 +- plugins/tcl/Makefile.am | 3 +- plugins/tmpdisk/Makefile.am | 5 +- plugins/torrent/Makefile.am | 5 +- plugins/vddk/Makefile.am | 3 +- plugins/zero/Makefile.am | 6 +- server/Makefile.am | 4 +- tests/Makefile.am | 37 ++++++++-- server/crypto.c | 12 +++- common/replacements/fsync.c | 3 +- common/replacements/pread.c | 3 +- common/replacements/pwrite.c | 3 +- ci/build.sh | 11 +-- ci/buildenv/fedora-35-cross-mingw32.sh | 2 +- ci/buildenv/fedora-35-cross-mingw64.sh | 2 +- ci/buildenv/opensuse-leap-154.sh | 71 ++++++++++++++++++ .../fedora-35-cross-mingw32.Dockerfile | 2 +- .../fedora-35-cross-mingw64.Dockerfile | 2 +- ci/containers/opensuse-leap-154.Dockerfile | 72 +++++++++++++++++++ ci/gitlab.yml | 1 + ci/gitlab/build-templates.yml | 5 ++ ci/gitlab/builds.yml | 26 +++++-- ci/gitlab/container-templates.yml | 1 + ci/gitlab/containers.yml | 7 ++ ci/manifest.yml | 8 ++- 105 files changed, 472 insertions(+), 147 deletions(-) create mode 100644 ci/buildenv/opensuse-leap-154.sh create mode 100644 ci/containers/opensuse-leap-154.Dockerfile -- 2.37.3
Eric Blake
2022-Oct-20 20:32 UTC
[Libguestfs] [nbdkit PATCH 01/10] ci: Update with lcitool
Fix a typo and add opensuse-leap-154, then rerun 'lcitool manifest
ci/manifest.yml' to pick up recent changes in lcitool that fix mingw
builds and improve how much time CI jobs can take.
---
ci/build.sh | 2 +-
ci/buildenv/fedora-35-cross-mingw32.sh | 2 +-
ci/buildenv/fedora-35-cross-mingw64.sh | 2 +-
ci/buildenv/opensuse-leap-154.sh | 71 ++++++++++++++++++
.../fedora-35-cross-mingw32.Dockerfile | 2 +-
.../fedora-35-cross-mingw64.Dockerfile | 2 +-
ci/containers/opensuse-leap-154.Dockerfile | 72 +++++++++++++++++++
ci/gitlab.yml | 1 +
ci/gitlab/build-templates.yml | 5 ++
ci/gitlab/builds.yml | 18 +++++
ci/gitlab/container-templates.yml | 1 +
ci/gitlab/containers.yml | 7 ++
ci/manifest.yml | 2 +
13 files changed, 182 insertions(+), 5 deletions(-)
create mode 100644 ci/buildenv/opensuse-leap-154.sh
create mode 100644 ci/containers/opensuse-leap-154.Dockerfile
diff --git a/ci/build.sh b/ci/build.sh
index aad31e3f..7d31d5c5 100755
--- a/ci/build.sh
+++ b/ci/build.sh
@@ -4,7 +4,7 @@ set -xe
skip_tests() {
# Add a way to run all the tests, even the skipped ones, with an
environment
- # variable, so that it can be set fora branch or fork in GitLab.
+ # variable, so that it can be set for a branch or fork in GitLab.
if test "$SKIPPED_TESTS" != "force"
then
# Skip tests from ci/skipped_tests if this is the right OS version
diff --git a/ci/buildenv/fedora-35-cross-mingw32.sh
b/ci/buildenv/fedora-35-cross-mingw32.sh
index 25473bd8..7d0b65c9 100644
--- a/ci/buildenv/fedora-35-cross-mingw32.sh
+++ b/ci/buildenv/fedora-35-cross-mingw32.sh
@@ -69,4 +69,4 @@ export MAKE="/usr/bin/make"
export PYTHON="/usr/bin/python3"
export ABI="i686-w64-mingw32"
-export CONFIGURE_OPTS="--hosti686-w64-mingw32"
+export CONFIGURE_OPTS="--host=i686-w64-mingw32"
diff --git a/ci/buildenv/fedora-35-cross-mingw64.sh
b/ci/buildenv/fedora-35-cross-mingw64.sh
index 59802779..b8bbbff7 100644
--- a/ci/buildenv/fedora-35-cross-mingw64.sh
+++ b/ci/buildenv/fedora-35-cross-mingw64.sh
@@ -69,4 +69,4 @@ export MAKE="/usr/bin/make"
export PYTHON="/usr/bin/python3"
export ABI="x86_64-w64-mingw32"
-export CONFIGURE_OPTS="--hostx86_64-w64-mingw32"
+export CONFIGURE_OPTS="--host=x86_64-w64-mingw32"
diff --git a/ci/buildenv/opensuse-leap-154.sh b/ci/buildenv/opensuse-leap-154.sh
new file mode 100644
index 00000000..2c6f9a2e
--- /dev/null
+++ b/ci/buildenv/opensuse-leap-154.sh
@@ -0,0 +1,71 @@
+# THIS FILE WAS AUTO-GENERATED
+#
+# $ lcitool manifest ci/manifest.yml
+#
+# https://gitlab.com/libvirt/libvirt-ci
+
+function install_buildenv() {
+ zypper update -y
+ zypper install -y \
+ autoconf \
+ automake \
+ bash \
+ bash-completion \
+ ca-certificates \
+ cargo \
+ ccache \
+ clang \
+ e2fsprogs \
+ expect \
+ gcc \
+ gcc-c++ \
+ git \
+ glibc-locale \
+ go \
+ gzip \
+ iproute2 \
+ jq \
+ libcurl-devel \
+ libgnutls-devel \
+ libguestfs-devel \
+ libnbd-devel \
+ libselinux-devel \
+ libssh-devel \
+ libtool \
+ libtorrent-devel \
+ libvirt-devel \
+ libzstd-devel \
+ lua-devel \
+ make \
+ mkisofs \
+ ocaml \
+ perl \
+ perl-Pod-Simple \
+ perl-base \
+ pkgconfig \
+ python3-base \
+ python3-boto3 \
+ python3-devel \
+ python3-flake8 \
+ qemu-tools \
+ rust \
+ socat \
+ tcl-devel \
+ util-linux \
+ xorriso \
+ xz \
+ xz-devel \
+ zlib-devel
+ rpm -qa | sort > /packages.txt
+ mkdir -p /usr/libexec/ccache-wrappers
+ ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/c++
+ ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/cc
+ ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/clang
+ ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/g++
+ ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/gcc
+}
+
+export CCACHE_WRAPPERSDIR="/usr/libexec/ccache-wrappers"
+export LANG="en_US.UTF-8"
+export MAKE="/usr/bin/make"
+export PYTHON="/usr/bin/python3"
diff --git a/ci/containers/fedora-35-cross-mingw32.Dockerfile
b/ci/containers/fedora-35-cross-mingw32.Dockerfile
index 9dfb1b70..30c5170e 100644
--- a/ci/containers/fedora-35-cross-mingw32.Dockerfile
+++ b/ci/containers/fedora-35-cross-mingw32.Dockerfile
@@ -83,4 +83,4 @@ RUN nosync dnf install -y \
ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/i686-w64-mingw32-gcc
ENV ABI "i686-w64-mingw32"
-ENV CONFIGURE_OPTS "--hosti686-w64-mingw32"
+ENV CONFIGURE_OPTS "--host=i686-w64-mingw32"
diff --git a/ci/containers/fedora-35-cross-mingw64.Dockerfile
b/ci/containers/fedora-35-cross-mingw64.Dockerfile
index c7bcf4fe..9f61835d 100644
--- a/ci/containers/fedora-35-cross-mingw64.Dockerfile
+++ b/ci/containers/fedora-35-cross-mingw64.Dockerfile
@@ -83,4 +83,4 @@ RUN nosync dnf install -y \
ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/x86_64-w64-mingw32-gcc
ENV ABI "x86_64-w64-mingw32"
-ENV CONFIGURE_OPTS "--hostx86_64-w64-mingw32"
+ENV CONFIGURE_OPTS "--host=x86_64-w64-mingw32"
diff --git a/ci/containers/opensuse-leap-154.Dockerfile
b/ci/containers/opensuse-leap-154.Dockerfile
new file mode 100644
index 00000000..498136c3
--- /dev/null
+++ b/ci/containers/opensuse-leap-154.Dockerfile
@@ -0,0 +1,72 @@
+# THIS FILE WAS AUTO-GENERATED
+#
+# $ lcitool manifest ci/manifest.yml
+#
+# https://gitlab.com/libvirt/libvirt-ci
+
+FROM registry.opensuse.org/opensuse/leap:15.4
+
+RUN zypper update -y && \
+ zypper install -y \
+ autoconf \
+ automake \
+ bash \
+ bash-completion \
+ ca-certificates \
+ cargo \
+ ccache \
+ clang \
+ e2fsprogs \
+ expect \
+ gcc \
+ gcc-c++ \
+ git \
+ glibc-locale \
+ go \
+ gzip \
+ iproute2 \
+ jq \
+ libcurl-devel \
+ libgnutls-devel \
+ libguestfs-devel \
+ libnbd-devel \
+ libselinux-devel \
+ libssh-devel \
+ libtool \
+ libtorrent-devel \
+ libvirt-devel \
+ libzstd-devel \
+ lua-devel \
+ make \
+ mkisofs \
+ ocaml \
+ perl \
+ perl-Pod-Simple \
+ perl-base \
+ pkgconfig \
+ python3-base \
+ python3-boto3 \
+ python3-devel \
+ python3-flake8 \
+ qemu-tools \
+ rust \
+ socat \
+ tcl-devel \
+ util-linux \
+ xorriso \
+ xz \
+ xz-devel \
+ zlib-devel && \
+ zypper clean --all && \
+ rpm -qa | sort > /packages.txt && \
+ mkdir -p /usr/libexec/ccache-wrappers && \
+ ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/c++ && \
+ ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/cc && \
+ ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/clang && \
+ ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/g++ && \
+ ln -s /usr/bin/ccache /usr/libexec/ccache-wrappers/gcc
+
+ENV CCACHE_WRAPPERSDIR "/usr/libexec/ccache-wrappers"
+ENV LANG "en_US.UTF-8"
+ENV MAKE "/usr/bin/make"
+ENV PYTHON "/usr/bin/python3"
diff --git a/ci/gitlab.yml b/ci/gitlab.yml
index d1cb3934..68ffe725 100644
--- a/ci/gitlab.yml
+++ b/ci/gitlab.yml
@@ -67,6 +67,7 @@ workflow:
debug:
image: docker.io/library/alpine:3
stage: sanity_checks
+ interruptible: true
needs: []
script:
- printenv | sort
diff --git a/ci/gitlab/build-templates.yml b/ci/gitlab/build-templates.yml
index 8c56851f..afe33739 100644
--- a/ci/gitlab/build-templates.yml
+++ b/ci/gitlab/build-templates.yml
@@ -26,6 +26,7 @@
.gitlab_native_build_job_prebuilt_env:
image: $CI_REGISTRY/$RUN_UPSTREAM_NAMESPACE/nbdkit/ci-$NAME:latest
stage: builds
+ interruptible: true
before_script:
- cat /packages.txt
rules:
@@ -61,6 +62,7 @@
.gitlab_native_build_job_local_env:
image: $IMAGE
stage: builds
+ interruptible: true
before_script:
- source ci/buildenv/$NAME.sh
- install_buildenv
@@ -138,6 +140,7 @@
.gitlab_cross_build_job_prebuilt_env:
image:
$CI_REGISTRY/$RUN_UPSTREAM_NAMESPACE/nbdkit/ci-$NAME-cross-$CROSS:latest
stage: builds
+ interruptible: true
before_script:
- cat /packages.txt
rules:
@@ -173,6 +176,7 @@
.gitlab_cross_build_job_local_env:
image: $IMAGE
stage: builds
+ interruptible: true
before_script:
- source ci/buildenv/$NAME.sh
- install_buildenv
@@ -232,6 +236,7 @@
.cirrus_build_job:
stage: builds
image: registry.gitlab.com/libvirt/libvirt-ci/cirrus-run:master
+ interruptible: true
needs: []
script:
- source ci/cirrus/$NAME.vars
diff --git a/ci/gitlab/builds.yml b/ci/gitlab/builds.yml
index b8793a5a..d0bc2653 100644
--- a/ci/gitlab/builds.yml
+++ b/ci/gitlab/builds.yml
@@ -237,6 +237,24 @@ x86_64-opensuse-leap-153-local-env:
NAME: opensuse-leap-153
+x86_64-opensuse-leap-154-prebuilt-env:
+ extends: .native_build_job_prebuilt_env
+ needs:
+ - job: x86_64-opensuse-leap-154-container
+ optional: true
+ allow_failure: false
+ variables:
+ NAME: opensuse-leap-154
+
+x86_64-opensuse-leap-154-local-env:
+ extends: .native_build_job_local_env
+ needs: []
+ allow_failure: false
+ variables:
+ IMAGE: registry.opensuse.org/opensuse/leap:15.4
+ NAME: opensuse-leap-154
+
+
x86_64-opensuse-tumbleweed-prebuilt-env:
extends: .native_build_job_prebuilt_env
needs:
diff --git a/ci/gitlab/container-templates.yml
b/ci/gitlab/container-templates.yml
index a577028d..edb4aba6 100644
--- a/ci/gitlab/container-templates.yml
+++ b/ci/gitlab/container-templates.yml
@@ -16,6 +16,7 @@
.container_job:
image: docker:stable
stage: containers
+ interruptible: false
needs: []
services:
- docker:dind
diff --git a/ci/gitlab/containers.yml b/ci/gitlab/containers.yml
index d812baea..9b6da610 100644
--- a/ci/gitlab/containers.yml
+++ b/ci/gitlab/containers.yml
@@ -77,6 +77,13 @@ x86_64-opensuse-leap-153-container:
NAME: opensuse-leap-153
+x86_64-opensuse-leap-154-container:
+ extends: .container_job
+ allow_failure: false
+ variables:
+ NAME: opensuse-leap-154
+
+
x86_64-opensuse-tumbleweed-container:
extends: .container_job
allow_failure: false
diff --git a/ci/manifest.yml b/ci/manifest.yml
index 57442b1a..6ef9f576 100644
--- a/ci/manifest.yml
+++ b/ci/manifest.yml
@@ -93,6 +93,8 @@ targets:
opensuse-leap-153: x86_64
+ opensuse-leap-154: x86_64
+
opensuse-tumbleweed: x86_64
macos-11:
--
2.37.3
Eric Blake
2022-Oct-20 20:32 UTC
[Libguestfs] [nbdkit PATCH 02/10] build: Fix VPATH build of protostrings.c
generate-protostrings.sh is a generated file, hence it lives in
builddir, which is not the same as srcdir in a VPATH build.
Fixes: 8aff349a ("common/protocol: Remove protostrings.sed, use bash+sed
instead.", v1.15.3)
---
common/protocol/Makefile.am | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/common/protocol/Makefile.am b/common/protocol/Makefile.am
index da7fa777..5ff5241d 100644
--- a/common/protocol/Makefile.am
+++ b/common/protocol/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2020 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -55,6 +55,6 @@ CLEANFILES += protostrings.c
protostrings.c: nbd-protocol.h generate-protostrings.sh Makefile
rm -f $@ $@-t
- $(srcdir)/generate-protostrings.sh > $@-t
+ $(builddir)/generate-protostrings.sh > $@-t
mv $@-t $@
chmod 0444 $@
--
2.37.3
Eric Blake
2022-Oct-20 20:32 UTC
[Libguestfs] [nbdkit PATCH 03/10] mingw: Avoid broken gnutls/socket.h header
gnutls 3.7.7 ships with a <gnutls/socket.h> that fails to compile on
mingw: https://gitlab.com/gnutls/gnutls/-/issues/1382. But it also
provides a stub function gnutls_transport_is_ktls_enabled that always
returns false (since ktls is a Linux-only thing for now). As such, we
are hitting compilation errors such as:
In file included from ../../server/crypto.c:59:
/usr/x86_64-w64-mingw32/sys-root/mingw/include/gnutls/socket.h:32:10: fatal
error: sys/socket.h: No such file or directory
32 | #include <sys/socket.h>
| ^~~~~~~~~~~~~~
compilation terminated.
unless we also probe for whether the header works. Noticed ever since
commit c4bc6d07 moved to newer lcitool that upgraded our CI mingw
environments into using the newer broken version of gnutls.
---
configure.ac | 1 +
server/crypto.c | 12 +++++++++---
2 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/configure.ac b/configure.ac
index dc9ff94f..d506fb51 100644
--- a/configure.ac
+++ b/configure.ac
@@ -646,6 +646,7 @@ AS_IF([test "x$GNUTLS_LIBS" != "x"],[
gnutls_srp_server_get_username \
gnutls_transport_is_ktls_enabled \
])
+ AC_CHECK_HEADERS([gnutls/socket.h])
LIBS="$old_LIBS"
dnl macOS has its own program called certtool and packages the
diff --git a/server/crypto.c b/server/crypto.c
index 070fcc55..1f605083 100644
--- a/server/crypto.c
+++ b/server/crypto.c
@@ -55,7 +55,13 @@
#include <gnutls/gnutls.h>
#include <gnutls/x509.h>
-#ifdef HAVE_GNUTLS_TRANSPORT_IS_KTLS_ENABLED
+#if defined HAVE_GNUTLS_TRANSPORT_IS_KTLS_ENABLED && \
+ defined HAVE_GNUTLS_SOCKET_H
+#define TRY_KTLS 1
+#else
+#define TRY_KTLS 0
+#endif
+#if TRY_KTLS
#include <gnutls/socket.h>
#endif
@@ -542,7 +548,7 @@ debug_session (gnutls_session_t session)
bool dhe = false, ecdh = false;
int grp;
const char *desc, *username, *hint;
-#ifdef HAVE_GNUTLS_TRANSPORT_IS_KTLS_ENABLED
+#if TRY_KTLS
gnutls_transport_ktls_enable_flags_t ktls_enabled;
#endif
@@ -552,7 +558,7 @@ debug_session (gnutls_session_t session)
desc = gnutls_session_get_desc (session);
if (desc) nbdkit_debug ("TLS session: %s", desc);
-#ifdef HAVE_GNUTLS_TRANSPORT_IS_KTLS_ENABLED
+#if TRY_KTLS
ktls_enabled = gnutls_transport_is_ktls_enabled (session);
switch (ktls_enabled) {
case GNUTLS_KTLS_RECV:
--
2.37.3
Eric Blake
2022-Oct-20 20:32 UTC
[Libguestfs] [nbdkit PATCH 04/10] build: Fix VPATH build when nbdkit not installed
Even when nbdkit is previously installed, we want to make sure we are
using the in-tree nbdkit-version.h, and not the pre-installed one.
Noticed when a native VPATH build succeeded but a mingw cross-build
failed with:
In file included from ../../../include/nbdkit-plugin.h:38,
from ../../../common/utils/environ.c:40:
../../../include/nbdkit-common.h:51:10: fatal error: nbdkit-version.h: No such
file or directory
51 | #include <nbdkit-version.h>
| ^~~~~~~~~~~~~~~~~~
compilation terminated.
We don't (currently) have a VPATH CI job, and even if we did, we may
not have spotted this as easily, as lcitool likes to prepopulate the
build containers with the distro's prebuilt nbdkit when possible.
At any rate, nbdkit-version.h is generated, so for a VPATH build to
find it, we must also include relative to builddir.
Fixes: 0c75ccde ("include: Expose nbdkit version information to
public", v1.15.1)
---
common/allocators/Makefile.am | 3 ++-
common/bitmap/Makefile.am | 3 ++-
common/regions/Makefile.am | 3 ++-
common/utils/Makefile.am | 3 ++-
filters/blocksize-policy/Makefile.am | 5 ++--
filters/blocksize/Makefile.am | 3 ++-
filters/cache/Makefile.am | 1 +
filters/cacheextents/Makefile.am | 3 ++-
filters/checkwrite/Makefile.am | 3 ++-
filters/cow/Makefile.am | 3 ++-
filters/ddrescue/Makefile.am | 3 ++-
filters/delay/Makefile.am | 3 ++-
filters/error/Makefile.am | 3 ++-
filters/exitlast/Makefile.am | 7 ++++--
filters/exitwhen/Makefile.am | 5 ++--
filters/exportname/Makefile.am | 3 ++-
filters/ext2/Makefile.am | 5 ++--
filters/extentlist/Makefile.am | 3 ++-
filters/fua/Makefile.am | 3 ++-
filters/gzip/Makefile.am | 3 ++-
filters/ip/Makefile.am | 3 ++-
filters/limit/Makefile.am | 5 ++--
filters/log/Makefile.am | 5 ++--
filters/luks/Makefile.am | 1 +
filters/multi-conn/Makefile.am | 3 ++-
filters/nocache/Makefile.am | 3 ++-
filters/noextents/Makefile.am | 3 ++-
filters/nofilter/Makefile.am | 3 ++-
filters/noparallel/Makefile.am | 3 ++-
filters/nozero/Makefile.am | 3 ++-
filters/offset/Makefile.am | 5 ++--
filters/partition/Makefile.am | 3 ++-
filters/pause/Makefile.am | 3 ++-
filters/protect/Makefile.am | 3 ++-
filters/rate/Makefile.am | 3 ++-
filters/readahead/Makefile.am | 3 ++-
filters/retry-request/Makefile.am | 3 ++-
filters/retry/Makefile.am | 3 ++-
filters/scan/Makefile.am | 3 ++-
filters/stats/Makefile.am | 3 ++-
filters/swab/Makefile.am | 3 ++-
filters/tar/Makefile.am | 3 ++-
filters/tls-fallback/Makefile.am | 3 ++-
filters/truncate/Makefile.am | 3 ++-
filters/xz/Makefile.am | 5 ++--
plugins/cc/Makefile.am | 5 ++--
plugins/cdi/Makefile.am | 5 ++--
plugins/curl/Makefile.am | 3 ++-
plugins/data/Makefile.am | 3 ++-
plugins/eval/Makefile.am | 5 ++--
plugins/example1/Makefile.am | 3 ++-
plugins/example2/Makefile.am | 3 ++-
plugins/example3/Makefile.am | 3 ++-
plugins/file/Makefile.am | 3 ++-
plugins/floppy/Makefile.am | 3 ++-
plugins/full/Makefile.am | 3 ++-
plugins/guestfs/Makefile.am | 3 ++-
plugins/info/Makefile.am | 3 ++-
plugins/iso/Makefile.am | 5 ++--
plugins/libvirt/Makefile.am | 3 ++-
plugins/linuxdisk/Makefile.am | 5 ++--
plugins/lua/Makefile.am | 3 ++-
plugins/memory/Makefile.am | 5 ++--
plugins/nbd/Makefile.am | 3 ++-
plugins/null/Makefile.am | 3 ++-
plugins/ocaml/Makefile.am | 3 ++-
plugins/ondemand/Makefile.am | 5 ++--
plugins/partitioning/Makefile.am | 3 ++-
plugins/pattern/Makefile.am | 3 ++-
plugins/perl/Makefile.am | 5 ++--
plugins/python/Makefile.am | 5 ++--
plugins/random/Makefile.am | 5 ++--
plugins/ruby/Makefile.am | 3 ++-
plugins/sh/Makefile.am | 3 ++-
plugins/sparse-random/Makefile.am | 5 ++--
plugins/split/Makefile.am | 5 ++--
plugins/ssh/Makefile.am | 3 ++-
plugins/tcl/Makefile.am | 3 ++-
plugins/tmpdisk/Makefile.am | 5 ++--
plugins/torrent/Makefile.am | 5 ++--
plugins/vddk/Makefile.am | 3 ++-
plugins/zero/Makefile.am | 6 +++--
server/Makefile.am | 4 ++-
tests/Makefile.am | 37 +++++++++++++++++++++++-----
84 files changed, 222 insertions(+), 110 deletions(-)
diff --git a/common/allocators/Makefile.am b/common/allocators/Makefile.am
index e130101a..e797d72c 100644
--- a/common/allocators/Makefile.am
+++ b/common/allocators/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2020 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -43,6 +43,7 @@ liballocators_la_SOURCES = \
$(NULL)
liballocators_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
diff --git a/common/bitmap/Makefile.am b/common/bitmap/Makefile.am
index 3d397982..6c752f5d 100644
--- a/common/bitmap/Makefile.am
+++ b/common/bitmap/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -39,6 +39,7 @@ libbitmap_la_SOURCES = \
$(NULL)
libbitmap_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
$(NULL)
libbitmap_la_CFLAGS = $(WARNINGS_CFLAGS)
diff --git a/common/regions/Makefile.am b/common/regions/Makefile.am
index 796bb957..7927e462 100644
--- a/common/regions/Makefile.am
+++ b/common/regions/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -39,6 +39,7 @@ libregions_la_SOURCES = \
$(NULL)
libregions_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/common/utils/Makefile.am b/common/utils/Makefile.am
index 5b3b901f..c53a4416 100644
--- a/common/utils/Makefile.am
+++ b/common/utils/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -57,6 +57,7 @@ libutils_la_SOURCES = \
$(NULL)
libutils_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
$(NULL)
diff --git a/filters/blocksize-policy/Makefile.am
b/filters/blocksize-policy/Makefile.am
index 62700b86..eb6e7ae0 100644
--- a/filters/blocksize-policy/Makefile.am
+++ b/filters/blocksize-policy/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -41,9 +41,10 @@ nbdkit_blocksize_policy_filter_la_SOURCES = \
$(NULL)
nbdkit_blocksize_policy_filter_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_blocksize_policy_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_blocksize_policy_filter_la_LDFLAGS = \
diff --git a/filters/blocksize/Makefile.am b/filters/blocksize/Makefile.am
index 577ff7a2..5de4a0a8 100644
--- a/filters/blocksize/Makefile.am
+++ b/filters/blocksize/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_blocksize_filter_la_SOURCES = \
nbdkit_blocksize_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/cache/Makefile.am b/filters/cache/Makefile.am
index 0aa5d746..27336214 100644
--- a/filters/cache/Makefile.am
+++ b/filters/cache/Makefile.am
@@ -53,6 +53,7 @@ nbdkit_cache_filter_la_SOURCES = \
nbdkit_cache_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/bitmap \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
diff --git a/filters/cacheextents/Makefile.am b/filters/cacheextents/Makefile.am
index dda85d3b..85638315 100644
--- a/filters/cacheextents/Makefile.am
+++ b/filters/cacheextents/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_cacheextents_filter_la_SOURCES = \
nbdkit_cacheextents_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/checkwrite/Makefile.am b/filters/checkwrite/Makefile.am
index 0f6a2b1e..53762866 100644
--- a/filters/checkwrite/Makefile.am
+++ b/filters/checkwrite/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_checkwrite_filter_la_SOURCES = \
nbdkit_checkwrite_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/cow/Makefile.am b/filters/cow/Makefile.am
index aecbc9ef..6765eb64 100644
--- a/filters/cow/Makefile.am
+++ b/filters/cow/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -45,6 +45,7 @@ nbdkit_cow_filter_la_SOURCES = \
nbdkit_cow_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/bitmap \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
diff --git a/filters/ddrescue/Makefile.am b/filters/ddrescue/Makefile.am
index d1999220..bb294a6e 100644
--- a/filters/ddrescue/Makefile.am
+++ b/filters/ddrescue/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,6 +44,7 @@ nbdkit_ddrescue_filter_la_SOURCES = \
nbdkit_ddrescue_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
diff --git a/filters/delay/Makefile.am b/filters/delay/Makefile.am
index 312d644c..01f77e9e 100644
--- a/filters/delay/Makefile.am
+++ b/filters/delay/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_delay_filter_la_SOURCES = \
nbdkit_delay_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
nbdkit_delay_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_delay_filter_la_LIBADD = \
diff --git a/filters/error/Makefile.am b/filters/error/Makefile.am
index 54ced29f..375cdc6b 100644
--- a/filters/error/Makefile.am
+++ b/filters/error/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_error_filter_la_SOURCES = \
nbdkit_error_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/exitlast/Makefile.am b/filters/exitlast/Makefile.am
index 205b032a..b3bf0ddd 100644
--- a/filters/exitlast/Makefile.am
+++ b/filters/exitlast/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -40,7 +40,10 @@ nbdkit_exitlast_filter_la_SOURCES = \
$(top_srcdir)/include/nbdkit-filter.h \
$(NULL)
-nbdkit_exitlast_filter_la_CPPFLAGS = -I$(top_srcdir)/include
+nbdkit_exitlast_filter_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
+ $(NULL)
nbdkit_exitlast_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_exitlast_filter_la_LIBADD = \
$(IMPORT_LIBRARY_ON_WINDOWS) \
diff --git a/filters/exitwhen/Makefile.am b/filters/exitwhen/Makefile.am
index 39a944ea..ab2cb47e 100644
--- a/filters/exitwhen/Makefile.am
+++ b/filters/exitwhen/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -41,10 +41,11 @@ nbdkit_exitwhen_filter_la_SOURCES = \
$(NULL)
nbdkit_exitwhen_filter_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_exitwhen_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_exitwhen_filter_la_LIBADD = \
diff --git a/filters/exportname/Makefile.am b/filters/exportname/Makefile.am
index e6a2a4b1..21d04391 100644
--- a/filters/exportname/Makefile.am
+++ b/filters/exportname/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_exportname_filter_la_SOURCES = \
nbdkit_exportname_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
diff --git a/filters/ext2/Makefile.am b/filters/ext2/Makefile.am
index 0993d2af..9ed17439 100644
--- a/filters/ext2/Makefile.am
+++ b/filters/ext2/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -45,9 +45,10 @@ nbdkit_ext2_filter_la_SOURCES = \
$(NULL)
nbdkit_ext2_filter_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_ext2_filter_la_CFLAGS = \
$(WARNINGS_CFLAGS) \
diff --git a/filters/extentlist/Makefile.am b/filters/extentlist/Makefile.am
index 2975ee4b..2df21db8 100644
--- a/filters/extentlist/Makefile.am
+++ b/filters/extentlist/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_extentlist_filter_la_SOURCES = \
nbdkit_extentlist_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
diff --git a/filters/fua/Makefile.am b/filters/fua/Makefile.am
index c642a688..d8ea5a3e 100644
--- a/filters/fua/Makefile.am
+++ b/filters/fua/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_fua_filter_la_SOURCES = \
nbdkit_fua_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
nbdkit_fua_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_fua_filter_la_LIBADD = \
diff --git a/filters/gzip/Makefile.am b/filters/gzip/Makefile.am
index b5761e2f..fd6f8cae 100644
--- a/filters/gzip/Makefile.am
+++ b/filters/gzip/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,6 +44,7 @@ nbdkit_gzip_filter_la_SOURCES = \
nbdkit_gzip_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
diff --git a/filters/ip/Makefile.am b/filters/ip/Makefile.am
index 49d40ca5..28a69883 100644
--- a/filters/ip/Makefile.am
+++ b/filters/ip/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_ip_filter_la_SOURCES = \
nbdkit_ip_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/limit/Makefile.am b/filters/limit/Makefile.am
index f01c1693..39b08cdc 100644
--- a/filters/limit/Makefile.am
+++ b/filters/limit/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -41,9 +41,10 @@ nbdkit_limit_filter_la_SOURCES = \
$(NULL)
nbdkit_limit_filter_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_limit_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_limit_filter_la_LDFLAGS = \
diff --git a/filters/log/Makefile.am b/filters/log/Makefile.am
index f5956809..0604c3a2 100644
--- a/filters/log/Makefile.am
+++ b/filters/log/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -46,9 +46,10 @@ nbdkit_log_filter_la_SOURCES = \
$(NULL)
nbdkit_log_filter_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_log_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_log_filter_la_LDFLAGS = \
diff --git a/filters/luks/Makefile.am b/filters/luks/Makefile.am
index 14253f12..dc4d6876 100644
--- a/filters/luks/Makefile.am
+++ b/filters/luks/Makefile.am
@@ -46,6 +46,7 @@ nbdkit_luks_filter_la_SOURCES = \
nbdkit_luks_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
diff --git a/filters/multi-conn/Makefile.am b/filters/multi-conn/Makefile.am
index 27d572ec..9aa18452 100644
--- a/filters/multi-conn/Makefile.am
+++ b/filters/multi-conn/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2021 Red Hat Inc.
+# Copyright (C) 2021, 2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_multi_conn_filter_la_SOURCES = \
nbdkit_multi_conn_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/nocache/Makefile.am b/filters/nocache/Makefile.am
index b83ace8e..cd982245 100644
--- a/filters/nocache/Makefile.am
+++ b/filters/nocache/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_nocache_filter_la_SOURCES = \
nbdkit_nocache_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
$(NULL)
nbdkit_nocache_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
diff --git a/filters/noextents/Makefile.am b/filters/noextents/Makefile.am
index 897bfc41..405db78e 100644
--- a/filters/noextents/Makefile.am
+++ b/filters/noextents/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_noextents_filter_la_SOURCES = \
nbdkit_noextents_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
nbdkit_noextents_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_noextents_filter_la_LIBADD = \
diff --git a/filters/nofilter/Makefile.am b/filters/nofilter/Makefile.am
index f4c2cfcf..c365cb10 100644
--- a/filters/nofilter/Makefile.am
+++ b/filters/nofilter/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_nofilter_filter_la_SOURCES = \
nbdkit_nofilter_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
$(NULL)
nbdkit_nofilter_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
diff --git a/filters/noparallel/Makefile.am b/filters/noparallel/Makefile.am
index 3740c797..6b6fac8d 100644
--- a/filters/noparallel/Makefile.am
+++ b/filters/noparallel/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_noparallel_filter_la_SOURCES = \
nbdkit_noparallel_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
$(NULL)
nbdkit_noparallel_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
diff --git a/filters/nozero/Makefile.am b/filters/nozero/Makefile.am
index 0cdef2be..75e4cdb0 100644
--- a/filters/nozero/Makefile.am
+++ b/filters/nozero/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_nozero_filter_la_SOURCES = \
nbdkit_nozero_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
$(NULL)
nbdkit_nozero_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
diff --git a/filters/offset/Makefile.am b/filters/offset/Makefile.am
index dcb65322..22b62bb2 100644
--- a/filters/offset/Makefile.am
+++ b/filters/offset/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -41,9 +41,10 @@ nbdkit_offset_filter_la_SOURCES = \
$(NULL)
nbdkit_offset_filter_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_offset_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_offset_filter_la_LDFLAGS = \
diff --git a/filters/partition/Makefile.am b/filters/partition/Makefile.am
index 48626a91..f14c641d 100644
--- a/filters/partition/Makefile.am
+++ b/filters/partition/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -45,6 +45,7 @@ nbdkit_partition_filter_la_SOURCES = \
nbdkit_partition_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/gpt \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
diff --git a/filters/pause/Makefile.am b/filters/pause/Makefile.am
index 0279e1ed..0cd08820 100644
--- a/filters/pause/Makefile.am
+++ b/filters/pause/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -45,6 +45,7 @@ nbdkit_pause_filter_la_SOURCES = \
nbdkit_pause_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/protect/Makefile.am b/filters/protect/Makefile.am
index 8964c6b1..b65ba69f 100644
--- a/filters/protect/Makefile.am
+++ b/filters/protect/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_protect_filter_la_SOURCES = \
nbdkit_protect_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/regions \
-I$(top_srcdir)/common/replacements \
diff --git a/filters/rate/Makefile.am b/filters/rate/Makefile.am
index d37afe5e..25471ebc 100644
--- a/filters/rate/Makefile.am
+++ b/filters/rate/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,6 +44,7 @@ nbdkit_rate_filter_la_SOURCES = \
nbdkit_rate_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
diff --git a/filters/readahead/Makefile.am b/filters/readahead/Makefile.am
index 2591eb84..9f2f95e0 100644
--- a/filters/readahead/Makefile.am
+++ b/filters/readahead/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,6 +44,7 @@ nbdkit_readahead_filter_la_SOURCES = \
nbdkit_readahead_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/retry-request/Makefile.am
b/filters/retry-request/Makefile.am
index cbc43884..bb0b728f 100644
--- a/filters/retry-request/Makefile.am
+++ b/filters/retry-request/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_retry_request_filter_la_SOURCES = \
nbdkit_retry_request_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/retry/Makefile.am b/filters/retry/Makefile.am
index 257084a2..abe36848 100644
--- a/filters/retry/Makefile.am
+++ b/filters/retry/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_retry_filter_la_SOURCES = \
nbdkit_retry_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/scan/Makefile.am b/filters/scan/Makefile.am
index 341d1830..f271c372 100644
--- a/filters/scan/Makefile.am
+++ b/filters/scan/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,6 +44,7 @@ nbdkit_scan_filter_la_SOURCES = \
nbdkit_scan_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/stats/Makefile.am b/filters/stats/Makefile.am
index cbf260a6..226ec9ea 100644
--- a/filters/stats/Makefile.am
+++ b/filters/stats/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,6 +44,7 @@ nbdkit_stats_filter_la_SOURCES = \
nbdkit_stats_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/swab/Makefile.am b/filters/swab/Makefile.am
index cc51a382..cb96bccc 100644
--- a/filters/swab/Makefile.am
+++ b/filters/swab/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,6 +44,7 @@ nbdkit_swab_filter_la_SOURCES = \
nbdkit_swab_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/tar/Makefile.am b/filters/tar/Makefile.am
index 2def9a67..1dca8881 100644
--- a/filters/tar/Makefile.am
+++ b/filters/tar/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -45,6 +45,7 @@ nbdkit_tar_filter_la_SOURCES = \
nbdkit_tar_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
diff --git a/filters/tls-fallback/Makefile.am b/filters/tls-fallback/Makefile.am
index ff4f5c53..f887330d 100644
--- a/filters/tls-fallback/Makefile.am
+++ b/filters/tls-fallback/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2020-2021 Red Hat Inc.
+# Copyright (C) 2020-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_tls_fallback_filter_la_SOURCES = \
nbdkit_tls_fallback_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
$(NULL)
nbdkit_tls_fallback_filter_la_CFLAGS = $(WARNINGS_CFLAGS)
diff --git a/filters/truncate/Makefile.am b/filters/truncate/Makefile.am
index fad2be32..7e6ef8b0 100644
--- a/filters/truncate/Makefile.am
+++ b/filters/truncate/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_truncate_filter_la_SOURCES = \
nbdkit_truncate_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/filters/xz/Makefile.am b/filters/xz/Makefile.am
index b1680f47..3ba63e8c 100644
--- a/filters/xz/Makefile.am
+++ b/filters/xz/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2013-2021 Red Hat Inc.
+# Copyright (C) 2013-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -47,9 +47,10 @@ nbdkit_xz_filter_la_SOURCES = \
$(NULL)
nbdkit_xz_filter_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_xz_filter_la_CFLAGS = \
$(WARNINGS_CFLAGS) \
diff --git a/plugins/cc/Makefile.am b/plugins/cc/Makefile.am
index 42113939..1015151c 100644
--- a/plugins/cc/Makefile.am
+++ b/plugins/cc/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -47,9 +47,10 @@ nbdkit_cc_plugin_la_SOURCES = \
nbdkit_cc_plugin_la_CPPFLAGS = \
-DCC="\"$(CC)\"" \
-DCFLAGS="\"$(CFLAGS)\"" \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
-I. \
$(NULL)
nbdkit_cc_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
diff --git a/plugins/cdi/Makefile.am b/plugins/cdi/Makefile.am
index 099555ad..7c96f8b3 100644
--- a/plugins/cdi/Makefile.am
+++ b/plugins/cdi/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,9 +44,10 @@ nbdkit_cdi_plugin_la_SOURCES = \
$(NULL)
nbdkit_cdi_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
-I. \
$(NULL)
nbdkit_cdi_plugin_la_CFLAGS = \
diff --git a/plugins/curl/Makefile.am b/plugins/curl/Makefile.am
index a016f98e..f08923e7 100644
--- a/plugins/curl/Makefile.am
+++ b/plugins/curl/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2014-2021 Red Hat Inc.
+# Copyright (C) 2014-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -46,6 +46,7 @@ nbdkit_curl_plugin_la_SOURCES = \
nbdkit_curl_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
diff --git a/plugins/data/Makefile.am b/plugins/data/Makefile.am
index 842324e6..2db904cf 100644
--- a/plugins/data/Makefile.am
+++ b/plugins/data/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -48,6 +48,7 @@ nbdkit_data_plugin_la_SOURCES = \
nbdkit_data_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/allocators \
-I$(top_srcdir)/common/replacements \
diff --git a/plugins/eval/Makefile.am b/plugins/eval/Makefile.am
index d65f8198..5038a4c3 100644
--- a/plugins/eval/Makefile.am
+++ b/plugins/eval/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -60,8 +60,9 @@ nbdkit_eval_plugin_la_SOURCES = \
$(top_srcdir)/include/nbdkit-plugin.h \
$(NULL)
nbdkit_eval_plugin_la_CPPFLAGS = \
- -I$(top_srcdir)/plugins/sh \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
+ -I$(top_srcdir)/plugins/sh \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/plugins/example1/Makefile.am b/plugins/example1/Makefile.am
index 82e0225e..a50c863d 100644
--- a/plugins/example1/Makefile.am
+++ b/plugins/example1/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2013-2021 Red Hat Inc.
+# Copyright (C) 2013-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_example1_plugin_la_SOURCES = \
nbdkit_example1_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
nbdkit_example1_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_example1_plugin_la_LIBADD = \
diff --git a/plugins/example2/Makefile.am b/plugins/example2/Makefile.am
index ecd3a03e..e1739a08 100644
--- a/plugins/example2/Makefile.am
+++ b/plugins/example2/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2013-2021 Red Hat Inc.
+# Copyright (C) 2013-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -46,6 +46,7 @@ endif
nbdkit_example2_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
nbdkit_example2_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_example2_plugin_la_LIBADD = \
diff --git a/plugins/example3/Makefile.am b/plugins/example3/Makefile.am
index a136edc4..1c1baf1b 100644
--- a/plugins/example3/Makefile.am
+++ b/plugins/example3/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2013-2021 Red Hat Inc.
+# Copyright (C) 2013-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -47,6 +47,7 @@ nbdkit_example3_plugin_la_SOURCES = \
nbdkit_example3_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
nbdkit_example3_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_example3_plugin_la_LIBADD = \
diff --git a/plugins/file/Makefile.am b/plugins/file/Makefile.am
index 9037b3d2..286aa9f5 100644
--- a/plugins/file/Makefile.am
+++ b/plugins/file/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2013-2021 Red Hat Inc.
+# Copyright (C) 2013-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,6 +44,7 @@ endif
nbdkit_file_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
diff --git a/plugins/floppy/Makefile.am b/plugins/floppy/Makefile.am
index 134424f5..51e500cd 100644
--- a/plugins/floppy/Makefile.am
+++ b/plugins/floppy/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -47,6 +47,7 @@ nbdkit_floppy_plugin_la_SOURCES = \
nbdkit_floppy_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/regions \
-I$(top_srcdir)/common/replacements \
diff --git a/plugins/full/Makefile.am b/plugins/full/Makefile.am
index 7eb1a944..8fea2464 100644
--- a/plugins/full/Makefile.am
+++ b/plugins/full/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_full_plugin_la_SOURCES = \
nbdkit_full_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
nbdkit_full_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_full_plugin_la_LIBADD = \
diff --git a/plugins/guestfs/Makefile.am b/plugins/guestfs/Makefile.am
index 68577d1a..86ae56b2 100644
--- a/plugins/guestfs/Makefile.am
+++ b/plugins/guestfs/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2013-2021 Red Hat Inc.
+# Copyright (C) 2013-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,6 +44,7 @@ nbdkit_guestfs_plugin_la_SOURCES = \
nbdkit_guestfs_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/plugins/info/Makefile.am b/plugins/info/Makefile.am
index 2689e01a..aa1de051 100644
--- a/plugins/info/Makefile.am
+++ b/plugins/info/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_info_plugin_la_SOURCES = \
nbdkit_info_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
$(NULL)
nbdkit_info_plugin_la_CFLAGS = \
diff --git a/plugins/iso/Makefile.am b/plugins/iso/Makefile.am
index c2784b33..bca0c95a 100644
--- a/plugins/iso/Makefile.am
+++ b/plugins/iso/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -46,9 +46,10 @@ nbdkit_iso_plugin_la_SOURCES = \
$(NULL)
nbdkit_iso_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
-I. \
$(NULL)
nbdkit_iso_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
diff --git a/plugins/libvirt/Makefile.am b/plugins/libvirt/Makefile.am
index d0c65c31..bd8acbf6 100644
--- a/plugins/libvirt/Makefile.am
+++ b/plugins/libvirt/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2013-2021 Red Hat Inc.
+# Copyright (C) 2013-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,6 +44,7 @@ nbdkit_libvirt_plugin_la_SOURCES = \
nbdkit_libvirt_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
nbdkit_libvirt_plugin_la_CFLAGS = \
$(WARNINGS_CFLAGS) \
diff --git a/plugins/linuxdisk/Makefile.am b/plugins/linuxdisk/Makefile.am
index 08396e11..015152e6 100644
--- a/plugins/linuxdisk/Makefile.am
+++ b/plugins/linuxdisk/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019-2021 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -51,11 +51,12 @@ nbdkit_linuxdisk_plugin_la_SOURCES = \
$(NULL)
nbdkit_linuxdisk_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/gpt \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/regions \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_linuxdisk_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_linuxdisk_plugin_la_LIBADD = \
diff --git a/plugins/lua/Makefile.am b/plugins/lua/Makefile.am
index 5982a08c..f0e12b8c 100644
--- a/plugins/lua/Makefile.am
+++ b/plugins/lua/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -47,6 +47,7 @@ nbdkit_lua_plugin_la_SOURCES = \
nbdkit_lua_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
nbdkit_lua_plugin_la_CFLAGS = \
$(WARNINGS_CFLAGS) \
diff --git a/plugins/memory/Makefile.am b/plugins/memory/Makefile.am
index 4c6ab620..f56faf06 100644
--- a/plugins/memory/Makefile.am
+++ b/plugins/memory/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -41,11 +41,12 @@ nbdkit_memory_plugin_la_SOURCES = \
$(NULL)
nbdkit_memory_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/allocators \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_memory_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_memory_plugin_la_LDFLAGS = \
diff --git a/plugins/nbd/Makefile.am b/plugins/nbd/Makefile.am
index 4c4f4174..30d61c82 100644
--- a/plugins/nbd/Makefile.am
+++ b/plugins/nbd/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,6 +44,7 @@ nbdkit_nbd_plugin_la_SOURCES = \
nbdkit_nbd_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
-I$(top_srcdir)/server \
diff --git a/plugins/null/Makefile.am b/plugins/null/Makefile.am
index 2541c418..da82d06e 100644
--- a/plugins/null/Makefile.am
+++ b/plugins/null/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_null_plugin_la_SOURCES = \
nbdkit_null_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
nbdkit_null_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_null_plugin_la_LIBADD = \
diff --git a/plugins/ocaml/Makefile.am b/plugins/ocaml/Makefile.am
index 05624176..48c7539b 100644
--- a/plugins/ocaml/Makefile.am
+++ b/plugins/ocaml/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2014-2021 Red Hat Inc.
+# Copyright (C) 2014-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -69,6 +69,7 @@ libnbdkitocaml_la_SOURCES = \
libnbdkitocaml_la_CPPFLAGS = \
-I$(OCAMLLIB) \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-DCAML_NAME_SPACE \
$(NULL)
diff --git a/plugins/ondemand/Makefile.am b/plugins/ondemand/Makefile.am
index 5019e62d..18d85e83 100644
--- a/plugins/ondemand/Makefile.am
+++ b/plugins/ondemand/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -64,10 +64,11 @@ nbdkit_ondemand_plugin_la_SOURCES = \
$(NULL)
nbdkit_ondemand_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_ondemand_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_ondemand_plugin_la_LDFLAGS = \
diff --git a/plugins/partitioning/Makefile.am b/plugins/partitioning/Makefile.am
index fc75b020..e7a254e3 100644
--- a/plugins/partitioning/Makefile.am
+++ b/plugins/partitioning/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -46,6 +46,7 @@ nbdkit_partitioning_plugin_la_SOURCES = \
nbdkit_partitioning_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/gpt \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/regions \
diff --git a/plugins/pattern/Makefile.am b/plugins/pattern/Makefile.am
index 8915a41b..c4a0406f 100644
--- a/plugins/pattern/Makefile.am
+++ b/plugins/pattern/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -42,6 +42,7 @@ nbdkit_pattern_plugin_la_SOURCES = \
nbdkit_pattern_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
$(NULL)
nbdkit_pattern_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
diff --git a/plugins/perl/Makefile.am b/plugins/perl/Makefile.am
index 61594cf1..82a6cfc5 100644
--- a/plugins/perl/Makefile.am
+++ b/plugins/perl/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2013-2021 Red Hat Inc.
+# Copyright (C) 2013-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -46,9 +46,10 @@ nbdkit_perl_plugin_la_SOURCES = \
$(NULL)
nbdkit_perl_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_perl_plugin_la_CFLAGS = \
$(WARNINGS_CFLAGS) \
diff --git a/plugins/python/Makefile.am b/plugins/python/Makefile.am
index bc35bc1f..4973ddad 100644
--- a/plugins/python/Makefile.am
+++ b/plugins/python/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2013-2021 Red Hat Inc.
+# Copyright (C) 2013-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -54,9 +54,10 @@ nbdkit_python_plugin_la_SOURCES = \
$(NULL)
nbdkit_python_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_python_plugin_la_CFLAGS = \
diff --git a/plugins/random/Makefile.am b/plugins/random/Makefile.am
index b5954d02..3ce53422 100644
--- a/plugins/random/Makefile.am
+++ b/plugins/random/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -41,9 +41,10 @@ nbdkit_random_plugin_la_SOURCES = \
$(NULL)
nbdkit_random_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_random_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_random_plugin_la_LIBADD = \
diff --git a/plugins/ruby/Makefile.am b/plugins/ruby/Makefile.am
index a6f687ac..becca09e 100644
--- a/plugins/ruby/Makefile.am
+++ b/plugins/ruby/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2013-2021 Red Hat Inc.
+# Copyright (C) 2013-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -47,6 +47,7 @@ nbdkit_ruby_plugin_la_SOURCES = \
nbdkit_ruby_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
$(NULL)
nbdkit_ruby_plugin_la_CFLAGS = \
diff --git a/plugins/sh/Makefile.am b/plugins/sh/Makefile.am
index 6c368efa..46b950b4 100644
--- a/plugins/sh/Makefile.am
+++ b/plugins/sh/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -53,6 +53,7 @@ nbdkit_sh_plugin_la_SOURCES = \
nbdkit_sh_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/plugins/sparse-random/Makefile.am
b/plugins/sparse-random/Makefile.am
index 5756f06e..0ef61cc2 100644
--- a/plugins/sparse-random/Makefile.am
+++ b/plugins/sparse-random/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -41,10 +41,11 @@ nbdkit_sparse_random_plugin_la_SOURCES = \
$(NULL)
nbdkit_sparse_random_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/bitmap \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_sparse_random_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_sparse_random_plugin_la_LIBADD = \
diff --git a/plugins/split/Makefile.am b/plugins/split/Makefile.am
index 200c8d79..c13ef8fe 100644
--- a/plugins/split/Makefile.am
+++ b/plugins/split/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -41,10 +41,11 @@ nbdkit_split_plugin_la_SOURCES = \
$(NULL)
nbdkit_split_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_split_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_split_plugin_la_LDFLAGS = \
diff --git a/plugins/ssh/Makefile.am b/plugins/ssh/Makefile.am
index ee0887f5..69f86d5b 100644
--- a/plugins/ssh/Makefile.am
+++ b/plugins/ssh/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2014-2021 Red Hat Inc.
+# Copyright (C) 2014-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,6 +44,7 @@ nbdkit_ssh_plugin_la_SOURCES = \
nbdkit_ssh_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
$(NULL)
diff --git a/plugins/tcl/Makefile.am b/plugins/tcl/Makefile.am
index b3bc23e9..1b9289af 100644
--- a/plugins/tcl/Makefile.am
+++ b/plugins/tcl/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -47,6 +47,7 @@ nbdkit_tcl_plugin_la_SOURCES = \
nbdkit_tcl_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
nbdkit_tcl_plugin_la_CFLAGS = \
$(WARNINGS_CFLAGS) \
diff --git a/plugins/tmpdisk/Makefile.am b/plugins/tmpdisk/Makefile.am
index a3f8cc52..a4c3d9b0 100644
--- a/plugins/tmpdisk/Makefile.am
+++ b/plugins/tmpdisk/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -59,9 +59,10 @@ nbdkit_tmpdisk_plugin_la_SOURCES = \
$(NULL)
nbdkit_tmpdisk_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
$(NULL)
nbdkit_tmpdisk_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_tmpdisk_plugin_la_LIBADD = \
diff --git a/plugins/torrent/Makefile.am b/plugins/torrent/Makefile.am
index f62958e4..7fe09b54 100644
--- a/plugins/torrent/Makefile.am
+++ b/plugins/torrent/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2018-2021 Red Hat Inc.
+# Copyright (C) 2018-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -44,9 +44,10 @@ nbdkit_torrent_plugin_la_SOURCES = \
$(NULL)
nbdkit_torrent_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
- -I$(top_srcdir)/include \
-I. \
$(NULL)
nbdkit_torrent_plugin_la_CFLAGS = \
diff --git a/plugins/vddk/Makefile.am b/plugins/vddk/Makefile.am
index 8485bcec..40461f1d 100644
--- a/plugins/vddk/Makefile.am
+++ b/plugins/vddk/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2013-2021 Red Hat Inc.
+# Copyright (C) 2013-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -56,6 +56,7 @@ nbdkit_vddk_plugin_la_SOURCES = \
nbdkit_vddk_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/utils \
-DVDDK_LIBDIR=\"$(libdir)/vmware-vix-disklib\" \
diff --git a/plugins/zero/Makefile.am b/plugins/zero/Makefile.am
index 7d84a889..ab71bc7f 100644
--- a/plugins/zero/Makefile.am
+++ b/plugins/zero/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2017-2021 Red Hat Inc.
+# Copyright (C) 2017-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -41,7 +41,9 @@ nbdkit_zero_plugin_la_SOURCES = \
$(NULL)
nbdkit_zero_plugin_la_CPPFLAGS = \
- -I$(top_srcdir)/include
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
+ $(NULL)
nbdkit_zero_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
nbdkit_zero_plugin_la_LIBADD = \
$(IMPORT_LIBRARY_ON_WINDOWS) \
diff --git a/server/Makefile.am b/server/Makefile.am
index 460a5a09..63c2c34e 100644
--- a/server/Makefile.am
+++ b/server/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2013-2021 Red Hat Inc.
+# Copyright (C) 2013-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -82,6 +82,7 @@ nbdkit_CPPFLAGS = \
-Dsbindir=\"$(sbindir)\" \
-Dsysconfdir=\"$(sysconfdir)\" \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/protocol \
-I$(top_srcdir)/common/replacements \
@@ -168,6 +169,7 @@ test_public_SOURCES = \
$(NULL)
test_public_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/protocol \
-I$(top_srcdir)/common/replacements \
diff --git a/tests/Makefile.am b/tests/Makefile.am
index cea09941..530b22bd 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -337,6 +337,7 @@ test_stdio_plugin_la_SOURCES = \
$(NULL)
test_stdio_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
-I$(top_srcdir)/common/replacements \
$(NULL)
test_stdio_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
@@ -363,7 +364,10 @@ test_flush_plugin_la_SOURCES = \
test-flush-plugin.c \
$(top_srcdir)/include/nbdkit-plugin.h \
$(NULL)
-test_flush_plugin_la_CPPFLAGS = -I$(top_srcdir)/include
+test_flush_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
+ $(NULL)
test_flush_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
# For use of the -rpath option, see:
# https://lists.gnu.org/archive/html/libtool/2007-07/msg00067.html
@@ -383,7 +387,10 @@ test_shutdown_plugin_la_SOURCES = \
test-shutdown-plugin.c \
$(top_srcdir)/include/nbdkit-plugin.h \
$(NULL)
-test_shutdown_plugin_la_CPPFLAGS = -I$(top_srcdir)/include
+test_shutdown_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
+ $(NULL)
test_shutdown_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
# For use of the -rpath option, see:
# https://lists.gnu.org/archive/html/libtool/2007-07/msg00067.html
@@ -409,6 +416,7 @@ test_just_plugin_header_SOURCES = \
$(NULL)
test_just_plugin_header_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
test_just_plugin_header_CFLAGS = $(WARNINGS_CFLAGS)
@@ -417,6 +425,7 @@ test_just_filter_header_SOURCES = \
$(NULL)
test_just_filter_header_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
test_just_filter_header_CFLAGS = $(WARNINGS_CFLAGS)
@@ -438,6 +447,7 @@ test_ansi_c_plugin_la_SOURCES = \
test_ansi_c_plugin_la_CPPFLAGS = \
-std=c90 -pedantic \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
test_ansi_c_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
# For use of the -rpath option, see:
@@ -464,6 +474,7 @@ test_cxx_plugin_la_SOURCES = \
$(NULL)
test_cxx_plugin_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
test_cxx_plugin_la_CXXFLAGS = $(WARNINGS_CFLAGS)
# For use of the -rpath option, see:
@@ -479,6 +490,7 @@ test_cxx_filter_la_SOURCES = \
$(NULL)
test_cxx_filter_la_CPPFLAGS = \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
test_cxx_filter_la_CXXFLAGS = $(WARNINGS_CFLAGS)
# For use of the -rpath option, see:
@@ -1037,6 +1049,7 @@ libvixDiskLib_la_SOURCES = \
libvixDiskLib_la_CPPFLAGS = \
-I$(top_srcdir)/plugins/vddk \
-I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
$(NULL)
libvixDiskLib_la_CXXFLAGS = $(WARNINGS_CFLAGS)
# For use of the -rpath option, see:
@@ -1348,7 +1361,10 @@ test_layers_plugin_la_SOURCES = \
test-layers-plugin.c \
$(top_srcdir)/include/nbdkit-plugin.h \
$(NULL)
-test_layers_plugin_la_CPPFLAGS = -I$(top_srcdir)/include
+test_layers_plugin_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
+ $(NULL)
test_layers_plugin_la_CFLAGS = $(WARNINGS_CFLAGS)
# For use of the -rpath option, see:
# https://lists.gnu.org/archive/html/libtool/2007-07/msg00067.html
@@ -1361,7 +1377,10 @@ test_layers_filter1_la_SOURCES = \
test-layers-filter.c \
$(top_srcdir)/include/nbdkit-filter.h \
$(NULL)
-test_layers_filter1_la_CPPFLAGS = -I$(top_srcdir)/include
+test_layers_filter1_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
+ $(NULL)
test_layers_filter1_la_CFLAGS = $(WARNINGS_CFLAGS)
-Dlayer='"filter1"'
# For use of the -rpath option, see:
# https://lists.gnu.org/archive/html/libtool/2007-07/msg00067.html
@@ -1374,7 +1393,10 @@ test_layers_filter2_la_SOURCES = \
test-layers-filter.c \
$(top_srcdir)/include/nbdkit-filter.h \
$(NULL)
-test_layers_filter2_la_CPPFLAGS = -I$(top_srcdir)/include
+test_layers_filter2_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
+ $(NULL)
test_layers_filter2_la_CFLAGS = $(WARNINGS_CFLAGS)
-Dlayer='"filter2"'
# For use of the -rpath option, see:
# https://lists.gnu.org/archive/html/libtool/2007-07/msg00067.html
@@ -1387,7 +1409,10 @@ test_layers_filter3_la_SOURCES = \
test-layers-filter.c \
$(top_srcdir)/include/nbdkit-filter.h \
$(NULL)
-test_layers_filter3_la_CPPFLAGS = -I$(top_srcdir)/include
+test_layers_filter3_la_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
+ $(NULL)
test_layers_filter3_la_CFLAGS = $(WARNINGS_CFLAGS)
-Dlayer='"filter3"'
# For use of the -rpath option, see:
# https://lists.gnu.org/archive/html/libtool/2007-07/msg00067.html
--
2.37.3
Eric Blake
2022-Oct-20 20:32 UTC
[Libguestfs] [nbdkit PATCH 05/10] golang: Attempt VPATH builds
I didn't check if Go is still trying to stick other files in $srcdir
('make distcheck' fails for other reasons), but at least with this
patch, it is no longer failing in a VPATH build with:
make[3]: Entering directory
'/home/eblake/nbdkit-tmp/build/plugins/golang'
cd examples/disk && \
PKG_CONFIG_PATH="/home/eblake/nbdkit-tmp/build/server/local${PKG_CONFIG_PATH:+:$PKG_CONFIG_PATH}"
\
go build -o nbdkit-godisk-plugin.so -buildmode=c-shared
/bin/sh: line 1: cd: examples/disk: No such file or directory
Fixes: 1ff44288 ("Add the ability to write plugins in golang."
---
plugins/golang/Makefile.am | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/plugins/golang/Makefile.am b/plugins/golang/Makefile.am
index 781d1812..88bae576 100644
--- a/plugins/golang/Makefile.am
+++ b/plugins/golang/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2020-2021 Red Hat Inc.
+# Copyright (C) 2020-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -70,27 +70,27 @@ noinst_DATA = \
examples/disk/nbdkit-godisk-plugin.so: \
$(plugin_sources) examples/disk/disk.go
- cd examples/disk && \
+ cd $(srcdir)/examples/disk && \
PKG_CONFIG_PATH="$(abs_top_builddir)/server/local$${PKG_CONFIG_PATH:+:$$PKG_CONFIG_PATH}"
\
- $(GOLANG) build -o nbdkit-godisk-plugin.so -buildmode=c-shared
+ $(GOLANG) build -o $(abs_builddir)/examples/disk/nbdkit-godisk-plugin.so
-buildmode=c-shared
examples/dump-plugin/nbdkit-godump-plugin.so: \
$(plugin_sources) examples/dump-plugin/dumpplugin.go
- cd examples/dump-plugin && \
+ cd $(srcdir)/examples/dump-plugin && \
PKG_CONFIG_PATH="$(abs_top_builddir)/server/local$${PKG_CONFIG_PATH:+:$$PKG_CONFIG_PATH}"
\
- $(GOLANG) build -o nbdkit-godump-plugin.so -buildmode=c-shared
+ $(GOLANG) build -o
$(abs_builddir)/examples/dump-plugin/nbdkit-godump-plugin.so -buildmode=c-shared
examples/minimal/nbdkit-gominimal-plugin.so: \
$(plugin_sources) examples/minimal/minimal.go
- cd examples/minimal && \
+ cd $(srcdir)/examples/minimal && \
PKG_CONFIG_PATH="$(abs_top_builddir)/server/local$${PKG_CONFIG_PATH:+:$$PKG_CONFIG_PATH}"
\
- $(GOLANG) build -o nbdkit-gominimal-plugin.so -buildmode=c-shared
+ $(GOLANG) build -o $(abs_builddir)/examples/minimal/nbdkit-gominimal-plugin.so
-buildmode=c-shared
examples/ramdisk/nbdkit-goramdisk-plugin.so: \
$(plugin_sources) examples/ramdisk/ramdisk.go
- cd examples/ramdisk && \
+ cd $(srcdir)/examples/ramdisk && \
PKG_CONFIG_PATH="$(abs_top_builddir)/server/local$${PKG_CONFIG_PATH:+:$$PKG_CONFIG_PATH}"
\
- $(GOLANG) build -o nbdkit-goramdisk-plugin.so -buildmode=c-shared
+ $(GOLANG) build -o $(abs_builddir)/examples/ramdisk/nbdkit-goramdisk-plugin.so
-buildmode=c-shared
# Tests.
TESTS = dump-plugin-examples.sh
--
2.37.3
Eric Blake
2022-Oct-20 20:32 UTC
[Libguestfs] [nbdkit PATCH 06/10] build: Only attempt to build vddk on Linux
When --enable/disable-vddk is not given to configure, our default was
to base on the current architecture. But we know that we are
targeting a .so library built for Linux, so we can also gate things
based on the host OS. And doing so means that vddk is no longer even
attempted on mingw, eliminating the need to explicitly enable/disable
it in our CI recipes.
---
configure.ac | 6 +++---
ci/build.sh | 2 --
2 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/configure.ac b/configure.ac
index d506fb51..000a7d67 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1302,11 +1302,11 @@ AC_ARG_ENABLE([vddk],
dnl newer versions which are supported only on x86-64. Don't
dnl compile on other platforms.
AC_MSG_CHECKING([if the host CPU is compatible with VDDK])
- AS_IF([test "$host_cpu" = "x86_64"],[
- AC_MSG_RESULT([yes ($host_cpu)])
+ AS_IF([test "$host_cpu" = "x86_64" && test
"$host_os" = "linux-gnu"],[
+ AC_MSG_RESULT([yes ($host)])
enable_vddk=yes
],[
- AC_MSG_RESULT([no ($host_cpu)])
+ AC_MSG_RESULT([no ($host)])
enable_vddk=no
])
])
diff --git a/ci/build.sh b/ci/build.sh
index 7d31d5c5..241d0ef5 100755
--- a/ci/build.sh
+++ b/ci/build.sh
@@ -122,14 +122,12 @@ main() {
CONFIG_ARGS="\
$CONFIG_ARGS
--disable-ocaml
---disable-vddk
"
;;
*)
CONFIG_ARGS="\
$CONFIG_ARGS
--enable-ocaml
---enable-vddk
"
;;
esac
--
2.37.3
Eric Blake
2022-Oct-20 20:32 UTC
[Libguestfs] [nbdkit PATCH 07/10] rust: Skip building in VPATH
Cargo does not play nicely with VPATH (at least, that's what my quick
google search found:
https://github.com/rust-lang/cargo/issues/5457#issuecomment-451695299).
Easiest is to just disable it when we detect a VPATH build.
---
configure.ac | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/configure.ac b/configure.ac
index 000a7d67..9541b591 100644
--- a/configure.ac
+++ b/configure.ac
@@ -942,11 +942,16 @@ EOF
])
dnl For developing plugins in Rust, optional.
+dnl Rust does not play nicely with VPATH builds
AC_CHECK_PROG([CARGO],[cargo],[cargo],[no])
AC_ARG_ENABLE([rust],
[AS_HELP_STRING([--disable-rust], [disable Rust plugin])],
[],
- [enable_rust=yes])
+ [if test "x$(realpath $srcdir)" = "x$(realpath .)";
then
+ enable_rust=yes
+ else
+ enable_rust=no
+ fi])
AM_CONDITIONAL([HAVE_RUST],
[test "x$CARGO" != "xno" && test
"x$enable_rust" != "xno"])
--
2.37.3
Eric Blake
2022-Oct-20 20:32 UTC
[Libguestfs] [nbdkit PATCH 08/10] mingw: Provide nbdkit_debug() in Windows replacements
Silence compiler warnings such as:
../../../common/replacements/fsync.c: In function 'fsync':
../../../common/replacements/fsync.c:58:5: warning: implicit declaration of
function 'nbdkit_debug' [-Wimplicit-function-declaration]
58 | nbdkit_debug ("ReadFile: bad handle");
| ^~~~~~~~~~~~
---
common/replacements/Makefile.am | 7 ++++++-
common/replacements/fsync.c | 3 ++-
common/replacements/pread.c | 3 ++-
common/replacements/pwrite.c | 3 ++-
4 files changed, 12 insertions(+), 4 deletions(-)
diff --git a/common/replacements/Makefile.am b/common/replacements/Makefile.am
index da0f8fec..9ad59148 100644
--- a/common/replacements/Makefile.am
+++ b/common/replacements/Makefile.am
@@ -1,5 +1,5 @@
# nbdkit
-# Copyright (C) 2019 Red Hat Inc.
+# Copyright (C) 2019-2022 Red Hat Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
@@ -33,6 +33,11 @@ include $(top_srcdir)/common-rules.mk
SUBDIRS = win32
+AM_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_builddir)/include \
+ $(NULL)
+
noinst_LTLIBRARIES = libcompat.la
# sources should be empty
libcompat_la_SOURCES diff --git a/common/replacements/fsync.c
b/common/replacements/fsync.c
index a7f3bf27..0224a957 100644
--- a/common/replacements/fsync.c
+++ b/common/replacements/fsync.c
@@ -1,5 +1,5 @@
/* nbdkit
- * Copyright (C) 2019-2020 Red Hat Inc.
+ * Copyright (C) 2019-2022 Red Hat Inc.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
@@ -46,6 +46,7 @@
/* Replacement fsync for Win32. */
+#include "nbdkit-plugin.h"
#include <windows.h>
int
diff --git a/common/replacements/pread.c b/common/replacements/pread.c
index ab690071..28a6aacc 100644
--- a/common/replacements/pread.c
+++ b/common/replacements/pread.c
@@ -1,5 +1,5 @@
/* nbdkit
- * Copyright (C) 2019-2020 Red Hat Inc.
+ * Copyright (C) 2019-2022 Red Hat Inc.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
@@ -47,6 +47,7 @@
/* Replacement pread for Win32. */
+#include "nbdkit-plugin.h"
#include <windows.h>
ssize_t
diff --git a/common/replacements/pwrite.c b/common/replacements/pwrite.c
index 71e56ad1..54d40fe1 100644
--- a/common/replacements/pwrite.c
+++ b/common/replacements/pwrite.c
@@ -1,5 +1,5 @@
/* nbdkit
- * Copyright (C) 2019-2020 Red Hat Inc.
+ * Copyright (C) 2019-2022 Red Hat Inc.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
@@ -47,6 +47,7 @@
/* Replacement pwrite for Win32. */
+#include "nbdkit-plugin.h"
#include <windows.h>
ssize_t
--
2.37.3
Eric Blake
2022-Oct-20 20:32 UTC
[Libguestfs] [nbdkit PATCH 09/10] perl: Auto-disable on mingw
Attempting to build perl on mingw fails horribly with:
libtool: compile: i686-w64-mingw32-gcc -DHAVE_CONFIG_H -I.
-I../../../plugins/perl -I../.. -I../../../include -I../../include
-I../../../common/include -I../../../common/utils -D_REENTRANT -D_GNU_SOURCE -O2
-flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall
-Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS
-specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong
-specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic
-fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fwrapv
-fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -I/usr/lib64/perl5/CORE -O2 -g -pipe -Wall
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4 -MT
nbdkit_perl_plugin_la-perl.lo -MD -MP -MF .deps/nbdkit_perl_plugin_la-perl.Tpo
-c ../../../plugins/perl/perl.c -DDLL_EXPORT -DPIC -o
.libs/nbdkit_perl_plugin_la-perl.o
Assembler messages:
Fatal error: no compiled in support for x86_64
cc1: error: plugin support is disabled; configure with --enable-plugin
cc1: sorry, unimplemented: 64-bit mode not compiled in
Let's catch this at configure time, at which point we no longer need
to explicitly enable/disable perl at CI time (although we still want
to force --enable-perl on at least some of our other containers).
---
configure.ac | 13 ++++++++++++-
ci/build.sh | 6 +++++-
ci/gitlab/builds.yml | 8 ++++----
ci/manifest.yml | 6 ++++--
4 files changed, 25 insertions(+), 8 deletions(-)
diff --git a/configure.ac b/configure.ac
index 9541b591..97a23b2d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -806,7 +806,18 @@ AS_IF([test "x$PERL" != "xno"
&& test "x$enable_perl" != "xno"],[
PERL_LDOPTS="$($PERL -MExtUtils::Embed -e 'ldopts')"
AC_MSG_RESULT([$PERL_LDOPTS])
- dnl XXX Could check these actually work.
+ dnl Check these actually work.
+ AC_MSG_CHECKING([whether Perl modules will compile])
+ old_CFLAGS="$CFLAGS"
+ old_LIBS="$LIBS"
+ CFLAGS="$PERL_CFLAGS -I$PERL_ARCHLIB/CORE $CFLAGS"
+ LIBS="$PERL_LDOPTS $LIBS"
+ AC_CHECK_FUNCS([perl_alloc])
+ CFLAGS="$old_CFLAGS"
+ LIBS="$old_LIBS"
+ if test "x$ac_cv_func_perl_alloc" != xyes; then
+ enable_perl=no
+ fi
])
AM_CONDITIONAL([HAVE_PERL],[test "x$enable_perl" != "xno"
&& test "x$PERL" != "xno"])
AC_SUBST([PERL_ARCHLIB])
diff --git a/ci/build.sh b/ci/build.sh
index 241d0ef5..0eb07e93 100755
--- a/ci/build.sh
+++ b/ci/build.sh
@@ -70,6 +70,10 @@ main() {
autoreconf -if
+ # These are options we want in all CI builds (if the container can't
+ # build it, we want an error). Options not mentioned here default to
+ # being auto-detected by the container, but can have explicit
+ # overrides below.
CONFIG_ARGS="\
--disable-libguestfs-tests
--enable-gcc-warnings \
@@ -99,7 +103,7 @@ main() {
if test "$PERL" = "skip"
then
CONFIG_ARGS="$CONFIG_ARGS --disable-perl"
- else
+ elif test "$PERL" = "force"
CONFIG_ARGS="$CONFIG_ARGS --enable-perl"
fi
diff --git a/ci/gitlab/builds.yml b/ci/gitlab/builds.yml
index d0bc2653..185a1d83 100644
--- a/ci/gitlab/builds.yml
+++ b/ci/gitlab/builds.yml
@@ -169,6 +169,7 @@ x86_64-fedora-35-prebuilt-env:
allow_failure: false
variables:
NAME: fedora-35
+ PERL: force
x86_64-fedora-35-local-env:
extends: .native_build_job_local_env
@@ -177,6 +178,7 @@ x86_64-fedora-35-local-env:
variables:
IMAGE: registry.fedoraproject.org/fedora:35
NAME: fedora-35
+ PERL: force
x86_64-fedora-rawhide-prebuilt-env:
@@ -187,6 +189,7 @@ x86_64-fedora-rawhide-prebuilt-env:
allow_failure: false
variables:
NAME: fedora-rawhide
+ PERL: force
x86_64-fedora-rawhide-local-env:
extends: .native_build_job_local_env
@@ -195,6 +198,7 @@ x86_64-fedora-rawhide-local-env:
variables:
IMAGE: registry.fedoraproject.org/fedora:rawhide
NAME: fedora-rawhide
+ PERL: force
x86_64-fedora-rawhide-clang-prebuilt-env:
@@ -304,7 +308,6 @@ mingw32-fedora-35-prebuilt-env:
CROSS: mingw32
GOLANG: skip
NAME: fedora-35
- PERL: skip
RUST: skip
mingw32-fedora-35-local-env:
@@ -316,7 +319,6 @@ mingw32-fedora-35-local-env:
GOLANG: skip
IMAGE: registry.fedoraproject.org/fedora:35
NAME: fedora-35
- PERL: skip
RUST: skip
@@ -330,7 +332,6 @@ mingw64-fedora-35-prebuilt-env:
CROSS: mingw64
GOLANG: skip
NAME: fedora-35
- PERL: skip
RUST: skip
mingw64-fedora-35-local-env:
@@ -342,7 +343,6 @@ mingw64-fedora-35-local-env:
GOLANG: skip
IMAGE: registry.fedoraproject.org/fedora:35
NAME: fedora-35
- PERL: skip
RUST: skip
diff --git a/ci/manifest.yml b/ci/manifest.yml
index 6ef9f576..3de6b608 100644
--- a/ci/manifest.yml
+++ b/ci/manifest.yml
@@ -50,22 +50,24 @@ targets:
fedora-35:
jobs:
- arch: x86_64
+ variables:
+ PERL: force
- arch: mingw32
variables:
- PERL: skip
RUST: skip
GOLANG: skip
- arch: mingw64
variables:
- PERL: skip
RUST: skip
GOLANG: skip
fedora-rawhide:
jobs:
- arch: x86_64
+ variables:
+ PERL: force
- arch: x86_64
suffix: -clang
--
2.37.3
Eric Blake
2022-Oct-20 20:32 UTC
[Libguestfs] [nbdkit PATCH 10/10] ci: Fix typo in last patch
I didn't mean to kill the entire CI pipeline with a syntax error!
Fixes: 4446896f
---
ci/build.sh | 1 +
1 file changed, 1 insertion(+)
diff --git a/ci/build.sh b/ci/build.sh
index 0eb07e93..3803f6d2 100755
--- a/ci/build.sh
+++ b/ci/build.sh
@@ -104,6 +104,7 @@ main() {
then
CONFIG_ARGS="$CONFIG_ARGS --disable-perl"
elif test "$PERL" = "force"
+ then
CONFIG_ARGS="$CONFIG_ARGS --enable-perl"
fi
--
2.37.3