From: Jeremy Hylton Date: Thu, 31 Aug 2000 18:11:07 +0000 (+0000) Subject: This module has a poor name, since it can be used under FreeBSD and X-Git-Tag: v2.0b1~125 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a3895c0d291c795ed9e36fd86118d6679f1d917b;p=python This module has a poor name, since it can be used under FreeBSD and Linux. Perhaps winaudio would be better, as it would offend both parties equally. tg@freebsd.org: allow this module to compile under FreeBSD (he suggests voxwareaudio) --- diff --git a/Modules/linuxaudiodev.c b/Modules/linuxaudiodev.c index 5bcbaf2854..72ba567061 100644 --- a/Modules/linuxaudiodev.c +++ b/Modules/linuxaudiodev.c @@ -27,10 +27,20 @@ #endif #include +#if defined(linux) #include typedef unsigned long uint32_t; +#elif defined(__FreeBSD__) +#include + +#ifndef SNDCTL_DSP_CHANNELS +#define SNDCTL_DSP_CHANNELS SOUND_PCM_WRITE_CHANNELS +#endif + +#endif + typedef struct { PyObject_HEAD; int x_fd; /* The open file */