From 837ec7ef971d3b33160958c6831f7567e84c9aeb Mon Sep 17 00:00:00 2001 From: Yaakov Selkowitz Date: Fri, 24 Jun 2016 15:01:43 -0500 Subject: cygwin 2.5.2 --- 0001-Fix-compile-with-GCC-5-Werror.patch | 73 ------------------- 0002-Remove-broken-ieeefp.h-macros.patch | 54 -------------- 0003-cygwin-fix-errors-with-GCC-5.patch | 83 ---------------------- ...in-work-around-GCC-5-preprocessor-changes.patch | 32 --------- cygwin.spec | 18 ++--- sources | 2 +- 6 files changed, 7 insertions(+), 255 deletions(-) delete mode 100644 0001-Fix-compile-with-GCC-5-Werror.patch delete mode 100644 0002-Remove-broken-ieeefp.h-macros.patch delete mode 100644 0003-cygwin-fix-errors-with-GCC-5.patch delete mode 100644 0004-cygwin-work-around-GCC-5-preprocessor-changes.patch diff --git a/0001-Fix-compile-with-GCC-5-Werror.patch b/0001-Fix-compile-with-GCC-5-Werror.patch deleted file mode 100644 index c1975e1..0000000 --- a/0001-Fix-compile-with-GCC-5-Werror.patch +++ /dev/null @@ -1,73 +0,0 @@ -From 8b8952064cfacf91b18aed37fbd44f621edb6941 Mon Sep 17 00:00:00 2001 -From: Yaakov Selkowitz -Date: Thu, 11 Feb 2016 20:16:06 -0600 -Subject: [PATCH 1/4] Fix compile with GCC 5 -Werror - - newlib/libc/ - * stdio64/freopen64.c: Include for memset(). - * stdlib/quick_exit.c: Include for _exit(). - * string/gnu_basename.c (__gnu_basename): Fix discarded const - qualifier warning. - * stdlib/strtold.c: Include "mprec.h" for _strtorx_r(). - -Signed-off-by: Yaakov Selkowitz ---- - newlib/libc/stdio64/freopen64.c | 1 + - newlib/libc/stdlib/quick_exit.c | 1 + - newlib/libc/stdlib/strtold.c | 2 ++ - newlib/libc/string/gnu_basename.c | 2 +- - 4 files changed, 5 insertions(+), 1 deletion(-) - -diff --git a/newlib/libc/stdio64/freopen64.c b/newlib/libc/stdio64/freopen64.c -index 8a069d5..f7df354 100644 ---- a/newlib/libc/stdio64/freopen64.c -+++ b/newlib/libc/stdio64/freopen64.c -@@ -74,6 +74,7 @@ Supporting OS subroutines required: <>, <>, <>, - - #include - #include -+#include - #include - #include - #include -diff --git a/newlib/libc/stdlib/quick_exit.c b/newlib/libc/stdlib/quick_exit.c -index fc43571..1d6fb23 100644 ---- a/newlib/libc/stdlib/quick_exit.c -+++ b/newlib/libc/stdlib/quick_exit.c -@@ -28,6 +28,7 @@ - */ - - #include -+#include - #include - - /** -diff --git a/newlib/libc/stdlib/strtold.c b/newlib/libc/stdlib/strtold.c -index 96254eb..a6d415d 100644 ---- a/newlib/libc/stdlib/strtold.c -+++ b/newlib/libc/stdlib/strtold.c -@@ -30,6 +30,8 @@ POSSIBILITY OF SUCH DAMAGE. - - #include - #include "local.h" -+#include "mprec.h" -+#undef FLT_ROUNDS - - #ifdef _HAVE_LONG_DOUBLE - -diff --git a/newlib/libc/string/gnu_basename.c b/newlib/libc/string/gnu_basename.c -index 46b92d0..90e22cc 100644 ---- a/newlib/libc/string/gnu_basename.c -+++ b/newlib/libc/string/gnu_basename.c -@@ -20,7 +20,7 @@ _DEFUN (__gnu_basename, (path), - char *p; - if ((p = strrchr (path, '/'))) - return p + 1; -- return path; -+ return (char *) path; - } - - #endif /* !_NO_BASENAME */ --- -2.7.4 - diff --git a/0002-Remove-broken-ieeefp.h-macros.patch b/0002-Remove-broken-ieeefp.h-macros.patch deleted file mode 100644 index c1c5f8f..0000000 --- a/0002-Remove-broken-ieeefp.h-macros.patch +++ /dev/null @@ -1,54 +0,0 @@ -From ac2f9e23ecd197758e7cc2ca1b8717add3d8762b Mon Sep 17 00:00:00 2001 -From: Yaakov Selkowitz -Date: Thu, 11 Feb 2016 20:23:10 -0600 -Subject: [PATCH 2/4] Remove broken ieeefp.h macros - -Any attempt to use isnanf, isinff, or finitef from with -GCC 5 on platforms other than SPU result in a "lvalue required as -unary '&' operand" error. - - newlib/libc/ - * include/ieeefp.h (__ieeefp_isnanf): Remove broken macro. - (__ieeefp_isinff, __ieeefp_finitef): Ditto. - -Signed-off-by: Yaakov Selkowitz ---- - newlib/libc/include/ieeefp.h | 17 ++++++----------- - 1 file changed, 6 insertions(+), 11 deletions(-) - -diff --git a/newlib/libc/include/ieeefp.h b/newlib/libc/include/ieeefp.h -index 9eb274d..2ffa456 100644 ---- a/newlib/libc/include/ieeefp.h -+++ b/newlib/libc/include/ieeefp.h -@@ -270,22 +270,17 @@ int _EXFUN(finitef, (float)); - #define __IEEE_DBL_NAN_EXP 0x7ff - #define __IEEE_FLT_NAN_EXP 0xff - --#ifndef __ieeefp_isnanf --#define __ieeefp_isnanf(x) (((*(long *)&(x) & 0x7f800000L)==0x7f800000L) && \ -- ((*(long *)&(x) & 0x007fffffL)!=0000000000L)) --#endif -+#ifdef __ieeefp_isnanf - #define isnanf(x) __ieeefp_isnanf(x) -- --#ifndef __ieeefp_isinff --#define __ieeefp_isinff(x) (((*(long *)&(x) & 0x7f800000L)==0x7f800000L) && \ -- ((*(long *)&(x) & 0x007fffffL)==0000000000L)) - #endif --#define isinff(x) __ieeefp_isinff(x) - --#ifndef __ieeefp_finitef --#define __ieeefp_finitef(x) (((*(long *)&(x) & 0x7f800000L)!=0x7f800000L)) -+#ifdef __ieeefp_isinff -+#define isinff(x) __ieeefp_isinff(x) - #endif -+ -+#ifdef __ieeefp_finitef - #define finitef(x) __ieeefp_finitef(x) -+#endif - - #ifdef _DOUBLE_IS_32BITS - #undef __IEEE_DBL_EXPBIAS --- -2.7.4 - diff --git a/0003-cygwin-fix-errors-with-GCC-5.patch b/0003-cygwin-fix-errors-with-GCC-5.patch deleted file mode 100644 index 36b0311..0000000 --- a/0003-cygwin-fix-errors-with-GCC-5.patch +++ /dev/null @@ -1,83 +0,0 @@ -From c5f03820fc4f8c9910f52ab2ef951a6e32ed3ff1 Mon Sep 17 00:00:00 2001 -From: Yaakov Selkowitz -Date: Fri, 12 Feb 2016 11:17:35 -0600 -Subject: [PATCH 3/4] cygwin: fix errors with GCC 5 - -GCC 5 switched from C89 to C11 by default. This implies a change from -GNU to C99 inline by default, which have very different meanings of -extern inline vs. static inline: - -https://gcc.gnu.org/onlinedocs/gcc/Inline.html - -Marking these as gnu_inline retains the previous behaviour. - - winsup/cygwin/ - * exceptions.cc (exception::handle): Change debugging to int to fix - an always-true boolean comparison warning. - * include/cygwin/config.h (__getreent): Mark gnu_inline. - * winbase.h (ilockcmpexch, ilockcmpexch64): Ditto. - -Signed-off-by: Yaakov Selkowitz ---- - winsup/cygwin/exceptions.cc | 4 ++-- - winsup/cygwin/include/cygwin/config.h | 1 + - winsup/cygwin/winbase.h | 2 ++ - 3 files changed, 5 insertions(+), 2 deletions(-) - -diff --git a/winsup/cygwin/exceptions.cc b/winsup/cygwin/exceptions.cc -index c3a45d2..1627d43 100644 ---- a/winsup/cygwin/exceptions.cc -+++ b/winsup/cygwin/exceptions.cc -@@ -637,7 +637,7 @@ EXCEPTION_DISPOSITION - exception::handle (EXCEPTION_RECORD *e, exception_list *frame, CONTEXT *in, - PDISPATCHER_CONTEXT dispatch) - { -- static bool NO_COPY debugging; -+ static int NO_COPY debugging = 0; - _cygtls& me = _my_tls; - - #ifndef __x86_64__ -@@ -808,7 +808,7 @@ exception::handle (EXCEPTION_RECORD *e, exception_list *frame, CONTEXT *in, - rtl_unwind (frame, e); - else - { -- debugging = true; -+ debugging = 1; - return ExceptionContinueExecution; - } - -diff --git a/winsup/cygwin/include/cygwin/config.h b/winsup/cygwin/include/cygwin/config.h -index 58cff05..204826d 100644 ---- a/winsup/cygwin/include/cygwin/config.h -+++ b/winsup/cygwin/include/cygwin/config.h -@@ -43,6 +43,7 @@ extern "C" { - #else - #include "../tlsoffsets.h" - #endif -+__attribute__((gnu_inline)) - extern inline struct _reent *__getreent (void) - { - register char *ret; -diff --git a/winsup/cygwin/winbase.h b/winsup/cygwin/winbase.h -index 666f74a..1e825e4 100644 ---- a/winsup/cygwin/winbase.h -+++ b/winsup/cygwin/winbase.h -@@ -11,6 +11,7 @@ details. */ - #ifndef _WINBASE2_H - #define _WINBASE2_H - -+__attribute__((gnu_inline)) - extern __inline__ LONG - ilockcmpexch (volatile LONG *t, LONG v, LONG c) - { -@@ -30,6 +31,7 @@ ilockcmpexch (volatile LONG *t, LONG v, LONG c) - #undef InterlockedCompareExchangePointer - - #ifdef __x86_64__ -+__attribute__((gnu_inline)) - extern __inline__ LONGLONG - ilockcmpexch64 (volatile LONGLONG *t, LONGLONG v, LONGLONG c) - { --- -2.7.4 - diff --git a/0004-cygwin-work-around-GCC-5-preprocessor-changes.patch b/0004-cygwin-work-around-GCC-5-preprocessor-changes.patch deleted file mode 100644 index 691d997..0000000 --- a/0004-cygwin-work-around-GCC-5-preprocessor-changes.patch +++ /dev/null @@ -1,32 +0,0 @@ -From ef64aa4940e1d9120875a74f37b8419680f535e3 Mon Sep 17 00:00:00 2001 -From: Yaakov Selkowitz -Date: Fri, 12 Feb 2016 16:02:13 -0600 -Subject: [PATCH 4/4] cygwin: work around GCC 5 preprocessor changes - -GCC 5 adds #line directives (and hence extra newlines) for macros -expansions, which confuses cygmagic. Using the -P flag avoids -them entirely. - -https://cygwin.com/ml/cygwin-patches/2016-q1/msg00016.html - -Signed-off-by: Yaakov Selkowitz ---- - winsup/cygwin/cygmagic | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/winsup/cygwin/cygmagic b/winsup/cygwin/cygmagic -index b945291..036c79c 100755 ---- a/winsup/cygwin/cygmagic -+++ b/winsup/cygwin/cygmagic -@@ -24,7 +24,7 @@ sumit() { - while [ -n "$1" ]; do - define=$1; shift - struct=$1; shift -- sum=`$gcc -D__CYGMAGIC__ -E $file | sed -n "/^$struct/,/^};/p" | sed -e 's/[ ]//g' -e '/^$/d' | sumit | awk '{printf "0x%xU", $1}'` -+ sum=`$gcc -D__CYGMAGIC__ -E -P $file | sed -n "/^$struct/,/^};/p" | sed -e 's/[ ]//g' -e '/^$/d' | sumit | awk '{printf "0x%xU", $1}'` - echo "#define $define $sum" - curr=`sed -n "s/^#[ ]*define CURR_$define[ ][ ]*\([^ ][^ ]*\)/\1/p" $file` - [ "$curr" != "$sum" ] && echo "*** WARNING WARNING WARNING WARNING WARNING *** --- -2.7.4 - diff --git a/cygwin.spec b/cygwin.spec index 8efb79b..85119be 100644 --- a/cygwin.spec +++ b/cygwin.spec @@ -1,22 +1,17 @@ %{?cygwin_package_header} Name: cygwin -Version: 2.4.1 -Release: 2%{?dist} +Version: 2.5.2 +Release: 1%{?dist} Summary: Cygwin cross-compiler runtime -License: GPLv2 with exceptions +License: LGPLv3+ and GPLv3+ Group: Development/Libraries URL: http://www.cygwin.com/ BuildArch: noarch # downloaded and extracted by get-sources.sh Source0: newlib-cygwin-%{version}.tar.bz2 -# GCC 5 patches -Patch1: 0001-Fix-compile-with-GCC-5-Werror.patch -Patch2: 0002-Remove-broken-ieeefp.h-macros.patch -Patch3: 0003-cygwin-fix-errors-with-GCC-5.patch -Patch4: 0004-cygwin-work-around-GCC-5-preprocessor-changes.patch BuildRequires: cygwin32-filesystem >= 7 BuildRequires: cygwin32-binutils @@ -70,10 +65,6 @@ Cygwin 64-bit cross-compiler runtime, base libraries. %prep %setup -q -n newlib-cygwin -%patch1 -p1 -%patch2 -p1 -%patch3 -p1 -%patch4 -p1 touch winsup/cygwin/tlsoffsets*.h touch winsup/cygwin/devices.cc @@ -150,6 +141,9 @@ rm -fr $RPM_BUILD_ROOT%{cygwin64_includedir}/rpc/ %changelog +* Fri Jun 24 2016 Yaakov Selkowitz - 2.5.2-1 +- new version + * Wed Mar 30 2016 Yaakov Selkowitz - 2.4.1-2 - Fix build with GCC 5 diff --git a/sources b/sources index bf0270a..9931c7b 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -26a50d8088892f05d9e482a512799292 newlib-cygwin-2.4.1.tar.bz2 +44ad55b635c8e8c136e99c5819537821 newlib-cygwin-2.5.2.tar.bz2 -- cgit