mirror of
				https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
				synced 2025-10-29 05:40:23 -04:00 
			
		
		
		
	build-sys: meson: Rearrange shell completion between daemon and client
Rename bash completion file to pactl and install it with client build. Completions specific to daemon are now just symlinks, create target directory first to install them. Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/659>
This commit is contained in:
		
							parent
							
								
									80c0a497d3
								
							
						
					
					
						commit
						5f43173209
					
				
					 4 changed files with 22 additions and 16 deletions
				
			
		|  | @ -3,27 +3,33 @@ if bashcompletiondir != 'no' | |||
| 
 | ||||
|   if get_option('daemon') | ||||
|     aliases += [ | ||||
|       'pulseaudio', | ||||
|       'pacmd', | ||||
|       'pasuspender', | ||||
|     ] | ||||
| 
 | ||||
|     # Create target directory for symlinks | ||||
|     if meson.version().version_compare('>= 0.60.0') | ||||
|       install_emptydir(bashcompletiondir) | ||||
|     else | ||||
|       meson.add_install_script('sh', '-c', 'mkdir -p $DESTDIR@0@'.format(bashcompletiondir)) | ||||
|     endif | ||||
|   endif | ||||
| 
 | ||||
|   if get_option('client') | ||||
|   aliases += [ | ||||
|     'pacat', | ||||
|     'pactl', | ||||
|     'padsp', | ||||
|     'paplay', | ||||
|     'parec', | ||||
|     'parecord', | ||||
|   ] | ||||
|     aliases += [ | ||||
|       'pacat', | ||||
|       'padsp', | ||||
|       'paplay', | ||||
|       'parec', | ||||
|       'parecord', | ||||
|     ] | ||||
|     install_data('pactl', install_dir : bashcompletiondir) | ||||
|   endif | ||||
| 
 | ||||
|   install_data('pulseaudio', install_dir : bashcompletiondir) | ||||
| 
 | ||||
|   foreach alias : aliases | ||||
|     dst = join_paths(bashcompletiondir, alias) | ||||
|     cmd = 'ln -fs @0@ $DESTDIR@1@'.format('pulseaudio', dst) | ||||
|     cmd = 'ln -fs @0@ $DESTDIR@1@'.format('pactl', dst) | ||||
|     meson.add_install_script('sh', '-c', cmd) | ||||
|   endforeach | ||||
| endif | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Igor V. Kovalenko
						Igor V. Kovalenko