diff options
author | Marc-Antoine Perennou <Marc-Antoine@Perennou.com> | 2011-11-21 22:09:13 +0100 |
---|---|---|
committer | Marc-Antoine Perennou <Marc-Antoine@Perennou.com> | 2011-11-21 22:09:13 +0100 |
commit | 131703926afee7063b00c074d76c10e22b632f52 (patch) | |
tree | d64334fc30b096f4f70ff8341f6bb0372084f67e | |
parent | libpeas: port to vala 0.14 (diff) | |
download | keruspe-131703926afee7063b00c074d76c10e22b632f52.tar.gz keruspe-131703926afee7063b00c074d76c10e22b632f52.tar.bz2 keruspe-131703926afee7063b00c074d76c10e22b632f52.zip |
add valgrind patches from ::gentoo
Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
-rw-r--r-- | dev-util/valgrind/Manifest | 6 | ||||
-rw-r--r-- | dev-util/valgrind/files/valgrind-3.7.0-fix-gcc-regex.patch | 12 | ||||
-rw-r--r-- | dev-util/valgrind/files/valgrind-3.7.0-fno-stack-protector.patch | 12 | ||||
-rw-r--r-- | dev-util/valgrind/files/valgrind-3.7.0-non-exec-stack.patch | 138 | ||||
-rw-r--r-- | dev-util/valgrind/files/valgrind-3.7.0-respect-flags.patch | 13 | ||||
-rw-r--r-- | dev-util/valgrind/valgrind-9999.ebuild | 24 |
6 files changed, 194 insertions, 11 deletions
diff --git a/dev-util/valgrind/Manifest b/dev-util/valgrind/Manifest index 09f7cf61..d1adb25e 100644 --- a/dev-util/valgrind/Manifest +++ b/dev-util/valgrind/Manifest @@ -1,2 +1,6 @@ AUX valgrind-3.6.0-local-labels.patch 1388 RMD160 e9c0064d1e857f1e616c5d9ca7a03e78eae3d5ab SHA1 173820d5671f56c864850c2d8df9d6d301dfda38 SHA256 34ae13eda378677f1e662e0813f138de9b897d6592d20872c58ed8ac1bcf7def -EBUILD valgrind-9999.ebuild 2375 RMD160 2d99d82d14fd489d6ad25655a4b7d3e84c2268e2 SHA1 707e2eb4438dd10d027dbb56a2fa6aa250a2886d SHA256 20fddf51bcef59be183eeb9bf57038ce488ca9d4563849e7edc0c7b0874b8909 +AUX valgrind-3.7.0-fix-gcc-regex.patch 581 RMD160 ab1bcd6f79b208f73ea6cc1f4cde1cefc07b74ca SHA1 63820c292db0b245f056629f2cf4247bcad7ecff SHA256 697049e69b5fe85211dab18e471ac4c8d18a50c1fa650466dcba2cacca322bd1 +AUX valgrind-3.7.0-fno-stack-protector.patch 554 RMD160 df9a699ff35cf867e17b04a200c5e68015955167 SHA1 ed6368061d47448a597f6a2a9635f66e244b5a13 SHA256 83ed90a0e8a8b06dca8aad4e7f1a12e3c84621d502427c0913b72740b310f479 +AUX valgrind-3.7.0-non-exec-stack.patch 5644 RMD160 86178ee97653b2b4074e98e2342c5104583fa759 SHA1 8074a41b2e8915fa3a63ce827a14088949057bed SHA256 4de10480b6e27379083203df3cfedccdace68d0aad611440478ca2f1b2f89751 +AUX valgrind-3.7.0-respect-flags.patch 360 RMD160 b3ca9a393a68d312fa12cd272720e67c8661cfc4 SHA1 2ca0d9474bd4a81d45981bc8433359832d1ce8b9 SHA256 6b1e5938ecafc29428a698296423c71924848b1e746d6ee8a0f1dd91141f1019 +EBUILD valgrind-9999.ebuild 2555 RMD160 249a2ebf477a5595231194e6d2e9e40861e27ff9 SHA1 70ef52a206a0e0856db21662e310cdc808404025 SHA256 9232ed2cf7fe514df426fe61d8366a18f927baf185eb11059ab166bb176adff2 diff --git a/dev-util/valgrind/files/valgrind-3.7.0-fix-gcc-regex.patch b/dev-util/valgrind/files/valgrind-3.7.0-fix-gcc-regex.patch new file mode 100644 index 00000000..3233333c --- /dev/null +++ b/dev-util/valgrind/files/valgrind-3.7.0-fix-gcc-regex.patch @@ -0,0 +1,12 @@ +diff -Naur valgrind-3.7.0.orig//configure.in valgrind-3.7.0/configure.in +--- valgrind-3.7.0.orig//configure.in 2011-11-05 07:13:30.000000000 -0400 ++++ valgrind-3.7.0/configure.in 2011-11-10 18:13:39.000000000 -0500 +@@ -109,7 +109,7 @@ + | head -n 1 \ + | $SED 's/i686-apple-darwin10//' \ + | $SED 's/i686-apple-darwin11//' \ +- | $SED 's/^[^0-9]*\([0-9.]*\).*$/\1/'`] ++ | $SED 's/.*\s\([.0-9]*\)$/\1/'`] + + is_clang="notclang" + if test "x`${CC} --version | head -n 1 | $SED 's/\(clang\) version.*/\1/'`" = "xclang" ; then diff --git a/dev-util/valgrind/files/valgrind-3.7.0-fno-stack-protector.patch b/dev-util/valgrind/files/valgrind-3.7.0-fno-stack-protector.patch new file mode 100644 index 00000000..6af45531 --- /dev/null +++ b/dev-util/valgrind/files/valgrind-3.7.0-fno-stack-protector.patch @@ -0,0 +1,12 @@ +diff -Naur valgrind-3.7.0.orig//Makefile.all.am valgrind-3.7.0/Makefile.all.am +--- valgrind-3.7.0.orig//Makefile.all.am 2011-10-26 17:24:45.000000000 -0400 ++++ valgrind-3.7.0/Makefile.all.am 2011-11-10 16:18:18.000000000 -0500 +@@ -82,7 +82,7 @@ + # performance and get whatever useful warnings we can out of gcc. + # -fno-builtin is important for defeating LLVM's idiom recognition + # that somehow causes VG_(memset) to get into infinite recursion. +-AM_CFLAGS_BASE = \ ++AM_CFLAGS_BASE = -fno-stack-protector \ + -O2 -g \ + -Wall \ + -Wmissing-prototypes \ diff --git a/dev-util/valgrind/files/valgrind-3.7.0-non-exec-stack.patch b/dev-util/valgrind/files/valgrind-3.7.0-non-exec-stack.patch new file mode 100644 index 00000000..d6cc26da --- /dev/null +++ b/dev-util/valgrind/files/valgrind-3.7.0-non-exec-stack.patch @@ -0,0 +1,138 @@ +diff -Naur valgrind-3.7.0.orig//coregrind/Makefile.am valgrind-3.7.0/coregrind/Makefile.am +--- valgrind-3.7.0.orig//coregrind/Makefile.am 2011-11-10 20:02:47.000000000 -0500 ++++ valgrind-3.7.0/coregrind/Makefile.am 2011-11-10 20:03:00.000000000 -0500 +@@ -292,14 +292,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-ppc64-linux.S \ +- m_dispatch/dispatch-arm-linux.S \ +- m_dispatch/dispatch-s390x-linux.S \ +- m_dispatch/dispatch-x86-darwin.S \ +- m_dispatch/dispatch-amd64-darwin.S \ + m_gdbserver/m_gdbserver.c \ + m_gdbserver/inferiors.c \ + m_gdbserver/m_gdbserver.c \ +@@ -322,8 +314,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/scheduler.c \ + m_scheduler/sema.c \ +@@ -335,14 +325,6 @@ + m_sigframe/sigframe-s390x-linux.c \ + m_sigframe/sigframe-x86-darwin.c \ + m_sigframe/sigframe-amd64-darwin.c \ +- m_syswrap/syscall-x86-linux.S \ +- m_syswrap/syscall-amd64-linux.S \ +- m_syswrap/syscall-ppc32-linux.S \ +- m_syswrap/syscall-ppc64-linux.S \ +- m_syswrap/syscall-arm-linux.S \ +- m_syswrap/syscall-s390x-linux.S \ +- m_syswrap/syscall-x86-darwin.S \ +- m_syswrap/syscall-amd64-darwin.S \ + m_syswrap/syswrap-main.c \ + m_syswrap/syswrap-generic.c \ + m_syswrap/syswrap-linux.c \ +@@ -361,6 +343,24 @@ + 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_start-@VGCONF_ARCH_PRI@-darwin.S \ ++ m_start-@VGCONF_ARCH_SEC@-darwin.S \ ++ m_mach/mach_traps-@VGCONF_ARCH_PRI@-darwin.S \ ++ m_mach/mach_traps-@VGCONF_ARCH_SEC@-darwin.S ++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.7.0.orig//coregrind/m_dispatch/dispatch-amd64-linux.S valgrind-3.7.0/coregrind/m_dispatch/dispatch-amd64-linux.S +--- valgrind-3.7.0.orig//coregrind/m_dispatch/dispatch-amd64-linux.S 2011-10-26 17:24:42.000000000 -0400 ++++ valgrind-3.7.0/coregrind/m_dispatch/dispatch-amd64-linux.S 2011-11-10 20:07:40.000000000 -0500 +@@ -349,11 +349,11 @@ + ret + .size VG_(run_a_noredir_translation), .-VG_(run_a_noredir_translation) + ++#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.7.0.orig//coregrind/m_dispatch/dispatch-x86-linux.S valgrind-3.7.0/coregrind/m_dispatch/dispatch-x86-linux.S +--- valgrind-3.7.0.orig//coregrind/m_dispatch/dispatch-x86-linux.S 2011-10-26 17:24:42.000000000 -0400 ++++ valgrind-3.7.0/coregrind/m_dispatch/dispatch-x86-linux.S 2011-11-10 20:04:07.000000000 -0500 +@@ -320,12 +320,11 @@ + ret + .size VG_(run_a_noredir_translation), .-VG_(run_a_noredir_translation) + +- ++#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.7.0.orig//coregrind/m_syswrap/syscall-amd64-linux.S valgrind-3.7.0/coregrind/m_syswrap/syscall-amd64-linux.S +--- valgrind-3.7.0.orig//coregrind/m_syswrap/syscall-amd64-linux.S 2011-11-10 20:02:47.000000000 -0500 ++++ valgrind-3.7.0/coregrind/m_syswrap/syscall-amd64-linux.S 2011-11-10 20:03:00.000000000 -0500 +@@ -205,11 +205,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.7.0.orig//coregrind/m_syswrap/syscall-x86-linux.S valgrind-3.7.0/coregrind/m_syswrap/syscall-x86-linux.S +--- valgrind-3.7.0.orig//coregrind/m_syswrap/syscall-x86-linux.S 2011-11-10 20:02:47.000000000 -0500 ++++ valgrind-3.7.0/coregrind/m_syswrap/syscall-x86-linux.S 2011-11-10 20:03:00.000000000 -0500 +@@ -164,12 +164,12 @@ + ML_(blksys_committed): .long 4b + ML_(blksys_finished): .long 5b + .previous +- +-/* Let the linker know we don't need an executable stack */ +-.section .note.GNU-stack,"",@progbits + + #endif // defined(VGP_x86_linux) + ++/* Let the linker know we don't need an executable stack */ ++.section .note.GNU-stack,"",@progbits ++ + /*--------------------------------------------------------------------*/ + /*--- end ---*/ + /*--------------------------------------------------------------------*/ diff --git a/dev-util/valgrind/files/valgrind-3.7.0-respect-flags.patch b/dev-util/valgrind/files/valgrind-3.7.0-respect-flags.patch new file mode 100644 index 00000000..860e09c8 --- /dev/null +++ b/dev-util/valgrind/files/valgrind-3.7.0-respect-flags.patch @@ -0,0 +1,13 @@ +diff -Naur valgrind-3.7.0.orig//mpi/Makefile.am valgrind-3.7.0/mpi/Makefile.am +--- valgrind-3.7.0.orig//mpi/Makefile.am 2011-10-26 17:24:23.000000000 -0400 ++++ valgrind-3.7.0/mpi/Makefile.am 2011-11-10 16:03:14.000000000 -0500 +@@ -7,9 +7,6 @@ + CC = $(MPI_CC) + DEFS = + DEFAULT_INCLUDES = +-CPPFLAGS = +-CFLAGS = +-LDFLAGS = + + EXTRA_DIST = \ + mpiwrap_type_test.c diff --git a/dev-util/valgrind/valgrind-9999.ebuild b/dev-util/valgrind/valgrind-9999.ebuild index a8329923..b8c044a2 100644 --- a/dev-util/valgrind/valgrind-9999.ebuild +++ b/dev-util/valgrind/valgrind-9999.ebuild @@ -18,21 +18,25 @@ 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 + # Respect CFLAGS, LDFLAGS - sed -i -e '/^CPPFLAGS =/d' -e '/^CFLAGS =/d' -e '/^LDFLAGS =/d' \ - mpi/Makefile.am || die + epatch "${FILESDIR}"/${PN}-3.7.0-respect-flags.patch # Changing Makefile.all.am to disable SSP - sed -i -e 's:^AM_CFLAGS_BASE = :AM_CFLAGS_BASE = -fno-stack-protector :' \ - Makefile.all.am || die - - # Correct hard coded doc location - sed -i -e "s:doc/valgrind:doc/${PF}:" \ - docs/Makefile.am || die + 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.7.0-non-exec-stack.patch + + # Fix the regex to get gcc's version + epatch "${FILESDIR}"/${PN}-3.7.0-fix-gcc-regex.patch + # Regenerate autotools files eautoreconf } @@ -65,8 +69,8 @@ src_configure() { } src_install() { - emake DESTDIR="${D}" install || die - dodoc AUTHORS NEWS README* + emake DESTDIR="${D}" install + dodoc AUTHORS FAQ.txt NEWS README* pax-mark m "${D}"/usr/$(get_libdir)/valgrind/*-*-linux } |