* [gentoo-commits] repo/gentoo:master commit in: dev-util/valgrind/, dev-util/valgrind/files/
@ 2022-07-21 15:20 Anthony G. Basile
0 siblings, 0 replies; 11+ messages in thread
From: Anthony G. Basile @ 2022-07-21 15:20 UTC (permalink / raw
To: gentoo-commits
commit: 1ea5ea8366262f347d003d9c337f7a92a81477ac
Author: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
AuthorDate: Thu Jul 21 15:19:58 2022 +0000
Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
CommitDate: Thu Jul 21 15:19:58 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1ea5ea83
dev-util/valgrind: add musl support
Package-Manager: Portage-3.0.30, Repoman-3.0.3
Signed-off-by: Anthony G. Basile <blueness <AT> gentoo.org>
.../valgrind/files/valgrind-3.13.0-malloc.patch | 26 ++++++++++++++++++++++
dev-util/valgrind/valgrind-3.19.0.ebuild | 6 +++++
dev-util/valgrind/valgrind-9999.ebuild | 6 +++++
3 files changed, 38 insertions(+)
diff --git a/dev-util/valgrind/files/valgrind-3.13.0-malloc.patch b/dev-util/valgrind/files/valgrind-3.13.0-malloc.patch
new file mode 100644
index 000000000000..ac6d90fef50f
--- /dev/null
+++ b/dev-util/valgrind/files/valgrind-3.13.0-malloc.patch
@@ -0,0 +1,26 @@
+From: https://git.alpinelinux.org/aports/tree/main/valgrind/
+
+--- valgrind-3.13.0/coregrind/m_replacemalloc/vg_replace_malloc.c
++++ valgrind-3.13.0/coregrind/m_replacemalloc/vg_replace_malloc.c
+@@ -765,13 +765,15 @@ static void init(void);
+ DO_INIT; \
+ MALLOC_TRACE("realloc(%p,%llu)", ptrV, (ULong)new_size ); \
+ \
+- if (ptrV == NULL) \
+- /* We need to call a malloc-like function; so let's use \
+- one which we know exists. */ \
+- return VG_REPLACE_FUNCTION_EZU(10010,VG_Z_LIBC_SONAME,malloc) \
+- (new_size); \
++ if (ptrV == NULL) { \
++ TRIGGER_MEMCHECK_ERROR_IF_UNDEFINED(new_size); \
++ v = (void*)VALGRIND_NON_SIMD_CALL1( info.tl_malloc, new_size ); \
++ MALLOC_TRACE(" = %p\n", v ); \
++ return v; \
++ } \
+ if (new_size <= 0) { \
+- VG_REPLACE_FUNCTION_EZU(10050,VG_Z_LIBC_SONAME,free)(ptrV); \
++ if (ptrV != NULL) \
++ VALGRIND_NON_SIMD_CALL1( info.tl_free, ptrV ); \
+ MALLOC_TRACE(" = 0\n"); \
+ return NULL; \
+ } \
diff --git a/dev-util/valgrind/valgrind-3.19.0.ebuild b/dev-util/valgrind/valgrind-3.19.0.ebuild
index 5a2a07829d30..4ff9c8e71913 100644
--- a/dev-util/valgrind/valgrind-3.19.0.ebuild
+++ b/dev-util/valgrind/valgrind-3.19.0.ebuild
@@ -34,6 +34,12 @@ src_prepare() {
eapply "${FILESDIR}"/${PN}-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch
+ # conditionally copy musl specific suppressions && apply patch
+ if use elibc_musl ; then
+ cp "${FILESDIR}/musl.supp" "${S}"
+ eapply "${FILESDIR}/valgrind-3.13.0-malloc.patch"
+ fi
+
if [[ ${CHOST} == *-solaris* ]] ; then
# upstream doesn't support this, but we don't build with
# Sun/Oracle ld, we have a GNU toolchain, so get some things
diff --git a/dev-util/valgrind/valgrind-9999.ebuild b/dev-util/valgrind/valgrind-9999.ebuild
index 5a2a07829d30..4ff9c8e71913 100644
--- a/dev-util/valgrind/valgrind-9999.ebuild
+++ b/dev-util/valgrind/valgrind-9999.ebuild
@@ -34,6 +34,12 @@ src_prepare() {
eapply "${FILESDIR}"/${PN}-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch
+ # conditionally copy musl specific suppressions && apply patch
+ if use elibc_musl ; then
+ cp "${FILESDIR}/musl.supp" "${S}"
+ eapply "${FILESDIR}/valgrind-3.13.0-malloc.patch"
+ fi
+
if [[ ${CHOST} == *-solaris* ]] ; then
# upstream doesn't support this, but we don't build with
# Sun/Oracle ld, we have a GNU toolchain, so get some things
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-util/valgrind/, dev-util/valgrind/files/
@ 2023-08-28 6:40 Sam James
0 siblings, 0 replies; 11+ messages in thread
From: Sam James @ 2023-08-28 6:40 UTC (permalink / raw
To: gentoo-commits
commit: 1d76aa204945dc2626c7bdd16144f3844c9e5480
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Mon Aug 28 06:31:05 2023 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Aug 28 06:37:13 2023 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1d76aa20
dev-util/valgrind: backport two fixes (suppressions w/ new glibc, memcpy false positive)
1) Fix suppressions w/ >=glibc-2.34 (sort of >=glibc-2.38)
This might be a glibc-2.38 thing wrt why I started hitting it now but
I suspect it's actually because of 1f0fd3e2aee01e0c09e7103c8af4183b57faef49 which
enabled ISA magic.
This breaks <glibc-2.34 in lieu of a proper upstream fix but those versions
are masked in Gentoo anyway.
2) Add a workaround (same as Fedora) for false positive "overlapping memcpy"
errors with _FORTIFY_SOURCE's memcpy_chk.
Bug: https://bugs.kde.org/show_bug.cgi?id=402833
Bug: https://bugs.kde.org/show_bug.cgi?id=453084
Bug: https://bugs.kde.org/show_bug.cgi?id=464671
Signed-off-by: Sam James <sam <AT> gentoo.org>
.../valgrind-3.21.0-glibc-2.34-suppressions.patch | 197 +++++++++++++++++++++
.../valgrind-3.21.0-memcpy-fortify_source.patch | 26 +++
...grind-9999.ebuild => valgrind-3.21.0-r2.ebuild} | 6 +-
dev-util/valgrind/valgrind-9999.ebuild | 2 +
4 files changed, 228 insertions(+), 3 deletions(-)
diff --git a/dev-util/valgrind/files/valgrind-3.21.0-glibc-2.34-suppressions.patch b/dev-util/valgrind/files/valgrind-3.21.0-glibc-2.34-suppressions.patch
new file mode 100644
index 000000000000..c4111326cfa2
--- /dev/null
+++ b/dev-util/valgrind/files/valgrind-3.21.0-glibc-2.34-suppressions.patch
@@ -0,0 +1,197 @@
+commit e04914e10126d3a8de13302e958bbfd5e83a6637
+Author: Romain Geissler <romain.geissler@amadeus.com>
+Date: Mon Jan 30 16:09:47 2023 +0000
+
+ Fragile temporary fix for https://bugs.kde.org/show_bug.cgi?id=464671: avoid using @GLIBC_VERSION@ with our recent toolchains.
+
+ This is fragile as it might a bit too many things (especially ld*.so, which maybe shall be written "ld-linux-*.so" to be a bit more robust)
+ and also it doesn't work for glibc < 2.34.
+
+ Ideally something similar to GLIBC_LIBC_PATH shall be introduced for ld.so and libdl.so, so that
+ it covers both glibc < 2.34 and glibc >= 2.34.
+
+--- a/glibc-2.X.supp.in
++++ b/glibc-2.X.supp.in
+@@ -39,74 +39,74 @@
+ {
+ dl-hack3-cond-1
+ Memcheck:Cond
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
++ obj:*/lib*/ld*.so*
++ obj:*/lib*/ld*.so*
++ obj:*/lib*/ld*.so*
+ }
+ {
+ dl-hack3-cond-2
+ Memcheck:Cond
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/libc-@GLIBC_VERSION@*.so*
++ obj:*/lib*/ld*.so*
++ obj:*/lib*/ld*.so*
++ obj:@GLIBC_LIBC_PATH@
+ }
+ {
+ dl-hack3-cond-3
+ Memcheck:Cond
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/libc-@GLIBC_VERSION@*.so*
+- obj:*/lib*/libc-@GLIBC_VERSION@*.so*
++ obj:*/lib*/ld*.so*
++ obj:@GLIBC_LIBC_PATH@
++ obj:@GLIBC_LIBC_PATH@
+ }
+ {
+ dl-hack3-cond-4
+ Memcheck:Cond
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/libdl-@GLIBC_VERSION@*.so*
++ obj:*/lib*/ld*.so*
++ obj:*/lib*/ld*.so*
++ obj:@GLIBC_LIBC_PATH@
+ }
+
+ {
+ dl-hack4-64bit-addr-1
+ Memcheck:Addr8
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
++ obj:*/lib*/ld*.so*
++ obj:*/lib*/ld*.so*
++ obj:*/lib*/ld*.so*
+ }
+ {
+ dl-hack4-64bit-addr-2
+ Memcheck:Addr8
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/libc-@GLIBC_VERSION@*.so*
++ obj:*/lib*/ld*.so*
++ obj:*/lib*/ld*.so*
++ obj:@GLIBC_LIBC_PATH@
+ }
+ {
+ dl-hack4-64bit-addr-3
+ Memcheck:Addr8
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so*
+- obj:*/lib*/libdl-@GLIBC_VERSION@*.so*
++ obj:*/lib*/ld*.so*
++ obj:*/lib*/ld*.so*
++ obj:@GLIBC_LIBC_PATH@
+ }
+
+ {
+ dl-hack5-32bit-addr-1
+ Memcheck:Addr4
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so
++ obj:*/lib*/ld*.so
++ obj:*/lib*/ld*.so
++ obj:*/lib*/ld*.so
+ }
+ {
+ dl-hack5-32bit-addr-3
+ Memcheck:Addr4
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so
+- obj:*/lib*/libdl-@GLIBC_VERSION@*.so*
++ obj:*/lib*/ld*.so
++ obj:*/lib*/ld*.so
++ obj:@GLIBC_LIBC_PATH@
+ }
+ {
+ dl-hack5-32bit-addr-4
+ Memcheck:Addr4
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so
+- obj:*/lib*/libdl-@GLIBC_VERSION@*.so*
+- obj:*/lib*/ld-@GLIBC_VERSION@*.so
++ obj:*/lib*/ld*.so
++ obj:@GLIBC_LIBC_PATH@
++ obj:*/lib*/ld*.so
+ }
+
+
+@@ -124,7 +124,7 @@
+ glibc-2.5.x-on-SUSE-10.2-(PPC)-2a
+ Memcheck:Cond
+ fun:index
+- obj:*ld-@GLIBC_VERSION@.*.so
++ obj:*/lib*/ld*.so*
+ }
+ {
+ glibc-2.5.x-on-SuSE-10.2-(PPC)-2b
+@@ -136,7 +136,7 @@
+ glibc-2.5.5-on-SuSE-10.2-(PPC)-2c
+ Memcheck:Addr4
+ fun:index
+- obj:*ld-@GLIBC_VERSION@.*.so
++ obj:*/lib*/ld*.so*
+ }
+ {
+ glibc-2.3.5-on-SuSE-10.1-(PPC)-3
+@@ -149,9 +149,9 @@
+ {
+ glibc-@GLIBC_VERSION@-on-SUSE-10.3-(x86)
+ Memcheck:Addr4
+- obj:*/lib/ld-@GLIBC_VERSION@*.so
+- obj:*/lib/ld-@GLIBC_VERSION@*.so
+- obj:*/lib/ld-@GLIBC_VERSION@*.so
++ obj:*/lib/ld*.so
++ obj:*/lib/ld*.so
++ obj:*/lib/ld*.so
+ }
+
+ {
+@@ -168,9 +168,9 @@
+ Memcheck:Param
+ socketcall.sendto(msg)
+ fun:__sendto_nocancel
+- obj:/*libc-@GLIBC_VERSION@*.so
+- obj:/*libc-@GLIBC_VERSION@*.so
+- obj:/*libc-@GLIBC_VERSION@*.so
++ obj:@GLIBC_LIBC_PATH@
++ obj:@GLIBC_LIBC_PATH@
++ obj:@GLIBC_LIBC_PATH@
+ }
+ {
+ glibc24-64bit-padding-1c
+@@ -180,7 +180,7 @@
+ fun:__nscd_get_map_ref
+ fun:nscd_get*_r
+ fun:*nscd*
+- obj:/*libc-@GLIBC_VERSION@*.so
++ obj:@GLIBC_LIBC_PATH@
+ }
+
+
+@@ -199,18 +199,18 @@
+ Memcheck:Param
+ socketcall.sendto(msg)
+ fun:send
+- obj:/*libc-@GLIBC_VERSION@*.so
+- obj:/*libc-@GLIBC_VERSION@*.so
+- obj:/*libc-@GLIBC_VERSION@*.so
++ obj:@GLIBC_LIBC_PATH@
++ obj:@GLIBC_LIBC_PATH@
++ obj:@GLIBC_LIBC_PATH@
+ }
+ {
+ X11-64bit-padding-4b
+ Memcheck:Param
+ socketcall.send(msg)
+ fun:send
+- obj:/*libc-@GLIBC_VERSION@*.so
+- obj:/*libc-@GLIBC_VERSION@*.so
+- obj:/*libc-@GLIBC_VERSION@*.so
++ obj:@GLIBC_LIBC_PATH@
++ obj:@GLIBC_LIBC_PATH@
++ obj:@GLIBC_LIBC_PATH@
+ }
+
+ ##----------------------------------------------------------------------##
diff --git a/dev-util/valgrind/files/valgrind-3.21.0-memcpy-fortify_source.patch b/dev-util/valgrind/files/valgrind-3.21.0-memcpy-fortify_source.patch
new file mode 100644
index 000000000000..87acc9ff9f55
--- /dev/null
+++ b/dev-util/valgrind/files/valgrind-3.21.0-memcpy-fortify_source.patch
@@ -0,0 +1,26 @@
+Avoid false positives w/ overlapping memcpy args with _FORTIFY_SOURCE's
+memcpy_chk.
+
+https://src.fedoraproject.org/rpms/valgrind/raw/rawhide/f/valgrind-3.21.0-no-memcpy-replace-check.patch
+https://bugs.kde.org/show_bug.cgi?id=402833
+https://bugs.kde.org/show_bug.cgi?id=453084
+--- a/shared/vg_replace_strmem.c
++++ b/shared/vg_replace_strmem.c
+@@ -1128,7 +1128,7 @@ static inline void my_exit ( int x )
+ MEMMOVE_OR_MEMCPY(20181, soname, fnname, 0)
+
+ #define MEMCPY(soname, fnname) \
+- MEMMOVE_OR_MEMCPY(20180, soname, fnname, 1)
++ MEMMOVE_OR_MEMCPY(20180, soname, fnname, 0) /* See KDE bug #402833 */
+
+ #if defined(VGO_linux)
+ /* For older memcpy we have to use memmove-like semantics and skip
+@@ -1714,8 +1714,6 @@ static inline void my_exit ( int x )
+ RECORD_COPY(len); \
+ if (len == 0) \
+ return dst; \
+- if (is_overlap(dst, src, len, len)) \
+- RECORD_OVERLAP_ERROR("memcpy_chk", dst, src, len); \
+ if ( dst > src ) { \
+ d = (HChar *)dst + len - 1; \
+ s = (const HChar *)src + len - 1; \
diff --git a/dev-util/valgrind/valgrind-9999.ebuild b/dev-util/valgrind/valgrind-3.21.0-r2.ebuild
similarity index 96%
copy from dev-util/valgrind/valgrind-9999.ebuild
copy to dev-util/valgrind/valgrind-3.21.0-r2.ebuild
index a32a0da1588d..8a4f5d8f4003 100644
--- a/dev-util/valgrind/valgrind-9999.ebuild
+++ b/dev-util/valgrind/valgrind-3.21.0-r2.ebuild
@@ -32,6 +32,8 @@ PATCHES=(
# Respect CFLAGS, LDFLAGS
"${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
"${FILESDIR}"/${PN}-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch
+ "${FILESDIR}"/${PN}-3.21.0-glibc-2.34-suppressions.patch
+ "${FILESDIR}"/${PN}-3.21.0-memcpy-fortify_source.patch
)
src_prepare() {
@@ -57,9 +59,7 @@ src_prepare() {
}
src_configure() {
- local myconf=(
- --with-gdbscripts-dir="${EPREFIX}"/usr/share/gdb/auto-load
- )
+ local myconf=()
# Respect ar, bug #468114
tc-export AR
diff --git a/dev-util/valgrind/valgrind-9999.ebuild b/dev-util/valgrind/valgrind-9999.ebuild
index a32a0da1588d..c1a57f63331b 100644
--- a/dev-util/valgrind/valgrind-9999.ebuild
+++ b/dev-util/valgrind/valgrind-9999.ebuild
@@ -32,6 +32,8 @@ PATCHES=(
# Respect CFLAGS, LDFLAGS
"${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
"${FILESDIR}"/${PN}-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch
+ "${FILESDIR}"/${PN}-3.21.0-glibc-2.34-suppressions.patch
+ "${FILESDIR}"/${PN}-3.21.0-memcpy-fortify_source.patch
)
src_prepare() {
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-util/valgrind/, dev-util/valgrind/files/
@ 2023-02-03 16:53 Sam James
0 siblings, 0 replies; 11+ messages in thread
From: Sam James @ 2023-02-03 16:53 UTC (permalink / raw
To: gentoo-commits
commit: 692265a7c229589d0529db3982dded2e8de1f8a1
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Feb 3 16:15:41 2023 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Feb 3 16:51:38 2023 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=692265a7
dev-util/valgrind: drop 3.19.0, 3.20.0
Signed-off-by: Sam James <sam <AT> gentoo.org>
dev-util/valgrind/Manifest | 1 -
.../valgrind/files/valgrind-3.19.0-clang-15.patch | 33 ------
dev-util/valgrind/valgrind-3.19.0.ebuild | 129 ---------------------
dev-util/valgrind/valgrind-3.20.0.ebuild | 129 ---------------------
4 files changed, 292 deletions(-)
diff --git a/dev-util/valgrind/Manifest b/dev-util/valgrind/Manifest
index c7f5d50fd001..28151efc39af 100644
--- a/dev-util/valgrind/Manifest
+++ b/dev-util/valgrind/Manifest
@@ -1,3 +1,2 @@
-DIST valgrind-3.19.0.tar.bz2 16403296 BLAKE2B d3ccd25789ec4d87a0ddab58d8098246a33a083505b42adaa94ee3af659cbe073e516bc98163ef56233e6cd9de2125839b71ee443fbc0db6557dcb35a6c05280 SHA512 f720a89dc4c4989cc5714bff9efe97529f71990bcfad7a92b889ce099c4326d6da07fa4d5fbab2e9125e20f352354f6178471e49e419b613a3c82c2a1c667ab2
DIST valgrind-3.20.0.tar.bz2 16469274 BLAKE2B 8217dcfc185c7f6601fedd8d53bb35d260b985b8049c8c73a26151db6650b1607e8e53b614652c40962ea7382b9301c4b234a933c8d81f57e649ebf3f703e630 SHA512 d6bfb9284d0410134ee7e2a5975b13c01508dd5587b562947d8197b3c113b76fdfac88c4072948be68bbf0dbeb17b4d1acb1412ce898adaa83c30ae2c6a1c12b
DIST valgrind-3.20.0.tar.bz2.asc 488 BLAKE2B 12642e4f85c7b17bdb892221f74d80ce919554ffde3cdfa79ca27f4c5f8b48dac699084b8296b5cea285b5af660a0bc51c42b108a725be60002b14f0fda7eac7 SHA512 70dd20f15b159ffbf016c118046ee42160dd867415f1c565a92995952b1720ec36fc48557f6b523d28e6f675d62df10a4022e900fa4a104626b9e6ed6fe9ad6d
diff --git a/dev-util/valgrind/files/valgrind-3.19.0-clang-15.patch b/dev-util/valgrind/files/valgrind-3.19.0-clang-15.patch
deleted file mode 100644
index 77b2e8b091a4..000000000000
--- a/dev-util/valgrind/files/valgrind-3.19.0-clang-15.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-https://sourceware.org/git/?p=valgrind.git;a=commit;h=1dbc46750f7f716ae3b9cf718380df77422379da
-https://bugs.gentoo.org/869320
-
-From: Paul Floyd <pjfloyd@wanadoo.fr>
-Date: Tue, 19 Apr 2022 22:03:01 +0200
-Subject: [PATCH] Bug 452779 Valgrind fails to build on FreeBSD 13.0 with
- llvm-devel (15.0.0)
-
-This fixes building.
-
-I may make the -lgcc and libgcc-sup conditonal on not using clang later.
---- a/Makefile.tool.am
-+++ b/Makefile.tool.am
-@@ -16,14 +16,14 @@ TOOL_DEPENDENCIES_@VGCONF_PLATFORM_SEC_CAPS@ = \
- $(top_builddir)/VEX/libvex-@VGCONF_ARCH_SEC@-@VGCONF_OS@.a
- endif
-
--
--TOOL_LDADD_COMMON = -lgcc \
-- $(top_builddir)/coregrind/libgcc-sup-@VGCONF_ARCH_PRI@-@VGCONF_OS@.a
-+TOOL_LDADD_COMMON = -lgcc
- TOOL_LDADD_@VGCONF_PLATFORM_PRI_CAPS@ = \
-- $(TOOL_DEPENDENCIES_@VGCONF_PLATFORM_PRI_CAPS@) $(TOOL_LDADD_COMMON)
-+ $(TOOL_DEPENDENCIES_@VGCONF_PLATFORM_PRI_CAPS@) $(TOOL_LDADD_COMMON) \
-+ $(top_builddir)/coregrind/libgcc-sup-@VGCONF_ARCH_PRI@-@VGCONF_OS@.a
- if VGCONF_HAVE_PLATFORM_SEC
- TOOL_LDADD_@VGCONF_PLATFORM_SEC_CAPS@ = \
-- $(TOOL_DEPENDENCIES_@VGCONF_PLATFORM_SEC_CAPS@) $(TOOL_LDADD_COMMON)
-+ $(TOOL_DEPENDENCIES_@VGCONF_PLATFORM_SEC_CAPS@) $(TOOL_LDADD_COMMON) \
-+ $(top_builddir)/coregrind/libgcc-sup-@VGCONF_ARCH_SEC@-@VGCONF_OS@.a
- endif
-
-
diff --git a/dev-util/valgrind/valgrind-3.19.0.ebuild b/dev-util/valgrind/valgrind-3.19.0.ebuild
deleted file mode 100644
index f7e812e805cc..000000000000
--- a/dev-util/valgrind/valgrind-3.19.0.ebuild
+++ /dev/null
@@ -1,129 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit autotools flag-o-matic toolchain-funcs multilib pax-utils
-
-DESCRIPTION="An open-source memory debugger for GNU/Linux"
-HOMEPAGE="https://valgrind.org"
-if [[ ${PV} == 9999 ]]; then
- EGIT_REPO_URI="https://sourceware.org/git/${PN}.git"
- inherit git-r3
-else
- SRC_URI="https://sourceware.org/pub/valgrind/${P}.tar.bz2"
- KEYWORDS="-* amd64 arm arm64 ppc ppc64 x86 ~amd64-linux ~x86-linux ~x64-macos ~x64-solaris"
-fi
-
-LICENSE="GPL-2"
-SLOT="0"
-IUSE="mpi"
-
-DEPEND="mpi? ( virtual/mpi )"
-RDEPEND="${DEPEND}"
-
-PATCHES=(
- # Respect CFLAGS, LDFLAGS
- "${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
- "${FILESDIR}"/${PN}-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch
- "${FILESDIR}"/${PN}-3.19.0-clang-15.patch
-)
-
-src_prepare() {
- # Correct hard coded doc location
- sed -i -e "s:doc/valgrind:doc/${PF}:" docs/Makefile.am || die
-
- # Don't force multiarch stuff on OSX, bug #306467
- sed -i -e 's:-arch \(i386\|x86_64\)::g' Makefile.all.am || die
-
- # Conditionally copy musl specific suppressions && apply patch
- if use elibc_musl ; then
- cp "${FILESDIR}/musl.supp" "${S}" || die
- PATCHES+=( "${FILESDIR}"/valgrind-3.13.0-malloc.patch )
- fi
-
- if [[ ${CHOST} == *-solaris* ]] ; then
- # upstream doesn't support this, but we don't build with
- # Sun/Oracle ld, we have a GNU toolchain, so get some things
- # working the Linux/GNU way
- find "${S}" -name "Makefile.am" -o -name "Makefile.tool.am" | xargs \
- sed -i -e 's:-M,/usr/lib/ld/map.noexstk:-z,noexecstack:' || die
- cp "${S}"/coregrind/link_tool_exe_{linux,solaris}.in
- fi
-
- default
-
- # Regenerate autotools files
- eautoreconf
-}
-
-src_configure() {
- local myconf=()
-
- # Respect ar, bug #468114
- tc-export AR
-
- # -fomit-frame-pointer "Assembler messages: Error: junk `8' after expression"
- # while compiling insn_sse.c in none/tests/x86
- # -fstack-protector more undefined references to __guard and __stack_smash_handler
- # because valgrind doesn't link to glibc (bug #114347)
- # -fstack-protector-all Fails same way as -fstack-protector/-fstack-protector-strong.
- # Note: -fstack-protector-explicit is a no-op for Valgrind, no need to strip it
- # -fstack-protector-strong See -fstack-protector (bug #620402)
- # -m64 -mx32 for multilib-portage, bug #398825
- # -ggdb3 segmentation fault on startup
- # -flto* fails to build, bug #858509
- filter-flags -fomit-frame-pointer
- filter-flags -fstack-protector
- filter-flags -fstack-protector-all
- filter-flags -fstack-protector-strong
- filter-flags -m64 -mx32
- replace-flags -ggdb3 -ggdb2
- filter-lto
-
- if use amd64 || use ppc64; then
- ! has_multilib_profile && myconf+=("--enable-only64bit")
- fi
-
- # Force bitness on darwin, bug #306467
- use x64-macos && myconf+=("--enable-only64bit")
-
- # Don't use mpicc unless the user asked for it (bug #258832)
- if ! use mpi; then
- myconf+=("--without-mpicc")
- fi
-
- econf "${myconf[@]}"
-}
-
-src_install() {
- default
-
- if [[ ${PV} == "9999" ]]; then
- # Otherwise FAQ.txt won't exist:
- emake -C docs FAQ.txt
- mv docs/FAQ.txt . || die "Couldn't move FAQ.txt"
- fi
-
- dodoc FAQ.txt
-
- pax-mark m "${ED}"/usr/$(get_libdir)/valgrind/*-*-linux
-
- if [[ ${CHOST} == *-darwin* ]] ; then
- # fix install_names on shared libraries, can't turn them into bundles,
- # as dyld won't load them any more then, bug #306467
- local l
- for l in "${ED}"/usr/lib/valgrind/*.so ; do
- install_name_tool -id "${EPREFIX}"/usr/lib/valgrind/${l##*/} "${l}"
- done
- fi
-}
-
-pkg_postinst() {
- elog "Valgrind will not work if glibc does not have debug symbols."
- elog "To fix this you can add splitdebug to FEATURES in make.conf"
- elog "and remerge glibc. See:"
- elog "https://bugs.gentoo.org/show_bug.cgi?id=214065"
- elog "https://bugs.gentoo.org/show_bug.cgi?id=274771"
- elog "https://bugs.gentoo.org/show_bug.cgi?id=388703"
-}
diff --git a/dev-util/valgrind/valgrind-3.20.0.ebuild b/dev-util/valgrind/valgrind-3.20.0.ebuild
deleted file mode 100644
index 5d8a7a3727cd..000000000000
--- a/dev-util/valgrind/valgrind-3.20.0.ebuild
+++ /dev/null
@@ -1,129 +0,0 @@
-# Copyright 1999-2023 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit autotools flag-o-matic toolchain-funcs multilib pax-utils
-
-DESCRIPTION="An open-source memory debugger for GNU/Linux"
-HOMEPAGE="https://valgrind.org"
-if [[ ${PV} == 9999 ]]; then
- EGIT_REPO_URI="https://sourceware.org/git/${PN}.git"
- inherit git-r3
-else
- SRC_URI="https://sourceware.org/pub/valgrind/${P}.tar.bz2"
- KEYWORDS="-* amd64 arm arm64 ~ppc ppc64 x86 ~amd64-linux ~x86-linux ~x64-macos ~x64-solaris"
-fi
-
-LICENSE="GPL-2"
-SLOT="0"
-IUSE="mpi"
-
-DEPEND="mpi? ( virtual/mpi )"
-RDEPEND="${DEPEND}"
-
-PATCHES=(
- # Respect CFLAGS, LDFLAGS
- "${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
- "${FILESDIR}"/${PN}-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch
- "${FILESDIR}"/${P}-tests-clang16.patch
-)
-
-src_prepare() {
- # Correct hard coded doc location
- sed -i -e "s:doc/valgrind:doc/${PF}:" docs/Makefile.am || die
-
- # Don't force multiarch stuff on OSX, bug #306467
- sed -i -e 's:-arch \(i386\|x86_64\)::g' Makefile.all.am || die
-
- # Conditionally copy musl specific suppressions && apply patch
- if use elibc_musl ; then
- cp "${FILESDIR}/musl.supp" "${S}" || die
- PATCHES+=( "${FILESDIR}"/valgrind-3.13.0-malloc.patch )
- fi
-
- if [[ ${CHOST} == *-solaris* ]] ; then
- # upstream doesn't support this, but we don't build with
- # Sun/Oracle ld, we have a GNU toolchain, so get some things
- # working the Linux/GNU way
- find "${S}" -name "Makefile.am" -o -name "Makefile.tool.am" | xargs \
- sed -i -e 's:-M,/usr/lib/ld/map.noexstk:-z,noexecstack:' || die
- cp "${S}"/coregrind/link_tool_exe_{linux,solaris}.in
- fi
-
- default
-
- # Regenerate autotools files
- eautoreconf
-}
-
-src_configure() {
- local myconf=()
-
- # Respect ar, bug #468114
- tc-export AR
-
- # -fomit-frame-pointer "Assembler messages: Error: junk `8' after expression"
- # while compiling insn_sse.c in none/tests/x86
- # -fstack-protector more undefined references to __guard and __stack_smash_handler
- # because valgrind doesn't link to glibc (bug #114347)
- # -fstack-protector-all Fails same way as -fstack-protector/-fstack-protector-strong.
- # Note: -fstack-protector-explicit is a no-op for Valgrind, no need to strip it
- # -fstack-protector-strong See -fstack-protector (bug #620402)
- # -m64 -mx32 for multilib-portage, bug #398825
- # -ggdb3 segmentation fault on startup
- # -flto* fails to build, bug #858509
- filter-flags -fomit-frame-pointer
- filter-flags -fstack-protector
- filter-flags -fstack-protector-all
- filter-flags -fstack-protector-strong
- filter-flags -m64 -mx32
- replace-flags -ggdb3 -ggdb2
- filter-lto
-
- if use amd64 || use ppc64; then
- ! has_multilib_profile && myconf+=("--enable-only64bit")
- fi
-
- # Force bitness on darwin, bug #306467
- use x64-macos && myconf+=("--enable-only64bit")
-
- # Don't use mpicc unless the user asked for it (bug #258832)
- if ! use mpi; then
- myconf+=("--without-mpicc")
- fi
-
- econf "${myconf[@]}"
-}
-
-src_install() {
- default
-
- if [[ ${PV} == "9999" ]]; then
- # Otherwise FAQ.txt won't exist:
- emake -C docs FAQ.txt
- mv docs/FAQ.txt . || die "Couldn't move FAQ.txt"
- fi
-
- dodoc FAQ.txt
-
- pax-mark m "${ED}"/usr/$(get_libdir)/valgrind/*-*-linux
-
- if [[ ${CHOST} == *-darwin* ]] ; then
- # fix install_names on shared libraries, can't turn them into bundles,
- # as dyld won't load them any more then, bug #306467
- local l
- for l in "${ED}"/usr/lib/valgrind/*.so ; do
- install_name_tool -id "${EPREFIX}"/usr/lib/valgrind/${l##*/} "${l}"
- done
- fi
-}
-
-pkg_postinst() {
- elog "Valgrind will not work if glibc does not have debug symbols."
- elog "To fix this you can add splitdebug to FEATURES in make.conf"
- elog "and remerge glibc. See:"
- elog "https://bugs.gentoo.org/show_bug.cgi?id=214065"
- elog "https://bugs.gentoo.org/show_bug.cgi?id=274771"
- elog "https://bugs.gentoo.org/show_bug.cgi?id=388703"
-}
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-util/valgrind/, dev-util/valgrind/files/
@ 2022-10-28 10:43 Sam James
0 siblings, 0 replies; 11+ messages in thread
From: Sam James @ 2022-10-28 10:43 UTC (permalink / raw
To: gentoo-commits
commit: 02d1a49f0e132101104b4d803f78af6a951ab0e5
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Oct 28 10:43:08 2022 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Oct 28 10:43:08 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=02d1a49f
dev-util/valgrind: drop 3.16.1, 3.17.0
Signed-off-by: Sam James <sam <AT> gentoo.org>
dev-util/valgrind/Manifest | 2 -
dev-util/valgrind/files/valgrind-3.17.0-lld.patch | 77 --------------
dev-util/valgrind/valgrind-3.16.1.ebuild | 119 ---------------------
dev-util/valgrind/valgrind-3.17.0.ebuild | 121 ----------------------
4 files changed, 319 deletions(-)
diff --git a/dev-util/valgrind/Manifest b/dev-util/valgrind/Manifest
index 1caffcb2df1d..756f26086c14 100644
--- a/dev-util/valgrind/Manifest
+++ b/dev-util/valgrind/Manifest
@@ -1,5 +1,3 @@
-DIST valgrind-3.16.1.tar.bz2 16262776 BLAKE2B 1c333c26827f7a8356869e8758da9dd6a7444642ac4f6377c84fdab8349b9cee1e9bf2cf2eb86043c4feffab342dd97da20e76d7566d0296189e6ea8483a8c65 SHA512 2a4173efe1b6facdd2f5c5ee8ed006704168eba1813736fccc8191d60363afd96197512cf42037e65f18d4ddd49adc74a54c47210df216fba3c46bf68ef0f950
-DIST valgrind-3.17.0.tar.bz2 16459075 BLAKE2B 96569db9bc3c25ca195a4caa64da6e96b9bff7edd82727fccccaa8307162e29f4e150386c7c9611152fc1afde609d0922aa84067957b72dff03810ee23045e9c SHA512 94de78942a7059e1ab84d1c0c0b8f3efd1c2d15c70b97bc7edc8136812778adb6f8187149d53a60a8c6a7c8b40534f9be5cfed0eb3c0c314545b681f950b108f
DIST valgrind-3.18.1.tar.bz2 16149159 BLAKE2B a98322e4c12ae1bc495659217bd398b85e459288e775ba5f543b9ce1faa5bdfc17791178c0e7b9703a31588cc4c7cbde814b7a43b2ec76e7362e2aeeb100d935 SHA512 a03b5cd7eafab4a1cea07f46464c1546ae1cb3d106649626b1e55658badf90e58d1f3854a38a33d5dffd8237f5555ae7e1f27a4b40e06254f87825c7fc61b59b
DIST valgrind-3.19.0.tar.bz2 16403296 BLAKE2B d3ccd25789ec4d87a0ddab58d8098246a33a083505b42adaa94ee3af659cbe073e516bc98163ef56233e6cd9de2125839b71ee443fbc0db6557dcb35a6c05280 SHA512 f720a89dc4c4989cc5714bff9efe97529f71990bcfad7a92b889ce099c4326d6da07fa4d5fbab2e9125e20f352354f6178471e49e419b613a3c82c2a1c667ab2
DIST valgrind-3.20.0.tar.bz2 16469274 BLAKE2B 8217dcfc185c7f6601fedd8d53bb35d260b985b8049c8c73a26151db6650b1607e8e53b614652c40962ea7382b9301c4b234a933c8d81f57e649ebf3f703e630 SHA512 d6bfb9284d0410134ee7e2a5975b13c01508dd5587b562947d8197b3c113b76fdfac88c4072948be68bbf0dbeb17b4d1acb1412ce898adaa83c30ae2c6a1c12b
diff --git a/dev-util/valgrind/files/valgrind-3.17.0-lld.patch b/dev-util/valgrind/files/valgrind-3.17.0-lld.patch
deleted file mode 100644
index 56a7c0f72f46..000000000000
--- a/dev-util/valgrind/files/valgrind-3.17.0-lld.patch
+++ /dev/null
@@ -1,77 +0,0 @@
-https://bugs.kde.org/show_bug.cgi?id=439046
----
-diff --git a/configure.ac b/configure.ac
-index 4582fb5d0..63fd6c25e 100755
---- a/configure.ac
-+++ b/configure.ac
-@@ -2639,30 +2639,52 @@ CFLAGS=$safe_CFLAGS
- # will reside. -Ttext aligns just the .text section start (but not any
- # other section).
- #
--# So test for -Ttext-segment which is supported by all bfd ld versions
-+# LLVM ld.lld 10.0 changed the semantics of its -Ttext. See "Breaking changes"
-+# in https://releases.llvm.org/10.0.0/tools/lld/docs/ReleaseNotes.html
-+# The --image-base option (since version 6.0?) provides the semantics needed.
-+# -Ttext-segment generates an error, but -Ttext now more closely
-+# follows the GNU (bfd) ld's -Ttext.
-+#
-+# So test first for --image-base support, and if that fails then
-+# for -Ttext-segment which is supported by all bfd ld versions
- # and use that if it exists. If it doesn't exist it must be an older
- # version of gold and we can fall back to using -Ttext which has the
- # right semantics.
-
--AC_MSG_CHECKING([if the linker accepts -Wl,-Ttext-segment])
--
- safe_CFLAGS=$CFLAGS
--CFLAGS="-static -nodefaultlibs -nostartfiles -Wl,-Ttext-segment=$valt_load_address_pri_norml -Werror"
-+AC_MSG_CHECKING([if the linker accepts -Wl,--image-base])
-+
-+CFLAGS="-static -nodefaultlibs -nostartfiles -Wl,--image-base=$valt_load_address_pri_norml -Werror"
-
- AC_LINK_IFELSE(
- [AC_LANG_SOURCE([int _start () { return 0; }])],
- [
- linker_using_t_text="no"
-- AC_SUBST([FLAG_T_TEXT], ["-Ttext-segment"])
-+ AC_SUBST([FLAG_T_TEXT], ["--image-base"])
- AC_MSG_RESULT([yes])
- ], [
-- linker_using_t_text="yes"
-- AC_SUBST([FLAG_T_TEXT], ["-Ttext"])
- AC_MSG_RESULT([no])
-+
-+ AC_MSG_CHECKING([if the linker accepts -Wl,-Ttext-segment])
-+
-+ CFLAGS="-static -nodefaultlibs -nostartfiles -Wl,-Ttext-segment=$valt_load_address_pri_norml -Werror"
-+
-+ AC_LINK_IFELSE(
-+ [AC_LANG_SOURCE([int _start () { return 0; }])],
-+ [
-+ linker_using_t_text="no"
-+ AC_SUBST([FLAG_T_TEXT], ["-Ttext-segment"])
-+ AC_MSG_RESULT([yes])
-+ ], [
-+ linker_using_t_text="yes"
-+ AC_SUBST([FLAG_T_TEXT], ["-Ttext"])
-+ AC_MSG_RESULT([no])
-+ ])
- ])
-+
- CFLAGS=$safe_CFLAGS
-
--# If the linker only supports -Ttext (not -Ttext-segment) then we will
-+# If the linker only supports -Ttext (not -Ttext-segment or --image-base) then we will
- # have to strip any build-id ELF NOTEs from the statically linked tools.
- # Otherwise the build-id NOTE might end up at the default load address.
- # (Pedantically if the linker is gold then -Ttext is fine, but newer
-@@ -2688,7 +2710,7 @@ AC_LINK_IFELSE(
- AC_MSG_RESULT([no])
- ])
- else
--AC_MSG_NOTICE([ld -Ttext-segment used, no need to strip build-id NOTEs.])
-+AC_MSG_NOTICE([ld --image-base or -Ttext-segment used, no need to strip build-id NOTEs.])
- AC_SUBST([FLAG_NO_BUILD_ID], [""])
- fi
- CFLAGS=$safe_CFLAGS
---
diff --git a/dev-util/valgrind/valgrind-3.16.1.ebuild b/dev-util/valgrind/valgrind-3.16.1.ebuild
deleted file mode 100644
index 268884944a78..000000000000
--- a/dev-util/valgrind/valgrind-3.16.1.ebuild
+++ /dev/null
@@ -1,119 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-inherit autotools flag-o-matic toolchain-funcs multilib pax-utils
-
-DESCRIPTION="An open-source memory debugger for GNU/Linux"
-HOMEPAGE="https://www.valgrind.org"
-LICENSE="GPL-2"
-SLOT="0"
-IUSE="mpi"
-
-if [[ ${PV} == "9999" ]]; then
- EGIT_REPO_URI="https://sourceware.org/git/${PN}.git"
- inherit git-r3
-else
- SRC_URI="https://sourceware.org/pub/valgrind/${P}.tar.bz2"
- KEYWORDS="-* amd64 arm arm64 ppc ppc64 x86 ~amd64-linux ~x86-linux ~x64-macos ~x64-solaris"
-fi
-
-DEPEND="mpi? ( virtual/mpi )"
-RDEPEND="${DEPEND}"
-
-src_prepare() {
- # Correct hard coded doc location
- sed -i -e "s:doc/valgrind:doc/${PF}:" docs/Makefile.am || die
-
- # Don't force multiarch stuff on OSX, bug #306467
- sed -i -e 's:-arch \(i386\|x86_64\)::g' Makefile.all.am || die
-
- # Respect CFLAGS, LDFLAGS
- eapply "${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
-
- eapply "${FILESDIR}"/${PN}-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch
-
- if [[ ${CHOST} == *-solaris* ]] ; then
- # upstream doesn't support this, but we don't build with
- # Sun/Oracle ld, we have a GNU toolchain, so get some things
- # working the Linux/GNU way
- find "${S}" -name "Makefile.am" -o -name "Makefile.tool.am" | xargs \
- sed -i -e 's:-M,/usr/lib/ld/map.noexstk:-z,noexecstack:' || die
- cp "${S}"/coregrind/link_tool_exe_{linux,solaris}.in
- fi
-
- # Allow users to test their own patches
- eapply_user
-
- # Regenerate autotools files
- eautoreconf
-}
-
-src_configure() {
- local myconf=()
-
- # Respect ar, bug #468114
- tc-export AR
-
- # -fomit-frame-pointer "Assembler messages: Error: junk `8' after expression"
- # while compiling insn_sse.c in none/tests/x86
- # -fstack-protector more undefined references to __guard and __stack_smash_handler
- # because valgrind doesn't link to glibc (bug #114347)
- # -fstack-protector-all Fails same way as -fstack-protector/-fstack-protector-strong.
- # Note: -fstack-protector-explicit is a no-op for Valgrind, no need to strip it
- # -fstack-protector-strong See -fstack-protector (bug #620402)
- # -m64 -mx32 for multilib-portage, bug #398825
- # -ggdb3 segmentation fault on startup
- filter-flags -fomit-frame-pointer
- filter-flags -fstack-protector
- filter-flags -fstack-protector-all
- filter-flags -fstack-protector-strong
- filter-flags -m64 -mx32
- replace-flags -ggdb3 -ggdb2
-
- if use amd64 || use ppc64; then
- ! has_multilib_profile && myconf+=("--enable-only64bit")
- fi
-
- # Force bitness on darwin, bug #306467
- use x64-macos && myconf+=("--enable-only64bit")
-
- # Don't use mpicc unless the user asked for it (bug #258832)
- if ! use mpi; then
- myconf+=("--without-mpicc")
- fi
-
- econf "${myconf[@]}"
-}
-
-src_install() {
- default
-
- if [[ ${PV} == "9999" ]]; then
- # Otherwise FAQ.txt won't exist:
- emake -C docs FAQ.txt
- mv docs/FAQ.txt . || die "Couldn't move FAQ.txt"
- fi
-
- dodoc FAQ.txt
-
- pax-mark m "${ED}"/usr/$(get_libdir)/valgrind/*-*-linux
-
- if [[ ${CHOST} == *-darwin* ]] ; then
- # fix install_names on shared libraries, can't turn them into bundles,
- # as dyld won't load them any more then, bug #306467
- local l
- for l in "${ED}"/usr/lib/valgrind/*.so ; do
- install_name_tool -id "${EPREFIX}"/usr/lib/valgrind/${l##*/} "${l}"
- done
- fi
-}
-
-pkg_postinst() {
- elog "Valgrind will not work if glibc does not have debug symbols."
- elog "To fix this you can add splitdebug to FEATURES in make.conf"
- elog "and remerge glibc. See:"
- elog "https://bugs.gentoo.org/show_bug.cgi?id=214065"
- elog "https://bugs.gentoo.org/show_bug.cgi?id=274771"
- elog "https://bugs.gentoo.org/show_bug.cgi?id=388703"
-}
diff --git a/dev-util/valgrind/valgrind-3.17.0.ebuild b/dev-util/valgrind/valgrind-3.17.0.ebuild
deleted file mode 100644
index d1d6fdd5f4cc..000000000000
--- a/dev-util/valgrind/valgrind-3.17.0.ebuild
+++ /dev/null
@@ -1,121 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-inherit autotools flag-o-matic toolchain-funcs multilib pax-utils
-
-DESCRIPTION="An open-source memory debugger for GNU/Linux"
-HOMEPAGE="https://www.valgrind.org"
-LICENSE="GPL-2"
-SLOT="0"
-IUSE="mpi"
-
-if [[ ${PV} == "9999" ]]; then
- EGIT_REPO_URI="https://sourceware.org/git/${PN}.git"
- inherit git-r3
-else
- SRC_URI="https://sourceware.org/pub/valgrind/${P}.tar.bz2"
- KEYWORDS="-* amd64 arm arm64 ppc ppc64 x86 ~amd64-linux ~x86-linux ~x64-macos ~x64-solaris"
-fi
-
-DEPEND="mpi? ( virtual/mpi )"
-RDEPEND="${DEPEND}"
-
-src_prepare() {
- # Correct hard coded doc location
- sed -i -e "s:doc/valgrind:doc/${PF}:" docs/Makefile.am || die
-
- # Don't force multiarch stuff on OSX, bug #306467
- sed -i -e 's:-arch \(i386\|x86_64\)::g' Makefile.all.am || die
-
- # Respect CFLAGS, LDFLAGS
- eapply "${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
-
- eapply "${FILESDIR}"/${PN}-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch
-
- eapply "${FILESDIR}"/${PN}-3.17.0-lld.patch
-
- if [[ ${CHOST} == *-solaris* ]] ; then
- # upstream doesn't support this, but we don't build with
- # Sun/Oracle ld, we have a GNU toolchain, so get some things
- # working the Linux/GNU way
- find "${S}" -name "Makefile.am" -o -name "Makefile.tool.am" | xargs \
- sed -i -e 's:-M,/usr/lib/ld/map.noexstk:-z,noexecstack:' || die
- cp "${S}"/coregrind/link_tool_exe_{linux,solaris}.in
- fi
-
- # Allow users to test their own patches
- eapply_user
-
- # Regenerate autotools files
- eautoreconf
-}
-
-src_configure() {
- local myconf=()
-
- # Respect ar, bug #468114
- tc-export AR
-
- # -fomit-frame-pointer "Assembler messages: Error: junk `8' after expression"
- # while compiling insn_sse.c in none/tests/x86
- # -fstack-protector more undefined references to __guard and __stack_smash_handler
- # because valgrind doesn't link to glibc (bug #114347)
- # -fstack-protector-all Fails same way as -fstack-protector/-fstack-protector-strong.
- # Note: -fstack-protector-explicit is a no-op for Valgrind, no need to strip it
- # -fstack-protector-strong See -fstack-protector (bug #620402)
- # -m64 -mx32 for multilib-portage, bug #398825
- # -ggdb3 segmentation fault on startup
- filter-flags -fomit-frame-pointer
- filter-flags -fstack-protector
- filter-flags -fstack-protector-all
- filter-flags -fstack-protector-strong
- filter-flags -m64 -mx32
- replace-flags -ggdb3 -ggdb2
-
- if use amd64 || use ppc64; then
- ! has_multilib_profile && myconf+=("--enable-only64bit")
- fi
-
- # Force bitness on darwin, bug #306467
- use x64-macos && myconf+=("--enable-only64bit")
-
- # Don't use mpicc unless the user asked for it (bug #258832)
- if ! use mpi; then
- myconf+=("--without-mpicc")
- fi
-
- econf "${myconf[@]}"
-}
-
-src_install() {
- default
-
- if [[ ${PV} == "9999" ]]; then
- # Otherwise FAQ.txt won't exist:
- emake -C docs FAQ.txt
- mv docs/FAQ.txt . || die "Couldn't move FAQ.txt"
- fi
-
- dodoc FAQ.txt
-
- pax-mark m "${ED}"/usr/$(get_libdir)/valgrind/*-*-linux
-
- if [[ ${CHOST} == *-darwin* ]] ; then
- # fix install_names on shared libraries, can't turn them into bundles,
- # as dyld won't load them any more then, bug #306467
- local l
- for l in "${ED}"/usr/lib/valgrind/*.so ; do
- install_name_tool -id "${EPREFIX}"/usr/lib/valgrind/${l##*/} "${l}"
- done
- fi
-}
-
-pkg_postinst() {
- elog "Valgrind will not work if glibc does not have debug symbols."
- elog "To fix this you can add splitdebug to FEATURES in make.conf"
- elog "and remerge glibc. See:"
- elog "https://bugs.gentoo.org/show_bug.cgi?id=214065"
- elog "https://bugs.gentoo.org/show_bug.cgi?id=274771"
- elog "https://bugs.gentoo.org/show_bug.cgi?id=388703"
-}
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-util/valgrind/, dev-util/valgrind/files/
@ 2019-11-04 17:39 Matt Turner
0 siblings, 0 replies; 11+ messages in thread
From: Matt Turner @ 2019-11-04 17:39 UTC (permalink / raw
To: gentoo-commits
commit: d720304b0505f3791eb088673aaba891b73b16d6
Author: Matt Turner <mattst88 <AT> gentoo <DOT> org>
AuthorDate: Mon Nov 4 17:37:34 2019 +0000
Commit: Matt Turner <mattst88 <AT> gentoo <DOT> org>
CommitDate: Mon Nov 4 17:39:10 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d720304b
dev-util/valgrind: Fix test suite build failure on ppc
Closes: https://bugs.gentoo.org/685070
Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org>
...5.0-Build-ldst_multiple-test-with-fno-pie.patch | 22 ++++++++++++++++++++++
dev-util/valgrind/valgrind-3.15.0.ebuild | 2 ++
dev-util/valgrind/valgrind-9999.ebuild | 2 ++
3 files changed, 26 insertions(+)
diff --git a/dev-util/valgrind/files/valgrind-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch b/dev-util/valgrind/files/valgrind-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch
new file mode 100644
index 00000000000..44176658df7
--- /dev/null
+++ b/dev-util/valgrind/files/valgrind-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch
@@ -0,0 +1,22 @@
+From beab8d9f8d65230567270331017184c8762faa42 Mon Sep 17 00:00:00 2001
+From: Matt Turner <mattst88@gmail.com>
+Date: Mon, 4 Nov 2019 09:12:16 -0800
+Subject: [PATCH] Build ldst_multiple test with -fno-pie
+
+Bug: https://bugs.gentoo.org/685070
+---
+ none/tests/ppc32/Makefile.am | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/none/tests/ppc32/Makefile.am b/none/tests/ppc32/Makefile.am
+index 11697c99a..222efd3f2 100644
+--- a/none/tests/ppc32/Makefile.am
++++ b/none/tests/ppc32/Makefile.am
+@@ -156,3 +156,4 @@ test_isa_2_07_part2_LDADD = -lm
+ test_tm_LDADD = -lm
+ test_touch_tm_LDADD = -lm
+
++ldst_multiple_CFLAGS = $(AM_CFLAGS) -fno-pie
+--
+2.23.0
+
diff --git a/dev-util/valgrind/valgrind-3.15.0.ebuild b/dev-util/valgrind/valgrind-3.15.0.ebuild
index b18a128859a..d252d9dcee4 100644
--- a/dev-util/valgrind/valgrind-3.15.0.ebuild
+++ b/dev-util/valgrind/valgrind-3.15.0.ebuild
@@ -31,6 +31,8 @@ src_prepare() {
# Respect CFLAGS, LDFLAGS
eapply "${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
+ eapply "${FILESDIR}"/${PN}-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch
+
if [[ ${CHOST} == *-solaris* ]] ; then
# upstream doesn't support this, but we don't build with
# Sun/Oracle ld, we have a GNU toolchain, so get some things
diff --git a/dev-util/valgrind/valgrind-9999.ebuild b/dev-util/valgrind/valgrind-9999.ebuild
index b7152e95dc5..41689a1904e 100644
--- a/dev-util/valgrind/valgrind-9999.ebuild
+++ b/dev-util/valgrind/valgrind-9999.ebuild
@@ -31,6 +31,8 @@ src_prepare() {
# Respect CFLAGS, LDFLAGS
eapply "${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
+ eapply "${FILESDIR}"/${PN}-3.15.0-Build-ldst_multiple-test-with-fno-pie.patch
+
if [[ ${CHOST} == *-solaris* ]] ; then
# upstream doesn't support this, but we don't build with
# Sun/Oracle ld, we have a GNU toolchain, so get some things
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-util/valgrind/, dev-util/valgrind/files/
@ 2018-09-05 12:25 Thomas Deutschmann
0 siblings, 0 replies; 11+ messages in thread
From: Thomas Deutschmann @ 2018-09-05 12:25 UTC (permalink / raw
To: gentoo-commits
commit: e276088867d6e2493f445a332ab85811ec23a403
Author: Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
AuthorDate: Wed Sep 5 12:24:48 2018 +0000
Commit: Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
CommitDate: Wed Sep 5 12:25:11 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e2760888
dev-util/valgrind: fix reading debug info from binaries built with -z
separate-code
Closes: https://bugs.gentoo.org/664882
Package-Manager: Portage-2.3.48, Repoman-2.3.10
...ept-read-only-PT_LOAD-segments-and-rodata.patch | 95 +++++++++++++++
...further-mappings-after-read-all-debuginfo.patch | 70 +++++++++++
dev-util/valgrind/valgrind-3.13.0-r3.ebuild | 128 +++++++++++++++++++++
3 files changed, 293 insertions(+)
diff --git a/dev-util/valgrind/files/valgrind-3.13.0-accept-read-only-PT_LOAD-segments-and-rodata.patch b/dev-util/valgrind/files/valgrind-3.13.0-accept-read-only-PT_LOAD-segments-and-rodata.patch
new file mode 100644
index 00000000000..41f73b43f35
--- /dev/null
+++ b/dev-util/valgrind/files/valgrind-3.13.0-accept-read-only-PT_LOAD-segments-and-rodata.patch
@@ -0,0 +1,95 @@
+See https://bugs.gentoo.org/664882
+
+From 64aa729bfae71561505a40c12755bd6b55bb3061 Mon Sep 17 00:00:00 2001
+From: Mark Wielaard <mark@klomp.org>
+Date: Thu, 12 Jul 2018 13:56:00 +0200
+Subject: [PATCH] Accept read-only PT_LOAD segments and .rodata.
+
+The new binutils ld -z separate-code option creates multiple read-only
+PT_LOAD segments and might place .rodata in a non-executable segment.
+
+Allow and keep track of separate read-only segments and allow a readonly
+page with .rodata section.
+
+Based on patches from Tom Hughes <tom@compton.nu> and
+H.J. Lu <hjl.tools@gmail.com>.
+
+https://bugs.kde.org/show_bug.cgi?id=395682
+---
+ coregrind/m_debuginfo/debuginfo.c | 2 --
+ coregrind/m_debuginfo/readelf.c | 34 +++++++++++++++++++++++--------
+ 3 files changed, 27 insertions(+), 10 deletions(-)
+
+--- a/coregrind/m_debuginfo/debuginfo.c
++++ b/coregrind/m_debuginfo/debuginfo.c
+@@ -957,9 +957,7 @@
+ # error "Unknown platform"
+ # endif
+
+-# if defined(VGP_x86_darwin) && DARWIN_VERS >= DARWIN_10_7
+ is_ro_map = seg->hasR && !seg->hasW && !seg->hasX;
+-# endif
+
+ # if defined(VGO_solaris)
+ is_rx_map = seg->hasR && seg->hasX && !seg->hasW;
+--- a/coregrind/m_debuginfo/readelf.c
++++ b/coregrind/m_debuginfo/readelf.c
+@@ -1785,7 +1785,7 @@
+ Bool loaded = False;
+ for (j = 0; j < VG_(sizeXA)(di->fsm.maps); j++) {
+ const DebugInfoMapping* map = VG_(indexXA)(di->fsm.maps, j);
+- if ( (map->rx || map->rw)
++ if ( (map->rx || map->rw || map->ro)
+ && map->size > 0 /* stay sane */
+ && a_phdr.p_offset >= map->foff
+ && a_phdr.p_offset < map->foff + map->size
+@@ -1816,6 +1816,16 @@
+ i, (UWord)item.bias);
+ loaded = True;
+ }
++ if (map->ro
++ && (a_phdr.p_flags & (PF_R | PF_W | PF_X))
++ == PF_R) {
++ item.exec = False;
++ VG_(addToXA)(svma_ranges, &item);
++ TRACE_SYMTAB(
++ "PT_LOAD[%ld]: acquired as ro, bias 0x%lx\n",
++ i, (UWord)item.bias);
++ loaded = True;
++ }
+ }
+ }
+ if (!loaded) {
+@@ -2083,17 +2093,25 @@
+ }
+ }
+
+- /* Accept .rodata where mapped as rx (data), even if zero-sized */
++ /* Accept .rodata where mapped as rx or rw (data), even if zero-sized */
+ if (0 == VG_(strcmp)(name, ".rodata")) {
+- if (inrx && !di->rodata_present) {
+- di->rodata_present = True;
++ if (!di->rodata_present) {
+ di->rodata_svma = svma;
+- di->rodata_avma = svma + inrx->bias;
++ di->rodata_avma = svma;
+ di->rodata_size = size;
+- di->rodata_bias = inrx->bias;
+ di->rodata_debug_svma = svma;
+- di->rodata_debug_bias = inrx->bias;
+- /* NB was 'inrw' prior to r11794 */
++ if (inrx) {
++ di->rodata_avma += inrx->bias;
++ di->rodata_bias = inrx->bias;
++ di->rodata_debug_bias = inrx->bias;
++ } else if (inrw) {
++ di->rodata_avma += inrw->bias;
++ di->rodata_bias = inrw->bias;
++ di->rodata_debug_bias = inrw->bias;
++ } else {
++ BAD(".rodata");
++ }
++ di->rodata_present = True;
+ TRACE_SYMTAB("acquiring .rodata svma = %#lx .. %#lx\n",
+ di->rodata_svma,
+ di->rodata_svma + di->rodata_size - 1);
diff --git a/dev-util/valgrind/files/valgrind-3.13.0-ignore-further-mappings-after-read-all-debuginfo.patch b/dev-util/valgrind/files/valgrind-3.13.0-ignore-further-mappings-after-read-all-debuginfo.patch
new file mode 100644
index 00000000000..5b47512c155
--- /dev/null
+++ b/dev-util/valgrind/files/valgrind-3.13.0-ignore-further-mappings-after-read-all-debuginfo.patch
@@ -0,0 +1,70 @@
+Follow up for valgrind-3.13.0-accept-read-only-PT_LOAD-segments-and-rodata.patch.
+
+From e752326cc050803c3bcfde1f8606bead66ff9642 Mon Sep 17 00:00:00 2001
+From: Julian Seward <jseward@acm.org>
+Date: Tue, 14 Aug 2018 10:13:46 +0200
+Subject: [PATCH] VG_(di_notify_mmap): once we've read debuginfo for an object,
+ ignore all further mappings. n-i-bz.
+
+Once we've read debuginfo for an object, ignore all further mappings. If we
+don't do that, applications that mmap in their own objects to inspect them for
+whatever reason, will cause "irrelevant" mappings to be recorded in the
+object's fsm.maps table. This can lead to serious problems later on.
+
+This has become necessary because 64aa729bfae71561505a40c12755bd6b55bb3061 of
+Thu Jul 12 2018 (the fix for bug 395682) started recording readonly segments
+in the fsm.maps table, where before they were ignored.
+---
+ coregrind/m_debuginfo/debuginfo.c | 29 ++++++++++++++++++++++++++++-
+ 1 file changed, 28 insertions(+), 1 deletion(-)
+
+diff --git a/coregrind/m_debuginfo/debuginfo.c b/coregrind/m_debuginfo/debuginfo.c
+index c36d498..55c05cb 100644
+--- a/coregrind/m_debuginfo/debuginfo.c
++++ b/coregrind/m_debuginfo/debuginfo.c
+@@ -1200,6 +1200,32 @@ ULong VG_(di_notify_mmap)( Addr a, Bool allow_SkFileV, Int use_fd )
+ di = find_or_create_DebugInfo_for( filename );
+ vg_assert(di);
+
++ /* Ignore all mappings for this filename once we've read debuginfo for it.
++ This avoids the confusion of picking up "irrelevant" mappings in
++ applications which mmap their objects outside of ld.so, for example
++ Firefox's Gecko profiler.
++
++ What happens in that case is: the application maps the object "ro" for
++ whatever reason. We record the mapping di->fsm.maps. The application
++ later unmaps the object. However, the mapping is not removed from
++ di->fsm.maps. Later, when some other (unrelated) object is mapped (via
++ ld.so) into that address space, we first unload any debuginfo that has a
++ mapping intersecting that area. That means we will end up incorrectly
++ unloading debuginfo for the object with the "irrelevant" mappings. This
++ causes various problems, not least because it can unload the debuginfo
++ for libc.so and so cause malloc intercepts to become un-intercepted.
++
++ This fix assumes that all mappings made once we've read debuginfo for
++ an object are irrelevant. I think that's OK, but need to check with
++ mjw/thh. */
++ if (di->have_dinfo) {
++ if (debug)
++ VG_(printf)("di_notify_mmap-4x: "
++ "ignoring mapping because we already read debuginfo "
++ "for DebugInfo* %p\n", di);
++ return 0;
++ }
++
+ if (debug)
+ VG_(printf)("di_notify_mmap-4: "
+ "noting details in DebugInfo* at %p\n", di);
+@@ -1220,7 +1246,8 @@ ULong VG_(di_notify_mmap)( Addr a, Bool allow_SkFileV, Int use_fd )
+ di->fsm.have_ro_map |= is_ro_map;
+
+ /* So, finally, are we in an accept state? */
+- if (di->fsm.have_rx_map && di->fsm.have_rw_map && !di->have_dinfo) {
++ vg_assert(!di->have_dinfo);
++ if (di->fsm.have_rx_map && di->fsm.have_rw_map) {
+ /* Ok, so, finally, we found what we need, and we haven't
+ already read debuginfo for this object. So let's do so now.
+ Yee-ha! */
+--
+2.9.3
+
diff --git a/dev-util/valgrind/valgrind-3.13.0-r3.ebuild b/dev-util/valgrind/valgrind-3.13.0-r3.ebuild
new file mode 100644
index 00000000000..4c963a7314d
--- /dev/null
+++ b/dev-util/valgrind/valgrind-3.13.0-r3.ebuild
@@ -0,0 +1,128 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+inherit autotools flag-o-matic toolchain-funcs multilib pax-utils
+
+DESCRIPTION="An open-source memory debugger for GNU/Linux"
+HOMEPAGE="http://www.valgrind.org"
+LICENSE="GPL-2"
+SLOT="0"
+IUSE="mpi"
+
+if [[ ${PV} == "9999" ]]; then
+ EGIT_REPO_URI="git://sourceware.org/git/${PN}.git/"
+ inherit git-r3
+else
+ SRC_URI="ftp://sourceware.org/pub/valgrind/${P}.tar.bz2"
+ KEYWORDS="-* ~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x86-macos ~x64-solaris"
+fi
+
+DEPEND="mpi? ( virtual/mpi )"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ # Correct hard coded doc location
+ sed -i -e "s:doc/valgrind:doc/${PF}:" docs/Makefile.am || die
+
+ # Don't force multiarch stuff on OSX, bug #306467
+ sed -i -e 's:-arch \(i386\|x86_64\)::g' Makefile.all.am || die
+
+ # Respect CFLAGS, LDFLAGS
+ eapply "${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
+
+ # Fix test failures on glibc-2.26
+ eapply "${FILESDIR}"/${P}-test-fixes.patch
+
+ # Fix --xml-socket command line option (qt-creator), bug #641790
+ eapply "${FILESDIR}"/${P}-xml-socket.patch
+
+ # Fix reading debug info from binaries built with -z separate-code, bug #664882
+ eapply "${FILESDIR}"/${P}-accept-read-only-PT_LOAD-segments-and-rodata.patch
+ eapply "${FILESDIR}"/${P}-ignore-further-mappings-after-read-all-debuginfo.patch
+
+ if [[ ${CHOST} == *-solaris* ]] ; then
+ # upstream doesn't support this, but we don't build with
+ # Sun/Oracle ld, we have a GNU toolchain, so get some things
+ # working the Linux/GNU way
+ find "${S}" -name "Makefile.am" -o -name "Makefile.tool.am" | xargs \
+ sed -i -e 's:-M,/usr/lib/ld/map.noexstk:-z,noexecstack:' || die
+ cp "${S}"/coregrind/link_tool_exe_{linux,solaris}.in
+ fi
+
+ # Allow users to test their own patches
+ eapply_user
+
+ # Regenerate autotools files
+ eautoreconf
+}
+
+src_configure() {
+ local myconf=()
+
+ # Respect ar, bug #468114
+ tc-export AR
+
+ # -fomit-frame-pointer "Assembler messages: Error: junk `8' after expression"
+ # while compiling insn_sse.c in none/tests/x86
+ # -fstack-protector more undefined references to __guard and __stack_smash_handler
+ # because valgrind doesn't link to glibc (bug #114347)
+ # -fstack-protector-all Fails same way as -fstack-protector/-fstack-protector-strong.
+ # Note: -fstack-protector-explicit is a no-op for Valgrind, no need to strip it
+ # -fstack-protector-strong See -fstack-protector (bug #620402)
+ # -m64 -mx32 for multilib-portage, bug #398825
+ # -ggdb3 segmentation fault on startup
+ filter-flags -fomit-frame-pointer
+ filter-flags -fstack-protector
+ filter-flags -fstack-protector-all
+ filter-flags -fstack-protector-strong
+ filter-flags -m64 -mx32
+ replace-flags -ggdb3 -ggdb2
+
+ if use amd64 || use ppc64; then
+ ! has_multilib_profile && myconf+=("--enable-only64bit")
+ fi
+
+ # Force bitness on darwin, bug #306467
+ use x86-macos && myconf+=("--enable-only32bit")
+ use x64-macos && myconf+=("--enable-only64bit")
+
+ # Don't use mpicc unless the user asked for it (bug #258832)
+ if ! use mpi; then
+ myconf+=("--without-mpicc")
+ fi
+
+ econf "${myconf[@]}"
+}
+
+src_install() {
+ default
+
+ if [[ ${PV} == "9999" ]]; then
+ # Otherwise FAQ.txt won't exist:
+ emake -C docs FAQ.txt
+ mv docs/FAQ.txt . || die "Couldn't move FAQ.txt"
+ fi
+
+ dodoc FAQ.txt
+
+ pax-mark m "${ED}"/usr/$(get_libdir)/valgrind/*-*-linux
+
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ # fix install_names on shared libraries, can't turn them into bundles,
+ # as dyld won't load them any more then, bug #306467
+ local l
+ for l in "${ED}"/usr/lib/valgrind/*.so ; do
+ install_name_tool -id "${EPREFIX}"/usr/lib/valgrind/${l##*/} "${l}"
+ done
+ fi
+}
+
+pkg_postinst() {
+ elog "Valgrind will not work if glibc does not have debug symbols."
+ elog "To fix this you can add splitdebug to FEATURES in make.conf"
+ elog "and remerge glibc. See:"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=214065"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=274771"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=388703"
+}
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-util/valgrind/, dev-util/valgrind/files/
@ 2018-02-28 17:54 Austin English
0 siblings, 0 replies; 11+ messages in thread
From: Austin English @ 2018-02-28 17:54 UTC (permalink / raw
To: gentoo-commits
commit: 727a3c7b1f8094d1a66314e64077fe93dbe5dd2d
Author: Azamat H. Hackimov <azamat.hackimov <AT> gmail <DOT> com>
AuthorDate: Wed Dec 20 07:10:04 2017 +0000
Commit: Austin English <wizardedit <AT> gentoo <DOT> org>
CommitDate: Wed Feb 28 17:54:10 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=727a3c7b
dev-util/valgrind: fix for --xml-socket option
Fix for Qt Creator working.
Closes: https://bugs.gentoo.org/641790
Package-Manager: Portage-2.3.13, Repoman-2.3.3
.../files/valgrind-3.13.0-xml-socket.patch | 27 ++++++++++++++++++++++
...grind-9999.ebuild => valgrind-3.13.0-r2.ebuild} | 26 +++++++++++++--------
dev-util/valgrind/valgrind-9999.ebuild | 20 ++++++++--------
3 files changed, 53 insertions(+), 20 deletions(-)
diff --git a/dev-util/valgrind/files/valgrind-3.13.0-xml-socket.patch b/dev-util/valgrind/files/valgrind-3.13.0-xml-socket.patch
new file mode 100644
index 00000000000..56039c48bc2
--- /dev/null
+++ b/dev-util/valgrind/files/valgrind-3.13.0-xml-socket.patch
@@ -0,0 +1,27 @@
+From: Ivo Raisr <ivosh@ivosh.net>
+Date: Thu, 3 Aug 2017 05:22:01 +0000 (+0000)
+Subject: Fix handling command line option --xml-socket.
+X-Git-Url: https://sourceware.org/git/?p=valgrind.git;a=commitdiff_plain;h=34dd8493de39314033509bb7ad62673f33dcf3db
+
+Fix handling command line option --xml-socket.
+Fixes BZ#382998
+Patch by: Orgad Shaneh <orgads@gmail.com>
+
+
+
+git-svn-id: svn://svn.valgrind.org/valgrind/trunk@16467
+---
+
+diff --git a/coregrind/m_libcprint.c b/coregrind/m_libcprint.c
+index d66c67d..f6ba202 100644
+--- a/coregrind/m_libcprint.c
++++ b/coregrind/m_libcprint.c
+@@ -526,7 +526,7 @@ void VG_(init_log_xml_sinks)(VgLogTo log_to, VgLogTo xml_to,
+ break;
+
+ case VgLogTo_Socket:
+- log_fd = prepare_sink_socket(VG_(clo_xml_fname_unexpanded),
++ xml_fd = prepare_sink_socket(VG_(clo_xml_fname_unexpanded),
+ &VG_(xml_output_sink), True);
+ break;
+ }
diff --git a/dev-util/valgrind/valgrind-9999.ebuild b/dev-util/valgrind/valgrind-3.13.0-r2.ebuild
similarity index 85%
copy from dev-util/valgrind/valgrind-9999.ebuild
copy to dev-util/valgrind/valgrind-3.13.0-r2.ebuild
index 855bd8a16c2..f509e509703 100644
--- a/dev-util/valgrind/valgrind-9999.ebuild
+++ b/dev-util/valgrind/valgrind-3.13.0-r2.ebuild
@@ -1,7 +1,7 @@
-# Copyright 1999-2017 Gentoo Foundation
+# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-EAPI="6"
+EAPI=6
inherit autotools flag-o-matic toolchain-funcs multilib pax-utils
DESCRIPTION="An open-source memory debugger for GNU/Linux"
@@ -31,6 +31,12 @@ src_prepare() {
# Respect CFLAGS, LDFLAGS
eapply "${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
+ # Fix test failures on glibc-2.26
+ eapply "${FILESDIR}"/${P}-test-fixes.patch
+
+ # Fix --xml-socket command line option (qt-creator), bug #641790
+ eapply "${FILESDIR}"/${P}-xml-socket.patch
+
# Allow users to test their own patches
eapply_user
@@ -39,7 +45,7 @@ src_prepare() {
}
src_configure() {
- local myconf
+ local myconf=()
# Respect ar, bug #468114
tc-export AR
@@ -61,23 +67,23 @@ src_configure() {
replace-flags -ggdb3 -ggdb2
if use amd64 || use ppc64; then
- ! has_multilib_profile && myconf="${myconf} --enable-only64bit"
+ ! has_multilib_profile && myconf+=("--enable-only64bit")
fi
# Force bitness on darwin, bug #306467
- use x86-macos && myconf="${myconf} --enable-only32bit"
- use x64-macos && myconf="${myconf} --enable-only64bit"
+ use x86-macos && myconf+=("--enable-only32bit")
+ use x64-macos && myconf+=("--enable-only64bit")
# Don't use mpicc unless the user asked for it (bug #258832)
if ! use mpi; then
- myconf="${myconf} --without-mpicc"
+ myconf+=("--without-mpicc")
fi
- econf ${myconf}
+ econf "${myconf[@]}"
}
src_install() {
- emake DESTDIR="${D}" install
+ default
if [[ ${PV} == "9999" ]]; then
# Otherwise FAQ.txt won't exist:
@@ -85,7 +91,7 @@ src_install() {
mv docs/FAQ.txt . || die "Couldn't move FAQ.txt"
fi
- dodoc AUTHORS FAQ.txt NEWS README*
+ dodoc FAQ.txt
pax-mark m "${ED}"/usr/$(get_libdir)/valgrind/*-*-linux
diff --git a/dev-util/valgrind/valgrind-9999.ebuild b/dev-util/valgrind/valgrind-9999.ebuild
index 855bd8a16c2..2b96d5f5150 100644
--- a/dev-util/valgrind/valgrind-9999.ebuild
+++ b/dev-util/valgrind/valgrind-9999.ebuild
@@ -1,7 +1,7 @@
-# Copyright 1999-2017 Gentoo Foundation
+# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-EAPI="6"
+EAPI=6
inherit autotools flag-o-matic toolchain-funcs multilib pax-utils
DESCRIPTION="An open-source memory debugger for GNU/Linux"
@@ -39,7 +39,7 @@ src_prepare() {
}
src_configure() {
- local myconf
+ local myconf=()
# Respect ar, bug #468114
tc-export AR
@@ -61,23 +61,23 @@ src_configure() {
replace-flags -ggdb3 -ggdb2
if use amd64 || use ppc64; then
- ! has_multilib_profile && myconf="${myconf} --enable-only64bit"
+ ! has_multilib_profile && myconf+=("--enable-only64bit")
fi
# Force bitness on darwin, bug #306467
- use x86-macos && myconf="${myconf} --enable-only32bit"
- use x64-macos && myconf="${myconf} --enable-only64bit"
+ use x86-macos && myconf+=("--enable-only32bit")
+ use x64-macos && myconf+=("--enable-only64bit")
# Don't use mpicc unless the user asked for it (bug #258832)
if ! use mpi; then
- myconf="${myconf} --without-mpicc"
+ myconf+=("--without-mpicc")
fi
- econf ${myconf}
+ econf "${myconf[@]}"
}
src_install() {
- emake DESTDIR="${D}" install
+ default
if [[ ${PV} == "9999" ]]; then
# Otherwise FAQ.txt won't exist:
@@ -85,7 +85,7 @@ src_install() {
mv docs/FAQ.txt . || die "Couldn't move FAQ.txt"
fi
- dodoc AUTHORS FAQ.txt NEWS README*
+ dodoc FAQ.txt
pax-mark m "${ED}"/usr/$(get_libdir)/valgrind/*-*-linux
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-util/valgrind/, dev-util/valgrind/files/
@ 2017-12-12 21:59 Austin English
0 siblings, 0 replies; 11+ messages in thread
From: Austin English @ 2017-12-12 21:59 UTC (permalink / raw
To: gentoo-commits
commit: c0dad8f0e252a0e30dbbe4e1f285f619374fed84
Author: Austin English <wizardedit <AT> gentoo <DOT> org>
AuthorDate: Tue Dec 12 21:36:05 2017 +0000
Commit: Austin English <wizardedit <AT> gentoo <DOT> org>
CommitDate: Tue Dec 12 21:59:33 2017 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c0dad8f0
dev-util/valgrind: fix test failures with newer glibc-3.13.0
Gentoo-Bug: https://bugs.gentoo.org/637488
Package-Manager: Portage-2.3.13, Repoman-2.3.3
.../files/valgrind-3.13.0-test-fixes.patch | 29 ++++++
dev-util/valgrind/valgrind-3.13.0-r1.ebuild | 112 +++++++++++++++++++++
2 files changed, 141 insertions(+)
diff --git a/dev-util/valgrind/files/valgrind-3.13.0-test-fixes.patch b/dev-util/valgrind/files/valgrind-3.13.0-test-fixes.patch
new file mode 100644
index 00000000000..9bdd29013ba
--- /dev/null
+++ b/dev-util/valgrind/files/valgrind-3.13.0-test-fixes.patch
@@ -0,0 +1,29 @@
+See:
+https://bugs.gentoo.org/637488
+https://bugs.kde.org/show_bug.cgi?id=387686
+
+commit 2b5eab6a8db1b0487a3ad7fc4e7eeda6d3513626
+Author: Mark Wielaard <mark@klomp.org>
+Date: Thu Jun 29 15:26:30 2017 +0000
+
+ memcheck/tests: Use ucontext_t instead of struct ucontext
+
+ glibc 2.26 does not expose struct ucontext anymore.
+
+ Signed-off-by: Khem Raj <raj.khem@gmail.com>
+
+ git-svn-id: svn://svn.valgrind.org/valgrind/trunk@16457
+
+diff --git a/memcheck/tests/linux/stack_changes.c b/memcheck/tests/linux/stack_changes.c
+index a978fc2b0..7f97b90a5 100644
+--- a/memcheck/tests/linux/stack_changes.c
++++ b/memcheck/tests/linux/stack_changes.c
+@@ -10,7 +10,7 @@
+ // This test is checking the libc context calls (setcontext, etc.) and
+ // checks that Valgrind notices their stack changes properly.
+
+-typedef struct ucontext mycontext;
++typedef ucontext_t mycontext;
+
+ mycontext ctx1, ctx2, oldc;
+ int count;
diff --git a/dev-util/valgrind/valgrind-3.13.0-r1.ebuild b/dev-util/valgrind/valgrind-3.13.0-r1.ebuild
new file mode 100644
index 00000000000..1abaadfd609
--- /dev/null
+++ b/dev-util/valgrind/valgrind-3.13.0-r1.ebuild
@@ -0,0 +1,112 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="6"
+inherit autotools flag-o-matic toolchain-funcs multilib pax-utils
+
+DESCRIPTION="An open-source memory debugger for GNU/Linux"
+HOMEPAGE="http://www.valgrind.org"
+LICENSE="GPL-2"
+SLOT="0"
+IUSE="mpi"
+
+if [[ ${PV} == "9999" ]]; then
+ EGIT_REPO_URI="git://sourceware.org/git/${PN}.git/"
+ inherit git-r3
+else
+ SRC_URI="ftp://sourceware.org/pub/valgrind/${P}.tar.bz2"
+ KEYWORDS="-* ~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x86-macos"
+fi
+
+DEPEND="mpi? ( virtual/mpi )"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ # Correct hard coded doc location
+ sed -i -e "s:doc/valgrind:doc/${PF}:" docs/Makefile.am || die
+
+ # Don't force multiarch stuff on OSX, bug #306467
+ sed -i -e 's:-arch \(i386\|x86_64\)::g' Makefile.all.am || die
+
+ # Respect CFLAGS, LDFLAGS
+ eapply "${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
+
+ # Fix test failures on glibc-2.26
+ eapply "${FILESDIR}"/${P}-test-fixes.patch
+
+ # Allow users to test their own patches
+ eapply_user
+
+ # Regenerate autotools files
+ eautoreconf
+}
+
+src_configure() {
+ local myconf
+
+ # Respect ar, bug #468114
+ tc-export AR
+
+ # -fomit-frame-pointer "Assembler messages: Error: junk `8' after expression"
+ # while compiling insn_sse.c in none/tests/x86
+ # -fstack-protector more undefined references to __guard and __stack_smash_handler
+ # because valgrind doesn't link to glibc (bug #114347)
+ # -fstack-protector-all Fails same way as -fstack-protector/-fstack-protector-strong.
+ # Note: -fstack-protector-explicit is a no-op for Valgrind, no need to strip it
+ # -fstack-protector-strong See -fstack-protector (bug #620402)
+ # -m64 -mx32 for multilib-portage, bug #398825
+ # -ggdb3 segmentation fault on startup
+ filter-flags -fomit-frame-pointer
+ filter-flags -fstack-protector
+ filter-flags -fstack-protector-all
+ filter-flags -fstack-protector-strong
+ filter-flags -m64 -mx32
+ replace-flags -ggdb3 -ggdb2
+
+ if use amd64 || use ppc64; then
+ ! has_multilib_profile && myconf="${myconf} --enable-only64bit"
+ fi
+
+ # Force bitness on darwin, bug #306467
+ use x86-macos && myconf="${myconf} --enable-only32bit"
+ use x64-macos && myconf="${myconf} --enable-only64bit"
+
+ # Don't use mpicc unless the user asked for it (bug #258832)
+ if ! use mpi; then
+ myconf="${myconf} --without-mpicc"
+ fi
+
+ econf ${myconf}
+}
+
+src_install() {
+ emake DESTDIR="${D}" install
+
+ if [[ ${PV} == "9999" ]]; then
+ # Otherwise FAQ.txt won't exist:
+ emake -C docs FAQ.txt
+ mv docs/FAQ.txt . || die "Couldn't move FAQ.txt"
+ fi
+
+ dodoc AUTHORS FAQ.txt NEWS README*
+
+ pax-mark m "${ED}"/usr/$(get_libdir)/valgrind/*-*-linux
+
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ # fix install_names on shared libraries, can't turn them into bundles,
+ # as dyld won't load them any more then, bug #306467
+ local l
+ for l in "${ED}"/usr/lib/valgrind/*.so ; do
+ install_name_tool -id "${EPREFIX}"/usr/lib/valgrind/${l##*/} "${l}"
+ done
+ fi
+}
+
+pkg_postinst() {
+ elog "Valgrind will not work if glibc does not have debug symbols."
+ elog "To fix this you can add splitdebug to FEATURES in make.conf"
+ elog "and remerge glibc. See:"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=214065"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=274771"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=388703"
+}
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-util/valgrind/, dev-util/valgrind/files/
@ 2016-10-26 19:09 Matthias Schwarzott
0 siblings, 0 replies; 11+ messages in thread
From: Matthias Schwarzott @ 2016-10-26 19:09 UTC (permalink / raw
To: gentoo-commits
commit: eed44ac50d1a0b0643909f59259751b174879bf1
Author: Matthias Schwarzott <zzam <AT> gentoo <DOT> org>
AuthorDate: Wed Oct 26 19:07:52 2016 +0000
Commit: Matthias Schwarzott <zzam <AT> gentoo <DOT> org>
CommitDate: Wed Oct 26 19:07:52 2016 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=eed44ac5
dev-util/valgrind: drop no longer needed executable stack patch from version 3.12.0
Package-Manager: portage-2.3.2
.../files/valgrind-3.12.0-non-exec-stack.patch | 86 ----------------------
dev-util/valgrind/valgrind-3.12.0.ebuild | 4 -
2 files changed, 90 deletions(-)
diff --git a/dev-util/valgrind/files/valgrind-3.12.0-non-exec-stack.patch b/dev-util/valgrind/files/valgrind-3.12.0-non-exec-stack.patch
deleted file mode 100644
index 7f41eff..00000000
--- a/dev-util/valgrind/files/valgrind-3.12.0-non-exec-stack.patch
+++ /dev/null
@@ -1,86 +0,0 @@
-diff -Naur valgrind-3.12.0.orig/coregrind/Makefile.am valgrind-3.12.0/coregrind/Makefile.am
---- valgrind-3.12.0.orig/coregrind/Makefile.am 2016-10-21 06:37:39.000000000 -0400
-+++ valgrind-3.12.0/coregrind/Makefile.am 2016-10-23 16:05:46.904546117 -0400
-@@ -359,21 +359,6 @@
- m_demangle/dyn-string.c \
- m_demangle/d-demangle.c \
- m_demangle/safe-ctype.c \
-- m_dispatch/dispatch-x86-linux.S \
-- m_dispatch/dispatch-amd64-linux.S \
-- m_dispatch/dispatch-ppc32-linux.S \
-- m_dispatch/dispatch-ppc64be-linux.S \
-- m_dispatch/dispatch-ppc64le-linux.S \
-- m_dispatch/dispatch-arm-linux.S \
-- m_dispatch/dispatch-arm64-linux.S \
-- m_dispatch/dispatch-s390x-linux.S \
-- m_dispatch/dispatch-mips32-linux.S \
-- m_dispatch/dispatch-mips64-linux.S \
-- m_dispatch/dispatch-tilegx-linux.S \
-- m_dispatch/dispatch-x86-darwin.S \
-- m_dispatch/dispatch-amd64-darwin.S \
-- m_dispatch/dispatch-x86-solaris.S \
-- m_dispatch/dispatch-amd64-solaris.S \
- m_gdbserver/inferiors.c \
- m_gdbserver/m_gdbserver.c \
- m_gdbserver/regcache.c \
-@@ -399,8 +384,6 @@
- m_initimg/initimg-pathscan.c \
- m_mach/mach_basics.c \
- m_mach/mach_msg.c \
-- m_mach/mach_traps-x86-darwin.S \
-- m_mach/mach_traps-amd64-darwin.S \
- m_replacemalloc/replacemalloc_core.c \
- m_scheduler/sched-lock.c \
- m_scheduler/sched-lock-generic.c \
-@@ -420,21 +403,6 @@
- m_sigframe/sigframe-x86-darwin.c \
- m_sigframe/sigframe-amd64-darwin.c \
- m_sigframe/sigframe-solaris.c \
-- m_syswrap/syscall-x86-linux.S \
-- m_syswrap/syscall-amd64-linux.S \
-- m_syswrap/syscall-ppc32-linux.S \
-- m_syswrap/syscall-ppc64be-linux.S \
-- m_syswrap/syscall-ppc64le-linux.S \
-- m_syswrap/syscall-arm-linux.S \
-- m_syswrap/syscall-arm64-linux.S \
-- m_syswrap/syscall-s390x-linux.S \
-- m_syswrap/syscall-mips32-linux.S \
-- m_syswrap/syscall-mips64-linux.S \
-- m_syswrap/syscall-tilegx-linux.S \
-- m_syswrap/syscall-x86-darwin.S \
-- m_syswrap/syscall-amd64-darwin.S \
-- m_syswrap/syscall-x86-solaris.S \
-- m_syswrap/syscall-amd64-solaris.S \
- m_syswrap/syswrap-main.c \
- m_syswrap/syswrap-generic.c \
- m_syswrap/syswrap-linux.c \
-@@ -461,6 +429,29 @@
- m_ume/main.c \
- m_ume/script.c
-
-+COREGRIND_SOURCES_COMMON += \
-+ m_dispatch/dispatch-@VGCONF_ARCH_PRI@-@VGCONF_OS@.S \
-+ m_syswrap/syscall-@VGCONF_ARCH_PRI@-@VGCONF_OS@.S
-+
-+if VGCONF_HAVE_PLATFORM_SEC
-+COREGRIND_SOURCES_COMMON += \
-+ m_dispatch/dispatch-@VGCONF_ARCH_SEC@-@VGCONF_OS@.S \
-+ m_syswrap/syscall-@VGCONF_ARCH_SEC@-@VGCONF_OS@.S
-+endif
-+
-+if VGCONF_OS_IS_DARWIN
-+COREGRIND_SOURCES_COMMON += \
-+ m_dispatch/dispatch-@VGCONF_ARCH_PRI@-darwin.S \
-+ m_syswrap/syscall-@VGCONF_ARCH_PRI@-darwin.S \
-+ m_mach/mach_traps-@VGCONF_ARCH_PRI@-darwin.S
-+if VGCONF_HAVE_PLATFORM_SEC
-+COREGRIND_SOURCES_COMMON += \
-+ m_dispatch/dispatch-@VGCONF_ARCH_SEC@-darwin.S \
-+ m_syswrap/syscall-@VGCONF_ARCH_SEC@-darwin.S \
-+ m_mach/mach_traps-@VGCONF_ARCH_SEC@-darwin.S
-+endif
-+endif
-+
- libcoregrind_@VGCONF_ARCH_PRI@_@VGCONF_OS@_a_SOURCES = \
- $(COREGRIND_SOURCES_COMMON)
- nodist_libcoregrind_@VGCONF_ARCH_PRI@_@VGCONF_OS@_a_SOURCES = \
diff --git a/dev-util/valgrind/valgrind-3.12.0.ebuild b/dev-util/valgrind/valgrind-3.12.0.ebuild
index e9e5899..c88c83c 100644
--- a/dev-util/valgrind/valgrind-3.12.0.ebuild
+++ b/dev-util/valgrind/valgrind-3.12.0.ebuild
@@ -30,10 +30,6 @@ src_prepare() {
# Changing Makefile.all.am to disable SSP
epatch "${FILESDIR}"/${PN}-3.7.0-fno-stack-protector.patch
- # Don't build in empty assembly files for other platforms or we'll get a QA
- # warning about executable stacks.
- epatch "${FILESDIR}"/${PN}-3.12.0-non-exec-stack.patch
-
# Allow users to test their own patches
epatch_user
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-util/valgrind/, dev-util/valgrind/files/
@ 2016-10-23 20:30 Anthony G. Basile
0 siblings, 0 replies; 11+ messages in thread
From: Anthony G. Basile @ 2016-10-23 20:30 UTC (permalink / raw
To: gentoo-commits
commit: 65361448b036a5a9f2ed5790a556316d58a3b782
Author: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
AuthorDate: Sun Oct 23 20:11:18 2016 +0000
Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
CommitDate: Sun Oct 23 20:30:11 2016 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=65361448
dev-util/valgrind: version bump to 3.12.0
Package-Manager: portage-2.2.28
dev-util/valgrind/Manifest | 1 +
.../files/valgrind-3.12.0-non-exec-stack.patch | 86 ++++++++++++++++++
dev-util/valgrind/valgrind-3.12.0.ebuild | 100 +++++++++++++++++++++
3 files changed, 187 insertions(+)
diff --git a/dev-util/valgrind/Manifest b/dev-util/valgrind/Manifest
index d251a79..4af5f23 100644
--- a/dev-util/valgrind/Manifest
+++ b/dev-util/valgrind/Manifest
@@ -1,2 +1,3 @@
DIST valgrind-3.10.1.tar.bz2 10967905 SHA256 fa253dc26ddb661b6269df58144eff607ea3f76a9bcfe574b0c7726e1dfcb997 SHA512 8f3d27637c13b06381b3dd44088244e0cf2f7008f40e46f34322f2a5bfa6373d29ce68ff49f19c48f1a5f139d8be5838b9606206e0ce2599c5f74c0db8ce2642 WHIRLPOOL 3d55f35b02195d9859d9192726ea708277f1d3339005d959baa224822c5b71f5347cdd28c7fd8153c10d1e3282855e853caf9c7192751bebdbbc3444c33d885a
DIST valgrind-3.11.0.tar.bz2 11910809 SHA256 6c396271a8c1ddd5a6fb9abe714ea1e8a86fce85b30ab26b4266aeb4c2413b42 SHA512 a25f97fa80aef4ad1e86b303886cd7a97aac248820a4c24e3d3dc26567dd7d2d86db237866468fd43885a9fb8534cb0a8e301a3c752fffbc231a2842272999da WHIRLPOOL a881df25e64789954d9bcb44617fd92d832ae9953689c01f8f79d737379c523a6f3a8125283518a6f256770a5c4f204b7b859794cf714abb0a742a69b272ef0e
+DIST valgrind-3.12.0.tar.bz2 12788556 SHA256 67ca4395b2527247780f36148b084f5743a68ab0c850cb43e4a5b4b012cf76a1 SHA512 2c083f7c2e74dc58600397726d9d3af7a2cea40fe3d8733149886d1d77867e6c09996e5be1c58dd932f3662acf7363e04eeadbc0f9c8f0dac089e605024229be WHIRLPOOL 136dd4f358bd18165a5801083cc73fc269a84bf491880af9842e789feea62181e16ca4c099db06fb4ffacf0cb0189b1b29d64790cc4202442f6f6b71ce4c6eea
diff --git a/dev-util/valgrind/files/valgrind-3.12.0-non-exec-stack.patch b/dev-util/valgrind/files/valgrind-3.12.0-non-exec-stack.patch
new file mode 100644
index 00000000..7f41eff
--- /dev/null
+++ b/dev-util/valgrind/files/valgrind-3.12.0-non-exec-stack.patch
@@ -0,0 +1,86 @@
+diff -Naur valgrind-3.12.0.orig/coregrind/Makefile.am valgrind-3.12.0/coregrind/Makefile.am
+--- valgrind-3.12.0.orig/coregrind/Makefile.am 2016-10-21 06:37:39.000000000 -0400
++++ valgrind-3.12.0/coregrind/Makefile.am 2016-10-23 16:05:46.904546117 -0400
+@@ -359,21 +359,6 @@
+ m_demangle/dyn-string.c \
+ m_demangle/d-demangle.c \
+ m_demangle/safe-ctype.c \
+- m_dispatch/dispatch-x86-linux.S \
+- m_dispatch/dispatch-amd64-linux.S \
+- m_dispatch/dispatch-ppc32-linux.S \
+- m_dispatch/dispatch-ppc64be-linux.S \
+- m_dispatch/dispatch-ppc64le-linux.S \
+- m_dispatch/dispatch-arm-linux.S \
+- m_dispatch/dispatch-arm64-linux.S \
+- m_dispatch/dispatch-s390x-linux.S \
+- m_dispatch/dispatch-mips32-linux.S \
+- m_dispatch/dispatch-mips64-linux.S \
+- m_dispatch/dispatch-tilegx-linux.S \
+- m_dispatch/dispatch-x86-darwin.S \
+- m_dispatch/dispatch-amd64-darwin.S \
+- m_dispatch/dispatch-x86-solaris.S \
+- m_dispatch/dispatch-amd64-solaris.S \
+ m_gdbserver/inferiors.c \
+ m_gdbserver/m_gdbserver.c \
+ m_gdbserver/regcache.c \
+@@ -399,8 +384,6 @@
+ m_initimg/initimg-pathscan.c \
+ m_mach/mach_basics.c \
+ m_mach/mach_msg.c \
+- m_mach/mach_traps-x86-darwin.S \
+- m_mach/mach_traps-amd64-darwin.S \
+ m_replacemalloc/replacemalloc_core.c \
+ m_scheduler/sched-lock.c \
+ m_scheduler/sched-lock-generic.c \
+@@ -420,21 +403,6 @@
+ m_sigframe/sigframe-x86-darwin.c \
+ m_sigframe/sigframe-amd64-darwin.c \
+ m_sigframe/sigframe-solaris.c \
+- m_syswrap/syscall-x86-linux.S \
+- m_syswrap/syscall-amd64-linux.S \
+- m_syswrap/syscall-ppc32-linux.S \
+- m_syswrap/syscall-ppc64be-linux.S \
+- m_syswrap/syscall-ppc64le-linux.S \
+- m_syswrap/syscall-arm-linux.S \
+- m_syswrap/syscall-arm64-linux.S \
+- m_syswrap/syscall-s390x-linux.S \
+- m_syswrap/syscall-mips32-linux.S \
+- m_syswrap/syscall-mips64-linux.S \
+- m_syswrap/syscall-tilegx-linux.S \
+- m_syswrap/syscall-x86-darwin.S \
+- m_syswrap/syscall-amd64-darwin.S \
+- m_syswrap/syscall-x86-solaris.S \
+- m_syswrap/syscall-amd64-solaris.S \
+ m_syswrap/syswrap-main.c \
+ m_syswrap/syswrap-generic.c \
+ m_syswrap/syswrap-linux.c \
+@@ -461,6 +429,29 @@
+ m_ume/main.c \
+ m_ume/script.c
+
++COREGRIND_SOURCES_COMMON += \
++ m_dispatch/dispatch-@VGCONF_ARCH_PRI@-@VGCONF_OS@.S \
++ m_syswrap/syscall-@VGCONF_ARCH_PRI@-@VGCONF_OS@.S
++
++if VGCONF_HAVE_PLATFORM_SEC
++COREGRIND_SOURCES_COMMON += \
++ m_dispatch/dispatch-@VGCONF_ARCH_SEC@-@VGCONF_OS@.S \
++ m_syswrap/syscall-@VGCONF_ARCH_SEC@-@VGCONF_OS@.S
++endif
++
++if VGCONF_OS_IS_DARWIN
++COREGRIND_SOURCES_COMMON += \
++ m_dispatch/dispatch-@VGCONF_ARCH_PRI@-darwin.S \
++ m_syswrap/syscall-@VGCONF_ARCH_PRI@-darwin.S \
++ m_mach/mach_traps-@VGCONF_ARCH_PRI@-darwin.S
++if VGCONF_HAVE_PLATFORM_SEC
++COREGRIND_SOURCES_COMMON += \
++ m_dispatch/dispatch-@VGCONF_ARCH_SEC@-darwin.S \
++ m_syswrap/syscall-@VGCONF_ARCH_SEC@-darwin.S \
++ m_mach/mach_traps-@VGCONF_ARCH_SEC@-darwin.S
++endif
++endif
++
+ libcoregrind_@VGCONF_ARCH_PRI@_@VGCONF_OS@_a_SOURCES = \
+ $(COREGRIND_SOURCES_COMMON)
+ nodist_libcoregrind_@VGCONF_ARCH_PRI@_@VGCONF_OS@_a_SOURCES = \
diff --git a/dev-util/valgrind/valgrind-3.12.0.ebuild b/dev-util/valgrind/valgrind-3.12.0.ebuild
new file mode 100644
index 00000000..e9e5899
--- /dev/null
+++ b/dev-util/valgrind/valgrind-3.12.0.ebuild
@@ -0,0 +1,100 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+inherit autotools eutils flag-o-matic toolchain-funcs multilib pax-utils
+
+DESCRIPTION="An open-source memory debugger for GNU/Linux"
+HOMEPAGE="http://www.valgrind.org"
+SRC_URI="http://www.valgrind.org/downloads/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="-* ~amd64 ~arm ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x86-macos"
+IUSE="mpi"
+
+DEPEND="mpi? ( virtual/mpi )"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ # Correct hard coded doc location
+ sed -i -e "s:doc/valgrind:doc/${PF}:" docs/Makefile.am || die
+
+ # Don't force multiarch stuff on OSX, bug #306467
+ sed -i -e 's:-arch \(i386\|x86_64\)::g' Makefile.all.am || die
+
+ # Respect CFLAGS, LDFLAGS
+ epatch "${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
+
+ # Changing Makefile.all.am to disable SSP
+ epatch "${FILESDIR}"/${PN}-3.7.0-fno-stack-protector.patch
+
+ # Don't build in empty assembly files for other platforms or we'll get a QA
+ # warning about executable stacks.
+ epatch "${FILESDIR}"/${PN}-3.12.0-non-exec-stack.patch
+
+ # Allow users to test their own patches
+ epatch_user
+
+ # Regenerate autotools files
+ eautoreconf
+}
+
+src_configure() {
+ local myconf
+
+ # Respect ar, bug #468114
+ tc-export AR
+
+ # -fomit-frame-pointer "Assembler messages: Error: junk `8' after expression"
+ # while compiling insn_sse.c in none/tests/x86
+ # -fstack-protector more undefined references to __guard and __stack_smash_handler
+ # because valgrind doesn't link to glibc (bug #114347)
+ # -m64 -mx32 for multilib-portage, bug #398825
+ # -ggdb3 segmentation fault on startup
+ filter-flags -fomit-frame-pointer
+ filter-flags -fstack-protector
+ filter-flags -m64 -mx32
+ replace-flags -ggdb3 -ggdb2
+
+ if use amd64 || use ppc64; then
+ ! has_multilib_profile && myconf="${myconf} --enable-only64bit"
+ fi
+
+ # Force bitness on darwin, bug #306467
+ use x86-macos && myconf="${myconf} --enable-only32bit"
+ use x64-macos && myconf="${myconf} --enable-only64bit"
+
+ # Don't use mpicc unless the user asked for it (bug #258832)
+ if ! use mpi; then
+ myconf="${myconf} --without-mpicc"
+ fi
+
+ econf ${myconf}
+}
+
+src_install() {
+ emake DESTDIR="${D}" install
+ dodoc AUTHORS FAQ.txt NEWS README*
+
+ pax-mark m "${ED}"/usr/$(get_libdir)/valgrind/*-*-linux
+
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ # fix install_names on shared libraries, can't turn them into bundles,
+ # as dyld won't load them any more then, bug #306467
+ local l
+ for l in "${ED}"/usr/lib/valgrind/*.so ; do
+ install_name_tool -id "${EPREFIX}"/usr/lib/valgrind/${l##*/} "${l}"
+ done
+ fi
+}
+
+pkg_postinst() {
+ elog "Valgrind will not work if glibc does not have debug symbols."
+ elog "To fix this you can add splitdebug to FEATURES in make.conf"
+ elog "and remerge glibc. See:"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=214065"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=274771"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=388703"
+}
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-util/valgrind/, dev-util/valgrind/files/
@ 2015-09-26 11:01 Anthony G. Basile
0 siblings, 0 replies; 11+ messages in thread
From: Anthony G. Basile @ 2015-09-26 11:01 UTC (permalink / raw
To: gentoo-commits
commit: 8f9cf7a11173a39580ba875fcfbbfd6d307a0579
Author: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
AuthorDate: Sat Sep 26 11:05:44 2015 +0000
Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
CommitDate: Sat Sep 26 11:06:07 2015 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8f9cf7a1
dev-util/valgrind: version bump to 3.11.0
Package-Manager: portage-2.2.20.1
dev-util/valgrind/Manifest | 1 +
.../files/valgrind-3.11.0-non-exec-stack.patch | 154 +++++++++++++++++++++
dev-util/valgrind/valgrind-3.11.0.ebuild | 106 ++++++++++++++
3 files changed, 261 insertions(+)
diff --git a/dev-util/valgrind/Manifest b/dev-util/valgrind/Manifest
index 1073c90..418783d 100644
--- a/dev-util/valgrind/Manifest
+++ b/dev-util/valgrind/Manifest
@@ -1,4 +1,5 @@
DIST valgrind-3.10.1.tar.bz2 10967905 SHA256 fa253dc26ddb661b6269df58144eff607ea3f76a9bcfe574b0c7726e1dfcb997 SHA512 8f3d27637c13b06381b3dd44088244e0cf2f7008f40e46f34322f2a5bfa6373d29ce68ff49f19c48f1a5f139d8be5838b9606206e0ce2599c5f74c0db8ce2642 WHIRLPOOL 3d55f35b02195d9859d9192726ea708277f1d3339005d959baa224822c5b71f5347cdd28c7fd8153c10d1e3282855e853caf9c7192751bebdbbc3444c33d885a
+DIST valgrind-3.11.0.tar.bz2 11910809 SHA256 6c396271a8c1ddd5a6fb9abe714ea1e8a86fce85b30ab26b4266aeb4c2413b42 SHA512 a25f97fa80aef4ad1e86b303886cd7a97aac248820a4c24e3d3dc26567dd7d2d86db237866468fd43885a9fb8534cb0a8e301a3c752fffbc231a2842272999da WHIRLPOOL a881df25e64789954d9bcb44617fd92d832ae9953689c01f8f79d737379c523a6f3a8125283518a6f256770a5c4f204b7b859794cf714abb0a742a69b272ef0e
DIST valgrind-3.7.0.tar.bz2 6624216 SHA256 5d62c0330f1481fe2c593249192fa68ff454c19c34343978cc9ce91aa324cbf6 SHA512 0ccf6607fe6d26f0dc0f3d6e45f84645925d0a90ce4ecf6acfc6b4d374d3e909b2a628b03c0a964a45d2462cca6877f818a5f72b3e4a5bbf3a2d9b8a9a343d5f WHIRLPOOL 44bf8c423d6f3222f5e777333acc21e94dfa680509b2152289129961296d8afc090466b6407248b6e172b3c42da5448206f257bd63f8e44aba01007f92a6fde1
DIST valgrind-3.8.1.tar.bz2 7962963 SHA256 473be00576bed311a662b277a2bfbe97d9cca4058e68619a0e420c9fc19958db SHA512 ba31f5d43bd2d9533846bed6456a0eae40ac071ff8732201dd75c9e2cd7e9ce3224cb5928b9c8fc859a75ce6867a9b6a1fb2ba8ab62cd3944893d6d4156ab25c WHIRLPOOL 81e63bb649455ed29fcd60fc7f3cebde456a610118b9b24530d3b2e8aa4a7561369e992af86ffb158e1f7fc0db7b91738564402931a947a79bb789bd26a8e065
DIST valgrind-3.9.0.tar.bz2 10003156 SHA256 e6af71a06bc2534541b07743e1d58dc3caf744f38205ca3e5b5a0bdf372ed6f0 SHA512 4b748f9f9a647df50db75fb56f83ee2f25bad9f1f4e4f05c4ac1d1e919e6cd954975c1f325dbedb509c44be1a8516ac2a5f269090946a0d728166ab183016c7b WHIRLPOOL e73c4dcdff829a34889f5654c5ec314f32d2c33f9e64bde3f811359a252749a6c677db80bf2aa2647f935cd38a0ccc19c0358a7b13198032c5d636f97e9e71de
diff --git a/dev-util/valgrind/files/valgrind-3.11.0-non-exec-stack.patch b/dev-util/valgrind/files/valgrind-3.11.0-non-exec-stack.patch
new file mode 100644
index 0000000..b5c151a
--- /dev/null
+++ b/dev-util/valgrind/files/valgrind-3.11.0-non-exec-stack.patch
@@ -0,0 +1,154 @@
+diff -Naur valgrind-3.11.0.orig/coregrind/Makefile.am valgrind-3.11.0/coregrind/Makefile.am
+--- valgrind-3.11.0.orig/coregrind/Makefile.am 2015-09-08 09:23:26.000000000 -0400
++++ valgrind-3.11.0/coregrind/Makefile.am 2015-09-26 06:52:04.226983707 -0400
+@@ -354,21 +354,6 @@
+ m_demangle/demangle.c \
+ m_demangle/dyn-string.c \
+ m_demangle/safe-ctype.c \
+- m_dispatch/dispatch-x86-linux.S \
+- m_dispatch/dispatch-amd64-linux.S \
+- m_dispatch/dispatch-ppc32-linux.S \
+- m_dispatch/dispatch-ppc64be-linux.S \
+- m_dispatch/dispatch-ppc64le-linux.S \
+- m_dispatch/dispatch-arm-linux.S \
+- m_dispatch/dispatch-arm64-linux.S \
+- m_dispatch/dispatch-s390x-linux.S \
+- m_dispatch/dispatch-mips32-linux.S \
+- m_dispatch/dispatch-mips64-linux.S \
+- m_dispatch/dispatch-tilegx-linux.S \
+- m_dispatch/dispatch-x86-darwin.S \
+- m_dispatch/dispatch-amd64-darwin.S \
+- m_dispatch/dispatch-x86-solaris.S \
+- m_dispatch/dispatch-amd64-solaris.S \
+ m_gdbserver/inferiors.c \
+ m_gdbserver/m_gdbserver.c \
+ m_gdbserver/regcache.c \
+@@ -394,8 +379,6 @@
+ m_initimg/initimg-pathscan.c \
+ m_mach/mach_basics.c \
+ m_mach/mach_msg.c \
+- m_mach/mach_traps-x86-darwin.S \
+- m_mach/mach_traps-amd64-darwin.S \
+ m_replacemalloc/replacemalloc_core.c \
+ m_scheduler/sched-lock.c \
+ m_scheduler/sched-lock-generic.c \
+@@ -415,21 +398,6 @@
+ m_sigframe/sigframe-x86-darwin.c \
+ m_sigframe/sigframe-amd64-darwin.c \
+ m_sigframe/sigframe-solaris.c \
+- m_syswrap/syscall-x86-linux.S \
+- m_syswrap/syscall-amd64-linux.S \
+- m_syswrap/syscall-ppc32-linux.S \
+- m_syswrap/syscall-ppc64be-linux.S \
+- m_syswrap/syscall-ppc64le-linux.S \
+- m_syswrap/syscall-arm-linux.S \
+- m_syswrap/syscall-arm64-linux.S \
+- m_syswrap/syscall-s390x-linux.S \
+- m_syswrap/syscall-mips32-linux.S \
+- m_syswrap/syscall-mips64-linux.S \
+- m_syswrap/syscall-tilegx-linux.S \
+- m_syswrap/syscall-x86-darwin.S \
+- m_syswrap/syscall-amd64-darwin.S \
+- m_syswrap/syscall-x86-solaris.S \
+- m_syswrap/syscall-amd64-solaris.S \
+ m_syswrap/syswrap-main.c \
+ m_syswrap/syswrap-generic.c \
+ m_syswrap/syswrap-linux.c \
+@@ -456,6 +424,29 @@
+ m_ume/main.c \
+ m_ume/script.c
+
++COREGRIND_SOURCES_COMMON += \
++ m_dispatch/dispatch-@VGCONF_ARCH_PRI@-@VGCONF_OS@.S \
++ m_syswrap/syscall-@VGCONF_ARCH_PRI@-@VGCONF_OS@.S
++
++if VGCONF_HAVE_PLATFORM_SEC
++COREGRIND_SOURCES_COMMON += \
++ m_dispatch/dispatch-@VGCONF_ARCH_SEC@-@VGCONF_OS@.S \
++ m_syswrap/syscall-@VGCONF_ARCH_SEC@-@VGCONF_OS@.S
++endif
++
++if VGCONF_OS_IS_DARWIN
++COREGRIND_SOURCES_COMMON += \
++ m_dispatch/dispatch-@VGCONF_ARCH_PRI@-darwin.S \
++ m_syswrap/syscall-@VGCONF_ARCH_PRI@-darwin.S \
++ m_mach/mach_traps-@VGCONF_ARCH_PRI@-darwin.S
++if VGCONF_HAVE_PLATFORM_SEC
++COREGRIND_SOURCES_COMMON += \
++ m_dispatch/dispatch-@VGCONF_ARCH_SEC@-darwin.S \
++ m_syswrap/syscall-@VGCONF_ARCH_SEC@-darwin.S \
++ m_mach/mach_traps-@VGCONF_ARCH_SEC@-darwin.S
++endif
++endif
++
+ libcoregrind_@VGCONF_ARCH_PRI@_@VGCONF_OS@_a_SOURCES = \
+ $(COREGRIND_SOURCES_COMMON)
+ nodist_libcoregrind_@VGCONF_ARCH_PRI@_@VGCONF_OS@_a_SOURCES = \
+diff -Naur valgrind-3.11.0.orig/coregrind/m_dispatch/dispatch-amd64-linux.S valgrind-3.11.0/coregrind/m_dispatch/dispatch-amd64-linux.S
+--- valgrind-3.11.0.orig/coregrind/m_dispatch/dispatch-amd64-linux.S 2015-09-08 09:23:26.000000000 -0400
++++ valgrind-3.11.0/coregrind/m_dispatch/dispatch-amd64-linux.S 2015-09-26 06:46:20.103000200 -0400
+@@ -249,11 +249,11 @@
+
+ .size VG_(disp_run_translations), .-VG_(disp_run_translations)
+
++#endif // defined(VGP_amd64_linux)
++
+ /* Let the linker know we don't need an executable stack */
+ .section .note.GNU-stack,"",@progbits
+
+-#endif // defined(VGP_amd64_linux)
+-
+ /*--------------------------------------------------------------------*/
+ /*--- end ---*/
+ /*--------------------------------------------------------------------*/
+diff -Naur valgrind-3.11.0.orig/coregrind/m_dispatch/dispatch-x86-linux.S valgrind-3.11.0/coregrind/m_dispatch/dispatch-x86-linux.S
+--- valgrind-3.11.0.orig/coregrind/m_dispatch/dispatch-x86-linux.S 2015-09-08 09:23:26.000000000 -0400
++++ valgrind-3.11.0/coregrind/m_dispatch/dispatch-x86-linux.S 2015-09-26 06:46:20.103000200 -0400
+@@ -240,11 +240,11 @@
+
+ .size VG_(disp_run_translations), .-VG_(disp_run_translations)
+
++#endif // defined(VGP_x86_linux)
++
+ /* Let the linker know we don't need an executable stack */
+ .section .note.GNU-stack,"",@progbits
+
+-#endif // defined(VGP_x86_linux)
+-
+ /*--------------------------------------------------------------------*/
+ /*--- end ---*/
+ /*--------------------------------------------------------------------*/
+diff -Naur valgrind-3.11.0.orig/coregrind/m_syswrap/syscall-amd64-linux.S valgrind-3.11.0/coregrind/m_syswrap/syscall-amd64-linux.S
+--- valgrind-3.11.0.orig/coregrind/m_syswrap/syscall-amd64-linux.S 2015-09-08 09:23:26.000000000 -0400
++++ valgrind-3.11.0/coregrind/m_syswrap/syscall-amd64-linux.S 2015-09-26 06:46:20.103000200 -0400
+@@ -244,11 +244,11 @@
+ ML_(blksys_finished): .quad 5b
+ .previous
+
++#endif // defined(VGP_amd64_linux)
++
+ /* Let the linker know we don't need an executable stack */
+ .section .note.GNU-stack,"",@progbits
+
+-#endif // defined(VGP_amd64_linux)
+-
+ /*--------------------------------------------------------------------*/
+ /*--- end ---*/
+ /*--------------------------------------------------------------------*/
+diff -Naur valgrind-3.11.0.orig/coregrind/m_syswrap/syscall-x86-linux.S valgrind-3.11.0/coregrind/m_syswrap/syscall-x86-linux.S
+--- valgrind-3.11.0.orig/coregrind/m_syswrap/syscall-x86-linux.S 2015-09-08 09:23:26.000000000 -0400
++++ valgrind-3.11.0/coregrind/m_syswrap/syscall-x86-linux.S 2015-09-26 06:46:20.103000200 -0400
+@@ -184,11 +184,11 @@
+ ML_(blksys_finished): .long 5b
+ .previous
+
++#endif // defined(VGP_x86_linux)
++
+ /* Let the linker know we don't need an executable stack */
+ .section .note.GNU-stack,"",@progbits
+
+-#endif // defined(VGP_x86_linux)
+-
+ /*--------------------------------------------------------------------*/
+ /*--- end ---*/
+ /*--------------------------------------------------------------------*/
diff --git a/dev-util/valgrind/valgrind-3.11.0.ebuild b/dev-util/valgrind/valgrind-3.11.0.ebuild
new file mode 100644
index 0000000..8b2d9ca
--- /dev/null
+++ b/dev-util/valgrind/valgrind-3.11.0.ebuild
@@ -0,0 +1,106 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+inherit autotools eutils flag-o-matic toolchain-funcs multilib pax-utils
+
+DESCRIPTION="An open-source memory debugger for GNU/Linux"
+HOMEPAGE="http://www.valgrind.org"
+SRC_URI="http://www.valgrind.org/downloads/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="-* ~amd64 ~arm ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x86-macos"
+IUSE="mpi"
+
+DEPEND="mpi? ( virtual/mpi )"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+ # Correct hard coded doc location
+ sed -i -e "s:doc/valgrind:doc/${PF}:" docs/Makefile.am || die
+
+ # Don't force multiarch stuff on OSX, bug #306467
+ sed -i -e 's:-arch \(i386\|x86_64\)::g' Makefile.all.am || die
+
+ # Respect CFLAGS, LDFLAGS
+ epatch "${FILESDIR}"/${PN}-3.7.0-respect-flags.patch
+
+ # Changing Makefile.all.am to disable SSP
+ epatch "${FILESDIR}"/${PN}-3.7.0-fno-stack-protector.patch
+
+ # Yet more local labels, this time for ppc32 & ppc64
+ epatch "${FILESDIR}"/${PN}-3.6.0-local-labels.patch
+
+ # Don't build in empty assembly files for other platforms or we'll get a QA
+ # warning about executable stacks.
+ epatch "${FILESDIR}"/${PN}-3.11.0-non-exec-stack.patch
+
+ # Allow users to test their own patches
+ epatch_user
+
+ # Regenerate autotools files
+ eautoreconf
+}
+
+src_configure() {
+ local myconf
+
+ # Respect ar, bug #468114
+ tc-export AR
+
+ # -fomit-frame-pointer "Assembler messages: Error: junk `8' after expression"
+ # while compiling insn_sse.c in none/tests/x86
+ # -fpie valgrind seemingly hangs when built with pie on
+ # amd64 (bug #102157)
+ # -fstack-protector more undefined references to __guard and __stack_smash_handler
+ # because valgrind doesn't link to glibc (bug #114347)
+ # -m64 -mx32 for multilib-portage, bug #398825
+ # -ggdb3 segmentation fault on startup
+ filter-flags -fomit-frame-pointer
+ filter-flags -fpie
+ filter-flags -fstack-protector
+ filter-flags -m64 -mx32
+ replace-flags -ggdb3 -ggdb2
+
+ if use amd64 || use ppc64; then
+ ! has_multilib_profile && myconf="${myconf} --enable-only64bit"
+ fi
+
+ # Force bitness on darwin, bug #306467
+ use x86-macos && myconf="${myconf} --enable-only32bit"
+ use x64-macos && myconf="${myconf} --enable-only64bit"
+
+ # Don't use mpicc unless the user asked for it (bug #258832)
+ if ! use mpi; then
+ myconf="${myconf} --without-mpicc"
+ fi
+
+ econf ${myconf}
+}
+
+src_install() {
+ emake DESTDIR="${D}" install
+ dodoc AUTHORS FAQ.txt NEWS README*
+
+ pax-mark m "${ED}"/usr/$(get_libdir)/valgrind/*-*-linux
+
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ # fix install_names on shared libraries, can't turn them into bundles,
+ # as dyld won't load them any more then, bug #306467
+ local l
+ for l in "${ED}"/usr/lib/valgrind/*.so ; do
+ install_name_tool -id "${EPREFIX}"/usr/lib/valgrind/${l##*/} "${l}"
+ done
+ fi
+}
+
+pkg_postinst() {
+ elog "Valgrind will not work if glibc does not have debug symbols."
+ elog "To fix this you can add splitdebug to FEATURES in make.conf"
+ elog "and remerge glibc. See:"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=214065"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=274771"
+ elog "https://bugs.gentoo.org/show_bug.cgi?id=388703"
+}
^ permalink raw reply related [flat|nested] 11+ messages in thread
end of thread, other threads:[~2023-08-28 6:40 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-07-21 15:20 [gentoo-commits] repo/gentoo:master commit in: dev-util/valgrind/, dev-util/valgrind/files/ Anthony G. Basile
-- strict thread matches above, loose matches on Subject: below --
2023-08-28 6:40 Sam James
2023-02-03 16:53 Sam James
2022-10-28 10:43 Sam James
2019-11-04 17:39 Matt Turner
2018-09-05 12:25 Thomas Deutschmann
2018-02-28 17:54 Austin English
2017-12-12 21:59 Austin English
2016-10-26 19:09 Matthias Schwarzott
2016-10-23 20:30 Anthony G. Basile
2015-09-26 11:01 Anthony G. Basile
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox