You've already forked wine-staging
mirror of
https://gitlab.winehq.org/wine/wine-staging.git
synced 2025-04-13 14:42:51 -07:00
Added patch to implement preloader for Mac OS.
This commit is contained in:
@ -0,0 +1,49 @@
|
||||
From 3174d46a02a1112d2f31a16ad895731fbbaddf21 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
|
||||
Date: Mon, 12 Jun 2017 00:18:37 +0200
|
||||
Subject: libs/wine: Do not restrict base address of main thread on 64 bit mac
|
||||
os.
|
||||
|
||||
---
|
||||
libs/wine/loader.c | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/libs/wine/loader.c b/libs/wine/loader.c
|
||||
index e362a1d1939..5f37dc978ba 100644
|
||||
--- a/libs/wine/loader.c
|
||||
+++ b/libs/wine/loader.c
|
||||
@@ -700,6 +700,7 @@ struct apple_stack_info
|
||||
* Callback for wine_mmap_enum_reserved_areas to allocate space for
|
||||
* the secondary thread's stack.
|
||||
*/
|
||||
+#ifndef _WIN64
|
||||
static int apple_alloc_thread_stack( void *base, size_t size, void *arg )
|
||||
{
|
||||
struct apple_stack_info *info = arg;
|
||||
@@ -716,6 +717,7 @@ static int apple_alloc_thread_stack( void *base, size_t size, void *arg )
|
||||
info->desired_size, PROT_READ|PROT_WRITE, MAP_FIXED );
|
||||
return (info->stack != (void *)-1);
|
||||
}
|
||||
+#endif
|
||||
|
||||
/***********************************************************************
|
||||
* apple_create_wine_thread
|
||||
@@ -733,6 +735,7 @@ static void apple_create_wine_thread( void *init_func )
|
||||
|
||||
if (!pthread_attr_init( &attr ))
|
||||
{
|
||||
+#ifndef _WIN64
|
||||
struct apple_stack_info info;
|
||||
|
||||
/* Try to put the new thread's stack in the reserved area. If this
|
||||
@@ -744,6 +747,7 @@ static void apple_create_wine_thread( void *init_func )
|
||||
wine_mmap_remove_reserved_area( info.stack, info.desired_size, 0 );
|
||||
pthread_attr_setstackaddr( &attr, (char*)info.stack + info.desired_size );
|
||||
}
|
||||
+#endif
|
||||
|
||||
if (!pthread_attr_setdetachstate( &attr, PTHREAD_CREATE_JOINABLE ) &&
|
||||
!pthread_create( &thread, &attr, init_func, NULL ))
|
||||
--
|
||||
2.13.1
|
||||
|
File diff suppressed because it is too large
Load Diff
3
patches/loader-OSX_Preloader/definition
Normal file
3
patches/loader-OSX_Preloader/definition
Normal file
@ -0,0 +1,3 @@
|
||||
Fixes: [33159] Implement preloader for Mac OS
|
||||
Depends: Staging
|
||||
Depends: configure-Absolute_RPATH
|
Reference in New Issue
Block a user