From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1Cb7cP-0003QA-Li for qemu-devel@nongnu.org; Sun, 05 Dec 2004 20:24:49 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1Cb7cP-0003Py-7q for qemu-devel@nongnu.org; Sun, 05 Dec 2004 20:24:49 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1Cb7cP-0003Pv-4J for qemu-devel@nongnu.org; Sun, 05 Dec 2004 20:24:49 -0500 Received: from [38.113.3.71] (helo=smtp-out.hotpop.com) by monty-python.gnu.org with esmtp (Exim 4.34) id 1Cb7SR-0001vj-Si for qemu-devel@nongnu.org; Sun, 05 Dec 2004 20:14:32 -0500 Received: from phreaker.net (kubrick.hotpop.com [38.113.3.103]) by smtp-out.hotpop.com (Postfix) with SMTP id 5FEC11266AD0 for ; Mon, 6 Dec 2004 01:14:29 +0000 (UTC) Received: from jbrown.mylinuxbox.org (pcp03144805pcs.midval01.tn.comcast.net [68.59.228.236]) by smtp-1.hotpop.com (Postfix) with ESMTP id 6DF821A014B for ; Mon, 6 Dec 2004 01:14:26 +0000 (UTC) Date: Sun, 5 Dec 2004 20:13:16 -0500 From: "Jim C. Brown" Subject: Re: [Qemu-devel] Soundwrapper and artsd (fails to share) Message-ID: <20041206011316.GA15922@jbrown.mylinuxbox.org> References: <41B3A197.2030807@hermes.cam.ac.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org On Mon, Dec 06, 2004 at 03:42:59AM +0300, malc wrote: > On Mon, 6 Dec 2004, Richard Neill wrote: > > >Dear All, > > > >I wonder why the following doesn't seem to work? Qemu still takes an > >exclusive lock on the soundcard, even when invoked with soundwrapper. > >I'm using this invocation: > > There is no such thing as excluse soundcard lock, /dev/dsp is being opened > and if sound hardware does not support multiple hardware channels then > this is where the story ends. Not at all. One can pipe the sound thru daemons such as Artsd, ESD, etc. These daemons then muliplex the sound to the actual hardware. Of course the programs have to be specially designed to use these daemons, but sometimes you can use tricks to fool regular programs into thinking that they're talking to the hardware when they are only sending messages to a pipe or socket. These typically involve a wrapper of some sort. Currently the wrappers don't work w/ qemu. (I've only tried 2, artsdsp and esddsp). It isn't hard to add arts support to qemu, I just haven't had the time to convert the code yet. > > > > >soundwrapper /usr/local/bin/qemu -cdrom servicepacks.iso -hda > >winxp_pro_hd.img -boot c -localtime -enable-audio -m 256 -monitor stdio > > I'm not quite sure what soundwrapper is, but if it is just a script that > calls artsdsp under the hood, then it's a no go: > > > # artsdsp i386-softmmu/qemu > artsdsp works only for binaries > I don't get this error. It doesn't even make sense, because A) artsdsp works for scripts and B) qemu is a binary. artsdsp is merely a script that makes use of the LD_PRELOAD trick, which wraps open(), write(), and a few other things in order to intercept attempts to open /dev/dsp (and related audio devices) and replace them with messages to artsd. Of course, artsdsp doesn't work for qemu anyways, so it's a moot point. -- Infinite complexity begets infinite beauty. Infinite precision begets infinite perfection.