daapd

Server for DAAP, the digital audio access protocol

© deleet 2003, Alexander Oberdörster

daapd scans a directory for music files (mp3, aac, uncompressed) and makes them available via the Apple proprietary protocol DAAP. DAAP clients can browse the directory and retrieve individual files, either by streaming or by downloading them.

daapd is free software.

Download

If you are upgrading from version 0.2.1 or earlier, please note the following:

Ports & Packages

There are packages for Debian and Gentoo Linux. daapd is also part of the FreeBSD Ports, Fink and NetBSD pgksrc. There's a port to the other OS as well (using CygWin).

There are two installation HOWTOs for Linux, a general one and one geared towards Fedora Linux.

FAQ/Troubleshooting

If you have problems compiling, see the FAQ.

Libraries needed

daapd uses POSIX Threads. In addition to that, the following libraries have to be installed prior to daapd installation:

The following libraries are optional:

Please see their respective documentation for their installation process. In case of MAD, you only need libid3tag. It is distributed separately. In case of mpeg4ip, you only need mp4v2. See README.mpeg4ip included in the daapd distribution for details.

The daapd distribution includes libhttpd-persistent and daaplib. libhttpd-persistent is a modified version of David Hughes' libhttpd.

News

05/03/2006
daapd 0.2.4b. Two small changes to adapt daapd to the current versions of MaxOS X (10.4.x) and iTunes (6.0.4) (thanks, Antoine Reilles).
01/05/2005
daapd 0.2.4a. Bugfixes and additions to static playlists. daapd parses paths with backslashes correctly now; title and length info is read from PLS and M3U Extended files.
01/02/2005
daapd 0.2.4. Adds static playlists. daapd reads playlists in M3U, M3U extended and PLS format (specification). daapd adds all playlist it finds during the file scan to the list of playlists and adds all included files to the database. Files not found on disk are not added to database and playlist; relative paths are resolved. The order of the titles in playlists is preserved. daapd also forwards URLs to iTunes, so playlist entries can point to other servers or web radio stations. Only the http protocol is supported; AFAIK, this is a limitation of iTunes.

