newsboat: Update from 2.19 to 2.20.1

This commit is contained in:
Fredrik Fornwall 2020-08-12 10:26:50 +02:00
parent b185949d1f
commit 7d1783752e
8 changed files with 112 additions and 73 deletions

View File

@ -1,6 +1,6 @@
diff -u -r ../newsboat-2.16.1/Makefile ./Makefile
--- ../newsboat-2.16.1/Makefile 2019-06-26 17:55:21.000000000 +0000
+++ ./Makefile 2019-08-06 17:59:51.574712056 +0000
diff -u -r ../newsboat-2.20.1/Makefile ./Makefile
--- ../newsboat-2.20.1/Makefile 2020-06-24 09:51:43.000000000 +0000
+++ ./Makefile 2020-07-27 08:08:05.365435000 +0000
@@ -18,7 +18,7 @@
WARNFLAGS=-Werror -Wall -Wextra -Wunreachable-code
@ -32,8 +32,8 @@ diff -u -r ../newsboat-2.16.1/Makefile ./Makefile
PODBOAT=podboat
PODBOAT_SOURCES:=$(shell cat mk/podboat.deps)
PODBOAT_OBJS:=$(patsubst %.cpp,%.o,$(PODBOAT_SOURCES))
-PODBOAT_LIBS=-lboat -lnewsboat -lpthread -ldl
+PODBOAT_LIBS=-lboat -lnewsboat -ldl
-PODBOAT_LIBS=-lboat -lnewsboat -lfilter -lpthread -ldl
+PODBOAT_LIBS=-lboat -lnewsboat -lfilter -ldl
ifeq (, $(filter Linux GNU GNU/%, $(shell uname -s)))
NEWSBOAT_LIBS+=-liconv -lintl

View File

