Accepting request 762024 from home:mcepl:branches:devel:libraries:c_c++
- Add fno-common-build-errs.patch which fixes gh#libuv/libuv#2603 (bsc#1160280) OBS-URL: https://build.opensuse.org/request/show/762024 OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/libuv?expand=0&rev=37
This commit is contained in:
parent
9cbfaaeec2
commit
40ecf1a81f
82
fno-common-build-errs.patch
Normal file
82
fno-common-build-errs.patch
Normal file
@ -0,0 +1,82 @@
|
|||||||
|
From 35a43bdbfd9c4d6d875e92903799e693d5ac18ac Mon Sep 17 00:00:00 2001
|
||||||
|
From: Ben Noordhuis <info@bnoordhuis.nl>
|
||||||
|
Date: Tue, 7 Jan 2020 15:21:03 +0100
|
||||||
|
Subject: [PATCH 1/2] test: fix -fno-common build errors
|
||||||
|
|
||||||
|
Fixes: https://github.com/libuv/libuv/issues/2603
|
||||||
|
---
|
||||||
|
test/test-poll-close-doesnt-corrupt-stack.c | 6 ++----
|
||||||
|
test/test-poll-closesocket.c | 5 ++---
|
||||||
|
2 files changed, 4 insertions(+), 7 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/test/test-poll-close-doesnt-corrupt-stack.c b/test/test-poll-close-doesnt-corrupt-stack.c
|
||||||
|
index 3393820fc4..1d7e84f603 100644
|
||||||
|
--- a/test/test-poll-close-doesnt-corrupt-stack.c
|
||||||
|
+++ b/test/test-poll-close-doesnt-corrupt-stack.c
|
||||||
|
@@ -31,11 +31,9 @@
|
||||||
|
# define NO_INLINE __attribute__ ((noinline))
|
||||||
|
#endif
|
||||||
|
|
||||||
|
-
|
||||||
|
-uv_os_sock_t sock;
|
||||||
|
-uv_poll_t handle;
|
||||||
|
-
|
||||||
|
#ifdef _WIN32
|
||||||
|
+static uv_os_sock_t sock;
|
||||||
|
+static uv_poll_t handle;
|
||||||
|
static int close_cb_called = 0;
|
||||||
|
|
||||||
|
|
||||||
|
diff --git a/test/test-poll-closesocket.c b/test/test-poll-closesocket.c
|
||||||
|
index ecaa9e54a2..1a1c364112 100644
|
||||||
|
--- a/test/test-poll-closesocket.c
|
||||||
|
+++ b/test/test-poll-closesocket.c
|
||||||
|
@@ -25,10 +25,9 @@
|
||||||
|
#include "uv.h"
|
||||||
|
#include "task.h"
|
||||||
|
|
||||||
|
-uv_os_sock_t sock;
|
||||||
|
-uv_poll_t handle;
|
||||||
|
-
|
||||||
|
#ifdef _WIN32
|
||||||
|
+static uv_os_sock_t sock;
|
||||||
|
+static uv_poll_t handle;
|
||||||
|
static int close_cb_called = 0;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
From 5de278e32e50e7600e7aa3d88199e0a51d016b79 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Ben Noordhuis <info@bnoordhuis.nl>
|
||||||
|
Date: Tue, 7 Jan 2020 15:21:03 +0100
|
||||||
|
Subject: [PATCH 2/2] build: turn on -fno-common to catch regressions
|
||||||
|
|
||||||
|
Refs: https://github.com/libuv/libuv/issues/2603
|
||||||
|
---
|
||||||
|
common.gypi | 5 +++--
|
||||||
|
1 file changed, 3 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/common.gypi b/common.gypi
|
||||||
|
index 2297bdf0fb..8e2aa7160b 100644
|
||||||
|
--- a/common.gypi
|
||||||
|
+++ b/common.gypi
|
||||||
|
@@ -35,7 +35,7 @@
|
||||||
|
},
|
||||||
|
'conditions': [
|
||||||
|
['OS != "zos"', {
|
||||||
|
- 'cflags': [ '-O0', '-fwrapv' ]
|
||||||
|
+ 'cflags': [ '-O0', '-fno-common', '-fwrapv' ]
|
||||||
|
}],
|
||||||
|
['OS == "android"', {
|
||||||
|
'cflags': [ '-fPIE' ],
|
||||||
|
@@ -80,9 +80,10 @@
|
||||||
|
'conditions': [
|
||||||
|
['OS != "zos"', {
|
||||||
|
'cflags': [
|
||||||
|
- '-fomit-frame-pointer',
|
||||||
|
'-fdata-sections',
|
||||||
|
'-ffunction-sections',
|
||||||
|
+ '-fno-common',
|
||||||
|
+ '-fomit-frame-pointer',
|
||||||
|
],
|
||||||
|
}],
|
||||||
|
]
|
@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Jan 8 23:29:48 CET 2020 - Matej Cepl <mcepl@suse.com>
|
||||||
|
|
||||||
|
- Add fno-common-build-errs.patch which fixes gh#libuv/libuv#2603
|
||||||
|
(bsc#1160280)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Sun Sep 1 09:34:38 UTC 2019 - Andreas Stieger <andreas.stieger@gmx.de>
|
Sun Sep 1 09:34:38 UTC 2019 - Andreas Stieger <andreas.stieger@gmx.de>
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package libuv
|
# spec file for package libuv
|
||||||
#
|
#
|
||||||
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
|
# Copyright (c) 2020 SUSE LLC
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@ -29,6 +29,9 @@ Source1: https://dist.libuv.org/dist/v%{version}/libuv-v%{version}.tar.gz
|
|||||||
# https://github.com/libuv/libuv/blob/v1.x/MAINTAINERS.md
|
# https://github.com/libuv/libuv/blob/v1.x/MAINTAINERS.md
|
||||||
Source2: %{name}.keyring
|
Source2: %{name}.keyring
|
||||||
Patch1: fix_tests.patch
|
Patch1: fix_tests.patch
|
||||||
|
# PATCH-FIX-UPSTREAM fno-common-build-errs.patch gh#libuv/libuv#2603 mcepl@suse.com
|
||||||
|
# Builds with -fno-common fails in run_tests-test-poll-close-doesnt-corrupt-stack.c
|
||||||
|
Patch2: fno-common-build-errs.patch
|
||||||
BuildRequires: autoconf
|
BuildRequires: autoconf
|
||||||
BuildRequires: automake
|
BuildRequires: automake
|
||||||
BuildRequires: libtool
|
BuildRequires: libtool
|
||||||
@ -63,7 +66,7 @@ Mozilla's Rust language, Luvit, Julia, pyuv, and others.
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{name}-v%{version}
|
%setup -q -n %{name}-v%{version}
|
||||||
%patch1 -p1
|
%autopatch -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
./autogen.sh
|
./autogen.sh
|
||||||
|
Loading…
x
Reference in New Issue
Block a user