Hi All!

Everything works for me. MPD+ncmpcpp intensively tested and ncmpc+mpc
very superficially.

General issue: MPD+sndio don't nix sound. Can't start song with MPD when
mpv is running. I've always had that issue.

ok rsadowski@

On Mon Jun 04, 2018 at 09:47:02PM +0200, Landry Breuil wrote:
> Hi,
> 
> here are four diffs to update the mpd/mpc gang, works fine here. thx
> rsadowski@ for the c++ voodoo. ncmpc was rewritten to use c++14.
> fixed WANTLIB here and there to use the correct curses lib, as curses is
> the one reported in the end by ldd/objdump -p, i don't see any specific
> reason to use ncursesw there.
> Feedback from other mpd users welcome.
> 
> Landry

> Index: Makefile
> ===================================================================
> RCS file: /cvs/ports/audio/mpc/Makefile,v
> retrieving revision 1.26
> diff -u -r1.26 Makefile
> --- Makefile  23 Apr 2018 17:11:49 -0000      1.26
> +++ Makefile  4 Jun 2018 19:41:49 -0000
> @@ -2,7 +2,7 @@
>  
>  COMMENT=             command line client for mpd
>  
> -VER=                 0.29
> +VER=                 0.30
>  DISTNAME=            mpc-${VER}
>  CATEGORIES=          audio
>  EXTRACT_SUFX=                .tar.xz
> Index: distinfo
> ===================================================================
> RCS file: /cvs/ports/audio/mpc/distinfo,v
> retrieving revision 1.15
> diff -u -r1.15 distinfo
> --- distinfo  23 Apr 2018 16:51:50 -0000      1.15
> +++ distinfo  4 Jun 2018 19:41:49 -0000
> @@ -1,2 +1,2 @@
> -SHA256 (mpc-0.29.tar.xz) = AvHa7JAstI+M2qb+Icchn2IxsJHd2+Q3o6T7EssHudM=
> -SIZE (mpc-0.29.tar.xz) = 41872
> +SHA256 (mpc-0.30.tar.xz) = ZfxbCoQw7+msvm4mESeWBoJ2SyCrmUZ2NxvceX2Gf84=
> +SIZE (mpc-0.30.tar.xz) = 41968
> Index: patches/patch-doc_meson_build
> ===================================================================
> RCS file: /cvs/ports/audio/mpc/patches/patch-doc_meson_build,v
> retrieving revision 1.1
> diff -u -r1.1 patch-doc_meson_build
> --- patches/patch-doc_meson_build     23 Apr 2018 16:51:50 -0000      1.1
> +++ patches/patch-doc_meson_build     4 Jun 2018 19:41:49 -0000
> @@ -24,10 +24,11 @@
>  -    output: 'man',
>  +    output: 'man1',
>       input: ['index.rst', 'conf.py'],
> -     command: [sphinx, '-q', '-b', 'man', '-d', '@OUTDIR@/doctrees', 
> meson.current_source_dir(), '@OUTPUT@'],
> +-    command: [sphinx, '-q', '-b', 'man', '-d', '@OUTDIR@/doctrees', 
> meson.current_source_dir(), '@OUTPUT@/man1'],
> ++    command: [sphinx, '-q', '-b', 'man', '-d', '@OUTDIR@/doctrees', 
> meson.current_source_dir(), '@OUTPUT@'],
>       build_by_default: true,
>       install: true,
> --    install_dir: join_paths(get_option('datadir'), 'man', 'man1'),
> -+    install_dir: get_option('mandir')
> +-    install_dir: get_option('datadir'),
> ++    install_dir: get_option('mandir'),
>     )
>   endif

> Index: Makefile
> ===================================================================
> RCS file: /cvs/ports/audio/mpd/Makefile,v
> retrieving revision 1.116
> diff -u -r1.116 Makefile
> --- Makefile  23 Apr 2018 16:58:40 -0000      1.116
> +++ Makefile  4 Jun 2018 19:42:11 -0000
> @@ -2,7 +2,7 @@
>  
>  BROKEN-hppa =                no atomic ops
>  COMMENT =            Music Player Daemon
> -VER =                        0.20.18
> +VER =                        0.20.20
>  DISTNAME =           mpd-${VER}
>  CATEGORIES =         audio
>  HOMEPAGE =           https://www.musicpd.org/
> Index: distinfo
> ===================================================================
> RCS file: /cvs/ports/audio/mpd/distinfo,v
> retrieving revision 1.48
> diff -u -r1.48 distinfo
> --- distinfo  23 Apr 2018 16:58:40 -0000      1.48
> +++ distinfo  4 Jun 2018 19:42:11 -0000
> @@ -1,2 +1,2 @@
> -SHA256 (mpd-0.20.18.tar.gz) = pODRR/fRL/dg3DCSiFLj+klBqClSQ0kZGYugQJ7IrTw=
> -SIZE (mpd-0.20.18.tar.gz) = 1137008
> +SHA256 (mpd-0.20.20.tar.gz) = KZQHeiWVJIaHynj+EsYdxrHk55EzMMayCjmGJLyolZA=
> +SIZE (mpd-0.20.20.tar.gz) = 1139145
> Index: patches/patch-Makefile_in
> ===================================================================
> RCS file: /cvs/ports/audio/mpd/patches/patch-Makefile_in,v
> retrieving revision 1.23
> diff -u -r1.23 patch-Makefile_in
> --- patches/patch-Makefile_in 25 Aug 2017 10:06:59 -0000      1.23
> +++ patches/patch-Makefile_in 4 Jun 2018 19:42:11 -0000
> @@ -2,7 +2,7 @@
>  Index: Makefile.in
>  --- Makefile.in.orig
>  +++ Makefile.in
> -@@ -4652,7 +4652,7 @@ FILTER_LIBS = \
> +@@ -4680,7 +4680,7 @@ FILTER_LIBS = \
>   # Documentation
>   #
>   man_MANS = doc/mpd.1 doc/mpd.conf.5
> Index: patches/patch-src_Main_cxx
> ===================================================================
> RCS file: /cvs/ports/audio/mpd/patches/patch-src_Main_cxx,v
> retrieving revision 1.4
> diff -u -r1.4 patch-src_Main_cxx
> --- patches/patch-src_Main_cxx        30 May 2017 12:31:54 -0000      1.4
> +++ patches/patch-src_Main_cxx        4 Jun 2018 19:42:11 -0000
> @@ -5,7 +5,7 @@
>  Index: src/Main.cxx
>  --- src/Main.cxx.orig
>  +++ src/Main.cxx
> -@@ -123,7 +123,7 @@ static constexpr size_t MEGABYTE = 1024 * KILOBYTE;
> +@@ -115,7 +115,7 @@ static constexpr size_t MEGABYTE = 1024 * KILOBYTE;
>   static constexpr size_t DEFAULT_BUFFER_SIZE = 4 * MEGABYTE;
>   
>   static

> Index: Makefile
> ===================================================================
> RCS file: /cvs/ports/audio/ncmpc/Makefile,v
> retrieving revision 1.37
> diff -u -r1.37 Makefile
> --- Makefile  24 Nov 2017 13:31:39 -0000      1.37
> +++ Makefile  4 Jun 2018 19:41:42 -0000
> @@ -2,7 +2,7 @@
>  
>  COMMENT=             curses based frontend for mpd
>  
> -VER=                 0.29
> +VER=                 0.30
>  DISTNAME=            ncmpc-${VER}
>  EPOCH=                       0
>  CATEGORIES=          audio
> @@ -14,15 +14,18 @@
>  # GPLv2
>  PERMIT_PACKAGE_CDROM=        Yes
>  
> -WANTLIB=             c glib-2.0 intl mpdclient>=1 ncursesw
> +WANTLIB=             c glib-2.0 intl mpdclient>=1 ${COMPILER_LIBCXX} curses
>  
>  MASTER_SITES=                https://www.musicpd.org/download/ncmpc/${VER:R}/
>  
>  EXTRACT_SUFX=                .tar.xz
>  
> +COMPILER =           base-clang ports-gcc
> +
>  MODULES=             devel/meson
>  
> -BUILD_DEPENDS=               devel/gettext-tools
> +BUILD_DEPENDS=               devel/gettext-tools \
> +                     textproc/py-sphinx
>  
>  LIB_DEPENDS=         devel/gettext \
>                       devel/glib2 \
> @@ -35,7 +38,7 @@
>                       CPPFLAGS="-D_GNU_SOURCE \
>                                 -D_DEFAULT_SOURCE \
>                                 -I${LOCALBASE}/include" \
> -                     LDFLAGS="-lncursesw -L${LOCALBASE}/lib"
> +                     LDFLAGS="-L${LOCALBASE}/lib"
>  
>  post-install:
>       ${INSTALL_DATA_DIR} ${PREFIX}/share/examples/ncmpc
> Index: distinfo
> ===================================================================
> RCS file: /cvs/ports/audio/ncmpc/distinfo,v
> retrieving revision 1.15
> diff -u -r1.15 distinfo
> --- distinfo  24 Nov 2017 13:31:39 -0000      1.15
> +++ distinfo  4 Jun 2018 19:41:42 -0000
> @@ -1,2 +1,2 @@
> -SHA256 (ncmpc-0.29.tar.xz) = 72iptnFyOD6oDuRleQFRCUM/oFhyiBLSsOvt5mDYXxI=
> -SIZE (ncmpc-0.29.tar.xz) = 233876
> +SHA256 (ncmpc-0.30.tar.xz) = 4/4MtYuKd/Y/sWRcL5dLM08WFO/cg07GmO59hh8bEqM=
> +SIZE (ncmpc-0.30.tar.xz) = 245212
> Index: patches/patch-doc_meson_build
> ===================================================================
> RCS file: patches/patch-doc_meson_build
> diff -N patches/patch-doc_meson_build
> --- /dev/null 1 Jan 1970 00:00:00 -0000
> +++ patches/patch-doc_meson_build     4 Jun 2018 19:41:42 -0000
> @@ -0,0 +1,32 @@
> +$OpenBSD$
> +
> +Index: doc/meson.build
> +--- doc/meson.build.orig
> ++++ doc/meson.build
> +@@ -1,23 +1,13 @@
> + sphinx = find_program('sphinx-build', required:false)
> + if sphinx.found()
> +   custom_target(
> +-    'HTML documentation',
> +-    output: 'html',
> +-    input: ['index.rst', 'conf.py'],
> +-    command: [sphinx, '-q', '-b', 'html', '-d', '@OUTDIR@/doctrees', 
> meson.current_source_dir(), '@OUTPUT@'],
> +-    build_by_default: true,
> +-    install: true,
> +-    install_dir: join_paths(get_option('datadir'), 'doc', 
> meson.project_name()),
> +-  )
> +-
> +-  custom_target(
> +     'Manpage documentation',
> +-    output: 'man',
> ++    output: 'man1',
> +     input: ['index.rst', 'conf.py'],
> +-    command: [sphinx, '-q', '-b', 'man', '-d', '@OUTDIR@/doctrees', 
> meson.current_source_dir(), '@OUTPUT@/man1'],
> ++    command: [sphinx, '-q', '-b', 'man', '-d', '@OUTDIR@/doctrees', 
> meson.current_source_dir(), '@OUTPUT@'],
> +     build_by_default: true,
> +     install: true,
> +-    install_dir: get_option('datadir'),
> ++    install_dir: get_option('mandir'),
> +   )
> + endif
> + 
> Index: patches/patch-src_colors_c
> ===================================================================
> RCS file: patches/patch-src_colors_c
> diff -N patches/patch-src_colors_c
> --- patches/patch-src_colors_c        27 Mar 2017 17:26:10 -0000      1.4
> +++ /dev/null 1 Jan 1970 00:00:00 -0000
> @@ -1,25 +0,0 @@
> -$OpenBSD: patch-src_colors_c,v 1.4 2017/03/27 17:26:10 dcoppa Exp $
> -
> -"Fix" screen corruption in ncmpc. Colors and attributes can not be mixed.
> -Colors are in the low 8 bit, mask them in the appropriate places.
> -
> ---- src/colors.c.orig        Tue Mar 21 22:04:52 2017
> -+++ src/colors.c     Mon Mar 27 18:24:20 2017
> -@@ -85,7 +85,7 @@ colors_update_pair(enum color id)
> - {
> -     assert(id > 0 && id < COLOR_END);
> - 
> --    int fg = colors[id].color;
> -+    int fg = colors[id].color & 0xff;
> -     int bg = colors[COLOR_BACKGROUND].color;
> - 
> -     /* If color == COLOR_NONE (negative),
> -@@ -261,7 +261,7 @@ colors_use(WINDOW *w, enum color id)
> -     if (options.enable_colors) {
> -             /* color mode */
> -             if ((int)attrs != entry->color || (short)id != pair)
> --                    wattr_set(w, entry->color, id, NULL);
> -+                    wattr_set(w, entry->color & ~0xff, id, NULL);
> -     } else {
> - #endif
> -             /* mono mode */
> Index: patches/patch-src_colors_cxx
> ===================================================================
> RCS file: patches/patch-src_colors_cxx
> diff -N patches/patch-src_colors_cxx
> --- /dev/null 1 Jan 1970 00:00:00 -0000
> +++ patches/patch-src_colors_cxx      4 Jun 2018 19:41:42 -0000
> @@ -0,0 +1,27 @@
> +$OpenBSD$
> +
> +
> +"Fix" screen corruption in ncmpc. Colors and attributes can not be mixed.
> +Colors are in the low 8 bit, mask them in the appropriate places.
> +
> +Index: src/colors.cxx
> +--- src/colors.cxx.orig
> ++++ src/colors.cxx
> +@@ -99,7 +99,7 @@ colors_update_pair(enum color id)
> + {
> +     assert(id > 0 && id < COLOR_END);
> + 
> +-    int fg = colors[id].color;
> ++    int fg = colors[id].color & 0xff;
> +     int bg = colors[COLOR_BACKGROUND].color;
> + 
> +     /* If color == COLOR_NONE (negative),
> +@@ -257,7 +257,7 @@ colors_use(WINDOW *w, enum color id)
> +     if (options.enable_colors) {
> +             /* color mode */
> +             if ((int)attrs != entry->color || (short)id != pair)
> +-                    wattr_set(w, entry->color, id, nullptr);
> ++                    wattr_set(w, entry->color & 0xff, id, nullptr);
> +     } else {
> + #endif
> +             /* mono mode */
> Index: patches/patch-src_screen_cxx
> ===================================================================
> RCS file: patches/patch-src_screen_cxx
> diff -N patches/patch-src_screen_cxx
> --- /dev/null 1 Jan 1970 00:00:00 -0000
> +++ patches/patch-src_screen_cxx      4 Jun 2018 19:41:42 -0000
> @@ -0,0 +1,18 @@
> +$OpenBSD$
> +
> +Because c++14 zomg woot woot
> +
> +Index: src/screen.cxx
> +--- src/screen.cxx.orig
> ++++ src/screen.cxx
> +@@ -56,8 +56,8 @@ ScreenManager::MakePage(const struct screen_functions 
> +             return i;
> + 
> +     auto j = pages.emplace(&sf,
> +-                           sf.init(*this, main_window.w,
> +-                                   main_window.size));
> ++                           std::unique_ptr<Page>(sf.init(*this, 
> main_window.w,
> ++                                   main_window.size)));
> +     assert(j.second);
> +     return j.first;
> + }
> Index: patches/patch-src_screen_init_c
> ===================================================================
> RCS file: patches/patch-src_screen_init_c
> diff -N patches/patch-src_screen_init_c
> --- patches/patch-src_screen_init_c   27 Mar 2017 17:26:10 -0000      1.1
> +++ /dev/null 1 Jan 1970 00:00:00 -0000
> @@ -1,26 +0,0 @@
> -$OpenBSD: patch-src_screen_init_c,v 1.1 2017/03/27 17:26:10 dcoppa Exp $
> ---- src/screen_init.c.orig   Mon Mar 20 21:59:49 2017
> -+++ src/screen_init.c        Mon Mar 27 18:44:28 2017
> -@@ -26,7 +26,9 @@
> - #include "options.h"
> - #include "colors.h"
> - 
> -+#include <sys/ioctl.h>
> - #include <stdlib.h>
> -+#include <termios.h>
> - 
> - #ifndef NCMPC_MINI
> - /** welcome message time [s] */
> -@@ -63,6 +65,12 @@ screen_exit(void)
> - void
> - screen_resize(struct mpdclient *c)
> - {
> -+    struct winsize ws;
> -+    if (ioctl(fileno(stdout), TIOCGWINSZ, &ws) == 0) { 
> -+            LINES = ws.ws_row;
> -+            COLS = ws.ws_col;
> -+    }
> -+
> -     const unsigned cols = COLS, rows = LINES;
> -     if (cols < SCREEN_MIN_COLS || rows < SCREEN_MIN_ROWS) {
> -             screen_exit();

> Index: Makefile
> ===================================================================
> RCS file: /cvs/ports/audio/ncmpcpp/Makefile,v
> retrieving revision 1.68
> diff -u -r1.68 Makefile
> --- Makefile  11 Feb 2018 10:37:51 -0000      1.68
> +++ Makefile  4 Jun 2018 19:40:36 -0000
> @@ -5,7 +5,7 @@
>  
>  COMMENT =            ncurses mpd client inspired by ncmpc
>  
> -DISTNAME =           ncmpcpp-0.8.1
> +DISTNAME =           ncmpcpp-0.8.2
>  
>  EXTRACT_SUFX =               .tar.bz2
>  
> @@ -21,7 +21,7 @@
>  WANTLIB += boost_date_time-mt boost_filesystem-mt boost_locale-mt
>  WANTLIB += boost_program_options-mt boost_regex-mt boost_system-mt
>  WANTLIB += boost_thread-mt c crypto curl ereadline iconv m mpdclient
> -WANTLIB += ncursesw nghttp2 pthread ssl ${LIBCXX} tag termcap z
> +WANTLIB += curses nghttp2 pthread ssl ${LIBCXX} tag z
>  WANTLIB += ${COMPILER_LIBCXX}
>  
>  MASTER_SITES =               ${HOMEPAGE}stable/
> @@ -54,8 +54,8 @@
>                       ICU_CFLAGS="icu-is-not-really-needed" \
>                       ICU_LIBS="icu-is-not-really-needed" \
>                       ncursesw_CFLAGS="-D_GNU_SOURCE -D_DEFAULT_SOURCE" \
> -                     ncursesw_LIBS="-lncursesw" \
> -                     ax_cv_lib_readline="-L${LOCALBASE}/lib -lereadline 
> -ltermcap"
> +                     ncursesw_LIBS="-lcurses" \
> +                     ax_cv_lib_readline="-L${LOCALBASE}/lib -lereadline"
>  
>  NO_TEST =            Yes
>  
> Index: distinfo
> ===================================================================
> RCS file: /cvs/ports/audio/ncmpcpp/distinfo,v
> retrieving revision 1.23
> diff -u -r1.23 distinfo
> --- distinfo  11 Feb 2018 10:37:51 -0000      1.23
> +++ distinfo  4 Jun 2018 19:40:36 -0000
> @@ -1,2 +1,2 @@
> -SHA256 (ncmpcpp-0.8.1.tar.bz2) = TflXCh20ui3Jt1mquIsoPACAb7XSvOX10nousQ5oiP8=
> -SIZE (ncmpcpp-0.8.1.tar.bz2) = 464123
> +SHA256 (ncmpcpp-0.8.2.tar.bz2) = ZQuj6AiWJLetnkzBm8GsYCjtt1I8wRH6FobqRMCSFVQ=
> +SIZE (ncmpcpp-0.8.2.tar.bz2) = 465713

Reply via email to