tcsh: 6.19.00 -> 6.20.00

This commit is contained in:
Franz Pletz 2017-01-26 03:38:20 +01:00
parent b72b6a3160
commit e2b14abbe0
No known key found for this signature in database
GPG Key ID: 846FDED7792617B4
3 changed files with 8 additions and 59 deletions

View File

@ -1,28 +0,0 @@
From: christos <christos>
Date: Thu, 28 May 2015 11:47:03 +0000
Subject: [PATCH] avoid gcc-5 optimization malloc + memset = calloc (Fridolin
Pokorny)
---
tc.alloc.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/tc.alloc.c b/tc.alloc.c
index b9aec63..c1cb330 100644
--- a/tc.alloc.c
+++ b/tc.alloc.c
@@ -348,10 +348,13 @@ calloc(size_t i, size_t j)
{
#ifndef lint
char *cp;
+ volatile size_t k;
i *= j;
cp = xmalloc(i);
- memset(cp, 0, i);
+ /* Stop gcc 5.x from optimizing malloc+memset = calloc */
+ k = i;
+ memset(cp, 0, k);
return ((memalign_t) cp);
#else

View File

@ -3,19 +3,17 @@
stdenv.mkDerivation rec {
name = "tcsh-${version}";
version = "6.19.00";
version = "6.20.00";
src = fetchurl {
urls = [
"http://ftp.funet.fi/pub/mirrors/ftp.astron.com/pub/tcsh/${name}.tar.gz"
"ftp://ftp.astron.com/pub/tcsh/${name}.tar.gz"
"ftp://ftp.funet.fi/pub/unix/shells/tcsh/${name}.tar.gz"
];
sha256 = "0jaw51382pqyb6d1kgfg8ir0wd3p5qr2bmg8svcmjhlyp3h73qhj";
urls = [
"http://ftp.funet.fi/pub/mirrors/ftp.astron.com/pub/tcsh/${name}.tar.gz"
"ftp://ftp.astron.com/pub/tcsh/${name}.tar.gz"
"ftp://ftp.funet.fi/pub/unix/shells/tcsh/${name}.tar.gz"
];
sha256 = "17ggxkkn5skl0v1x0j6hbv5l0sgnidfzwv16992sqkdm983fg7dq";
};
patches = [ ./avoid-gcc5-wrong-optimisation.patch ./tcsh.glibc-2.24.patch ];
buildInputs = [ ncurses ];
meta = with stdenv.lib;{

View File

@ -1,21 +0,0 @@
Proposed patch from Debian bug tracker by Aurelien Jarno <aurel32@debian.org>
diff --git a/sh.proc.c b/sh.proc.c
index ad07250..5c68409 100644
--- a/sh.proc.c
+++ b/sh.proc.c
@@ -47,11 +47,11 @@ RCSID("$tcsh$")
# define HZ 16
#endif /* aiws */
-#if defined(_BSD) || (defined(IRIS4D) && __STDC__) || defined(__lucid) || defined(__linux__) || defined(__GNU__) || defined(__GLIBC__)
-# if !defined(__ANDROID__)
+#if defined(_BSD) || (defined(IRIS4D) && __STDC__) || defined(__lucid) || defined(__linux__) || defined(__GLIBC__)
+# if !defined(__ANDROID__) && !defined(__GLIBC__)
# define BSDWAIT
# endif
-#endif /* _BSD || (IRIS4D && __STDC__) || __lucid || glibc */
+#endif /* _BSD || (IRIS4D && __STDC__) || __lucid || gnu-linux */
#ifndef WTERMSIG
# define WTERMSIG(w) (((union wait *) &(w))->w_termsig)
# ifndef BSDWAIT