<div dir="ltr"><div><div><div>Thanks to Didier, I got my snap app's audio working in strict mode. I needed to add the "process-control" plug, probably because my application needs to spawn an audio-thread for feeding the audio device.<br><br></div>I have a few other app-armor denials that happen, but I'll look at those later when I get the chance.<br><br></div>Thanks again,<br></div>--Sp<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Sep 25, 2016 at 11:18 PM, Didier Roche <span dir="ltr"><<a href="mailto:didrocks@ubuntu.com" target="_blank">didrocks@ubuntu.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000"><span class="">
<div>Le 26/09/2016 à 06:27, Spencer Parkin a
écrit :<br>
</div>
<blockquote type="cite">
<div dir="ltr">
<div>
<div>
<div>So I did two things to resolve this, I'm not sure if
one of them was necessary, but...<br>
<br>
</div>
1) I changed my app command to "env
SDL_AUDIODRIVER=pulseaudio desktop-launch
$SNAP/bin/[myprog]"<br>
</div>
2) I changed the confinement from strict to devmode.<br>
<br>
</div>
It's probably the latter that solved the problem. If the
snapcraft developers are interested in testing out why audio
doesn't work in strict mode, they can use my program as an test
case, if they cared to.<br>
</div>
</blockquote></span>
Hey Spencer!<br>
<br>
Some things you can do to test in strict mode is to tail
/var/log/syslog, running your program, and check the apparmor denial
you probably get when acessing to some files/do some calls.<br>
That would be a great hint for you on debugging this issue, and
report a bug if a new interface tweak is needed!<br>
<br>
Remember that you won't be able to publish on the stable channel if
your snap is in devmode.<br>
<br>
Cheers,<br>
Didier
<span class=""><blockquote type="cite">
<div dir="ltr">
<div>
<div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On Sun, Sep 25, 2016 at 6:28 PM,
Spencer Parkin <span dir="ltr"><<a href="mailto:spencertparkin@gmail.com" target="_blank">spencertparkin@gmail.com</a>></span>
wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div>
<div>
<div>
<div>Hi,<br>
<br>
</div>
I'm adding sound-fx to my snap-app and am
running into the common problem of "it works
in my real system, but not in the confined
system." I'm not sure how to trouble-shoot
this problem. I've added the "pulseaudio"
plug to my snapcraft.yaml file, "snap
interface" reports that my snap-app is using
the "pulseaudio" plug, I've tried exporting
the "SDL_AUDIODRIVER=pulseaudio" environment
variable before running my snap to make sure
that I'm using the appropriate audio
back-end. Hmmm...maybe snap-apps can't read
environment variables? Maybe I need to
configure some env-vars in my snapcraft.yaml
file? I'll try to see how to setup the
environment (env-vars) for snaps.<br>
<br>
</div>
Anyhow, I can hear my sound-fx when run on my
real system, but not under unbuntu core.<br>
<br>
</div>
Thanks for any ideas you may have,<br>
</div>
--Sp<br>
</div>
</blockquote>
</div>
<br>
</div>
</div>
</div>
</div>
<br>
<fieldset></fieldset>
<br>
</blockquote>
<p><br>
</p>
</span></div>
<br>--<br>
Snapcraft mailing list<br>
<a href="mailto:Snapcraft@lists.snapcraft.io">Snapcraft@lists.snapcraft.io</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/snapcraft" rel="noreferrer" target="_blank">https://lists.ubuntu.com/<wbr>mailman/listinfo/snapcraft</a><br>
<br></blockquote></div><br></div>