Mpd 14.1 work in progress port. This needs the audio/faad update i posted 
earlier.

Please give it a spin and report any problems to me.

Known problems:
- tremor flavor crashes with ogg files.
- harsh error handling, calling abort() for common errors.


diff -ruNx CVS ./Makefile 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/Makefile
--- ./Makefile  Tue Oct 28 16:21:48 2008
+++ /home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/Makefile Sat Jan 31 
22:21:41 2009
@@ -1,8 +1,7 @@
 # $OpenBSD: Makefile,v 1.16 2008/10/28 15:21:48 naddy Exp $
 
 COMMENT=               Music Player Daemon
-DISTNAME=              mpd-0.13.2
-PKGNAME=               ${DISTNAME}p2
+DISTNAME=              mpd-0.14.1
 CATEGORIES=            audio
 HOMEPAGE=              http://www.musicpd.org/
 MAINTAINER=            Tobias Ulmer <tobi...@tmux.org>
@@ -13,53 +12,73 @@
 PERMIT_DISTFILES_CDROM=        Yes
 PERMIT_DISTFILES_FTP=  Yes
 
-WANTLIB=               c m pthread ogg z
+WANTLIB=               c m pthread
 
-MASTER_SITES=          ${HOMEPAGE}uploads/files/
+MASTER_SITES=          ${MASTER_SITE_SOURCEFORGE:=musicpd/}
 
-MODULES=               converters/libiconv
+MODULES=               converters/libiconv devel/gettext
 
 LIB_DEPENDS=           audiofile::devel/libaudiofile \
                        ao::audio/libao \
                        samplerate::audio/libsamplerate \
-                       faad.>=2::audio/faad \
+                       faad,mp4ff::audio/faad \
                        FLAC::audio/flac \
-                       id3tag::audio/libid3tag \
                        mad::audio/libmad \
                        mikmod::audio/libmikmod \
-                       mpcdec::audio/libmpcdec
+                       mpcdec::audio/libmpcdec \
+                       glib-2.0,gthread-2.0::devel/glib2 \
+                       mp3lame::audio/lame \
+                       wavpack::audio/wavpack \
+                       id3tag::audio/libid3tag \
+                       curl::net/curl \
+                       ogg::audio/libogg \
 
+#DEBUG=                        -g -O0
 FLAVORS=               tremor
 FLAVOR?=
 
-CONFIGURE_STYLE=       gnu
+AUTOCONF_VERSION=      2.62
+CONFIGURE_STYLE=       gnu autoconf automake
 CONFIGURE_ARGS+=        --enable-ao \
                        --disable-alsa \
                         --disable-oss \
                         --disable-pulse \
-                        --disable-sun \
                        --disable-jack \
+                       --enable-mvp \
                        --enable-mod \
                        --bindir=${PREFIX}/sbin \
                        --with-zeroconf=no
-# OggFLAC and tremor tests, initgroups(3)
+
+# OggFLAC, tremor tests, initgroups(3), id3tag, mp4ff
 CONFIGURE_ENV=         LDFLAGS="-L${LOCALBASE}/lib" \
-                       CPPFLAGS="-I${LOCALBASE}/include -D_BSD_SOURCE"
+                       CPPFLAGS="-I${LOCALBASE}/include -D_BSD_SOURCE" \
+                       ID3TAG_CFLAGS="-I${LOCALBASE}/include" \
+                       ID3TAG_LIBS="-L${LOCALBASE}/lib -lid3tag" \
+                       FAAD_CFLAGS="-I${LOCALBASE}/include"
 
 .if ${FLAVOR:L:Mtremor}
 CONFIGURE_ARGS+=       --with-tremor \
+                       --disable-mvp \
+                       --disable-shout-ogg \
+                       --disable-shout-mp3 \
                        --disable-oggflac \
-                       --disable-shout
+                       --disable-ffmpeg
 LIB_DEPENDS+=          vorbisidec::audio/tremor
 .else
-
-WANTLIB+=              theora
+WANTLIB+=              z
 LIB_DEPENDS+=          vorbis,vorbisfile,vorbisenc::audio/libvorbis \
+                       avcodec,avformat,avutil::graphics/ffmpeg \
+                       faac::audio/faac \
+                       a52::audio/liba52 \
+                       bz2::archivers/bzip2 \
+                       theora::multimedia/libtheora \
                        speex::audio/speex \
-                       shout::net/libshout
+                       shout::net/libshout \
+                       x264::multimedia/x264
 .endif
 
 USE_LIBTOOL=           Yes
+USE_GMAKE=             Yes
 
 post-install:
        ${INSTALL_DATA_DIR} ${PREFIX}/share/examples/mpd
diff -ruNx CVS ./distinfo 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/distinfo
--- ./distinfo  Tue Jul 15 10:40:49 2008
+++ /home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/distinfo Sat Jan 31 
02:59:54 2009
@@ -1,5 +1,5 @@
-MD5 (mpd-0.13.2.tar.gz) = M9DHsI4snipq1VcDyw0Y0A==
-RMD160 (mpd-0.13.2.tar.gz) = 0h4/aFisj7dp1CePmIwX/hWAvFM=
-SHA1 (mpd-0.13.2.tar.gz) = dEgA47ZnoNEUGAKbjtafdBTgbpw=
-SHA256 (mpd-0.13.2.tar.gz) = HxVm5XTvUbsVSXU93uUZcgD+QJS+5JyynIps1k0YSjE=
-SIZE (mpd-0.13.2.tar.gz) = 556468
+MD5 (mpd-0.14.1.tar.gz) = e7dyd7eEAk+soabJIvz4Dg==
+RMD160 (mpd-0.14.1.tar.gz) = Jjkx6Mu76v+jT9ezSU4T+UvCSOQ=
+SHA1 (mpd-0.14.1.tar.gz) = rZrx4ZSwFT2Bo8uada0n0aSHtrs=
+SHA256 (mpd-0.14.1.tar.gz) = 0Tjxqw0NimM8FR1A7Ljb3eYyPxIrZ6cAu3jssh8wxZ8=
+SIZE (mpd-0.14.1.tar.gz) = 367138
diff -ruNx CVS ./patches/patch-configure 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-configure
--- ./patches/patch-configure   Tue Jul 15 10:40:49 2008
+++ /home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-configure  
Thu Jan  1 01:00:00 1970
@@ -1,11 +0,0 @@
---- configure.orig     Tue Jun 17 07:46:22 2008
-+++ configure  Wed Jul  9 12:26:44 2008
-@@ -26288,7 +26288,7 @@ fi
-     LIBFLAC_LIBS="-L$libdir"
-   fi
- 
--  LIBFLAC_LIBS="$LIBFLAC_LIBS -lFLAC -lm"
-+  LIBFLAC_LIBS="$LIBFLAC_LIBS -lFLAC -logg -lm"
- 
-   if test "x$libFLAC_includes" != "x" ; then
-     LIBFLAC_CFLAGS="-I$libFLAC_includes"
diff -ruNx CVS ./patches/patch-doc_Makefile_am 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-doc_Makefile_am
--- ./patches/patch-doc_Makefile_am     Thu Jan  1 01:00:00 1970
+++ 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-doc_Makefile_am
    Sat Jan 31 12:25:51 2009
@@ -0,0 +1,25 @@
+$OpenBSD$
+--- doc/Makefile.am.orig       Sat Jan 31 12:25:18 2009
++++ doc/Makefile.am    Sat Jan 31 12:25:40 2009
+@@ -2,14 +2,14 @@ DOCBOOK_FILES = protocol.xml
+ DOCBOOK_HTML = $(patsubst %.xml,%.html,$(DOCBOOK_FILES))
+ 
+ man_MANS = mpd.1 mpd.conf.5
+-doc_DATA = mpdconf.example
++#doc_DATA = mpdconf.example
+ EXTRA_DIST = $(man_MANS) $(DOCBOOK_FILES) mpdconf.example
+ 
+ MOSTLYCLEANFILES = $(DOCBOOK_HTML)
+ 
+-if HAVE_XMLTO
+-doc_DATA += $(DOCBOOK_HTML)
+-
+-$(DOCBOOK_HTML): %.html: %.xml
+-      $(XMLTO) html-nochunks $<
+-endif
++#if HAVE_XMLTO
++#doc_DATA += $(DOCBOOK_HTML)
++#
++#$(DOCBOOK_HTML): %.html: %.xml
++#     $(XMLTO) html-nochunks $<
++#endif
diff -ruNx CVS ./patches/patch-doc_Makefile_in 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-doc_Makefile_in
--- ./patches/patch-doc_Makefile_in     Tue Jul 15 10:40:49 2008
+++ 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-doc_Makefile_in
    Thu Jan  1 01:00:00 1970
@@ -1,12 +0,0 @@
-$OpenBSD: patch-doc_Makefile_in,v 1.3 2008/07/15 08:40:49 bernd Exp $
---- doc/Makefile.in.orig       Tue Jun 17 07:46:21 2008
-+++ doc/Makefile.in    Wed Jul  9 12:27:25 2008
-@@ -121,7 +121,7 @@ am__quote = @am__quote@
- install_sh = @install_sh@
- man_MANS = mpd.1 mpd.conf.5
- docdir = $(prefix)/share/doc/$(PACKAGE)
--doc_DATA = COMMANDS mpdconf.example
-+doc_DATA = COMMANDS
- EXTRA_DIST = $(man_MANS) $(doc_DATA)
- subdir = doc
- mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
diff -ruNx CVS ./patches/patch-doc_mpdconf_example 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-doc_mpdconf_example
--- ./patches/patch-doc_mpdconf_example Tue Jul 15 10:40:49 2008
+++ 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-doc_mpdconf_example
        Sat Jan 31 18:07:23 2009
@@ -1,78 +1,87 @@
-$OpenBSD: patch-doc_mpdconf_example,v 1.5 2008/07/15 08:40:49 bernd Exp $
---- doc/mpdconf.example.orig   Mon Jun 16 04:48:07 2008
-+++ doc/mpdconf.example        Wed Jul  9 12:26:44 2008
-@@ -2,11 +2,11 @@
- # See the mpd.conf man page for a more detailed description of each parameter.
+$OpenBSD$
+--- doc/mpdconf.example.orig   Sat Jan 17 20:41:09 2009
++++ doc/mpdconf.example        Sat Jan 31 18:04:45 2009
+@@ -6,27 +6,27 @@
+ # This setting controls the top directory which MPD will search to discover 
the
+ # available audio files and add them to the daemon's online database.
+ #
+-music_directory                       "~/music"
++music_directory                       "/configure_your_music_directory"
+ #
+ # This setting sets the MPD internal playlist directory. The purpose of this
+ # directory is storage for playlists created by MPD. The server will use 
+ # playlist files not created by the server but only if they are in the MPD
+ # format.
+ #
+-playlist_directory            "~/.mpd/playlists"
++playlist_directory            "/var/spool/mpd/playlists"
+ #
+ # This setting sets the location of the MPD database. This file is used to
+ # load the database at server start up and store the database while the 
+ # server is not up.
+ #
+-db_file                               "~/.mpd/database"
++db_file                               "/var/spool/mpd/database"
+ # 
+ # These settings are the locations for the daemon log files for the daemon.
+ # These logs are great for troubleshooting, depending on your log_level
+ # settings.
+ #
+-log_file                      "~/.mpd/log"
+-error_file                    "~/.mpd/error-log"
++log_file                      "/var/log/mpd/log"
++error_file                    "/var/log/mpd/error-log"
+ 
###############################################################################
  
- ######################## REQUIRED PATHS ########################
--music_directory                 "~/music"
--playlist_directory              "~/.mpd/playlists"
--db_file                         "~/.mpd/mpd.db"
--log_file                        "~/.mpd/mpd.log"
--error_file                      "~/.mpd/mpd.error"
-+music_directory                 "/please-configure-your-music_directory"
-+playlist_directory              "/var/spool/mpd/playlists"
-+db_file                         "/var/spool/mpd/mpd.db"
-+log_file                        "/var/log/mpd/mpd.log"
-+error_file                      "/var/log/mpd/mpd.error"
- ################################################################
  
- 
-@@ -15,13 +15,13 @@ error_file                      "~/.mpd/mpd.error"
- # If you wish to use mpd --kill to stop MPD, then you must
- # specify a file here in which to store MPD's process ID.
+@@ -36,13 +36,13 @@ error_file                 "~/.mpd/error-log"
+ # for use of mpd --kill and some init scripts. This setting is disabled by
+ # default.
  #
