From: Alistair Leslie-Hughes Subject: dpvoice: new dll Message-Id: Date: Mon, 14 Apr 2014 15:05:51 +1000 Hi, Changelog: dpvoice: new dll Best Regards Alistair Leslie-Hughes From 7aec0aa61553ac21e7320021759436e649509224 Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Mon, 14 Apr 2014 11:27:09 +1000 Subject: [PATCH] New dll dpvoice To: wine-patches --- configure | 2 ++ configure.ac | 1 + dlls/dpvoice/Makefile.in | 6 ++++ dlls/dpvoice/dpvoice.spec | 6 ++++ dlls/dpvoice/main.c | 79 +++++++++++++++++++++++++++++++++++++++++++++++ dlls/dpvoice/version.rc | 26 ++++++++++++++++ 6 files changed, 120 insertions(+) create mode 100644 dlls/dpvoice/Makefile.in create mode 100644 dlls/dpvoice/dpvoice.spec create mode 100644 dlls/dpvoice/main.c create mode 100644 dlls/dpvoice/version.rc diff --git a/configure b/configure index fae5c0a..14b8ee5 100755 --- a/configure +++ b/configure @@ -1015,6 +1015,7 @@ enable_dpnaddr enable_dpnet enable_dpnhpast enable_dpnlobby +enable_dpvoice enable_dpwsockx enable_drmclien enable_dsound @@ -16860,6 +16861,7 @@ wine_fn_config_dll dpnet enable_dpnet clean,implib wine_fn_config_test dlls/dpnet/tests dpnet_test wine_fn_config_dll dpnhpast enable_dpnhpast wine_fn_config_dll dpnlobby enable_dpnlobby +wine_fn_config_dll dpvoice enable_dpvoice wine_fn_config_dll dpwsockx enable_dpwsockx wine_fn_config_dll drmclien enable_drmclien wine_fn_config_dll dsound enable_dsound clean,implib diff --git a/configure.ac b/configure.ac index 7e463b9..f6e9fa6 100644 --- a/configure.ac +++ b/configure.ac @@ -2838,6 +2838,7 @@ WINE_CONFIG_DLL(dpnet,,[clean,implib]) WINE_CONFIG_TEST(dlls/dpnet/tests) WINE_CONFIG_DLL(dpnhpast) WINE_CONFIG_DLL(dpnlobby) +WINE_CONFIG_DLL(dpvoice) WINE_CONFIG_DLL(dpwsockx) WINE_CONFIG_DLL(drmclien) WINE_CONFIG_DLL(dsound,,[clean,implib]) diff --git a/dlls/dpvoice/Makefile.in b/dlls/dpvoice/Makefile.in new file mode 100644 index 0000000..4a9f902 --- /dev/null +++ b/dlls/dpvoice/Makefile.in @@ -0,0 +1,6 @@ +MODULE = dpvoice.dll + +C_SRCS = \ + main.c + +RC_SRCS = version.rc diff --git a/dlls/dpvoice/dpvoice.spec b/dlls/dpvoice/dpvoice.spec new file mode 100644 index 0000000..5169b47 --- /dev/null +++ b/dlls/dpvoice/dpvoice.spec @@ -0,0 +1,6 @@ +1 stdcall DirectPlayVoiceCreate(ptr ptr) + +@ stdcall -private DllCanUnloadNow() +@ stdcall -private DllGetClassObject(ptr ptr ptr) +@ stdcall -private DllRegisterServer() +@ stdcall -private DllUnregisterServer() diff --git a/dlls/dpvoice/main.c b/dlls/dpvoice/main.c new file mode 100644 index 0000000..00b70d9 --- /dev/null +++ b/dlls/dpvoice/main.c @@ -0,0 +1,79 @@ +/* + * DirectPlay Voice + * + * Copyright (C) 2014 Alistair Leslie-Hughes + * + * This program 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 program 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 program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#include "config.h" +#include + +#include "windef.h" +#include "winbase.h" +#include "objbase.h" +#include "rpcproxy.h" +#include "wine/debug.h" + +WINE_DEFAULT_DEBUG_CHANNEL(dpvoice); + +static HINSTANCE DPVOICE_hInstance; + +HRESULT WINAPI DirectPlayVoiceCreate(LPCGUID pIID, PVOID *ppvInterface) +{ + FIXME("(%p, %p) stub\n", pIID, ppvInterface); + return E_NOTIMPL; +} + +BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) +{ + TRACE("(0x%p, %d, %p)\n", hinstDLL, fdwReason, lpvReserved); + + DPVOICE_hInstance = hinstDLL; + + switch (fdwReason) + { + case DLL_WINE_PREATTACH: + return FALSE; /* prefer native version */ + case DLL_PROCESS_ATTACH: + DisableThreadLibraryCalls(hinstDLL); + break; + default: + break; + } + + return TRUE; +} + +HRESULT WINAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID *ppv) +{ + FIXME(":stub\n"); + return E_FAIL; +} + +HRESULT WINAPI DllCanUnloadNow(void) +{ + return S_FALSE; +} + +HRESULT WINAPI DllRegisterServer(void) +{ + return __wine_register_resources( DPVOICE_hInstance ); +} + +HRESULT WINAPI DllUnregisterServer(void) +{ + return __wine_unregister_resources( DPVOICE_hInstance ); +} diff --git a/dlls/dpvoice/version.rc b/dlls/dpvoice/version.rc new file mode 100644 index 0000000..993b59c --- /dev/null +++ b/dlls/dpvoice/version.rc @@ -0,0 +1,26 @@ +/* + * Copyright (C) 2014 Alistair Leslie-Hughes + * + * 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 + */ + +#define WINE_FILEDESCRIPTION_STR "Wine DirectPlay Voice" +#define WINE_FILENAME_STR "dpvoice.dll" +#define WINE_FILEVERSION 5,3,2600,5512 +#define WINE_FILEVERSION_STR "5.3.2600.5512" +#define WINE_PRODUCTVERSION 5,3,2600,5512 +#define WINE_PRODUCTVERSION_STR "5.3" + +#include "wine/wine_common_ver.rc" -- 1.8.3.2