Displaying 20 results from an estimated 25 matches for "valgrind_cflags".
2018 Jul 01
2
[PATCH nbdkit] valgrind: Don't call dlclose when running under valgrind.
..._ARG_ENABLE([valgrind],
+ AS_HELP_STRING([--enable-valgrind], [enable Valgrind extensions, for developers]),
+ [enable_valgrind=yes],
+ [enable_valgrind=no])
+AS_IF([test "x$enable_valgrind" = "xyes"],[
+ PKG_CHECK_MODULES([VALGRIND], [valgrind], [
+ AC_SUBST([VALGRIND_CFLAGS])
+ AC_SUBST([VALGRIND_LIBS])
+ AC_DEFINE([HAVE_VALGRIND],[1],[Valgrind headers found at compile time])
+ ],[
+ AC_MSG_ERROR([--enable-valgrind given, but Valgrind headers are not available])
+ ])
+])
+
dnl Bash completion.
PKG_CHECK_MODULES([BASH_COMPLETION], [bash-com...
2018 Jul 01
0
Re: [PATCH nbdkit] valgrind: Don't call dlclose when running under valgrind.
...it a/src/Makefile.am b/src/Makefile.am
> index 7ead75c..915efe4 100644
> --- a/src/Makefile.am
> +++ b/src/Makefile.am
> @@ -63,7 +63,8 @@ nbdkit_CPPFLAGS = \
> nbdkit_CFLAGS = \
> -pthread \
> $(WARNINGS_CFLAGS) \
> - $(GNUTLS_CFLAGS)
> + $(GNUTLS_CFLAGS) \
> + $(VALGRIND_CFLAGS)
Just a note that this also has to be added to test_utils_CFLAGS at the
bottom of the same file, otherwise the tests fail to compile.
Rich.
--
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
vir...
2019 Mar 19
0
[PATCH nbdkit 2/9] server: Add CLEANUP_EXTENTS_FREE macro.
...ptr)
+{
+ nbdkit_extents_free (* (void **) ptr);
+}
+
void
cleanup_unlock (pthread_mutex_t **ptr)
{
diff --git a/server/Makefile.am b/server/Makefile.am
index 5722f7b..c139c05 100644
--- a/server/Makefile.am
+++ b/server/Makefile.am
@@ -150,7 +150,8 @@ test_extents_CFLAGS = $(WARNINGS_CFLAGS) $(VALGRIND_CFLAGS)
test_utils_SOURCES = \
test-utils.c \
utils.c \
- cleanup.c
+ cleanup.c \
+ extents.c
test_utils_CPPFLAGS = \
-I$(top_srcdir)/include \
-I$(top_srcdir)/common/include
--
2.20.1
2018 Oct 28
0
[PATCH nbdkit 1/4] common: Move get_current_dir_name(3) compatibility function.
...a/src/Makefile.am
+++ b/src/Makefile.am
@@ -102,5 +102,7 @@ test_utils_SOURCES = \
test-utils.c \
utils.c \
cleanup.c
-test_utils_CPPFLAGS = -I$(top_srcdir)/include
+test_utils_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_srcdir)/common/include
test_utils_CFLAGS = $(WARNINGS_CFLAGS) $(VALGRIND_CFLAGS)
diff --git a/src/utils.c b/src/utils.c
index 0e48d52..c9e1e14 100644
--- a/src/utils.c
+++ b/src/utils.c
@@ -44,20 +44,10 @@
#include <termios.h>
#include <errno.h>
+#include "get-current-dir-name.h"
+
#include "internal.h"
-#ifndef HAVE_GET_CURRENT_DIR_NAME...
2019 Apr 23
0
[nbdkit PATCH 1/4] cleanup: Move cleanup.c to common
...heck_PROGRAMS = test-utils
test_utils_SOURCES = \
test-utils.c \
utils.c \
- cleanup.c \
extents.c
test_utils_CPPFLAGS = \
-I$(top_srcdir)/include \
- -I$(top_srcdir)/common/include
+ -I$(top_srcdir)/common/include \
+ -I$(top_srcdir)/common/utils
test_utils_CFLAGS = $(WARNINGS_CFLAGS) $(VALGRIND_CFLAGS)
+test_utils_LDADD = \
+ $(top_builddir)/common/utils/libutils.la
--
2.20.1
2020 Mar 26
1
Re: [PATCH nbdkit 5/9 patch split 1/5] Create libnbdkit.so.
...uot; \
> -Dsbindir=\"$(sbindir)\" \
> -Dsysconfdir=\"$(sysconfdir)\" \
> + -I$(top_srcdir)/lib \
> -I$(top_srcdir)/include \
> -I$(top_srcdir)/common/include \
> -I$(top_srcdir)/common/protocol \
> @@ -93,6 +94,7 @@ nbdkit_CFLAGS = \
> $(VALGRIND_CFLAGS) \
> $(NULL)
> nbdkit_LDADD = \
> + ../lib/libnbdkit.la \
Is that ../ going to bite us on RHEL 7's older Automake? Do we need to
uses $(top_builddir) instead?
> +++ b/lib/lib.h
> @@ -0,0 +1,48 @@
> +#ifndef NBDKIT_LIB_H
> +#define NBDKIT_LIB_H
> +
> +#includ...
2020 Aug 18
0
[PATCH nbdkit 1/9] server: Add libnbdkit.so.
...t; \
-Dmandir=\"$(mandir)\" \
@@ -86,21 +90,22 @@ nbdkit_CPPFLAGS = \
-I$(top_srcdir)/common/protocol \
-I$(top_srcdir)/common/utils \
$(NULL)
-nbdkit_CFLAGS = \
+libnbdkit_la_CFLAGS = \
$(PTHREAD_CFLAGS) \
$(WARNINGS_CFLAGS) \
$(GNUTLS_CFLAGS) \
$(LIBSELINUX_CFLAGS) \
$(VALGRIND_CFLAGS) \
$(NULL)
-nbdkit_LDADD = \
+libnbdkit_la_LIBADD = \
$(GNUTLS_LIBS) \
$(LIBSELINUX_LIBS) \
$(DL_LIBS) \
$(top_builddir)/common/protocol/libprotocol.la \
$(top_builddir)/common/utils/libutils.la \
$(NULL)
-nbdkit_LDFLAGS = \
+libnbdkit_la_LDFLAGS = \
+ -shared $(NO_UNDEFINED_ON_WINDOW...
2020 Feb 16
0
[nbdkit PATCH v4 1/4] server: Export nbdkit_set_dlopen_prefix function
...FLAGS)
+nbdkit_shim_dlopen_la_LIBADD = $(DL_LIBS)
+nbdkit_shim_dlopen_la_LDFLAGS = \
+ -module -no-undefined -shared -avoid-version \
+ $(DL_LDFLAGS) \
+ $(NULL)
+
nbdkit_CPPFLAGS = \
-Dbindir=\"$(bindir)\" \
-Dlibdir=\"$(libdir)\" \
@@ -92,6 +104,7 @@ nbdkit_CFLAGS = \
$(VALGRIND_CFLAGS) \
$(NULL)
nbdkit_LDADD = \
+ nbdkit-shim-dlopen.la \
$(GNUTLS_LIBS) \
$(LIBSELINUX_LIBS) \
$(DL_LIBS) \
diff --git a/server/nbdkit.syms b/server/nbdkit.syms
index 96c22c07..d20e0784 100644
--- a/server/nbdkit.syms
+++ b/server/nbdkit.syms
@@ -63,6 +63,7 @@
nbdkit_peer_name;
nbdk...
2020 Mar 26
0
[PATCH nbdkit 5/9 patch split 2/5] lib: Move code for parsing, passwords and paths into libnbdkit.so.
..._public_SOURCES = \
+ test-public.c \
+ extents.c \
+ parse.c \
+ password.c \
+ $(NULL)
+test_public_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_srcdir)/common/include \
+ -I$(top_srcdir)/common/protocol \
+ -I$(top_srcdir)/common/utils \
+ $(NULL)
+test_public_CFLAGS = $(WARNINGS_CFLAGS) $(VALGRIND_CFLAGS)
+test_public_LDADD = \
+ $(top_builddir)/common/utils/libutils.la \
+ $(NULL)
diff --git a/server/Makefile.am b/server/Makefile.am
index ad0de9b1..8448bc10 100644
--- a/server/Makefile.am
+++ b/server/Makefile.am
@@ -43,7 +43,6 @@ nbdkit_SOURCES = \
crypto.c \
debug.c \
debug-flags.c \
- ext...
2020 Mar 26
0
[PATCH nbdkit 5/9 patch split 1/5] Create libnbdkit.so.
...FLAGS = \
-Dfilterdir=\"$(filterdir)\" \
-Dsbindir=\"$(sbindir)\" \
-Dsysconfdir=\"$(sysconfdir)\" \
+ -I$(top_srcdir)/lib \
-I$(top_srcdir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/protocol \
@@ -93,6 +94,7 @@ nbdkit_CFLAGS = \
$(VALGRIND_CFLAGS) \
$(NULL)
nbdkit_LDADD = \
+ ../lib/libnbdkit.la \
$(GNUTLS_LIBS) \
$(LIBSELINUX_LIBS) \
$(DL_LIBS) \
@@ -142,6 +144,7 @@ test_public_SOURCES = \
extents.c \
$(NULL)
test_public_CPPFLAGS = \
+ -I$(top_srcdir)/lib \
-I$(top_srcdir)/include \
-I$(top_srcdir)/common/include \
-I$(...
2019 Apr 23
8
[nbdkit PATCH 0/4] Start using cleanup macros in filters/plugins
There's more that can be done (in particular, use of CLEANUP_FREE),
but this is enough to at least see if I'm on the right track.
I couldn't figure out an obvious difference between common/include and
common/utils, but it looks like the former is for things that are
inlineable via .h only, while the latter is when you need to link in
a convenience library, so this landed in the
2020 Mar 26
9
[PATCH nbdkit 5/9 patch split 1/5] Create libnbdkit.so.
This is the previous 5/9 patch posted earlier today, split into
reviewable chunks. This passes bisection with -x 'make && make
check', but I didn't work very hard on the commit messages, so I refer
you back to the original patch to explain how it works:
https://www.redhat.com/archives/libguestfs/2020-March/msg00248.html
Rich.
2019 Jan 14
6
[PATCH nbdkit incomplete 0/5] Port to Windows.
This is an incomplete port to Windows. Currently the server compiles
and starts up successfully, but goes into an infinite loop when you
connect to it. Nevertheless I think the approach is ready for
feedback. This being Windows the changes go quite deep.
Rich.
2020 Aug 18
0
[PATCH nbdkit 3/9] server: Add general replacements for missing functions using LIBOBJS.
...$(NO_UNDEFINED_ON_WINDOWS) \
@@ -152,6 +154,7 @@ test_public_CPPFLAGS = \
-I$(top_srcdir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/protocol \
+ -I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
$(NULL)
test_public_CFLAGS = $(WARNINGS_CFLAGS) $(VALGRIND_CFLAGS)
diff --git a/common/replacements/getline.h b/common/replacements/getline.h
new file mode 100644
index 00000000..a9e1024a
--- /dev/null
+++ b/common/replacements/getline.h
@@ -0,0 +1,50 @@
+/* nbdkit
+ * Copyright (C) 2019 Red Hat Inc.
+ * All rights reserved.
+ *
+ * Redistribution and use in sour...
2020 Feb 16
6
[nbdkit PATCH v4 0/4] vddk: Drive library loading from libdir parameter.
I'm a lot happier with this version: no mucking with dlmopen(). It
does add a bit more coupling between nbdkit proper and the vddk plugin
(namely, nbdkit now exports a new function that the vddk plugin relies
on), but patch 2 adds testsuite coverage of the new function so we
shouldn't regress.
Patch 1 and 2 are new, patch 3 is unchanged from when Rich posted it
in v2, and patch 4 is
2020 Aug 20
0
[PATCH nbdkit 01/13] common/replacements: Replace missing functions using LIBOBJS.
...FLAGS = \
$(PTHREAD_LIBS) \
@@ -147,6 +149,7 @@ test_public_CPPFLAGS = \
-I$(top_srcdir)/include \
-I$(top_srcdir)/common/include \
-I$(top_srcdir)/common/protocol \
+ -I$(top_srcdir)/common/replacements \
-I$(top_srcdir)/common/utils \
$(NULL)
test_public_CFLAGS = $(WARNINGS_CFLAGS) $(VALGRIND_CFLAGS)
diff --git a/common/replacements/getline.h b/common/replacements/getline.h
new file mode 100644
index 00000000..6034d85d
--- /dev/null
+++ b/common/replacements/getline.h
@@ -0,0 +1,48 @@
+/* nbdkit
+ * Copyright (C) 2019 Red Hat Inc.
+ *
+ * Redistribution and use in source and binary forms, with...
2020 Aug 15
3
[PATCH EXPERIMENTAL nbdkit 0/2] Port to Windows using mingw.
The patches following do indeed allow you to compile nbdkit.exe, but
it does not actually work yet. I'm posting this experimental series
more as a work in progress and to get feedback.
Note this does not require Windows itself to build or test. You can
cross-compile it using mingw64-* packages on Fedora or Debian, and
test it [spoiler alert: it fails] using Wine.
Rich.
2019 Sep 28
11
[nbdkit PATCH v2 0/7] Spec compliance patches
Since the v1 series (0/4, at [1]), I've applied patches 1 and 2,
rewritten patch 3 [Forbid NUL in export and context names] into patch
4 here, patch 4 there turned into patch 6 here, and everything else
here is new.
[1]https://www.redhat.com/archives/libguestfs/2019-September/msg00180.html
I don't know if there is a handy reusable function for checking
whether a string contains valid
2019 Mar 19
0
[PATCH nbdkit 1/9] server: Implement extents/can_extents calls for plugins and filters.
...ils
-check_PROGRAMS = test-utils
+check_PROGRAMS = \
+ test-extents \
+ test-utils
+
+test_extents_SOURCES = \
+ test-extents.c \
+ extents.c
+test_extents_CPPFLAGS = \
+ -DIN_TEST_EXTENTS=1 \
+ -I$(top_srcdir)/include \
+ -I$(top_srcdir)/common/include
+test_extents_CFLAGS = $(WARNINGS_CFLAGS) $(VALGRIND_CFLAGS)
test_utils_SOURCES = \
test-utils.c \
--
2.20.1
2019 Mar 19
15
[PATCH nbdkit 0/9] [mainly for discussion and early review] Implement extents.
I want to post this but mainly for discussion and early review. It's
not safe for these patches to all go upstream yet (because not all
filters have been checked/adjusted), but if any patches were to go
upstream then probably 1 & 2 only are safe.
File, VDDK, memory and data plugins all work, although I have only
done minimal testing on them.
The current tests, such as they are, all