diff options
-rw-r--r-- | common/JackGlobals.cpp | 8 | ||||
-rw-r--r-- | common/JackGlobals.h | 15 | ||||
-rw-r--r-- | windows/libjackmp.dsp | 2 | ||||
-rw-r--r-- | windows/libjackservermp.dsp | 3 |
4 files changed, 20 insertions, 8 deletions
diff --git a/common/JackGlobals.cpp b/common/JackGlobals.cpp index 3afacc53..fa792fd6 100644 --- a/common/JackGlobals.cpp +++ b/common/JackGlobals.cpp @@ -29,14 +29,14 @@ namespace Jack static bool gKeyRealtimeInitialized = false; jack_tls_key gRealTime; -void jack_realtime_init() +void jack_init() { if (!gKeyRealtimeInitialized) { gKeyRealtimeInitialized = jack_tls_allocate_key(&gRealTime); } } -void jack_realtime_uninit() +void jack_uninit() { if (gKeyRealtimeInitialized) { jack_tls_free_key(gRealTime); @@ -52,10 +52,10 @@ BOOL WINAPI DllEntryPoint(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserv { switch (fdwReason) { case DLL_PROCESS_ATTACH: - jack_realtime_init(); + jack_init(); break; case DLL_PROCESS_DETACH: - jack_realtime_uninit(); + jack_uninit(); break; } return TRUE; diff --git a/common/JackGlobals.h b/common/JackGlobals.h index 10b435a0..ba26bc6b 100644 --- a/common/JackGlobals.h +++ b/common/JackGlobals.h @@ -22,6 +22,8 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. #include "JackError.h" #include "JackThread.h" +#include "JackThread.h" +#include "JackExports.h" namespace Jack { @@ -286,9 +288,18 @@ extern "C" #endif extern jack_tls_key gRealTime; + +#ifdef WIN32 + +EXPORT void jack_init(); +EXPORT void jack_uninit(); + +#else -void __attribute__ ((constructor)) jack_realtime_init(); -void __attribute__ ((destructor)) jack_realtime_uninit(); +void __attribute__ ((constructor)) jack_init(); +void __attribute__ ((destructor)) jack_uninit(); + +#endif #ifdef __cplusplus } diff --git a/windows/libjackmp.dsp b/windows/libjackmp.dsp index a4d96e16..3b12d51a 100644 --- a/windows/libjackmp.dsp +++ b/windows/libjackmp.dsp @@ -52,7 +52,7 @@ BSC32=bscmake.exe # ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
+# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /entry:"DllEntryPoint" /dll /machine:I386
!ELSEIF "$(CFG)" == "libjackmp - Win32 Debug"
diff --git a/windows/libjackservermp.dsp b/windows/libjackservermp.dsp index 771beaf2..0106b7b6 100644 --- a/windows/libjackservermp.dsp +++ b/windows/libjackservermp.dsp @@ -40,6 +40,7 @@ RSC=rc.exe # PROP Use_Debug_Libraries 0
# PROP Output_Dir "Release"
# PROP Intermediate_Dir "Release"
+# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBJACKDMP_EXPORTS" /YX /FD /c
# ADD CPP /nologo /MD /W3 /GR /GX /O2 /I "." /I "../common" /I "../common/jack" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LIBJACKDMP_EXPORTS" /D "__STDC__" /D "REGEX_MALLOC" /D "STDC_HEADERS" /D "__SMP__" /FR /YX /FD /c
@@ -52,7 +53,7 @@ BSC32=bscmake.exe # ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
+# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /entry:"DllEntryPoint" /dll /machine:I386
!ELSEIF "$(CFG)" == "libjackservermp - Win32 Debug"
|