I'm writing an audio HAL plugin to send the audio over the network to a device. I can get audio and stream it over a socket just fine but wanted to log debug messages to a file rather than syslog. However, when I try to open a file from within the HAL plugin, I get "Operation not permitted".
I tried writing to
/tmp
as well as to the temporary directory returned by NSTemporaryDirectory()
. None of these worked. It seems that the HAL plugin is sandboxed without disk access and I don't know how to provide those permissions as the plugin is run under coreaudio process.Anyone have any experience with writing to disk from an Audio HAL Plugin?