[arch-commits] Commit in liboping/trunk (PKGBUILD ncursesw.patch)

Gaëtan Bisson bisson at archlinux.org
Wed Jun 13 18:56:12 UTC 2018


    Date: Wednesday, June 13, 2018 @ 18:56:11
  Author: bisson
Revision: 342923

fix FS#58978

Added:
  liboping/trunk/ncursesw.patch
Modified:
  liboping/trunk/PKGBUILD

----------------+
 PKGBUILD       |   23 +++++++++++++++++------
 ncursesw.patch |   21 +++++++++++++++++++++
 2 files changed, 38 insertions(+), 6 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2018-06-13 18:42:20 UTC (rev 342922)
+++ PKGBUILD	2018-06-13 18:56:11 UTC (rev 342923)
@@ -3,7 +3,7 @@
 
 pkgname=liboping
 pkgver=1.10.0
-pkgrel=3
+pkgrel=4
 pkgdesc='C library to generate ICMP echo requests, better known as "ping packets"'
 url='https://noping.cc/'
 arch=('x86_64')
@@ -12,18 +12,29 @@
 makedepends=('ncurses')
 optdepends=('perl: perl bindings'
             'ncurses: noping CLI tool')
-source=("${url}files/${pkgname}-${pkgver}.tar.bz2")
-sha256sums=('eb38aa93f93e8ab282d97e2582fbaea88b3f889a08cbc9dbf20059c3779d5cd8')
+source=("${url}files/${pkgname}-${pkgver}.tar.bz2"
+        'ncursesw.patch')
+sha256sums=('eb38aa93f93e8ab282d97e2582fbaea88b3f889a08cbc9dbf20059c3779d5cd8'
+            '64db954250e7cd4f77ed28d0d4f3deb1525ebe4145c6b20caafc2459c8b1c780')
 
 install=install
 
-build() {
+prepare() {
 	cd "${srcdir}/${pkgname}-${pkgver}"
 
-	# setting capabilities/setuid is futile in fakeroot
-	# (we do that in the install script)
+	# Setting capabilities/setuid is futile in fakeroot.
+	# (We do that in the install script.)
 	sed -i 's/ install-exec-hook//g' src/Makefile.in
 
+	# Our ncurses has full UTF8 support although not called ncursesw.
+	patch -p1 -i ../ncursesw.patch
+
+	# Be serious.
+	sed '/-Wall -Werror/d' -i src/Makefile.*
+}
+
+build() {
+	cd "${srcdir}/${pkgname}-${pkgver}"
 	./configure --prefix=/usr --with-perl-bindings='INSTALLDIRS=vendor'
 	make
 }

Added: ncursesw.patch
===================================================================
--- ncursesw.patch	                        (rev 0)
+++ ncursesw.patch	2018-06-13 18:56:11 UTC (rev 342923)
@@ -0,0 +1,21 @@
+diff -Naur old/src/oping.c new/src/oping.c
+--- old/src/oping.c	2017-05-10 21:32:27.000000000 -1000
++++ new/src/oping.c	2018-06-13 08:29:44.887061003 -1000
+@@ -903,7 +903,6 @@
+ #if USE_NCURSES
+ static _Bool has_utf8() /* {{{ */
+ {
+-# if HAVE_NCURSESW_NCURSES_H
+ 	if (!opt_utf8)
+ 	{
+ 		/* Automatically determine */
+@@ -913,9 +912,6 @@
+ 			opt_utf8 = 1;
+ 	}
+ 	return ((_Bool) (opt_utf8 - 1));
+-# else
+-	return (0);
+-# endif
+ } /* }}} _Bool has_utf8 */
+ 
+ static int update_graph_boxplot (ping_context_t *ctx) /* {{{ */



More information about the arch-commits mailing list