@ -1,53 +0,0 @@
diff -uNr newsboat-2.17/rust/libnewsboat/Cargo.toml newsboat-2.17.mod/rust/libnewsboat/Cargo.toml
--- newsboat-2.17/rust/libnewsboat/Cargo.toml 2019-09-22 17:19:19.000000000 +0300
+++ newsboat-2.17.mod/rust/libnewsboat/Cargo.toml 2019-09-24 20:57:10.680900795 +0300
@@ -19,7 +19,6 @@
unicode-segmentation = "1"
curl-sys = "0.4.5"
libc = "0.2"
-gettext-rs = "0.4.1"
natord = "1.0.9"
# We don't use the following crates, but we pin their versions to make sure
@@ -37,12 +36,6 @@
# I want as little dependencies as practically possible.
default-features = false
-[dependencies.gettext-sys]
-version = "0.19.8"
-# Don't let the crate build its own copy of gettext; force it to use the one
-# built into glibc.
-features = [ "gettext-system" ]
-
[dev-dependencies]
tempfile = "3"
proptest = "0.7"
diff -uNr newsboat-2.17/rust/libnewsboat/src/cliargsparser.rs newsboat-2.17.mod/rust/libnewsboat/src/cliargsparser.rs
--- newsboat-2.17/rust/libnewsboat/src/cliargsparser.rs 2019-09-22 17:19:19.000000000 +0300
+++ newsboat-2.17.mod/rust/libnewsboat/src/cliargsparser.rs 2019-09-24 20:56:44.030818719 +0300
@@ -1,5 +1,4 @@
use clap::{App, Arg};
-use gettextrs::gettext;
use libc::{EXIT_FAILURE, EXIT_SUCCESS};
use std::path::PathBuf;
@@ -282,7 +281,7 @@
}
_ => {
args.display_msg = fmt!(
- &gettext("%s: %s: invalid loglevel value"),
+ "%s: %s: invalid loglevel value",
&opts[0],
log_level_str
);
diff -uNr newsboat-2.17/rust/libnewsboat/src/lib.rs newsboat-2.17.mod/rust/libnewsboat/src/lib.rs
--- newsboat-2.17/rust/libnewsboat/src/lib.rs 2019-09-22 17:19:19.000000000 +0300
+++ newsboat-2.17.mod/rust/libnewsboat/src/lib.rs 2019-09-24 20:56:44.030818719 +0300
@@ -11,7 +11,6 @@
#[macro_use]
extern crate proptest;
extern crate clap;
-extern crate gettextrs;
extern crate libc;
// This module must be declared before the others because it exports a `log!` macro that everyone

View File

@ -1,10 +1,9 @@
TERMUX_PKG_HOMEPAGE=https://newsboat.org/
TERMUX_PKG_DESCRIPTION="RSS/Atom feed reader for the text console"
TERMUX_PKG_LICENSE="MIT"
TERMUX_PKG_VERSION=2.19
TERMUX_PKG_REVISION=3
TERMUX_PKG_VERSION=2.20.1
TERMUX_PKG_SRCURL=https://newsboat.org/releases/${TERMUX_PKG_VERSION}/newsboat-${TERMUX_PKG_VERSION}.tar.xz
TERMUX_PKG_SHA256=ba484c825bb903daf6d33d55126107b59e41111b455d368362208f1825403d1b
TERMUX_PKG_SHA256=82782079b75fe307f7a5a17dff9e712aa5975678fa550fb728d5a46867943566
TERMUX_PKG_DEPENDS="libc++, libiconv, libandroid-support, libandroid-glob, json-c, libsqlite, libcurl, libxml2, stfl, ncurses, openssl"
TERMUX_PKG_BUILD_IN_SRC=true
TERMUX_PKG_RM_AFTER_INSTALL="share/locale"

View File

@ -0,0 +1,24 @@
diff -u -r ../newsboat-2.20.1/rust/libnewsboat/Cargo.toml ./rust/libnewsboat/Cargo.toml
--- ../newsboat-2.20.1/rust/libnewsboat/Cargo.toml 2020-06-24 09:51:43.000000000 +0000
+++ ./rust/libnewsboat/Cargo.toml 2020-08-12 07:29:42.738724000 +0000
@@ -20,7 +20,6 @@
nom = "5"
curl-sys = "0.4.5"
libc = "0.2"
-gettext-rs = "0.4.1"
natord = "1.0.9"
# We don't use the following crates, but we pin their versions to make sure
@@ -43,12 +42,6 @@
# I want as little dependencies as practically possible.
default-features = false
-[dependencies.gettext-sys]
-version = "0.19.8"
-# Don't let the crate build its own copy of gettext; force it to use the one
-# built into glibc.
-features = [ "gettext-system" ]
-
[dev-dependencies]
tempfile = "3"
# 0.9.6 fixes build failures on Nightly >=2020-04-08: https://github.com/newsboat/newsboat/issues/870

View File

@ -0,0 +1,18 @@
diff -u -r ../newsboat-2.20.1/rust/libnewsboat/src/cliargsparser.rs ./rust/libnewsboat/src/cliargsparser.rs
--- ../newsboat-2.20.1/rust/libnewsboat/src/cliargsparser.rs 2020-06-24 09:51:43.000000000 +0000
+++ ./rust/libnewsboat/src/cliargsparser.rs 2020-08-12 07:29:06.630175000 +0000
@@ -1,5 +1,4 @@
use clap::{App, Arg};
-use gettextrs::gettext;
use libc::{EXIT_FAILURE, EXIT_SUCCESS};
use std::path::PathBuf;
@@ -286,7 +285,7 @@
}
_ => {
args.display_msg = fmt!(
- &gettext("%s: %s: invalid loglevel value"),
+ "%s: %s: invalid loglevel value",
&opts[0],
log_level_str
);

View File

@ -1,27 +1,28 @@
diff -u -r ../newsboat-2.18/rust/libnewsboat/src/configpaths.rs ./rust/libnewsboat/src/configpaths.rs
--- ../newsboat-2.18/rust/libnewsboat/src/configpaths.rs 2019-12-22 11:56:20.000000000 +0000
+++ ./rust/libnewsboat/src/configpaths.rs 2020-01-02 20:41:18.852245000 +0000
@@ -1,6 +1,5 @@
use cliargsparser::CliArgsParser;
diff -u -r ../newsboat-2.20.1/rust/libnewsboat/src/configpaths.rs ./rust/libnewsboat/src/configpaths.rs
--- ../newsboat-2.20.1/rust/libnewsboat/src/configpaths.rs 2020-06-24 09:51:43.000000000 +0000
+++ ./rust/libnewsboat/src/configpaths.rs 2020-08-12 07:28:22.784578000 +0000
@@ -2,7 +2,6 @@
use crate::logger::{self, Level};
use crate::utils;
use dirs;
-use gettextrs::gettext;
use libc;
use logger::{self, Level};
use std::fs::{self, DirBuilder};
@@ -69,11 +68,9 @@
use std::io;
@@ -84,11 +83,10 @@
let uid = unsafe { libc::getuid() };
config_paths.error_message = fmt!(
- &gettext(
"Fatal error: couldn't determine home directory!\n\
Please set the HOME environment variable or add \
- a valid user for UID %u!"
a valid user for UID %u!"
- ),
+ a valid user for UID %u!",
+ ,
uid
);
@@ -131,7 +128,7 @@
@@ -146,7 +144,7 @@
if !self.silent {
eprintln!(
"{}",
@ -30,7 +31,7 @@ diff -u -r ../newsboat-2.18/rust/libnewsboat/src/configpaths.rs ./rust/libnewsbo
);
}
@@ -187,7 +184,7 @@
@@ -202,7 +200,7 @@
if !self.silent {
eprintln!(
"{}",
@ -39,7 +40,7 @@ diff -u -r ../newsboat-2.18/rust/libnewsboat/src/configpaths.rs ./rust/libnewsbo
);
}
@@ -199,7 +196,7 @@
@@ -214,7 +212,7 @@
eprintln!(
"{}",
&fmt!(

View File

@ -0,0 +1,10 @@
diff -u -r ../newsboat-2.20.1/rust/regex-rs/Cargo.toml ./rust/regex-rs/Cargo.toml
--- ../newsboat-2.20.1/rust/regex-rs/Cargo.toml 2020-06-24 09:51:43.000000000 +0000
+++ ./rust/regex-rs/Cargo.toml 2020-08-12 07:44:18.635260000 +0000
@@ -11,5 +11,4 @@
strprintf = { path="../strprintf" }
bitflags = "1.0"
-libc = ">=0.2.69"
-gettext-rs = "0.4.1"
+libc = { git = "https://github.com/fornwall/libc", branch = "android-regex" }

View File

@ -0,0 +1,40 @@
diff -u -r ../newsboat-2.20.1/rust/regex-rs/src/lib.rs ./rust/regex-rs/src/lib.rs
--- ../newsboat-2.20.1/rust/regex-rs/src/lib.rs 2020-06-24 09:51:43.000000000 +0000
+++ ./rust/regex-rs/src/lib.rs 2020-08-12 07:26:30.707888000 +0000
@@ -29,7 +29,6 @@
//! ```
use bitflags::bitflags;
-use gettextrs::gettext;
use libc::{regcomp, regerror, regex_t, regexec, regfree, regmatch_t};
use std::ffi::{CString, OsString};
use std::mem;
@@ -155,12 +154,12 @@
} else {
match regex_error_to_str(errcode, &regex) {
Some(regcomp_errmsg) => {
- let msg = fmt!(&gettext("regcomp returned code %i"), errcode);
+ let msg = fmt!("regcomp returned code %i", errcode);
let msg = format!("{}: {}", msg, regcomp_errmsg);
Err(msg)
}
- None => Err(fmt!(&gettext("regcomp returned code %i"), errcode)),
+ None => Err(fmt!("regcomp returned code %i", errcode)),
}
}
}
@@ -240,11 +239,11 @@
_ => unsafe {
match regex_error_to_str(errcode, &self.regex) {
Some(regexec_errmsg) => {
- let msg = fmt!(&gettext("regexec returned code %i"), errcode);
+ let msg = fmt!("regexec returned code %i", errcode);
let msg = format!("{}: {}", msg, regexec_errmsg);
Err(msg)
}
- None => Err(fmt!(&gettext("regexec returned code %i"), errcode)),
+ None => Err(fmt!("regexec returned code %i", errcode)),
}
},
}