This patch is needed to make Python understand it can build the OSS plugin. Some OSS ioctls are not supported on Solaris, so they are commented out. --- Python-3.3.0/setup.py-orig 2012-12-05 22:11:02.287046375 -0600 +++ Python-3.3.0/setup.py 2012-12-05 22:11:14.628661319 -0600 @@ -1557,7 +1557,7 @@ class PyBuildExt(build_ext): # End multiprocessing # Platform-specific libraries - if host_platform.startswith(('linux', 'freebsd', 'gnukfreebsd')): + if host_platform.startswith(('sunos5', 'linux', 'freebsd', 'gnukfreebsd')): exts.append( Extension('ossaudiodev', ['ossaudiodev.c']) ) else: missing.append('ossaudiodev') --- Python-3.3.0/Modules/ossaudiodev.c-orig 2012-12-05 22:27:48.103171342 -0600 +++ Python-3.3.0/Modules/ossaudiodev.c 2012-12-05 22:35:31.565854430 -0600 @@ -1215,6 +1215,7 @@ PyInit_ossaudiodev(void) _EXPORT_INT(m, SOUND_MIXER_MONITOR); #endif +#ifndef __sun /* Expose all the ioctl numbers for masochists who like to do this stuff directly. */ _EXPORT_INT(m, SNDCTL_COPR_HALT); @@ -1227,6 +1228,7 @@ PyInit_ossaudiodev(void) _EXPORT_INT(m, SNDCTL_COPR_SENDMSG); _EXPORT_INT(m, SNDCTL_COPR_WCODE); _EXPORT_INT(m, SNDCTL_COPR_WDATA); +#endif #ifdef SNDCTL_DSP_BIND_CHANNEL _EXPORT_INT(m, SNDCTL_DSP_BIND_CHANNEL); #endif @@ -1248,8 +1250,12 @@ PyInit_ossaudiodev(void) _EXPORT_INT(m, SNDCTL_DSP_GETSPDIF); #endif _EXPORT_INT(m, SNDCTL_DSP_GETTRIGGER); +#ifdef SNDCTL_DSP_MAPINBUF _EXPORT_INT(m, SNDCTL_DSP_MAPINBUF); +#endif +#ifdef SNDCTL_DSP_MAPOUTBUF _EXPORT_INT(m, SNDCTL_DSP_MAPOUTBUF); +#endif _EXPORT_INT(m, SNDCTL_DSP_NONBLOCK); _EXPORT_INT(m, SNDCTL_DSP_POST); #ifdef SNDCTL_DSP_PROFILE @@ -1269,6 +1275,7 @@ PyInit_ossaudiodev(void) _EXPORT_INT(m, SNDCTL_DSP_STEREO); _EXPORT_INT(m, SNDCTL_DSP_SUBDIVIDE); _EXPORT_INT(m, SNDCTL_DSP_SYNC); +#ifndef __sun _EXPORT_INT(m, SNDCTL_FM_4OP_ENABLE); _EXPORT_INT(m, SNDCTL_FM_LOAD_INSTR); _EXPORT_INT(m, SNDCTL_MIDI_INFO); @@ -1310,5 +1317,6 @@ PyInit_ossaudiodev(void) _EXPORT_INT(m, SNDCTL_TMR_STOP); _EXPORT_INT(m, SNDCTL_TMR_TEMPO); _EXPORT_INT(m, SNDCTL_TMR_TIMEBASE); +#endif return m; }