Resolves: #1441092 - compile with -fconserve-stack to prevent stack overflow

This commit is contained in:
Kamil Dudka 2017-05-11 10:16:18 +02:00
parent 3174c77ceb
commit 2524ac4722

View File

@ -3,7 +3,7 @@
Summary: Powerful interactive shell
Name: zsh
Version: 5.3.1
Release: 4%{?dist}
Release: 5%{?dist}
License: MIT
URL: http://zsh.sourceforge.net/
Group: System Environment/Shells
@ -68,6 +68,13 @@ This package contains the Zsh manual in html format.
cp -p %SOURCE7 .
%build
# Compile with -fconserve-stack to prevent stack overflow while executing
# unbounded call recursion in a shell script. Without this compiler flag,
# the default stack allocation limit (8192 KiB) is exceeded before the default
# shell call nesting limit (1000) is reached. See #1441092 for details.
# Minimal example: zsh -c 'foo() { if true; then foo; fi }; foo'
export CFLAGS="$RPM_OPT_FLAGS -fconserve-stack"
# make loading of module's dependencies work again (#1277996)
export LIBLDFLAGS='-z lazy'
@ -171,9 +178,13 @@ fi
%doc Doc/*.html
%changelog
* Thu May 11 2017 Kamil Dudka <kdudka@redhat.com> - 5.3.1-5
- compile with -fconserve-stack to prevent stack overflow (#1441092)
* Fri Mar 31 2017 Jason L Tibbitts III <tibbs@math.uh.edu> - 5.3.1-4
- Add build deps on gdbm-devel and pcre-devel. Pass --enable-pcre to
configure. These should ensure that the pcre and gdbm modules are built.
(#1438009)
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 5.3.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild