DEADSOFTWARE

osx: fix library linking (sdl_mixer)
[d2df-sdl.git] / src / lib / sdl2 / SDL2_mixer.pas
index e7f8131ea8039e5f5afa9d53e2a97fdf27f97f44..4a3890c1e424b446bba1d13b97763ec94f8a701f 100644 (file)
@@ -1,3 +1,4 @@
+{$MODE DELPHI}
 unit SDL2_mixer;
 
 {*
@@ -25,7 +26,7 @@ unit SDL2_mixer;
    ----------
 
    v.1.72-stable; 29.09.2013: fixed bug with procedures without parameters
-                              (they must have brackets)  
+                              (they must have brackets)
    v.1.70-stable; 16.09.2013: Initial Commit
 
 *}
@@ -44,6 +45,7 @@ const
 
   {$IFDEF UNIX}
     {$IFDEF DARWIN}
+      {$LINKLIB libSDL2_mixer}
       MIX_LibName = 'libSDL2_mixer.dylib';
     {$ELSE}
       {$IFDEF FPC}
@@ -257,7 +259,7 @@ function Mix_GetMusicHookData: Pointer cdecl; external MIX_LibName {$IFDEF DELPH
    *  before calling your callback.
    *}
 type
-  TMix_Channel_Finished = procedure(channel: Integer);
+  TMix_Channel_Finished = procedure(channel: Integer); cdecl;
 procedure Mix_ChannelFinished(channel_finished: TMix_Channel_Finished) cdecl; external MIX_LibName {$IFDEF DELPHI} {$IFDEF MACOS} name '_MIX_ChannelFinished' {$ENDIF} {$ENDIF};
 
   {* Special Effects API by ryan c. gordon. (icculus@icculus.org) *}