If you want to compile against a locally compiled (but not installed)
nbdkit, you can now set PKG_CONFIG_PATH=/path/to/nbdkit/server/local
Since it's not clear how useful this will be (we only want it for
internal reasons) this is not documented.
Thanks: Dan Berrangé, Eric Blake
---
.gitignore | 1 +
configure.ac | 1 +
server/local/nbdkit.pc.in | 43 +++++++++++++++++++++++++++++++++++++++
3 files changed, 45 insertions(+)
diff --git a/.gitignore b/.gitignore
index 4f6fcf1b..8c701295 100644
--- a/.gitignore
+++ b/.gitignore
@@ -83,6 +83,7 @@ plugins/*/*.3
/plugins/tar/nbdkit-tar-plugin
/plugins/tmpdisk/default-command.c
/podwrapper.pl
+/server/local/nbdkit.pc
/server/nbdkit
/server/nbdkit.pc
/server/synopsis.c
diff --git a/configure.ac b/configure.ac
index b71d9d8c..17d8d676 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1088,6 +1088,7 @@ AC_CONFIG_FILES([Makefile
filters/truncate/Makefile
filters/xz/Makefile
fuzzing/Makefile
+ server/local/nbdkit.pc
server/Makefile
server/nbdkit.pc
tests/functions.sh
diff --git a/server/local/nbdkit.pc.in b/server/local/nbdkit.pc.in
new file mode 100644
index 00000000..1d8b6bee
--- /dev/null
+++ b/server/local/nbdkit.pc.in
@@ -0,0 +1,43 @@
+# nbdkit
+# Copyright (C) 2013-2020 Red Hat Inc.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are
+# met:
+#
+# * Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# * Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# * Neither the name of Red Hat nor the names of its contributors may be
+# used to endorse or promote products derived from this software without
+# specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY RED HAT AND CONTRIBUTORS ''AS IS'' AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+# PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RED HAT OR
+# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
+# USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+# SUCH DAMAGE.
+
+# This alternate pkg-config file may be used to compile plugins
+# against a locally compiled (but not installed) nbdkit.
+
+prefix=@abs_top_builddir@
+exec_prefix=@abs_top_builddir@
+
+Name: @PACKAGE_NAME@
+Version: @PACKAGE_VERSION@
+Description: A toolkit for creating NBD servers
+Requires:
+Cflags: -I@abs_top_srcdir@/include -I@abs_top_builddir@/include
+Libs:
--
2.18.2