Module: wine
Branch: master
Commit: 68bbf86483d88df3442bfb3332b71438f6a508c4
URL: https://source.winehq.org/git/wine.git/?a=commit;h=68bbf86483d88df3442bfb33…
Author: Piotr Caban <piotr(a)codeweavers.com>
Date: Tue Apr 21 13:12:04 2020 +0200
vcruntime140_1: Add __CxxFrameHandler4 stub.
Signed-off-by: Piotr Caban <piotr(a)codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard(a)winehq.org>
---
dlls/vcruntime140_1/Makefile.in | 5 +++++
dlls/vcruntime140_1/except_x86_64.c | 34 +++++++++++++++++++++++++++++++++
dlls/vcruntime140_1/vcruntime140_1.spec | 2 +-
3 files changed, 40 insertions(+), 1 deletion(-)
diff --git a/dlls/vcruntime140_1/Makefile.in b/dlls/vcruntime140_1/Makefile.in
index b5e20fe92f..ab17b330be 100644
--- a/dlls/vcruntime140_1/Makefile.in
+++ b/dlls/vcruntime140_1/Makefile.in
@@ -1 +1,6 @@
MODULE = vcruntime140_1.dll
+
+EXTRADLLFLAGS = -mno-cygwin
+
+C_SRCS = \
+ except_x86_64.c
diff --git a/dlls/vcruntime140_1/except_x86_64.c b/dlls/vcruntime140_1/except_x86_64.c
new file mode 100644
index 0000000000..ff582e44da
--- /dev/null
+++ b/dlls/vcruntime140_1/except_x86_64.c
@@ -0,0 +1,34 @@
+/*
+ * C++ exception handling (ver. 4)
+ *
+ * Copyright 2020 Piotr Caban
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+#ifdef __x86_64__
+
+#include "wine/debug.h"
+
+WINE_DEFAULT_DEBUG_CHANNEL(seh);
+
+EXCEPTION_DISPOSITION __cdecl __CxxFrameHandler4(EXCEPTION_RECORD *rec,
+ ULONG64 frame, CONTEXT *context, DISPATCHER_CONTEXT *dispatch)
+{
+ FIXME("%p %lx %p %p\n", rec, frame, context, dispatch);
+ return ExceptionContinueSearch;
+}
+
+#endif
diff --git a/dlls/vcruntime140_1/vcruntime140_1.spec b/dlls/vcruntime140_1/vcruntime140_1.spec
index 5119df9b99..f41c7d2a12 100644
--- a/dlls/vcruntime140_1/vcruntime140_1.spec
+++ b/dlls/vcruntime140_1/vcruntime140_1.spec
@@ -1,3 +1,3 @@
-@ stub -arch=x86_64 __CxxFrameHandler4
+@ cdecl -arch=x86_64 __CxxFrameHandler4(ptr long ptr ptr)
@ stub -arch=x86_64 __NLG_Dispatch2
@ stub -arch=x86_64 __NLG_Return2
Module: wine
Branch: master
Commit: f6a363bc4108f3d45b7a5bac706d10579f4d2772
URL: https://source.winehq.org/git/wine.git/?a=commit;h=f6a363bc4108f3d45b7a5bac…
Author: Alexandre Julliard <julliard(a)winehq.org>
Date: Tue Apr 21 11:28:03 2020 +0200
winecrt0: Get rid of constructor support.
Signed-off-by: Alexandre Julliard <julliard(a)winehq.org>
---
dlls/winecrt0/Makefile.in | 2 --
dlls/winecrt0/crt0_private.h | 41 ------------------------------------
dlls/winecrt0/dll_entry.c | 49 --------------------------------------------
dlls/winecrt0/init.c | 46 -----------------------------------------
4 files changed, 138 deletions(-)
diff --git a/dlls/winecrt0/Makefile.in b/dlls/winecrt0/Makefile.in
index 909959dcb6..bcbd4e3b55 100644
--- a/dlls/winecrt0/Makefile.in
+++ b/dlls/winecrt0/Makefile.in
@@ -4,7 +4,6 @@ C_SRCS = \
crt_dllmain.c \
debug.c \
delay_load.c \
- dll_entry.c \
dll_main.c \
exception.c \
exe16_entry.c \
@@ -12,6 +11,5 @@ C_SRCS = \
exe_main.c \
exe_wentry.c \
exe_wmain.c \
- init.c \
register.c \
stub.c
diff --git a/dlls/winecrt0/crt0_private.h b/dlls/winecrt0/crt0_private.h
deleted file mode 100644
index b2c902e6bb..0000000000
--- a/dlls/winecrt0/crt0_private.h
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * crt0 library private definitions
- *
- * Copyright 2005 Alexandre Julliard
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
- */
-
-#ifndef __WINE_CRT0_PRIVATE_H__
-#define __WINE_CRT0_PRIVATE_H__
-
-#if defined(__APPLE__) || defined(__ANDROID__)
-static inline void _init(int argc, char **argv, char **envp ) { /* nothing */ }
-static inline void _fini(void) { /* nothing */ }
-#else
-extern void _init(int argc, char **argv, char **envp ) DECLSPEC_HIDDEN;
-extern void _fini(void) DECLSPEC_HIDDEN;
-#endif
-
-enum init_state
-{
- NO_INIT_DONE, /* no initialization done yet */
- DLL_REGISTERED, /* the dll has been registered */
- CONSTRUCTORS_DONE /* the constructors have been run (implies dll registered too) */
-};
-
-extern enum init_state __wine_spec_init_state DECLSPEC_HIDDEN;
-
-#endif /* __WINE_CRT0_PRIVATE_H__ */
diff --git a/dlls/winecrt0/dll_entry.c b/dlls/winecrt0/dll_entry.c
deleted file mode 100644
index 92bd069529..0000000000
--- a/dlls/winecrt0/dll_entry.c
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Default entry point for a dll
- *
- * Copyright 2005 Alexandre Julliard
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
- */
-
-#if 0
-#pragma makedep unix
-#endif
-
-#include <stdarg.h>
-#include "windef.h"
-#include "winbase.h"
-#include "wine/library.h"
-#include "crt0_private.h"
-
-extern BOOL WINAPI DECLSPEC_HIDDEN DllMain( HINSTANCE inst, DWORD reason, LPVOID reserved );
-
-BOOL WINAPI DECLSPEC_HIDDEN __wine_spec_dll_entry( HINSTANCE inst, DWORD reason, LPVOID reserved )
-{
- static BOOL call_fini;
- BOOL ret;
-
- if (reason == DLL_PROCESS_ATTACH && __wine_spec_init_state != CONSTRUCTORS_DONE)
- {
- call_fini = TRUE;
- _init( 0, NULL, NULL );
- }
-
- ret = DllMain( inst, reason, reserved );
-
- if (reason == DLL_PROCESS_DETACH && call_fini) _fini();
-
- return ret;
-}
diff --git a/dlls/winecrt0/init.c b/dlls/winecrt0/init.c
deleted file mode 100644
index 2ffe8e564c..0000000000
--- a/dlls/winecrt0/init.c
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Initialization code for spec files
- *
- * Copyright 2005 Alexandre Julliard
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
- */
-
-#if 0
-#pragma makedep unix
-#endif
-
-#include <stdarg.h>
-#include "windef.h"
-#include "winbase.h"
-#include "wine/library.h"
-#include "crt0_private.h"
-
-enum init_state __wine_spec_init_state = NO_INIT_DONE;
-
-extern const IMAGE_NT_HEADERS __wine_spec_nt_header;
-extern const char __wine_spec_file_name[];
-
-void DECLSPEC_HIDDEN __wine_spec_init(void)
-{
- __wine_spec_init_state = DLL_REGISTERED;
- __wine_dll_register( &__wine_spec_nt_header, __wine_spec_file_name );
-}
-
-void DECLSPEC_HIDDEN __wine_spec_init_ctor(void)
-{
- if (__wine_spec_init_state == NO_INIT_DONE) __wine_spec_init();
- __wine_spec_init_state = CONSTRUCTORS_DONE;
-}