From 0892d6d89e4d4127e807133934a339f677eb45e9 Mon Sep 17 00:00:00 2001 From: Sebastian Lackner Date: Sun, 6 Aug 2017 02:55:07 +0200 Subject: [PATCH] Added patch to prefer native version of packager.dll. --- .../0001-packager-Prefer-native-version.patch | 25 +++++++++++++++++++ patches/packager-DllMain/definition | 1 + patches/patchinstall.sh | 19 ++++++++++++++ 3 files changed, 45 insertions(+) create mode 100644 patches/packager-DllMain/0001-packager-Prefer-native-version.patch create mode 100644 patches/packager-DllMain/definition diff --git a/patches/packager-DllMain/0001-packager-Prefer-native-version.patch b/patches/packager-DllMain/0001-packager-Prefer-native-version.patch new file mode 100644 index 00000000..1220e7c6 --- /dev/null +++ b/patches/packager-DllMain/0001-packager-Prefer-native-version.patch @@ -0,0 +1,25 @@ +From 35edeed55faa516480528c5c5e64ceedd45e29fb Mon Sep 17 00:00:00 2001 +From: Sebastian Lackner +Date: Sun, 6 Aug 2017 02:50:23 +0200 +Subject: packager: Prefer native version. + +--- + dlls/packager/packager_main.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/dlls/packager/packager_main.c b/dlls/packager/packager_main.c +index c1d194e3684..af1ee224ca6 100644 +--- a/dlls/packager/packager_main.c ++++ b/dlls/packager/packager_main.c +@@ -675,6 +675,8 @@ BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, void *reserved) + TRACE("(%p, %u, %p)\n", instance, reason, reserved); + + switch(reason){ ++ case DLL_WINE_PREATTACH: ++ return FALSE; /* prefer native version */ + case DLL_PROCESS_ATTACH: + g_instance = instance; + DisableThreadLibraryCalls(instance); +-- +2.13.1 + diff --git a/patches/packager-DllMain/definition b/patches/packager-DllMain/definition new file mode 100644 index 00000000..83e85b8b --- /dev/null +++ b/patches/packager-DllMain/definition @@ -0,0 +1 @@ +Fixes: [43472] Prefer native version of packager.dll diff --git a/patches/patchinstall.sh b/patches/patchinstall.sh index 08f40df3..c61d0735 100755 --- a/patches/patchinstall.sh +++ b/patches/patchinstall.sh @@ -316,6 +316,7 @@ patch_enable_all () enable_oleaut32_x86_64_Marshaller="$1" enable_opengl32_Revert_Disable_Ext="$1" enable_opengl32_glDebugMessageCallback="$1" + enable_packager_DllMain="$1" enable_quartz_MediaSeeking_Positions="$1" enable_quartz_Silence_FIXMEs="$1" enable_riched20_Class_Tests="$1" @@ -1215,6 +1216,9 @@ patch_enable () opengl32-glDebugMessageCallback) enable_opengl32_glDebugMessageCallback="$2" ;; + packager-DllMain) + enable_packager_DllMain="$2" + ;; quartz-MediaSeeking_Positions) enable_quartz_MediaSeeking_Positions="$2" ;; @@ -7197,6 +7201,21 @@ if test "$enable_opengl32_glDebugMessageCallback" -eq 1; then ) >> "$patchlist" fi +# Patchset packager-DllMain +# | +# | This patchset fixes the following Wine bugs: +# | * [#43472] Prefer native version of packager.dll +# | +# | Modified files: +# | * dlls/packager/packager_main.c +# | +if test "$enable_packager_DllMain" -eq 1; then + patch_apply packager-DllMain/0001-packager-Prefer-native-version.patch + ( + printf '%s\n' '+ { "Sebastian Lackner", "packager: Prefer native version.", 1 },'; + ) >> "$patchlist" +fi + # Patchset quartz-MediaSeeking_Positions # | # | Modified files: