Skip to content

Instantly share code, notes, and snippets.

@froland
Created February 2, 2018 13:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save froland/322a3320fcabd46a5702bd4a2a228198 to your computer and use it in GitHub Desktop.
Save froland/322a3320fcabd46a5702bd4a2a228198 to your computer and use it in GitHub Desktop.
GCC-6.4.0 EasyBuild
--- branches/gcc-6-branch/libsanitizer/ChangeLog 2017/09/07 03:07:42 251827
+++ branches/gcc-6-branch/libsanitizer/ChangeLog 2017/09/07 07:15:24 251828
@@ -1,3 +1,14 @@
+2017-09-07 Matthias Klose <doko@ubuntu.com>
+
+ Backported from mainline
+ 2017-07-14 Jakub Jelinek <jakub@redhat.com>
+
+ PR sanitizer/81066
+ * sanitizer_common/sanitizer_linux.h: Cherry-pick upstream r307969.
+ * sanitizer_common/sanitizer_linux.cc: Likewise.
+ * sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cc: Likewise.
+ * tsan/tsan_platform_linux.cc: Likewise.
+
2017-07-04 Release Manager
* GCC 6.4.0 released.
--- branches/gcc-6-branch/libsanitizer/sanitizer_common/sanitizer_linux.cc 2016/04/15 14:52:49 235034
+++ branches/gcc-6-branch/libsanitizer/sanitizer_common/sanitizer_linux.cc 2017/09/07 07:15:24 251828
@@ -546,8 +546,7 @@
}
#endif
-uptr internal_sigaltstack(const struct sigaltstack *ss,
- struct sigaltstack *oss) {
+uptr internal_sigaltstack(const void *ss, void *oss) {
return internal_syscall(SYSCALL(sigaltstack), (uptr)ss, (uptr)oss);
}
--- branches/gcc-6-branch/libsanitizer/sanitizer_common/sanitizer_linux.h 2017/09/07 03:07:42 251827
+++ branches/gcc-6-branch/libsanitizer/sanitizer_common/sanitizer_linux.h 2017/09/07 07:15:24 251828
@@ -19,7 +19,6 @@
#include "sanitizer_platform_limits_posix.h"
struct link_map; // Opaque type returned by dlopen().
-struct sigaltstack;
namespace __sanitizer {
// Dirent structure for getdents(). Note that this structure is different from
@@ -28,8 +27,7 @@
// Syscall wrappers.
uptr internal_getdents(fd_t fd, struct linux_dirent *dirp, unsigned int count);
-uptr internal_sigaltstack(const struct sigaltstack* ss,
- struct sigaltstack* oss);
+uptr internal_sigaltstack(const void* ss, void* oss);
uptr internal_sigprocmask(int how, __sanitizer_sigset_t *set,
__sanitizer_sigset_t *oldset);
void internal_sigfillset(__sanitizer_sigset_t *set);
--- branches/gcc-6-branch/libsanitizer/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cc 2017/09/07 03:07:42 251827
+++ branches/gcc-6-branch/libsanitizer/sanitizer_common/sanitizer_stoptheworld_linux_libcdep.cc 2017/09/07 07:15:24 251828
@@ -267,7 +267,7 @@
// Alternate stack for signal handling.
InternalScopedBuffer<char> handler_stack_memory(kHandlerStackSize);
- struct sigaltstack handler_stack;
+ stack_t handler_stack;
internal_memset(&handler_stack, 0, sizeof(handler_stack));
handler_stack.ss_sp = handler_stack_memory.data();
handler_stack.ss_size = kHandlerStackSize;
--- branches/gcc-6-branch/libsanitizer/tsan/tsan_platform_linux.cc 2017/09/07 03:07:42 251827
+++ branches/gcc-6-branch/libsanitizer/tsan/tsan_platform_linux.cc 2017/09/07 07:15:24 251828
@@ -291,7 +291,7 @@
int ExtractResolvFDs(void *state, int *fds, int nfd) {
#if SANITIZER_LINUX
int cnt = 0;
- __res_state *statp = (__res_state*)state;
+ struct __res_state *statp = (struct __res_state*)state;
for (int i = 0; i < MAXNS && cnt < nfd; i++) {
if (statp->_u._ext.nsaddrs[i] && statp->_u._ext.nssocks[i] != -1)
fds[cnt++] = statp->_u._ext.nssocks[i];
--- branches/gcc-6-branch/libgcc/config/i386/linux-unwind.h 2017/07/04 10:22:56 249956
+++ branches/gcc-6-branch/libgcc/config/i386/linux-unwind.h 2017/07/04 10:23:57 249957
@@ -58,7 +58,7 @@
if (*(unsigned char *)(pc+0) == 0x48
&& *(unsigned long long *)(pc+1) == RT_SIGRETURN_SYSCALL)
{
- struct ucontext *uc_ = context->cfa;
+ ucontext_t *uc_ = context->cfa;
/* The void * cast is necessary to avoid an aliasing warning.
The aliasing warning is correct, but should not be a problem
because it does not alias anything. */
@@ -138,7 +138,7 @@
siginfo_t *pinfo;
void *puc;
siginfo_t info;
- struct ucontext uc;
+ ucontext_t uc;
} *rt_ = context->cfa;
/* The void * cast is necessary to avoid an aliasing warning.
The aliasing warning is correct, but should not be a problem
easyblock = 'EB_GCC'
name = 'GCCcore'
version = '6.4.0'
homepage = 'http://gcc.gnu.org/'
description = """
The GNU Compiler Collection includes front ends for C, C++, Objective-C,
Fortran, Java, and Ada, as well as libraries for these languages (libstdc++,
libgcj,...). [NOTE: This module does not include Objective-C, Java or Ada]
"""
toolchain = {'name': 'dummy', 'version': ''}
mpfr_version = '3.1.5'
source_urls = [
'http://ftpmirror.gnu.org/gnu/gcc/gcc-%(version)s', # GCC auto-resolving HTTP mirror
'http://ftpmirror.gnu.org/gnu/gmp', # idem for GMP
'http://ftpmirror.gnu.org/gnu/mpfr', # idem for MPFR
'http://www.multiprecision.org/mpc/download', # MPC official
'ftp://gcc.gnu.org/pub/gcc/infrastructure/', # GCC dependencies
'http://gcc.cybermirror.org/infrastructure/', # HTTP mirror for GCC dependencies
'http://isl.gforge.inria.fr/', # original HTTP source for ISL
]
sources = [
'gcc-%(version)s.tar.gz',
'gmp-6.1.2.tar.bz2',
'mpfr-%s.tar.bz2' % mpfr_version,
'mpc-1.0.3.tar.gz',
'isl-0.16.1.tar.bz2',
]
builddependencies = [
('M4', '1.4.18'),
('binutils', '2.28'),
]
patches = [
('mpfr-%s-allpatches-20170606.patch' % mpfr_version, '../mpfr-%s' % mpfr_version),
'GCCcore-6.2.0-fix-find-isl.patch',
'linux-unwind.patch',
'libsanitizer.patch',
]
checksums = [
'4715f02413f8a91d02d967521c084990c99ce1a671b8a450a80fbd4245f4b728', # gcc-6.4.0.tar.gz
'5275bb04f4863a13516b2f39392ac5e272f5e1bb8057b18aec1c9b79d73d8fb2', # gmp-6.1.2.tar.bz2
'ca498c1c7a74dd37a576f353312d1e68d490978de4395fa28f1cbd46a364e658', # mpfr-3.1.5.tar.gz
'617decc6ea09889fb08ede330917a00b16809b8db88c29c31bfbb49cbf88ecc3', # mpc-1.0.3.tar.gz
'412538bb65c799ac98e17e8cfcdacbb257a57362acfaaff254b0fcae970126d2', # isl-0.16.1.tar.bz2
'137108952139486755e8c1bee30314ffa9233cc05cddfd848aa85503a6fea9d7', # mpfr-3.1.5-allpatches-20170606.patch
'5ad909606d17d851c6ad629b4fddb6c1621844218b8d139fed18c502a7696c68', # GCCcore-6.2.0-fix-find-isl.patch
]
languages = ['c', 'c++', 'fortran']
withisl = True
moduleclass = 'compiler'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment