Bug#835838: [Pkg-alsa-devel] Bug#835838: pulseaudio: Do not intercept ALSA if environment variable is set

2017-02-16 Thread Jordi Mallach
El dl 13 de 02 de 2017 a les 13:30 +0100, en/na Javier Serrano Polo va
escriure:
> X-Debbugs-CC: pkg-alsa-de...@lists.alioth.debian.org
> 
> El dc 21 de 09 de 2016 a les 10:36 -0300, Felipe Sateler va escriure:
> > Alsa maintainers, what do you think?
> 
> Maintainers remain silent.
> 
> > Adding a similar check for a variable named
> > like PULSE_DISABLE_ALSA_PLUGIN or something like that should be
> > very
> > simple.
> 
> Felipe, what do you prefer? To apply the patch with
> PULSE_ALSA_HOOK_CONF
> in pulseaudio or if I implement PULSE_DISABLE_ALSA_PLUGIN in ALSA and
> you do a NMU?

I think PULSE_DISABLE_ALSA_PLUGIN sounds fine, but please propose the
patch to alsa-devel@, and after it is accepted, I am open to apply it
in Debian. I don't want to drag this patch forever.

-- 
Jordi Mallach PĂ©rez  --  Debian developer http://www.debian.org/
jo...@sindominio.net jo...@debian.org http://www.sindominio.net/
GnuPG public key information available at http://oskuro.net/

signature.asc
Description: This is a digitally signed message part
___
pkg-pulseaudio-devel mailing list
pkg-pulseaudio-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-pulseaudio-devel

Bug#835838: pulseaudio: Do not intercept ALSA if environment variable is set

2017-02-14 Thread Javier Serrano Polo
El dt 14 de 02 de 2017 a les 19:35 -0300, Felipe Sateler va escriure:
> Could you check with the release team if this change would be OK for stretch?
> 
> Otherwise I can queue this up for buster.

We can wait.

> Could you propose such a patch to the upstream alsa developers?

I can try.


smime.p7s
Description: S/MIME cryptographic signature
___
pkg-pulseaudio-devel mailing list
pkg-pulseaudio-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-pulseaudio-devel

Bug#835838: pulseaudio: Do not intercept ALSA if environment variable is set

2017-02-14 Thread Felipe Sateler
On Mon, Feb 13, 2017 at 9:30 AM, Javier Serrano Polo  wrote:
> X-Debbugs-CC: pkg-alsa-de...@lists.alioth.debian.org
>
> El dc 21 de 09 de 2016 a les 10:36 -0300, Felipe Sateler va escriure:
>> Alsa maintainers, what do you think?
>
> Maintainers remain silent.
>
>> Adding a similar check for a variable named
>> like PULSE_DISABLE_ALSA_PLUGIN or something like that should be very
>> simple.
>
> Felipe, what do you prefer? To apply the patch with PULSE_ALSA_HOOK_CONF
> in pulseaudio or if I implement PULSE_DISABLE_ALSA_PLUGIN in ALSA and
> you do a NMU?

I am definitely not comfortable doing an NMU of alsa for this.

Could you check with the release team if this change would be OK for stretch?

Otherwise I can queue this up for buster.

Either way, I'd still prefer if this was done upstream on the alsa
side. Could you propose such a patch to the upstream alsa developers?

-- 

Saludos,
Felipe Sateler

___
pkg-pulseaudio-devel mailing list
pkg-pulseaudio-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-pulseaudio-devel


Bug#835838: pulseaudio: Do not intercept ALSA if environment variable is set

2017-02-13 Thread Javier Serrano Polo
X-Debbugs-CC: pkg-alsa-de...@lists.alioth.debian.org

El dc 21 de 09 de 2016 a les 10:36 -0300, Felipe Sateler va escriure:
> Alsa maintainers, what do you think?

Maintainers remain silent.

> Adding a similar check for a variable named
> like PULSE_DISABLE_ALSA_PLUGIN or something like that should be very
> simple.

Felipe, what do you prefer? To apply the patch with PULSE_ALSA_HOOK_CONF
in pulseaudio or if I implement PULSE_DISABLE_ALSA_PLUGIN in ALSA and
you do a NMU?


smime.p7s
Description: S/MIME cryptographic signature
___
pkg-pulseaudio-devel mailing list
pkg-pulseaudio-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-pulseaudio-devel

Bug#835838: pulseaudio: Do not intercept ALSA if environment variable is set

2016-09-21 Thread Felipe Sateler
Hello alsa maintainers

