Skip to content

Commit

Permalink
Here be dragons
Browse files Browse the repository at this point in the history
  • Loading branch information
XspeedPL committed Dec 4, 2023
1 parent 7ab8fa3 commit 0f810fb
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 3 deletions.
6 changes: 3 additions & 3 deletions VisualC/SDL/SDL.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ResourceCompile>
<Link>
<AdditionalDependencies>setupapi.lib;winmm.lib;imm32.lib;version.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalDependencies>setupapi.lib;winmm.lib;imm32.lib;version.lib;$(SolutionDir)..\lib\Starglue.lib;%(AdditionalDependencies)</AdditionalDependencies>
<IgnoreAllDefaultLibraries>true</IgnoreAllDefaultLibraries>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
Expand Down Expand Up @@ -206,7 +206,7 @@
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ResourceCompile>
<Link>
<AdditionalDependencies>setupapi.lib;winmm.lib;imm32.lib;version.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalDependencies>setupapi.lib;winmm.lib;imm32.lib;version.lib;$(SolutionDir)..\lib\Starglue.lib;%(AdditionalDependencies)</AdditionalDependencies>
<IgnoreAllDefaultLibraries>true</IgnoreAllDefaultLibraries>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
Expand Down Expand Up @@ -629,4 +629,4 @@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
</Project>
14 changes: 14 additions & 0 deletions include/Starglue.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#ifndef Starglue
#define Starglue

#ifdef __cplusplus
extern "C" {
#endif

__declspec(dllexport) int __cdecl Starglue_Init();

#ifdef __cplusplus
}
#endif

#endif
Binary file added lib/Starglue.lib
Binary file not shown.
2 changes: 2 additions & 0 deletions src/SDL.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
misrepresented as being the original software.
3. This notice may not be removed or altered from any source distribution.
*/
#include "./Starglue.h"
#include "./SDL_internal.h"

#if defined(__WIN32__) || defined(__GDK__)
Expand Down Expand Up @@ -372,6 +373,7 @@ int SDL_InitSubSystem(Uint32 flags)

int SDL_Init(Uint32 flags)
{
Starglue_Init();
return SDL_InitSubSystem(flags);
}

Expand Down

0 comments on commit 0f810fb

Please sign in to comment.