Manual merge of version 6.0.3~repack-1+rpi1 and 7.0~repack-4 to produce 7.0~repack...
authorPeter Michael Green <plugwash@raspbian.org>
Fri, 22 Jul 2022 02:19:42 +0000 (02:19 +0000)
committerPeter Michael Green <plugwash@raspbian.org>
Fri, 22 Jul 2022 04:54:22 +0000 (04:54 +0000)
1  2 
debian/changelog
debian/patches/raspbian.patch
debian/patches/series
debian/rules
dlls/ntdll/unix/signal_arm.c

index e714765994a3a0ca10d0f8e9a2a2ea6cc7a45943,d3f5d31b4fd25e6580f08f538dc54500d8a73eb6..47bacb7a7a759c56c1b16111b24f040d2792c865
- wine (6.0.3~repack-1+rpi1) bookworm-staging; urgency=medium
++wine (7.0~repack-4+rpi1) bookworm-staging; urgency=medium
 +
++  [changes brought forward from 6.0.3~repack-1+rpi1 by Peter Michael Green <plugwash@raspbian.org> at Sat, 19 Mar 2022 00:48:02 +0000]
 +  * Build for armv6k on raspbian.
 +  * Replace movt instruction with orr instruction to support armv6k build.
 +
-  -- Peter Michael Green <plugwash@raspbian.org>  Sat, 19 Mar 2022 00:48:02 +0000
++ -- Peter Michael Green <plugwash@raspbian.org>  Fri, 22 Jul 2022 02:18:42 +0000
 +
- wine (6.0.3~repack-1) unstable; urgency=medium
+ wine (7.0~repack-4) unstable; urgency=medium
  
