freebsd-ports/games/kxl/files/patch-aa
Yukihiro Nakai 82b3a1f5ea Initial import.
a visual, sound game library.
2001-06-16 10:33:59 +00:00

65 lines
1.4 KiB
Plaintext

--- src/KXLsound.c.orig Thu May 17 18:08:13 2001
+++ src/KXLsound.c Sat Jun 16 19:31:43 2001
@@ -3,7 +3,6 @@
#include <fcntl.h>
#include <sys/time.h>
#include <sys/ioctl.h>
-#include <linux/soundcard.h>
#include "KXL.h"
#define MIN(a, b) ((a<b) ? a : b)
@@ -45,12 +44,14 @@
******************************************/
void KXL_SoundServer(void)
{
+#ifndef __FreeBSD__
Uint16 i;
KXL_SoundControl Command;
fd_set sound_fdset;
if (KXL_SoundOk == False)
return;
+
close(KXL_SoundData.Pipe[1]);
for (i = 0; i < MAX_SOUNDS_PLAYING; i ++)
@@ -166,6 +167,7 @@
}
}
}
+#endif
}
/******************************************
@@ -245,6 +247,7 @@
******************************************/
void KXL_InitSound(Uint8 *path, Uint8 **fname)
{
+#ifndef __FreeBSD__
KXL_SoundOk = False;
KXL_LoadSoundData(path, fname);
if (pipe(KXL_SoundData.Pipe) < 0) {
@@ -264,6 +267,7 @@
}
if (KXL_SoundOk == False)
fprintf(stderr, "KXL_InitSoundServer : no sounds\n");
+#endif
}
/******************************************
@@ -271,6 +275,7 @@
******************************************/
void KXL_EndSound(void)
{
+#ifndef __FreeBSD__
if (KXL_SoundOk == False)
return;
KXL_PlaySound(0, KXL_SOUND_STOP_ALL);
@@ -278,5 +283,6 @@
KXL_Free(KXL_wavelist[-- KXL_SoundData.ListCnt]);
KXL_Free(KXL_wavelist);
kill(KXL_SoundData.ID, SIGTERM);
+#endif
}