--#pid_file                        "~/.mpd/mpd.pid"
-+pid_file                        "/var/spool/mpd/mpd.pid"
+-#pid_file                     "~/.mpd/pid"
++pid_file                      "/var/spool/mpd/pid"
  #
- # If specified, MPD will save its current state (playlist,
- # current song, playing/paused, etc.) at exit.  This will be
- # used to restore the session the next time it is run.
+ # This setting sets the location of the file which contains information about
+ # most variables to get MPD back into the same general shape it was in before
+ # it was brought down. This setting is disabled by default.
  #
--#state_file                      "~/.mpd/mpdstate"
-+state_file                      "/var/spool/mpd/mpdstate"
+-#state_file                   "~/.mpd/state"
++state_file                    "/var/spool/mpd/state"
  #
- ################################################################
+ 
###############################################################################
  
-@@ -33,11 +33,11 @@ error_file                      "~/.mpd/mpd.error"
- # started by.  If left unspecified, MPD will not drop root
- # privileges at all (not recommended).
+@@ -55,17 +55,17 @@ error_file                 "~/.mpd/error-log"
+ # unprivileged user. This setting is disabled by default, and the server will
+ # run as root.
  #
--#user                            "nobody"
-+user                            "_mpd"
+-#user                         "nobody"
++user                          "_mpd"
  #
- # The address and port to listen on.
+ # This setting sets the address for the daemon to listen on. Careful attention
+ # should be paid if this is assigned to anything other then the default, any.
+ # This setting can deny access to control of the daemon.
  #
--#bind_to_address                 "any"
-+bind_to_address                 "localhost"
- #port                            "6600"
+ # For network
+-#bind_to_address              "any"
++bind_to_address                       "localhost"
  #
- # Controls the amount of information that is logged.  Can be
-@@ -108,6 +108,12 @@ error_file                      "~/.mpd/mpd.error"
- #        format                  "44100:16:2" # optional
- #}
+ # And for Unix Socket
+-#bind_to_address              "~/.mpd/socket"
++bind_to_address                       "/var/spool/mpd/socket"
  #
+ # This setting is the port that is desired for the daemon to get assigned to.
+ #
+@@ -151,6 +151,13 @@ error_file                        "~/.mpd/error-log"
+ #
+ # See <http://mpd.wikia.com/wiki/Configuration#Audio_Outputs> for examples of 
+ # other audio outputs.
 +
++# OpenBSD specific: not supported: Pulse, Jack, ALSA and OSS
 +audio_output {
-+      type                    "ao"
-+      name                    "Libao Audio Device"
++      type                    "ao"
++      name                    "Libao Audio Device"
 +}
 +
- # An example of a shout output (for streaming to Icecast):
  #
- #audio_output {
-@@ -157,12 +163,12 @@ error_file                      "~/.mpd/mpd.error"
+ # An example of an ALSA output:
  #
- #mixer_type                      "oss"
- #mixer_device                    "/dev/mixer"
--#mixer_control                   "PCM"
-+#mixer_control                   "vol"
- #
- # If you want MPD to adjust the volume of audio sent to the
- # audio outputs, you can tell it to use the software mixer:
- #
--#mixer_type                      "software"
-+mixer_type                      "software"
- #
- ################################################################
- 
diff -ruNx CVS ./patches/patch-src_decoder_thread_c 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_decoder_thread_c
--- ./patches/patch-src_decoder_thread_c        Thu Jan  1 01:00:00 1970
+++ 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_decoder_thread_c
       Sat Jan 31 17:44:39 2009
@@ -0,0 +1,19 @@
+$OpenBSD$
+--- src/decoder_thread.c.orig  Sat Jan 17 20:41:09 2009
++++ src/decoder_thread.c       Sat Jan 31 17:42:42 2009
+@@ -27,6 +27,7 @@
+ #include "path.h"
+ #include "log.h"
+ #include "ls.h"
++#include "utils.h"
+ 
+ #include <glib.h>
+ 
+@@ -237,6 +238,7 @@ void decoder_thread_start(void)
+       pthread_t decoder_thread;
+ 
+       pthread_attr_init(&attr);
++      xpthread_attr_minstacksize(&attr);
+       pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED);
+       if (pthread_create(&decoder_thread, &attr, decoder_task, NULL))
+               FATAL("Failed to spawn decoder task: %s\n", strerror(errno));
diff -ruNx CVS ./patches/patch-src_inputPlugins_aac_plugin_c 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_inputPlugins_aac_plugin_c
--- ./patches/patch-src_inputPlugins_aac_plugin_c       Tue Sep 16 00:04:17 2008
+++ 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_inputPlugins_aac_plugin_c
      Thu Jan  1 01:00:00 1970
@@ -1,21 +0,0 @@
-$OpenBSD: patch-src_inputPlugins_aac_plugin_c,v 1.2 2008/09/15 22:04:17 
jakemsr Exp $
---- src/inputPlugins/aac_plugin.c.orig Sun Jan 27 15:13:31 2008
-+++ src/inputPlugins/aac_plugin.c      Wed Jul 16 01:41:56 2008
-@@ -237,7 +237,7 @@ static float getAacFloatTotalTime(char *file)
-       size_t fileread, tagsize;
-       faacDecHandle decoder;
-       faacDecConfigurationPtr config;
--      unsigned long sampleRate;
-+      unsigned int sampleRate;
-       unsigned char channels;
-       InputStream inStream;
-       long bread;
-@@ -293,7 +293,7 @@ static int aac_decode(OutputBuffer * cb, DecoderContro
-       faacDecFrameInfo frameInfo;
-       faacDecConfigurationPtr config;
-       long bread;
--      unsigned long sampleRate;
-+      unsigned int sampleRate;
-       unsigned char channels;
-       int eof = 0;
-       unsigned int sampleCount;
diff -ruNx CVS ./patches/patch-src_inputPlugins_mp4_plugin_c 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_inputPlugins_mp4_plugin_c
--- ./patches/patch-src_inputPlugins_mp4_plugin_c       Tue Sep 16 00:04:17 2008
+++ 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_inputPlugins_mp4_plugin_c
      Thu Jan  1 01:00:00 1970
@@ -1,12 +0,0 @@
-$OpenBSD: patch-src_inputPlugins_mp4_plugin_c,v 1.2 2008/09/15 22:04:17 
jakemsr Exp $
---- src/inputPlugins/mp4_plugin.c.orig Sun Jan 27 15:13:31 2008
-+++ src/inputPlugins/mp4_plugin.c      Wed Jul 16 01:44:57 2008
-@@ -100,7 +100,7 @@ static int mp4_decode(OutputBuffer * cb, DecoderContro
-       faacDecConfigurationPtr config;
-       unsigned char *mp4Buffer;
-       unsigned int mp4BufferSize;
--      unsigned long sampleRate;
-+      unsigned int sampleRate;
-       unsigned char channels;
-       long sampleId;
-       long numSamples;
diff -ruNx CVS ./patches/patch-src_output_thread_c 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_output_thread_c
--- ./patches/patch-src_output_thread_c Thu Jan  1 01:00:00 1970
+++ 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_output_thread_c
        Sat Jan 31 17:44:41 2009
@@ -0,0 +1,19 @@
+$OpenBSD$
+--- src/output_thread.c.orig   Sat Jan 17 20:41:09 2009
++++ src/output_thread.c        Sat Jan 31 17:42:56 2009
+@@ -19,6 +19,7 @@
+ #include "output_thread.h"
+ #include "output_api.h"
+ #include "output_internal.h"
++#include "utils.h"
+ 
+ #include <glib.h>
+ #include <assert.h>
+@@ -172,6 +173,7 @@ void audio_output_thread_start(struct audio_output *ao
+       assert(ao->command == AO_COMMAND_NONE);
+ 
+       pthread_attr_init(&attr);
++      xpthread_attr_minstacksize(&attr);
+       pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED);
+       if (pthread_create(&ao->thread, &attr, audio_output_task, ao))
+               g_error("Failed to spawn output task: %s\n", strerror(errno));
diff -ruNx CVS ./patches/patch-src_player_thread_c 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_player_thread_c
--- ./patches/patch-src_player_thread_c Thu Jan  1 01:00:00 1970
+++ 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_player_thread_c
        Sat Jan 31 17:44:44 2009
@@ -0,0 +1,19 @@
+$OpenBSD$
+--- src/player_thread.c.orig   Sat Jan 17 20:41:09 2009
++++ src/player_thread.c        Sat Jan 31 17:43:09 2009
+@@ -28,6 +28,7 @@
+ #include "song.h"
+ #include "pipe.h"
+ #include "idle.h"
++#include "utils.h"
+ 
+ #include <glib.h>
+ 
+@@ -546,6 +547,7 @@ void player_create(void)
+       pthread_t player_thread;
+ 
+       pthread_attr_init(&attr);
++      xpthread_attr_minstacksize(&attr);
+       pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED);
+       if (pthread_create(&player_thread, &attr, player_task, NULL))
+               FATAL("Failed to spawn player task: %s\n", strerror(errno));
diff -ruNx CVS ./patches/patch-src_update_c 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_update_c
--- ./patches/patch-src_update_c        Thu Jan  1 01:00:00 1970
+++ 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_update_c   
    Sat Jan 31 17:35:40 2009
@@ -0,0 +1,11 @@
+$OpenBSD$
+--- src/update.c.orig  Sat Jan 31 17:31:35 2009
++++ src/update.c       Sat Jan 31 17:34:54 2009
+@@ -535,6 +535,7 @@ static void spawn_update_task(char *path)
+       progress = UPDATE_PROGRESS_RUNNING;
+       modified = false;
+       pthread_attr_init(&attr);
++      xpthread_attr_minstacksize(&attr);
+       if (pthread_create(&update_thr, &attr, update_task, path))
+               FATAL("Failed to spawn update task: %s\n", strerror(errno));
+       if (++update_task_id > update_task_id_max)
diff -ruNx CVS ./patches/patch-src_utils_c 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_utils_c
--- ./patches/patch-src_utils_c Thu Jan  1 01:00:00 1970
+++ 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_utils_c    
    Sat Jan 31 17:28:59 2009
@@ -0,0 +1,23 @@
+$OpenBSD$
+--- src/utils.c.orig   Sat Jan 31 17:19:35 2009
++++ src/utils.c        Sat Jan 31 17:28:41 2009
+@@ -235,3 +235,19 @@ void xpthread_cond_destroy(pthread_cond_t *cond)
+       if ((err = pthread_cond_destroy(cond)))
+               FATAL("failed to destroy cond: %s\n", strerror(err));
+ }
++
++void xpthread_attr_minstacksize(pthread_attr_t *attr)
++{
++      int err;
++      size_t stacksize;
++      size_t minstacksize = 128 * 1024;
++
++      if ((err = pthread_attr_getstacksize(attr, &stacksize)))
++              FATAL("failed to get stack size: %s\n", strerror(err));
++
++      if (stacksize < minstacksize)
++              stacksize = minstacksize;
++
++      if ((err = pthread_attr_setstacksize(attr, stacksize)))
++              FATAL("failed to set stack size: %s\n", strerror(err));
++}
diff -ruNx CVS ./patches/patch-src_utils_h 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_utils_h
--- ./patches/patch-src_utils_h Thu Jan  1 01:00:00 1970
+++ 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/patches/patch-src_utils_h    
    Sat Jan 31 17:29:02 2009
@@ -0,0 +1,10 @@
+$OpenBSD$
+--- src/utils.h.orig   Sat Jan 31 17:27:17 2009
++++ src/utils.h        Sat Jan 31 17:27:36 2009
+@@ -108,4 +108,6 @@ void xpthread_mutex_destroy(pthread_mutex_t *mutex);
+ 
+ void xpthread_cond_destroy(pthread_cond_t *cond);
+ 
++void xpthread_attr_minstacksize(pthread_attr_t *attr);
++
+ #endif
diff -ruNx CVS ./pkg/PLIST 
/home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/pkg/PLIST
--- ./pkg/PLIST Tue Jul 15 10:40:49 2008
+++ /home/tobiasu/work/openbsd/ports/mystuff/audio/mpd/pkg/PLIST        Sat Jan 
31 12:28:31 2009
@@ -5,8 +5,11 @@
 @man man/man5/mpd.conf.5
 @bin sbin/mpd
 share/doc/mpd/
-share/doc/mpd/COMMANDS
+share/doc/mpd/AUTHORS
+share/doc/mpd/COPYING
+share/doc/mpd/NEWS
 share/doc/mpd/README
+share/doc/mpd/TODO
 share/doc/mpd/UPGRADING
 share/examples/mpd/
 share/examples/mpd/mpd.conf

Reply via email to