-   * New upstream release 6.0.3, released Feb 25, 2022.
-   * Move nls files back to libwine (closes: #1006827).
+   * Fix syntax error in configure.ac.
+   * Support installing wine-binfmt without binfmt-support.
+   * Restore mistakenly removed binfmt-support file (closes: #1014323).
  
-  -- Michael Gilbert <mgilbert@debian.org>  Sun, 13 Mar 2022 04:27:41 +0000
+  -- Michael Gilbert <mgilbert@debian.org>  Wed, 06 Jul 2022 00:44:32 +0000
  
- wine (6.0.2~repack-3) unstable; urgency=medium
+ wine (7.0~repack-3) unstable; urgency=medium
  
-   * Remove nls files from the libwine package (closes: #1006539).
-   * Build for armv6t2 on armel (new minimum ARM architecture required by wine).
+   * Fix dangling symlinks (closes: #1012827).
+   * Support building with gcc 12 (closes: #1013067).
+  -- Michael Gilbert <mgilbert@debian.org>  Mon, 04 Jul 2022 00:34:31 +0000
+ wine (7.0~repack-2) unstable; urgency=medium
+   * Fix format string error on armhf.
+   * Denote wine32:i386 in launcher (closes: #1011461).
+   * Add support for systemd-binfmt (closes: #1012353).
+     - Thanks to Michael Biebl.
+   * Avoid infinite recursion in make_vulkan (closes: #1013501).
+     - Thanks to Adrian Heine.
+  -- Michael Gilbert <mgilbert@debian.org>  Sun, 03 Jul 2022 18:24:37 +0000
+ wine (7.0~repack-1) unstable; urgency=medium
+   * New upstream release 7.0, released Jan 18, 2022 (closes: #1007913).
+     - Fix crash during resolution change in a few games (closes: #1002023).
+  -- Michael Gilbert <mgilbert@debian.org>  Sun, 05 Jun 2022 21:54:23 +0000
+ wine-development (6.23~repack-4) unstable; urgency=medium
+   * Ignore unused function warnings on arm.
+  -- Michael Gilbert <mgilbert@debian.org>  Mon, 23 May 2022 22:46:02 +0000
+ wine-development (6.23~repack-3) unstable; urgency=medium
+   * Fix incorrect winedbg format strings on arm.
+   * Ignore warnings when building embedded libraries.
+   * Build for armv7-a on armel (new minimum ARM architecture required by wine).
+  -- Michael Gilbert <mgilbert@debian.org>  Mon, 23 May 2022 01:17:00 +0000
  
-  -- Michael Gilbert <mgilbert@debian.org>  Sun, 27 Feb 2022 21:18:36 +0000
+ wine-development (6.23~repack-2) unstable; urgency=medium
+   * Correct shift-overflow flag for clang on arm64.
+   * Add libusb-1.0-0-dev to the build dependencies.
+   * Build with system zlib PE only on i386 and amd64.
+   * Fix installation paths for fonts and nls files (closes: #1010269).
+  -- Michael Gilbert <mgilbert@debian.org>  Thu, 05 May 2022 18:09:14 +0000
+ wine-development (6.23~repack-1) unstable; urgency=medium
+   * New upstream release 6.23, released Dec 3, 2021.
+     - Mount manager and CoreAudio driver converted to PE.
+     - Support for exception handling in Wow64 mode.
+     - Optional support for using the distribution's PE libraries.
+     - A number of UI improvements in WineDbg.
+     - Various bug fixes.
+   * Fix wine64 preloader symlink (closes: #1009940).
+  -- Michael Gilbert <mgilbert@debian.org>  Mon, 25 Apr 2022 01:03:00 +0000
+ wine-development (6.22~repack-1) unstable; urgency=medium
+   * New upstream release 6.22, released Nov 19, 2021.
+     - Exception unwinding on ARM.
+     - More improvements to HID joystick support.
+     - WoW64 thunks in a number of Unix libraries.
+     - Beginnings of moving USER32 to Win32u.
+     - Various bug fixes.
+   * Fix incorrect format strings on armhf.
+  -- Michael Gilbert <mgilbert@debian.org>  Sun, 17 Apr 2022 05:28:05 +0000
+ wine-development (6.21~repack-1) unstable; urgency=medium
+   * New upstream release 6.21, released Nov 5, 2021.
+     - WinSpool, GPhoto, and a few other modules converted to PE.
+     - Better support for inline functions in DbgHelp.
+     - Beginnings of a MSDASQL implementation.
+     - Various bug fixes.
+   * Fix installation of wine64-preloader.
  
- wine (6.0.2~repack-2) unstable; urgency=medium
+  -- Michael Gilbert <mgilbert@debian.org>  Sun, 10 Apr 2022 06:22:40 +0000
+ wine-development (6.20~repack-1) unstable; urgency=medium
+   * New upstream release 6.20, released Oct 22, 2021.
+     - MSXml, XAudio, DInput and a few other modules converted to PE.
+     - A few system libraries are bundled with the source to support PE builds.
+     - HID joystick is now the only supported joystick backend in DirectInput.
+     - Better support for MSVCRT builds in Winelib.
+     - Various bug fixes.
+   * Append .static to the statically linked preloader binaries.
+  -- Michael Gilbert <mgilbert@debian.org>  Sat, 09 Apr 2022 16:28:27 +0000
+ wine-development (6.19~repack-2) unstable; urgency=medium
+   * Fix uninitialized variable warnings.
+  -- Michael Gilbert <mgilbert@debian.org>  Mon, 04 Apr 2022 03:10:09 +0000
+ wine-development (6.19~repack-1) unstable; urgency=medium
+   * New upstream release 6.19, released Oct 8, 2021.
+     - IPHlpApi, NsiProxy, WineDbg, and other modules converted to PE.
+     - More HID joystick work.
+     - Kernel parts of GDI moved to Win32u.
+     - More work towards Dwarf 3/4 debug support.
+     - Various bug fixes.
+  -- Michael Gilbert <mgilbert@debian.org>  Mon, 04 Apr 2022 01:10:02 +0000
+ wine-development (6.18~repack-1) unstable; urgency=medium
+   * New upstream release 6.18, released Sep 24, 2021.
+     - Shell32 and WineBus libraries converted to PE.
+     - More work towards Dwarf 3/4 debug support.
+     - HID joystick enabled by default.
+     - Various bug fixes.
+  -- Michael Gilbert <mgilbert@debian.org>  Thu, 31 Mar 2022 03:59:06 +0000
+ wine-development (6.17~repack-1) unstable; urgency=medium
+   * New upstream release 6.17, released Sep 10, 2021.
+     - WineCfg program converted to PE.
+     - Better high-DPI support in builtin applications.
+     - More preparation work for the GDI syscall interface.
+     - Improved debugger support in Wow64 mode.
+     - Various bug fixes.
+  -- Michael Gilbert <mgilbert@debian.org>  Wed, 30 Mar 2022 14:46:35 +0000
+ wine-development (6.16~repack-1) unstable; urgency=medium
+   * New upstream release 6.16, released Aug 27, 2021.
+     - Initial version of a HID-based joystick backend.
+     - Improved high-DPI theming support.
+     - More preparation work for the GDI syscall interface.
+     - Better CodeView support in WineDump.
+     - Various bug fixes.
+  -- Michael Gilbert <mgilbert@debian.org>  Wed, 30 Mar 2022 11:58:02 +0000
+ wine-development (6.15~repack-1) unstable; urgency=medium
+   * New upstream release 6.15, released Aug 13, 2021.
+     - WinSock (WS2_32) library converted to PE.
+     - Support for performance data in the registry.
+     - More 32->64-bit thunks for NTDLL calls.
+     - Improved floating point status handling in the C runtime.
+     - More preparation work for the GDI syscall interface.
+     - Various bug fixes.
  
-   * Fix font installation error.
+  -- Michael Gilbert <mgilbert@debian.org>  Tue, 29 Mar 2022 17:25:40 +0000
+ wine-development (6.14~repack-1) unstable; urgency=medium
+   * New upstream release 6.14, released Jul 30, 2021.
+     - 32->64-bit thunks implemented in WOW64 dll.
+     - More preparation work for the GDI syscall interface.
+     - Various bug fixes.
+  -- Michael Gilbert <mgilbert@debian.org>  Mon, 28 Mar 2022 20:41:47 +0000
+ wine-development (6.13~repack-1) unstable; urgency=medium
+   * New upstream release 6.13, released Jul 20, 2021.
+     - Proper scrollbar theming.
+     - More work towards WinSock PE conversion.
+     - Preparation work for the GDI syscall interface.
+     - Some progress on the IPHLPAPI PE conversion.
+     - Various bug fixes.
+  -- Michael Gilbert <mgilbert@debian.org>  Mon, 28 Mar 2022 20:18:03 +0000
+ wine-development (6.12~repack-1) unstable; urgency=medium
+   * New upstream release 6.12, released Jul 2, 2021.
+     - Builtin "Blue" and "Classic Blue" themes.
+     - More work towards WinSock PE conversion.
+     - Beginnings of the NSI (Network Store Interface) implementation.
+     - Support for 32/64-bit registry views in reg.exe.
+     - Various bug fixes.
+  -- Michael Gilbert <mgilbert@debian.org>  Sun, 27 Mar 2022 13:52:14 +0000
+ wine-development (6.11~repack-1) unstable; urgency=medium
+   * New upstream release 6.11, released Jun 18, 2021.
+     - Theming support in all builtin programs.
+     - All remaining CRT math functions imported from Musl.
+     - Support for codepage 720 (Arabic).
+     - Various bug fixes.
+  -- Michael Gilbert <mgilbert@debian.org>  Sun, 27 Mar 2022 04:01:42 +0000
+ wine-development (6.10~repack-1) unstable; urgency=medium
+   * New upstream release 6.10, released Jun 4, 2021.
+     - Shell folders naming scheme follows recent Windows.
+     - WinePulse library converted to PE.
+     - More math functions from Musl in the C runtime.
+     - Various bug fixes.
+   * Remove Jens Reyer from the uploaders.
+     - Thank you for your previous contributions.
+  -- Michael Gilbert <mgilbert@debian.org>  Sat, 26 Mar 2022 21:41:28 +0000
+ wine-development (6.9~repack-1) unstable; urgency=medium
+   * New upstream release 6.9, released May 21, 2021.
+     - WPCAP library converted to PE.
+     - Support for paper forms in the print spooler.
+     - More math functions from Musl in the C runtime.
+     - Various bug fixes.
+   * Enable support for JPEG XR image files.
+   * Copy dlls from libz-mingw for both i386 and x86_64.
+   * Move nls files from wine-development to libwine-development.
+  -- Michael Gilbert <mgilbert@debian.org>  Sat, 26 Mar 2022 19:42:48 +0000
+ wine-development (6.8~repack-1) unstable; urgency=medium
+   * New upstream release 6.8, released May 7, 2021.
+     - Libraries installed into architecture-specific subdirectories.
+     - Secur32 library converted to PE.
+     - Support for Map object in JavaScript.
+     - Various bug fixes.
+   * Handle new architecture-specific subdirectories.
+  -- Michael Gilbert <mgilbert@debian.org>  Wed, 09 Mar 2022 03:38:33 +0000
+ wine-development (6.7~repack-1) unstable; urgency=medium
+   * New upstream release 6.7, released Apr 23, 2021.
+     - Support building with openldap 2.5 (closes: #1005996).
+     - NetApi32, WLDAP32, and Kerberos libraries converted to PE.
+     - More Media Foundation work.
+     - ES6 JavaScript mode.
+     - Improved WOW64 file system redirection.
+     - More Plug & Play driver support.
+     - Keyboard raw input device.
+     - Various bug fixes.
+  -- Michael Gilbert <mgilbert@debian.org>  Tue, 08 Mar 2022 01:02:47 +0000
+ wine-development (6.6~repack-1) unstable; urgency=medium
+   * New upstream release 6.6, released Apr 9, 2021.
+     - DWrite and DnsApi libraries converted to PE.
+     - Plug & play driver support improvements.
+     - Various bug fixes.
+  -- Michael Gilbert <mgilbert@debian.org>  Mon, 07 Mar 2022 03:26:47 +0000
+ wine-development (6.5~repack-1) unstable; urgency=medium
+   * New upstream release 6.5, released Mar 26, 2021.
+     - OpenCL support updated to version 1.2.
+     - More support for IE compatibility modes in MSHTML.
+     - More windowless RichEdit work.
+     - A few more WinRT library stubs.
+     - Various bug fixes.
+   * Depend on libz-mingw-w64 >= 1.2.11+dfsg-4.
+  -- Michael Gilbert <mgilbert@debian.org>  Mon, 07 Mar 2022 02:40:34 +0000
+ wine-development (6.4~repack-1) unstable; urgency=medium
+   * New upstream release 6.4, released Mar 12, 2021.
+     - Support for the DTLS protocol.
+     - Fontset support in DirectWrite.
+     - Dialog for editing Access Control entries.
+     - Theming support for a few more common controls.
+     - Support for Korean Wansung encoding.
+     - Various bug fixes.
+  -- Michael Gilbert <mgilbert@debian.org>  Fri, 04 Mar 2022 18:46:54 +0000
+ wine-development (6.3~repack-1) unstable; urgency=medium
+   * New upstream release 6.3, released Feb 26, 2021.
+     - Better debugger support in the NT syscall interface.
+     - WineGStreamer library converted to PE.
+     - Still more WinRT support in WIDL.
+     - Optional support for build IDs.
+     - Various bug fixes.
+   * Move function_grep.pl to /usr/libexec (closes: #1006571).
+  -- Michael Gilbert <mgilbert@debian.org>  Wed, 02 Mar 2022 00:36:16 +0000
+ wine-development (6.2~repack-1) unstable; urgency=medium
+   * New upstream release 6.2, released Feb 12, 2021.
+     - Support for NTDLL debugger APIs.
+     - More WinRT support in WIDL.
+     - Various bug fixes.
+   * Build for armv6t2 on armel (new minimum ARM architecture required by wine).
  
-  -- Michael Gilbert <mgilbert@debian.org>  Sun, 27 Feb 2022 03:09:33 +0000
+  -- Michael Gilbert <mgilbert@debian.org>  Mon, 28 Feb 2022 02:08:53 +0000
  
- wine (6.0.2~repack-1) unstable; urgency=medium
+ wine-development (6.1~repack-1) unstable; urgency=medium
  
-   * New upstream release 6.0.2, released Oct 26, 2021 (closes: #995305).
-     - Compilation fixes: freetype, gcc 11 (closes: #984402).
+   * New upstream release 6.1, released Jan 29, 2021.
+     - Arabic text shaping.
+     - More WinRT support in WIDL.
+     - VKD3D version 1.2 is used for Direct3D 12.
+     - Support for Thumb-2 mode on ARM.
      - Various bug fixes.
-   * Support building with openldap 2.5 (closes: #1006016).
-   * Support building with unicode-data 14 (closes: #995580).
-   * Avoid deleting files outside of package source directory (closes: #991822).
  
-  -- Michael Gilbert <mgilbert@debian.org>  Sat, 26 Feb 2022 18:43:01 +0000
+  -- Michael Gilbert <mgilbert@debian.org>  Sun, 27 Feb 2022 06:18:32 +0000
  
  wine-development (6.0+repack-4) unstable; urgency=medium
  
index 00c7fdba21b63f55ce9718fc3b2adf175894a1bd,0000000000000000000000000000000000000000..1a7d767f847731ae497988577d409315938af820
mode 100644,000000..100644
--- /dev/null
@@@ -1,27 -1,0 +1,18 @@@
- ---
- The information above should follow the Patch Tagging Guidelines, please
- checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
- are templates for supplementary fields that you might want to add:
- Origin: <vendor|upstream|other>, <url of original patch>
- Bug: <url in upstream bugtracker>
- Bug-Debian: https://bugs.debian.org/<bugnumber>
- Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
- Forwarded: <no|not-needed|url proving that it has been forwarded>
- Reviewed-By: <name and email of someone who approved the patch>
- Last-Update: 2022-03-19
- --- wine-6.0.3~repack.orig/dlls/ntdll/unix/signal_arm.c
- +++ wine-6.0.3~repack/dlls/ntdll/unix/signal_arm.c
- @@ -613,7 +613,7 @@ __ASM_GLOBAL_FUNC( call_user_apc_dispatc
-                     "1:\tldr r0, [r10]\n\t"
-                     "sub sp, r0, #0x1a0\n\t"
-                     "mov r0, #3\n\t"
- -                   "movt r0, #32\n\t"
- +                   "orr r0, #2097152\n\t"
-                     "str r0, [sp]\n\t"         /* context.ContextFlags = CONTEXT_FULL */
-                     "mov r1, sp\n\t"
-                     "mov r0, #~1\n\t"
 +Description: Replace movt instruction with orr instruction to support armv6k build.
 +Author: Peter Michael Green <plugwash@raspbian.org>
 +
++diff --git a/dlls/ntdll/unix/signal_arm.c b/dlls/ntdll/unix/signal_arm.c
++index a1bcb0dd..206d32fe 100644
++--- a/dlls/ntdll/unix/signal_arm.c
+++++ b/dlls/ntdll/unix/signal_arm.c
++@@ -1213,8 +1213,8 @@ __ASM_GLOBAL_FUNC( __wine_syscall_dispatcher,
++                    "ldr sp, [r8, #0x38]\n\t"
++                    "add r8, r8, #0x10\n\t"
++                    "ldm r8, {r4-r12,pc}\n"
++-                   "5:\tmovw r0, #0x000d\n\t" /* STATUS_INVALID_PARAMETER */
++-                   "movt r0, #0xc000\n\t"
+++                   "5:\tmov r0, #0x000d\n\t" /* STATUS_INVALID_PARAMETER */
+++                   "orr r0, #0xc0000000\n\t"
++                    "add sp, sp, #0x10\n\t"
++                    "b 4b\n"
++                    __ASM_NAME("__wine_syscall_dispatcher_return") ":\n\t"
Simple merge
diff --cc debian/rules
index b7a0bcfc4a313d8fb3e89be5b9bed618e66d11c1,6e5a295cdd2a7aac8a153abdd76d5053bf263624..890fb4fe15e18b0e676de8ca729966b0411457a3
@@@ -69,22 -63,21 +63,21 @@@ export DEB_BUILD_MAINT_OPTIONS=hardenin
  endif
  
  # build with mingw on intel architectures
- ifeq ($(DEB_HOST_ARCH), i386)
- CONFLAGS+=--with-mingw
- endif
- ifeq ($(DEB_HOST_ARCH), amd64)
- CONFLAGS+=--with-mingw
+ ifneq (,$(filter $(DEB_HOST_ARCH),i386 amd64))
+ CONFLAGS+=--with-mingw ZLIB_PE_LIBS=z
  endif
  
- # on armel build for armv6t2
+ # build with soft float ABI and armv7-a instruction set on armel
  ifeq ($(DEB_HOST_ARCH), armel)
  CONFLAGS+=--with-float-abi=soft
- export DEB_CFLAGS_MAINT_APPEND+=-march=armv6t2 -Wno-array-parameter
+ export DEB_CFLAGS_MAINT_APPEND+=-march=armv7-a -Wno-unused-function
+ export DEB_LDFLAGS_MAINT_APPEND+=-march=armv7-a
  endif
  
- # warnings to ignore on armhf
+ # build with hard float ABI on armhf
  ifeq ($(DEB_HOST_ARCH), armhf)
- export DEB_CFLAGS_MAINT_APPEND+=-Wno-array-parameter -march=armv6k+fp
+ CONFLAGS+=--with-float-abi=hard
 -export DEB_CFLAGS_MAINT_APPEND+=-Wno-unused-function
++export DEB_CFLAGS_MAINT_APPEND+=-Wno-unused-function -march=armv6k+fp
  endif
  
  # on arm64 build using clang and ignore compiler warnings
index 38c82b6feafbd4010ac956960f3997df46f51521,a1bcb0ddd322c4af9439292ed18a22ed4f6c5e92..206d32fe057fb76ec4afb71c2d24a896a539ddb3
@@@ -1056,21 -1147,113 +1147,113 @@@ __ASM_GLOBAL_FUNC( signal_exit_thread
                     "movne sp, r3\n\t"
                     "blx r1" )
  
  /***********************************************************************
-  *           signal_exit_thread
+  *           __wine_syscall_dispatcher
   */
- void signal_exit_thread( int status, void (*func)(int) )
- {
-     call_thread_exit_func( status, func, NtCurrentTeb() );
- }
+ __ASM_GLOBAL_FUNC( __wine_syscall_dispatcher,
+                    "mrc p15, 0, r1, c13, c0, 2\n\t" /* NtCurrentTeb() */
+                    "ldr r1, [r1, #0x1d8]\n\t"       /* arm_thread_data()->syscall_frame */
+                    "add r0, r1, #0x10\n\t"
+                    "stm r0, {r4-r12,lr}\n\t"
+                    "add r2, sp, #0x10\n\t"
+                    "str r2, [r1, #0x38]\n\t"
+                    "str r3, [r1, #0x3c]\n\t"
+                    "mrs r0, CPSR\n\t"
+                    "bfi r0, lr, #5, #1\n\t"         /* set thumb bit */
+                    "str r0, [r1, #0x40]\n\t"
+                    "mov r0, #0\n\t"
+                    "str r0, [r1, #0x44]\n\t"        /* frame->restore_flags */
+ #ifndef __SOFTFP__
+                    "vmrs r0, fpscr\n\t"
+                    "str r0, [r1, #0x48]\n\t"
+                    "add r0, r1, #0x60\n\t"
+                    "vstm r0, {d0-d15}\n\t"
+ #endif
+                    "mov r6, sp\n\t"
+                    "mov sp, r1\n\t"
+                    "mov r8, r1\n\t"
+                    "ldr r5, [r1, #0x50]\n\t"        /* frame->syscall_table */
+                    "ubfx r4, ip, #12, #2\n\t"       /* syscall table number */
+                    "bfc ip, #12, #20\n\t"           /* syscall number */
+                    "add r4, r5, r4, lsl #4\n\t"
+                    "ldr r5, [r4, #8]\n\t"           /* table->ServiceLimit */
+                    "cmp ip, r5\n\t"
+                    "bcs 5f\n\t"
+                    "ldr r5, [r4, #12]\n\t"          /* table->ArgumentTable */
+                    "ldrb r5, [r5, ip]\n\t"
+                    "cmp r5, #16\n\t"
+                    "it le\n\t"
+                    "movle r5, #16\n\t"
+                    "sub r0, sp, r5\n\t"
+                    "and r0, #~7\n\t"
+                    "mov sp, r0\n"
+                    "2:\tsubs r5, r5, #4\n\t"
+                    "ldr r0, [r6, r5]\n\t"
+                    "str r0, [sp, r5]\n\t"
+                    "bgt 2b\n\t"
+                    "pop {r0-r3}\n\t"                /* first 4 args are in registers */
+                    "ldr r5, [r4]\n\t"               /* table->ServiceTable */
+                    "ldr ip, [r5, ip, lsl #2]\n\t"
+                    "blx ip\n"
+                    "4:\tldr ip, [r8, #0x44]\n\t"    /* frame->restore_flags */
+ #ifndef __SOFTFP__
+                    "tst ip, #4\n\t"                 /* CONTEXT_FLOATING_POINT */
+                    "beq 3f\n\t"
+                    "ldr r4, [r8, #0x48]\n\t"
+                    "vmsr fpscr, r4\n\t"
+                    "add r4, r8, #0x60\n\t"
+                    "vldm r4, {d0-d15}\n"
+                    "3:\n\t"
+ #endif
+                    "tst ip, #2\n\t"                 /* CONTEXT_INTEGER */
+                    "it ne\n\t"
+                    "ldmne r8, {r0-r3}\n\t"
+                    "ldr lr, [r8, #0x3c]\n\t"
+                    "ldr sp, [r8, #0x38]\n\t"
+                    "add r8, r8, #0x10\n\t"
+                    "ldm r8, {r4-r12,pc}\n"
 -                   "5:\tmovw r0, #0x000d\n\t" /* STATUS_INVALID_PARAMETER */
 -                   "movt r0, #0xc000\n\t"
++                   "5:\tmov r0, #0x000d\n\t" /* STATUS_INVALID_PARAMETER */
++                   "orr r0, #0xc0000000\n\t"
+                    "add sp, sp, #0x10\n\t"
+                    "b 4b\n"
+                    __ASM_NAME("__wine_syscall_dispatcher_return") ":\n\t"
+                    "mov r8, r0\n\t"
+                    "mov r0, r1\n\t"
+                    "b 4b" )
  
  
- /**********************************************************************
-  *           NtCurrentTeb   (NTDLL.@)
+ /***********************************************************************
+  *           __wine_setjmpex
   */
- TEB * WINAPI NtCurrentTeb(void)
- {
-     return pthread_getspecific( teb_key );
- }
+ __ASM_GLOBAL_FUNC( __wine_setjmpex,
+                    "stm r0, {r1,r4-r11}\n"         /* jmp_buf->Frame,R4..R11 */
+                    "str sp, [r0, #0x24]\n\t"       /* jmp_buf->Sp */
+                    "str lr, [r0, #0x28]\n\t"       /* jmp_buf->Pc */
+ #ifndef __SOFTFP__
+                    "vmrs r2, fpscr\n\t"
+                    "str r2, [r0, #0x2c]\n\t"       /* jmp_buf->Fpscr */
+                    "add r0, r0, #0x30\n\t"
+                    "vstm r0, {d8-d15}\n\t"         /* jmp_buf->D[0..7] */
+ #endif
+                    "mov r0, #0\n\t"
+                    "bx lr" )
+ /***********************************************************************
+  *           __wine_longjmp
+  */
+ __ASM_GLOBAL_FUNC( __wine_longjmp,
+                    "ldm r0, {r3-r11}\n\t"          /* jmp_buf->Frame,R4..R11 */
+                    "ldr sp, [r0, #0x24]\n\t"       /* jmp_buf->Sp */
+                    "ldr r2, [r0, #0x28]\n\t"       /* jmp_buf->Pc */
+ #ifndef __SOFTFP__
+                    "ldr r3, [r0, #0x2c]\n\t"       /* jmp_buf->Fpscr */
+                    "vmsr fpscr, r3\n\t"
+                    "add r0, r0, #0x30\n\t"
+                    "vldm r0, {d8-d15}\n\t"         /* jmp_buf->D[0..7] */
+ #endif
+                    "mov r0, r1\n\t"                /* retval */
+                    "bx r2" )
  
  #endif  /* __arm__ */