[PATCH 3/9] conf: Read a host-specific asoundrc

Takashi Iwai tiwai at suse.de
Tue Jun 23 12:54:19 CEST 2020


On Mon, 22 Jun 2020 15:15:09 +0200,
Mark Hills wrote:
> 
> On systems with a network mounted home directory this is thoroughly
> useful to allow for a core set of asoundrc settings, but with different
> settings on different hosts.
> 
> It's not possibly to implement this in our own asoundrc or local
> customisation, as it's too late. The installation file must be modified.
> 
> This is similar to ~/.Xdefaults-* on some systems.
> 
> Signed-off-by: Mark Hills <mark at xwax.org>

This kind of change popping up sometimes in the past, too, and I have
a mixed feeling whether to take such a change globally or not.

In one side, it can work, but OTOH, if you can deal with that detail,
you're certainly able to set up the environment variable easily, too.


thanks,

Takashi

> ---
>  src/conf/alsa.conf | 11 +++++++++++
>  1 file changed, 11 insertions(+)
> 
> diff --git a/src/conf/alsa.conf b/src/conf/alsa.conf
> index 18427ec6..4dae0e9c 100644
> --- a/src/conf/alsa.conf
> +++ b/src/conf/alsa.conf
> @@ -24,6 +24,17 @@
>  					"/alsa/asoundrc"
>  				]
>  			}
> +			{
> +				@func concat
> +				strings [
> +					"~/.asoundrc-"
> +					{
> +						@func getenv
> +						vars [ HOSTNAME ]
> +						default "localhost"
> +					}
> +				]
> +			}
>  		]
>  		errors false
>  	}
> -- 
> 2.17.5
> 


More information about the Alsa-devel mailing list