From c601bcd830d8b6847b413206f63648ac4f9f2f01 Mon Sep 17 00:00:00 2001 From: Paul Brossier Date: Sat, 23 Apr 2016 14:40:06 +0200 Subject: [PATCH] src/utils/windll.c: add dll main entry point --- src/utils/windll.c | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 src/utils/windll.c diff --git a/src/utils/windll.c b/src/utils/windll.c new file mode 100644 index 00000000..fea5c5ad --- /dev/null +++ b/src/utils/windll.c @@ -0,0 +1,53 @@ +/* + Copyright (C) 2016 Paul Brossier + + This file is part of aubio. + + aubio is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + aubio 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 General Public License for more details. + + You should have received a copy of the GNU General Public License + along with aubio. If not, see . + +*/ + +/** @file + + Windows dll entry point. + +*/ + +#ifdef HAVE_WIN_HACKS + +// latest version +#include +// for earlier versions, include WinSDKVer.h and set _WIN32_WINNT macro + +#define WIN32_LEAN_AND_MEAN +#include + +#include "aubio.h" + +BOOL APIENTRY DllMain( HMODULE hModule, + DWORD ul_reason_for_call, + LPVOID lpReserved ) +{ + switch (ul_reason_for_call) + { + case DLL_PROCESS_ATTACH: + case DLL_THREAD_ATTACH: + case DLL_THREAD_DETACH: + case DLL_PROCESS_DETACH: + break; + } + return TRUE; +} + +#endif -- 2.11.0