On 28 August 2016 at 14:40, Javier Serrano Polo wrote:
>
> There should be a way for an ALSA application not to be intercepted by
> PulseAudio; for instance, by setting an environment variable. One
> example is the ALSA back end of LMMS, where the interception is buggy
> ( https://bugs.debian.org/781479 ). With this patch, setting
> PULSE_ALSA_HOOK_CONF=/dev/null disables the interception.

It seems to me that the proper way to do this is for the pulseaudio
libasound plugin to detect an environment variable, and then
func_load_if_running does nothing in that case.

Alsa maintainers, what do you think? Does it make sense to you? The
code already checks for the PULSE_INTERNAL envvar, but abusing this
variable would be ugly. Adding a similar check for a variable named
like PULSE_DISABLE_ALSA_PLUGIN or something like that should be very
simple.


-- 

Saludos,
Felipe Sateler

___
pkg-pulseaudio-devel mailing list
pkg-pulseaudio-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-pulseaudio-devel


Bug#835838: pulseaudio: Do not intercept ALSA if environment variable is set

2016-09-03 Thread Javier Serrano Polo
El dv 02 de 09 de 2016 a les 22:40 -0300, Felipe Sateler va escriure:
> what this really does is load
> the file described in PULSE_ALSA_HOOK_CONF, and default to the known
> location?

Correct.



smime.p7s
Description: S/MIME cryptographic signature
___
pkg-pulseaudio-devel mailing list
pkg-pulseaudio-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-pulseaudio-devel

Bug#835838: pulseaudio: Do not intercept ALSA if environment variable is set

2016-09-02 Thread Felipe Sateler
On 1 September 2016 at 18:28, Javier Serrano Polo  wrote:
> El dl 29 de 08 de 2016 a les 12:51 -0300, Felipe Sateler va escriure:
>> Hmm. I wonder if instead of using an override pointing to a different
>> file, it would be a simple disable flag (ALSA_PULSE_DISABLE). Is this
>> possible in this configuration language?
>
> As far as I know, there is no conditional processing. It does not seem
> possible to configure with ALSA Lisp either. I guess ALSA_PULSE_DISABLE
> could be implemented in the pulse_load_if_running function.

I think that is a more logical place. Also, it has a higher chance of
reaching upstream (as the pulse default is a debianism).

I have also a question. in pulse.conf:

# Enable PulseAudio hook if PULSE_ALSA_HOOK_CONF is not set.

I'm fairly ignorant on this format, but what this really does is load
the file described in PULSE_ALSA_HOOK_CONF, and default to the known
location?

-- 

Saludos,
Felipe Sateler

___
pkg-pulseaudio-devel mailing list
pkg-pulseaudio-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-pulseaudio-devel


Bug#835838: pulseaudio: Do not intercept ALSA if environment variable is set

2016-09-01 Thread Javier Serrano Polo
El dl 29 de 08 de 2016 a les 12:51 -0300, Felipe Sateler va escriure:
> Hmm. I wonder if instead of using an override pointing to a different
> file, it would be a simple disable flag (ALSA_PULSE_DISABLE). Is this
> possible in this configuration language?

As far as I know, there is no conditional processing. It does not seem
possible to configure with ALSA Lisp either. I guess ALSA_PULSE_DISABLE
could be implemented in the pulse_load_if_running function.


smime.p7s
Description: S/MIME cryptographic signature
___
pkg-pulseaudio-devel mailing list
pkg-pulseaudio-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-pulseaudio-devel

Bug#835838: pulseaudio: Do not intercept ALSA if environment variable is set

2016-08-29 Thread Felipe Sateler
On 28 August 2016 at 14:40, Javier Serrano Polo  wrote:
> Package: pulseaudio
> Version: 9.0-2
> Severity: wishlist
> Tags: patch
>
> There should be a way for an ALSA application not to be intercepted by
> PulseAudio; for instance, by setting an environment variable. One
> example is the ALSA back end of LMMS, where the interception is buggy
> ( https://bugs.debian.org/781479 ). With this patch, setting
> PULSE_ALSA_HOOK_CONF=/dev/null disables the interception.

Hmm. I wonder if instead of using an override pointing to a different
file, it would be a simple disable flag (ALSA_PULSE_DISABLE). Is this
possible in this configuration language?

-- 

Saludos,
Felipe Sateler

___
pkg-pulseaudio-devel mailing list
pkg-pulseaudio-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-pulseaudio-devel


Bug#835838: pulseaudio: Do not intercept ALSA if environment variable is set

2016-08-28 Thread Javier Serrano Polo
Package: pulseaudio
Version: 9.0-2
Severity: wishlist
Tags: patch

There should be a way for an ALSA application not to be intercepted by
PulseAudio; for instance, by setting an environment variable. One
example is the ALSA back end of LMMS, where the interception is buggy
( https://bugs.debian.org/781479 ). With this patch, setting
PULSE_ALSA_HOOK_CONF=/dev/null disables the interception.
diff -Nru pulseaudio-9.0.orig/debian/pulse-alsa.conf pulseaudio-9.0/debian/pulse-alsa.conf
--- pulseaudio-9.0.orig/debian/pulse-alsa.conf	2016-08-13 04:40:38.0 +0200
+++ pulseaudio-9.0/debian/pulse-alsa.conf	2016-08-28 18:57:34.0 +0200
@@ -1,5 +1,5 @@
-# This file is referred to by /usr/share/alsa/pulse.conf to set pulseaudio as
-# the default output plugin for applications using alsa when PulseAudio is
+# This file is referred to by /usr/share/alsa/pulse-hook.conf to set pulseaudio
+# as the default output plugin for applications using alsa when PulseAudio is
 # running.
 
 pcm.!default {
diff -Nru pulseaudio-9.0.orig/debian/pulse.conf pulseaudio-9.0/debian/pulse.conf
--- pulseaudio-9.0.orig/debian/pulse.conf	2016-08-13 04:40:38.0 +0200
+++ pulseaudio-9.0/debian/pulse.conf	2016-08-28 19:01:55.0 +0200
@@ -1,15 +1,15 @@
-# PulseAudio alsa plugin configuration file to set the pulseaudio plugin as
-# default output for applications using alsa when pulseaudio is running.
-hook_func.pulse_load_if_running {
-	lib "libasound_module_conf_pulse.so"
-	func "conf_pulse_hook_load_if_running"
-}
-
+# Enable PulseAudio hook if PULSE_ALSA_HOOK_CONF is not set.
 @hooks [
 	{
-		func pulse_load_if_running
+		func load
 		files [
-			"/usr/share/alsa/pulse-alsa.conf"
+			{
+@func getenv
+vars [
+	PULSE_ALSA_HOOK_CONF
+]
+default "/usr/share/alsa/pulse-hook.conf"
+			}
 		]
 		errors false
 	}
diff -Nru pulseaudio-9.0.orig/debian/pulse-hook.conf pulseaudio-9.0/debian/pulse-hook.conf
--- pulseaudio-9.0.orig/debian/pulse-hook.conf	1970-01-01 01:00:00.0 +0100
+++ pulseaudio-9.0/debian/pulse-hook.conf	2016-08-13 04:40:38.0 +0200
@@ -0,0 +1,16 @@
+# PulseAudio alsa plugin configuration file to set the pulseaudio plugin as
+# default output for applications using alsa when pulseaudio is running.
+hook_func.pulse_load_if_running {
+	lib "libasound_module_conf_pulse.so"
+	func "conf_pulse_hook_load_if_running"
+}
+
+@hooks [
+	{
+		func pulse_load_if_running
+		files [
+			"/usr/share/alsa/pulse-alsa.conf"
+		]
+		errors false
+	}
+]
diff -Nru pulseaudio-9.0.orig/debian/rules pulseaudio-9.0/debian/rules
--- pulseaudio-9.0.orig/debian/rules	2016-08-13 04:40:38.0 +0200
+++ pulseaudio-9.0/debian/rules	2016-08-28 19:07:54.0 +0200
@@ -16,7 +16,7 @@
 	mkdir -p $(CURDIR)/debian/tmp/usr/share/alsa/alsa.conf.d
 	cp -a $(CURDIR)/debian/pulse.conf \
 		$(CURDIR)/debian/tmp/usr/share/alsa/alsa.conf.d
-	cp -a $(CURDIR)/debian/pulse-alsa.conf $(CURDIR)/debian/tmp/usr/share/alsa
+	cp -a $(CURDIR)/debian/pulse-alsa.conf $(CURDIR)/debian/pulse-hook.conf $(CURDIR)/debian/tmp/usr/share/alsa
 	install -d $(CURDIR)/debian/tmp/usr/share/apport/package-hooks
 	cp $(CURDIR)/debian/apport-hook.py $(CURDIR)/debian/tmp/usr/share/apport/package-hooks/source_pulseaudio.py
 


smime.p7s
Description: S/MIME cryptographic signature
___
pkg-pulseaudio-devel mailing list
pkg-pulseaudio-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-pulseaudio-devel