Patch for RtlUnwindEx fix and systemd binfmt macros

f38
Michael Cronenworth 10 years ago
parent d21e5d7c74
commit 2101e29194

@ -0,0 +1,76 @@
diff --git a/debian/changelog b/debian/changelog
index bf71cad..9293125 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,7 @@
+wine-staging (1.7.36-1) UNRELEASED; urgency=low
+ * Update patchset for RtlUnwindEx on x86_64 and fix a second bug.
+ -- Sebastian Lackner <sebastian@fds-team.de> Sun, 15 Feb 2015 22:24:13 +0100
+
wine-staging (1.7.36) unstable; urgency=low
* Fix an incompatibility of patchinstall.sh with non-bash shells under specific situations.
* Improve dinput-Events patch to be compatible with applications which do not explicitly poll for input.
diff --git a/patches/ntdll-RtlUnwindEx/0001-ntdll-Fix-check-for-end_frame-in-RtlUnwindEx-on-x86_.patch b/patches/ntdll-RtlUnwindEx/0001-ntdll-Fix-check-for-end_frame-in-RtlUnwindEx-on-x86_.patch
index 455a7fc..c5e8903 100644
--- a/patches/ntdll-RtlUnwindEx/0001-ntdll-Fix-check-for-end_frame-in-RtlUnwindEx-on-x86_.patch
+++ b/patches/ntdll-RtlUnwindEx/0001-ntdll-Fix-check-for-end_frame-in-RtlUnwindEx-on-x86_.patch
@@ -1,18 +1,32 @@
-From 7dd7631b611976b237acc63386b26866e5b4b253 Mon Sep 17 00:00:00 2001
+From 3c89d2a189c2cc869c7ce81293ab752e3fa57708 Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Sun, 25 Jan 2015 15:46:05 +0100
-Subject: ntdll: Fix check for end_frame in RtlUnwindEx on x86_64.
+Subject: ntdll: Fix check for end_frame in RtlUnwindEx on x86_64. (rev 2)
+Changes in v2:
+* Calling wine internal handlers should not mess up the EstablisherFrame.
---
- dlls/ntdll/signal_x86_64.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
+ dlls/ntdll/signal_x86_64.c | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/dlls/ntdll/signal_x86_64.c b/dlls/ntdll/signal_x86_64.c
-index 05581c2..e739cdb 100644
+index 05581c2..7072569 100644
--- a/dlls/ntdll/signal_x86_64.c
+++ b/dlls/ntdll/signal_x86_64.c
-@@ -3178,7 +3178,7 @@ void WINAPI RtlUnwindEx( PVOID end_frame, PVOID target_ip, EXCEPTION_RECORD *rec
- dispatch.EstablisherFrame = new_context.Rsp;
+@@ -3167,6 +3167,7 @@ void WINAPI RtlUnwindEx( PVOID end_frame, PVOID target_ip, EXCEPTION_RECORD *rec
+ }
+ else /* hack: call builtin handlers registered in the tib list */
+ {
++ DWORD64 backup_frame = dispatch.EstablisherFrame;
+ while ((ULONG64)teb_frame < new_context.Rsp && (ULONG64)teb_frame < (ULONG64)end_frame)
+ {
+ TRACE( "found builtin frame %p handler %p\n", teb_frame, teb_frame->Handler );
+@@ -3175,10 +3176,10 @@ void WINAPI RtlUnwindEx( PVOID end_frame, PVOID target_ip, EXCEPTION_RECORD *rec
+ teb_frame = __wine_pop_frame( teb_frame );
+ }
+ if ((ULONG64)teb_frame == (ULONG64)end_frame && (ULONG64)end_frame < new_context.Rsp) break;
+- dispatch.EstablisherFrame = new_context.Rsp;
++ dispatch.EstablisherFrame = backup_frame;
}
- if (context->Rsp == (ULONG64)end_frame) break;
@@ -21,5 +35,5 @@ index 05581c2..e739cdb 100644
}
--
-2.2.1
+2.2.2
diff --git a/patches/patchinstall.sh b/patches/patchinstall.sh
index b1ac228..9f8a0fa 100755
--- a/patches/patchinstall.sh
+++ b/patches/patchinstall.sh
@@ -2228,7 +2228,7 @@ fi
if test "$enable_ntdll_RtlUnwindEx" -eq 1; then
patch_apply ntdll-RtlUnwindEx/0001-ntdll-Fix-check-for-end_frame-in-RtlUnwindEx-on-x86_.patch
(
- echo '+ { "Sebastian Lackner", "ntdll: Fix check for end_frame in RtlUnwindEx on x86_64.", 1 },';
+ echo '+ { "Sebastian Lackner", "ntdll: Fix check for end_frame in RtlUnwindEx on x86_64.", 2 },';
) >> "$patchlist"
fi

@ -9,9 +9,17 @@
%global compholio 1 %global compholio 1
%endif # 0%{?fedora} %endif # 0%{?fedora}
# binfmt macros for RHEL
%if 0%{?fedora} <= 20 || 0%{?rhel} == 7
%_binfmtdir /usr/lib/binfmt.d
%binfmt_apply() \
/usr/lib/systemd/systemd-binfmt %{?*} >/dev/null 2>&1 || : \
%{nil}
%endif
Name: wine Name: wine
Version: 1.7.36 Version: 1.7.36
Release: 1%{?dist} Release: 2%{?dist}
Summary: A compatibility layer for windows applications Summary: A compatibility layer for windows applications
Group: Applications/Emulators Group: Applications/Emulators
@ -62,6 +70,9 @@ Patch511: wine-cjk.patch
# pulseaudio-patch is covered by that patch-set, too. # pulseaudio-patch is covered by that patch-set, too.
Source900: https://github.com/compholio/wine-compholio/archive/v%{version}.tar.gz#/wine-staging-%{version}.tar.gz Source900: https://github.com/compholio/wine-compholio/archive/v%{version}.tar.gz#/wine-staging-%{version}.tar.gz
# https://bugs.wine-staging.com/show_bug.cgi?id=68
Patch900: wine-staging-rtlunwindex.patch
%if !%{?no64bit} %if !%{?no64bit}
ExclusiveArch: %{ix86} x86_64 %{arm} ExclusiveArch: %{ix86} x86_64 %{arm}
%else %else
@ -292,7 +303,7 @@ Provides: wine-wow = %{version}-%{release}
%description core %description core
Wine core package includes the basic wine stuff needed by all other packages. Wine core package includes the basic wine stuff needed by all other packages.
%if 0%{?fedora} >= 15 %if 0%{?fedora} >= 15 || 0%{?rhel} >= 7
%package systemd %package systemd
Summary: Systemd config for the wine binfmt handler Summary: Systemd config for the wine binfmt handler
Group: Applications/Emulators Group: Applications/Emulators
@ -340,7 +351,7 @@ Requires(preun): /sbin/chkconfig, /sbin/service
Requires(postun): desktop-file-utils >= 0.8 Requires(postun): desktop-file-utils >= 0.8
Requires: wine-core = %{version}-%{release} Requires: wine-core = %{version}-%{release}
Requires: wine-common = %{version}-%{release} Requires: wine-common = %{version}-%{release}
%if 0%{?fedora} >= 15 %if 0%{?fedora} >= 15 || 0%{?rhel} >= 7
Requires: wine-systemd = %{version}-%{release} Requires: wine-systemd = %{version}-%{release}
%endif %endif
Requires: hicolor-icon-theme Requires: hicolor-icon-theme
@ -605,6 +616,7 @@ This package adds the opencl driver for wine.
# since the pulse patch is included in the compholio patches use it from # since the pulse patch is included in the compholio patches use it from
# there # there
gzip -dc %{SOURCE900} | tar -xf - --strip-components=1 gzip -dc %{SOURCE900} | tar -xf - --strip-components=1
%patch900 -p1 -b.rtlunwindex
%if 0%{?compholio} %if 0%{?compholio}
%{__make} -C patches DESTDIR="`pwd`" install %{__make} -C patches DESTDIR="`pwd`" install
@ -685,9 +697,9 @@ mkdir -p %{buildroot}%{_sysconfdir}/wine
# Allow users to launch Windows programs by just clicking on the .exe file... # Allow users to launch Windows programs by just clicking on the .exe file...
mkdir -p %{buildroot}%{_initrddir} mkdir -p %{buildroot}%{_initrddir}
install -p -c -m 755 %{SOURCE1} %{buildroot}%{_initrddir}/wine install -p -c -m 755 %{SOURCE1} %{buildroot}%{_initrddir}/wine
%if 0%{?fedora} >= 15 %if 0%{?fedora} >= 15 || 0%{?rhel} >= 7
mkdir -p %{buildroot}%{_usr}/lib/binfmt.d mkdir -p %{buildroot}%{_binfmtdir}
install -p -c -m 644 %{SOURCE2} %{buildroot}%{_usr}/lib/binfmt.d/wine.conf install -p -c -m 644 %{SOURCE2} %{buildroot}%{_binfmtdir}/wine.conf
%endif %endif
# add wine dir to desktop # add wine dir to desktop
@ -868,7 +880,7 @@ if [ $1 -eq 0 ]; then
fi fi
%post systemd %post systemd
/bin/systemctl try-restart systemd-binfmt.service %binfmt_apply wine.conf
%postun systemd %postun systemd
if [ $1 -eq 0 ]; then if [ $1 -eq 0 ]; then
@ -1733,9 +1745,9 @@ fi
%{_datadir}/icons/hicolor/scalable/apps/*svg %{_datadir}/icons/hicolor/scalable/apps/*svg
%endif %endif
%if 0%{?fedora} >= 15 %if 0%{?fedora} >= 15 || 0%{?rhel} >= 7
%files systemd %files systemd
%config %{_usr}/lib/binfmt.d/wine.conf %config %{_binfmtdir}/wine.conf
%files sysvinit %files sysvinit
%endif %endif
@ -1802,6 +1814,10 @@ fi
%{_libdir}/wine/opencl.dll.so %{_libdir}/wine/opencl.dll.so
%changelog %changelog
* Mon Feb 16 2015 Michael Cronenworth <mike@cchtml.com> - 1.7.36-2
- Patch for RtlUnwindEx fix (staging bz #68)
- Use new systemd macros for binfmt handling
* Sun Feb 08 2015 Michael Cronenworth <mike@cchtml.com> - 1.7.36-1 * Sun Feb 08 2015 Michael Cronenworth <mike@cchtml.com> - 1.7.36-1
- version upgrade - version upgrade

Loading…
Cancel
Save