Update to 0.7.7

Allow use of base ncurses

PR:		214314
Submitted by:	Oleg Gushchenkov <gor@clogic.com.ua>
Approved by:	<yamagi@yamagi.org> (maintainer)
This commit is contained in:
Jason E. Hale
2016-12-09 07:10:40 +00:00
parent 0eee0fc535
commit 54de16e080
4 changed files with 6 additions and 54 deletions

View File

@@ -1,13 +1,12 @@
# $FreeBSD$
PORTNAME= ncmpcpp
PORTVERSION= 0.7.5
PORTREVISION= 3
PORTVERSION= 0.7.7
CATEGORIES= audio
MASTER_SITES= http://ncmpcpp.rybczak.net/stable/
MAINTAINER= yamagi@yamagi.org
COMMENT= ncurses mpd client, clone of ncmpc with some new features
COMMENT= Ncurses mpd client, clone of ncmpc with some new features
LICENSE= GPLv2+
LICENSE_FILE= ${WRKSRC}/COPYING
@@ -18,7 +17,7 @@ LIB_DEPENDS= libmpdclient.so:audio/libmpdclient \
libicuuc.so:devel/icu \
libboost_filesystem.so:devel/boost-libs
USES= compiler:c++11-lib iconv libtool localbase ncurses:port pkgconfig tar:bzip2
USES= compiler:c++11-lib iconv libtool localbase ncurses pkgconfig readline tar:bzip2
GNU_CONFIGURE= yes
USE_GNOME= glib20
LDFLAGS+= -lpthread

View File

@@ -1,3 +1,3 @@
TIMESTAMP = 1471591908
SHA256 (ncmpcpp-0.7.5.tar.bz2) = 7e4f643020b36698462879013a8b16111f8c3a4c5819cf186aed78032a41e07d
SIZE (ncmpcpp-0.7.5.tar.bz2) = 443072
TIMESTAMP = 1481256402
SHA256 (ncmpcpp-0.7.7.tar.bz2) = b7bcbec83b1f88cc7b21f196b10be09a27b430566c59f402df170163464d01ef
SIZE (ncmpcpp-0.7.7.tar.bz2) = 443801

View File

@@ -1,29 +0,0 @@
--- src/mpdpp.cpp.orig 2016-04-17 05:41:01 UTC
+++ src/mpdpp.cpp
@@ -105,6 +105,8 @@ Connection::Connection() : m_connection(
m_port(6600),
m_timeout(15)
{
+ std::random_device rd;
+ m_gen.seed(rd());
}
void Connection::Connect()
@@ -570,7 +572,7 @@ bool Connection::AddRandomTag(mpd_tag_ty
if (number > tags.size())
return false;
- std::random_shuffle(tags.begin(), tags.end());
+ std::shuffle(tags.begin(), tags.end(), m_gen);
auto it = tags.begin();
for (size_t i = 0; i < number && it != tags.end(); ++i)
{
@@ -609,7 +611,7 @@ bool Connection::AddRandomSongs(size_t n
}
else
{
- std::random_shuffle(files.begin(), files.end());
+ std::shuffle(files.begin(), files.end(), m_gen);
StartCommandsList();
auto it = files.begin();
for (size_t i = 0; i < number && it != files.end(); ++i, ++it)

View File

@@ -1,18 +0,0 @@
--- src/mpdpp.h.orig 2016-04-17 05:41:01 UTC
+++ src/mpdpp.h
@@ -23,6 +23,7 @@
#include <cassert>
#include <exception>
+#include <random>
#include <set>
#include <vector>
@@ -587,6 +588,7 @@ private:
int m_port;
int m_timeout;
std::string m_password;
+ std::mt19937 m_gen;
};
}