summaryrefslogtreecommitdiff
path: root/dev-libs/libprelude/files/libprelude-3.0.0-perl-hardening.patch
diff options
context:
space:
mode:
Diffstat (limited to 'dev-libs/libprelude/files/libprelude-3.0.0-perl-hardening.patch')
-rw-r--r--dev-libs/libprelude/files/libprelude-3.0.0-perl-hardening.patch14
1 files changed, 14 insertions, 0 deletions
diff --git a/dev-libs/libprelude/files/libprelude-3.0.0-perl-hardening.patch b/dev-libs/libprelude/files/libprelude-3.0.0-perl-hardening.patch
new file mode 100644
index 000000000000..df77899c82fa
--- /dev/null
+++ b/dev-libs/libprelude/files/libprelude-3.0.0-perl-hardening.patch
@@ -0,0 +1,14 @@
+When : when building perl bindings. Without this patch, it does not take care of LDFLAGS.
+Why : It is required if you want to customize your own LDFLAGS, example : for hardening
+Upstream : https://www.prelude-siem.org/issues/761 It should be added in the next version of Prelude.
+--- a/bindings/perl/Makefile.PL.in
++++ b/bindings/perl/Makefile.PL.in
+@@ -27,7 +27,7 @@
+ my %attributs = (NAME => 'Prelude',
+ INC => '-I@top_builddir@ -I@top_builddir@/src/include -I@top_srcdir@/src/include -I@top_builddir@/src/libprelude-error -I@top_srcdir@/bindings/c++/include',
+ LIBS => ["-L@top_builddir@/src/.libs -lprelude -L@top_builddir@/bindings/c++/.libs -lpreludecpp", "-L$ENV{LIBDIR} -lprelude @LIBPRELUDE_LIBS@ @LIBADD_DL@ @LTLIBTHREAD@" ],
+- LDDLFLAGS => "-L@top_builddir@/src/.libs $Config{lddlflags}");
++ LDDLFLAGS => "-L@top_builddir@/src/.libs $Config{lddlflags} @LDFLAGS@,-rpath");
+
+ if ( abs_path("@top_srcdir@") ne abs_path("@top_builddir@") ) {
+ foreach my $filename ( qw/Prelude.cxx Prelude.pm/ ) {