From 88ca5b1c5be3b191ed95df803dffe055dd6525b4 Mon Sep 17 00:00:00 2001 From: Sebastian Harl Date: Tue, 5 Feb 2008 22:48:19 +0100 Subject: [PATCH] Added workaround for the "dlopen()-issue" of the perl plugin. There is no way to tell lt_dlopen() to use the RTLD_GLOBAL flag which is however required by the perl plugin (which would otherwise be unable to find symbols defined in libperl when loading perl modules that require such symbols). This can be worked around by using -DLT_LAZY_OR_NOW='RTLD_LAZY|RTLD_GLOBAL' when compiling collectd. This is rather a hack but the best solution I can currently think of. --- debian/rules | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/debian/rules b/debian/rules index fd65b70..19f2aae 100755 --- a/debian/rules +++ b/debian/rules @@ -14,6 +14,12 @@ DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) CFLAGS = -Wall -g -I$(CURDIR)/debian/include +# There is no way to tell lt_dlopen() to use the RTLD_GLOBAL flag which is +# however required by the perl plugin (which would otherwise be unable to find +# symbols defined in libperl when loading perl modules that require such +# symbols). This is a workaround for this issue. +CFLAGS += -DLT_LAZY_OR_NOW='RTLD_LAZY|RTLD_GLOBAL' + ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) CFLAGS += -O0 else -- 2.30.2