From: Mike Brady Date: Sun, 16 Apr 2017 13:36:56 +0000 (+0100) Subject: Create FREEBSD.md X-Git-Tag: 3.1.d6~20 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bfd22f18254f5106233d232b955746a18e625ed4;p=thirdparty%2Fshairport-sync.git Create FREEBSD.md --- diff --git a/FREEBSD.md b/FREEBSD.md new file mode 100644 index 00000000..4af46c3a --- /dev/null +++ b/FREEBSD.md @@ -0,0 +1,58 @@ +This is a very quick initial note about installing Shairport Sync on FreeBSD. Some manual installation is required. + +The build instrctions here install back ends of SNDIO (native to *BSD, AFAIK) and ALSA. ALSA is, or course, the Advanced Linux Sound Architecture, so it is not "native" to FreeBSD. It has, however, been ported, so it should work pretty well. + +This build was done on a default build of `FreeBSD 11.0-RELEASE-p9`. + +First, update everything: +``` +# freebsd-update fetch +# freebsd-update install +``` +Next, install the `pkg` package manager and update its lists: + +``` +# pkg +# pkg update +``` + +Now, install the ALSA and Avahi subsystems. Note: `avahi-app` is chosen because it doesn’t require X11 and `nss_mdns` allows FreeBSD +to resolve mDNS-originated addresses. Thanks to [reidransom](https://gist.github.com/reidransom/6033227) for this: + +``` +# pkg install alsa-utils avahi-app nss_mdns +``` +To enable these services to load automatically at startup, add these lines to `/etc/rc.conf`: +``` +dbus_enable="YES" +avahi_daemon_enable="YES" +``` +Next, change the `hosts:` line in `/etc/nsswitch.conf` to +``` +hosts: files dns mdns +``` +Reboot for these changes to take effect. + +Next, install the packages that are needed for Shairport Sync to be downloaded and build successfully: +``` +# pkg install git autotools pkgconf popt libconfig openssl sndio +``` + +Now, download Shairport Sync from GitHub and check out the `development` branch. +``` +$ git clone https://github.com/mikebrady/shairport-sync.git +$ cd shairport-sync +$ git checkout development +``` +Next, configure the build and compile it: + +``` +$ autoreconf -i -f +$ CPPFLAGS="-I/usr/local/include" ./configure --with-alsa --with-avahi --with-ssl=openssl --with-metadata +$ make +``` + +After this, you're on your own – the `$ sudo make install` step does not work for FreeBSD. Maybe some day... + +To continue, you should create a configuration file at `/usr/local/etc/shairport-sync.conf`. Please see the sample configuration file for more details. +