There are still some issues with playlists: Auto-update does not work correctly when playlists are deleted or modified (adding playlists works); Title and length info (M3U Extended, PLS) is not parsed yet. This is only relevant for tagless files and URLs. Paths with backslashes are not parsed correctly.
09/08/2004
daapd 0.2.3d. Fixed a stupid bug in the howl callback. If you had problems with daapd showing up in iTunes (i.e. with the mDNS Responder), try this update. Thanks to Bruce Sheplan for this one.
08/21/2004
daapd 0.2.3c. The howl API has changed as of howl 0.9.6. daapd 0.2.3c reflects this (and is only compatible with this version).
06/19/2004
daapd 0.2.3b. Added support for Xing/LAME headers. This speeds up parsing of MP3 files and in effect the complete initial scan of the filesystem. Fixed a few memory leaks. Fixed an issue in the makefile.
06/18/2004
daapd 0.2.3a. Added auto-updates. Clients waiting for updates are automatically notified of changes in the database. Currently, the whole database is sent; support of incremental updates (delta) is forthcoming. libhttpd has changed to support the new version and is now at version h.
06/17/2004
daapd 0.2.3. daapd scans the filesystem periodically now. This happens in a separate thread. Transmissions are compressed with gzip now. This can be turned off with -z (useful on slow machines and fast connections).
06/15/2004
daapd 0.2.2c. daapd should handle large files much more gracefully now (less thrashing, streaming starts faster). This only required a small change in libhttpd (which is now at version g).
06/15/2004
Made a few changes to documentation and makefile for clarification. Added a FAQ.
06/08/2004
Nathan Williams submitted ports of daapd to pgksrc. The package is tested with all combinations of 32/64-Bit, low- and high-endian architectures.
04/29/2004
daapd 0.2.2b. Fixed a bug in the mp3 duration calculation routines. Under certain circumstances, this caused iTunes to chop off tracks at the end. Thanks to Yann Bizeul for pointing this out.
04/28/2004
daapd 0.2.2a. Changed a few things to make daap compatible with iTunes 4.5. This includes changes in libhttpd, so make sure it is rebuilt as well. Added support for encoded AAC files: daapd streams .m4p files now, but the client has to be authorized to play them (thanks to Dustin Rue for the suggestion). Added a stub for a future admin interface. Pointing a web-browser to "SERVER-IP:3689/admin/rescan" causes daapd to rescan the database.
04/15/2004
daapd 0.2.2. Added support for MPEG4/AAC metadata (thanks to Robert Böhrs and Stephen Lee). Added service advertisement (DNS-SD) via howl (thanks to Sandy McArthur). Added a daemon mode (thanks to Dirk-Willem van Gulik). Fixed a bug that files that appear more than once in a directory structure get added multiple times. daapd ignores duplicates now (thanks to Mikol Graves). Added an rc script for linux/sysv init to the distribution (thanks to Mykle Hansen). daaplib and libhttpd-persistent are now included in the distribution.
12/02/2004
daapd 0.2.1d. Renamed libhttpd to libhttpd-persistent to allow both versions to be installed at the same time. This became neccessary because libhttpd-persistent turned out to be incompatible with the old version. Added support for comments / the ID3 comment field (thanks to Remi Gurski). If you have problems compiling, check that you have libid3tag >= 0.15.0b installed.
10/20/2003
daapd 0.2.1c. Automatic rescan of all the files on client connect is now off, because daapd turned out to be unresponsive during this process so all existing client connections are disrupted. Added an option for turning it back on. Thanks to Lee Lindquist for pointing this out.
10/17/2003
Quick fix: daapd 0.2.1b. Fixed a file descriptor leak (thanks to Ronald Rael Harvest).
10/16/2003
Apple released iTunes 4.1 today, als well as a version for Windows (v4.1 as well). daapd seems to work flawlessly with both. Apparently, there have been no changes to the sharing protocol.
10/16/2003
daapd 0.2.1 released. Added preliminary support for uncompressed audio and AAC. No metadata is read in yet. Added Unicode support. Fixed lots of bugs. See release notes for details. libdaap changed as well, so get the new version, too.
08/22/2003
bugfix to libhttpd. libhttp should be less CPU-hungry now when streaming files. Thanks to Eric Shelton.
06/22/2003
daapd 0.2 released. daapd uses libid3tag now (from MAD) instead of id3lib. libid3tag is significantly faster than id3lib and easier to compile. daapd also calculates track durations accurately now, skipping/jumping in mp3 frames is now possible and daapd looks for deleted files and removes them from the song database. Download the new version of libhttpd (d) and MAD as well.
06/06/2003
tiny bugfix to libhttpd. On Linux, daapd hogged the CPU after the directory scan. This is now fixed.
06/03/2003
daapd 0.1b released. The song database can be dumped to a file and re-read later to speed startup. Some small bug fixes and enhancements as well. libhttpd has changed, too.
06/01/2003
daapd 0.1a released. This is just a small bug fix that should fix the SEGFAULTs some people have experienced. iTunes 4.0.0 compatibility and authentication are fixed as well. Note that libhttpd was changed, too, so you have to download the new libhttpd as well (and recompile and install it prior to daapd compilation).

Platforms

daapd has been tested on the following systems:

but it should compile and run on most POSIX systems with minimal changes. Please contact the author if you manage to run daapd on systems not listed here.

About DAAP

DAAP is an http-based protocol for serving music content (and probably other media, too) over TCP/IP networks. DAAP was established by Apple iTunes 4.0 in April 2003. Official documentation is not available to date.

Further information on DAAP:

Older versions

Contact

You can contact the author at daap at deleet dot de.