Skip to content

Instantly share code, notes, and snippets.

@JimiC
Last active January 17, 2023 16:57
Show Gist options
  • Save JimiC/180edbaa6dfbe81672aed4e09c4ff777 to your computer and use it in GitHub Desktop.
Save JimiC/180edbaa6dfbe81672aed4e09c4ff777 to your computer and use it in GitHub Desktop.
Build and setup PulseAudio module for XRDP on MX Linux
#!/bin/sh
###############################################################################
#
# Build and setup PulseAudio module for XRDP on MX Linux
#
###############################################################################
pulsever=$(pulseaudio --version | awk '{print $2}')
sudo apt-get install -y git libpulse-dev autoconf m4 intltool build-essential dpkg-dev libtool libsndfile-dev libspeexdsp-dev libudev-dev
sudo cp /etc/apt/sources.list.d/debian.list /etc/apt/sources.list.d/debian.list~
sudo sed -Ei 's/^#*deb-src /deb-src /' /etc/apt/sources.list.d/debian.list
sudo apt-get update
sudo apt build-dep pulseaudio -y
cd /tmp
sudo apt source pulseaudio
cd /tmp/pulseaudio-$pulsever
sudo ./configure
sudo git clone https://github.com/neutrinolabs/pulseaudio-module-xrdp.git
cd pulseaudio-module-xrdp
sudo ./bootstrap
sudo ./configure PULSE_DIR="/tmp/pulseaudio-$pulsever"
sudo make
cd /tmp/pulseaudio-$pulsever/pulseaudio-module-xrdp/src/.libs
sudo install -t "/var/lib/xrdp-pulseaudio-installer" -D -m 644 *.so
echo "Install is complete."
echo "If you use Hyper-V please turn off your VM Machine and restart for changes to take effect"
echo "While connecting to the VM Machine make sure that from 'Local Resources > Remote audio > Settings' :"
echo "- 'Play on this computer' in 'Remote audio playback' is selected in order to enable audio playback"
echo "- 'Record on this computer' in 'Remote audio recording' is selected in order to enable audio recording"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment