pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/audio/ncspot
Module Name: pkgsrc
Committed By: kamil
Date: Sun Aug 23 14:57:43 UTC 2020
Modified Files:
pkgsrc/audio/ncspot: Makefile distinfo
pkgsrc/audio/ncspot/patches: patch-Cargo.toml
Added Files:
pkgsrc/audio/ncspot/patches: patch-src_main.rs
Log Message:
ncspot: Call libc::setlocale() to fix printing of non-ASCII characters
Upstream bug report:
https://github.com/hrkfdn/ncspot/issues/221
Analysis done by rvp @ UnitedBSD
https://www.unitedbsd.com/d/233-spotify/54
To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 pkgsrc/audio/ncspot/Makefile \
pkgsrc/audio/ncspot/distinfo
cvs rdiff -u -r1.1 -r1.2 pkgsrc/audio/ncspot/patches/patch-Cargo.toml
cvs rdiff -u -r0 -r1.1 pkgsrc/audio/ncspot/patches/patch-src_main.rs
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/audio/ncspot/Makefile
diff -u pkgsrc/audio/ncspot/Makefile:1.1 pkgsrc/audio/ncspot/Makefile:1.2
--- pkgsrc/audio/ncspot/Makefile:1.1 Thu Aug 20 16:24:59 2020
+++ pkgsrc/audio/ncspot/Makefile Sun Aug 23 14:57:42 2020
@@ -1,6 +1,7 @@
-# $NetBSD: Makefile,v 1.1 2020/08/20 16:24:59 pin Exp $
+# $NetBSD: Makefile,v 1.2 2020/08/23 14:57:42 kamil Exp $
DISTNAME= ncspot-0.2.1
+PKGREVISION= 1
CATEGORIES= audio
MASTER_SITES= ${MASTER_SITE_GITHUB:=hrkfdn/}
GITHUB_TAG= v${PKGVERSION_NOREV}
Index: pkgsrc/audio/ncspot/distinfo
diff -u pkgsrc/audio/ncspot/distinfo:1.1 pkgsrc/audio/ncspot/distinfo:1.2
--- pkgsrc/audio/ncspot/distinfo:1.1 Thu Aug 20 17:56:10 2020
+++ pkgsrc/audio/ncspot/distinfo Sun Aug 23 14:57:42 2020
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.1 2020/08/20 17:56:10 pin Exp $
+$NetBSD: distinfo,v 1.2 2020/08/23 14:57:42 kamil Exp $
SHA1 (addr2line-0.13.0.crate) = c7a6843df774a95b4db5a5511b58ab22c44f228a
RMD160 (addr2line-0.13.0.crate) = 22c733c5358313e9ca7fb95d1dbd695d03fcb552
@@ -1560,4 +1560,5 @@ SHA1 (xi-unicode-0.2.1.crate) = a7e8a8e9
RMD160 (xi-unicode-0.2.1.crate) = 1d50fd64d44638e4d44f154c4dc4f56bb7f3ce50
SHA512 (xi-unicode-0.2.1.crate) = cd5dde20cde2c9180247df4f6912139a436f7ab71ef86dac66418c0459df665c09fc3c5b497f8157a6209da32b3e9fda5f50d1ef06c1c8cc2557c4b90363e586
Size (xi-unicode-0.2.1.crate) = 88229 bytes
-SHA1 (patch-Cargo.toml) = 67719b3b51ecbb424b67d34b53688a71bcf480f1
+SHA1 (patch-Cargo.toml) = df5ac3791121c92707f34df5cc0ef31cab7785df
+SHA1 (patch-src_main.rs) = 3e9dcb8341463460c480e309cc782f23edece48c
Index: pkgsrc/audio/ncspot/patches/patch-Cargo.toml
diff -u pkgsrc/audio/ncspot/patches/patch-Cargo.toml:1.1 pkgsrc/audio/ncspot/patches/patch-Cargo.toml:1.2
--- pkgsrc/audio/ncspot/patches/patch-Cargo.toml:1.1 Thu Aug 20 16:24:59 2020
+++ pkgsrc/audio/ncspot/patches/patch-Cargo.toml Sun Aug 23 14:57:43 2020
@@ -1,10 +1,20 @@
-$NetBSD: patch-Cargo.toml,v 1.1 2020/08/20 16:24:59 pin Exp $
+$NetBSD: patch-Cargo.toml,v 1.2 2020/08/23 14:57:43 kamil Exp $
Use portaudio by default
---- Cargo.toml.orig 2020-07-17 22:02:08.000000000 +0000
+Use libc for setlocale() to fix non-ASCII character printing.
+https://github.com/hrkfdn/ncspot/issues/221
+
+--- Cargo.toml.orig 2020-08-13 08:27:21.000000000 +0000
+++ Cargo.toml
-@@ -48,11 +48,5 @@ version = "0.15"
+@@ -42,17 +42,12 @@ clipboard = { version = "0.5", optional
+ url = "1.7"
+ strum = "0.17.1"
+ strum_macros = "0.17.1"
++libc = "0.2"
+
+ [dependencies.cursive]
+ version = "0.15"
default-features = false
[features]
Added files:
Index: pkgsrc/audio/ncspot/patches/patch-src_main.rs
diff -u /dev/null pkgsrc/audio/ncspot/patches/patch-src_main.rs:1.1
--- /dev/null Sun Aug 23 14:57:43 2020
+++ pkgsrc/audio/ncspot/patches/patch-src_main.rs Sun Aug 23 14:57:43 2020
@@ -0,0 +1,26 @@
+$NetBSD: patch-src_main.rs,v 1.1 2020/08/23 14:57:43 kamil Exp $
+
+Use libc for setlocale() to fix non-ASCII character printing.
+https://github.com/hrkfdn/ncspot/issues/221
+
+--- src/main.rs.orig 2020-08-13 08:27:21.000000000 +0000
++++ src/main.rs
+@@ -47,6 +47,8 @@ use clap::{App, Arg};
+ use cursive::traits::Identifiable;
+ use cursive::{Cursive, CursiveExt};
+
++use std::ffi::CString;
++
+ use librespot_core::authentication::Credentials;
+ use librespot_core::cache::Cache;
+ use librespot_playback::audio_backend;
+@@ -141,6 +143,9 @@ struct UserDataInner {
+ }
+
+ fn main() {
++ unsafe {
++ libc::setlocale(libc::LC_ALL, CString::new("").unwrap().as_ptr());
++ }
+ let backends = {
+ let backends: Vec<&str> = audio_backend::BACKENDS.iter().map(|b| b.0).collect();
+ format!("Audio backends: {}", backends.join(", "))
Home |
Main Index |
Thread Index |
Old Index