3.4 KiB
Updating Shairport Sync
This guide is for updating an installation of Shairport Sync you built yourself. If you installed Shairport Sync from a package, these instructions don't apply.
To do an update, you basically have to go through the whole process of building Shairport Sync again, but a few steps are shorter because you've done them before; you won't have to reinstall the build tools or libraries needed, and you won't have to define the user and group or reconfigure the settings in the configuration file.
But before you begin, you should update and upgrade any packages.
Here is the sequence for Raspbian Jessie, which is based on Debian Jessie. The same commands work for Ubuntu, and maybe more. Here, a non-root user with sudo privileges is assumed.
$sudo apt-get update
$sudo apt-get upgrade
Next, stop playing music to your device.
Now, to update and install Shairport Sync, if you still have the directory in which you previously built Shairport Sync, it will contain the repository you originally downloaded. Navigate your way to it and check its status as follows:
$git status
You might get something like this
On branch master
Your branch is up-to-date with 'origin/master'.
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git checkout -- <file>..." to discard changes in working directory)
modified: INSTALL
If you get this, it means that the file INSTALL is different from what it was when you downloaded the repository the first time. In this case, it's not important, so discard the changes by checking out the repository's version using the following command:
$git checkout INSTALL
Eventually, having checked out all the modified files, you should get something like this:
On branch master
Your branch is up-to-date with 'origin/master'.
nothing to commit, working directory clean
(What this measn is that the files used to compile Shairport Sync are the same as they were when originally downloaded. They are up to date with what was downloaded, not with repository at GitHub. Now pull the changes from GitHub:
$git pull
Otherwise – say if you deleted the repository – just pull Shairport Sync from GitHub again and move into the new directory:
$git clone https://github.com/mikebrady/shairport-sync.git
$cd shairport-sync
Now, while in the shairport-sync directory, perform the following commands (note that there is a choice you must make in there):
$autoreconf -fi
#The following is the standard configuration for a Linux that uses the systemd initialisation system:
$./configure --with-alsa --with-avahi --with-ssl=openssl --with-metadata --with-soxr --with-systemd
#OR
#The following is the standard configuration for a Linux that uses the older System V initialisation system:
$./configure --with-alsa --with-avahi --with-ssl=openssl --with-metadata --with-soxr --with-systemv
$make
$sudo make install
At this point you have downloaded, compiled and installed the updated Shairport Sync. However, the older version is still running. So, you need to do a little more:
If you are on a systemd-based system such as Raspbian Jessie or recent versions of Ubuntu and Debian, execute the following commands:
$sudo systemctl daemon-reload
$sudo systemctl restart shairport-sync
Otherwise execute the following command:
$sudo service shairport-sync restart
That's it. Your Shairport Sync should be upgraded now.