Update "watch" package to version 3.2.6 (taken from "procps-3.2.6"
distribution). The new versions supports a lot of new command line options for e.g. cumulative or sub second intervals.
This commit is contained in:
parent
b2bede7c6c
commit
8b8715665e
3 changed files with 25 additions and 52 deletions
|
@ -1,12 +1,9 @@
|
|||
# $NetBSD: Makefile,v 1.5 2006/02/12 18:57:21 rillig Exp $
|
||||
#
|
||||
# $NetBSD: Makefile,v 1.6 2006/05/15 16:01:03 tron Exp $
|
||||
|
||||
DISTNAME= procps-2.0.2
|
||||
PKGNAME= watch-2.0.2
|
||||
PKGREVISION= 1
|
||||
DISTNAME= procps-3.2.6
|
||||
PKGNAME= ${DISTNAME:S/procps/watch/}
|
||||
CATEGORIES= misc
|
||||
MASTER_SITES= ftp://ftp.slackware.org/pub/linux/slackware/source/a/procps/ \
|
||||
${MASTER_SITE_SUNSITE:=slackware/source/a/procps/}
|
||||
MASTER_SITES= http://procps.sourceforge.net/
|
||||
|
||||
MAINTAINER= simonb@NetBSD.org
|
||||
COMMENT= Watch a program with update intervals
|
||||
|
@ -15,4 +12,6 @@ MAKEFILE= ${FILESDIR}/Makefile
|
|||
MAKE_ENV+= BINOWN=${BINOWN:Q} BINGRP=${BINGRP:Q}
|
||||
MAKE_ENV+= MANOWN=${MANOWN:Q} MANGRP=${MANGRP:Q}
|
||||
|
||||
.include "../../devel/ncurses/buildlink3.mk"
|
||||
|
||||
.include "../../mk/bsd.pkg.mk"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
$NetBSD: distinfo,v 1.3 2005/02/24 11:02:58 agc Exp $
|
||||
$NetBSD: distinfo,v 1.4 2006/05/15 16:01:03 tron Exp $
|
||||
|
||||
SHA1 (procps-2.0.2.tar.gz) = ee7af08ec5fda08b43a909a5c2305e1727788868
|
||||
RMD160 (procps-2.0.2.tar.gz) = a913e06eb4256682bbc30b348ab05f9d44bbed61
|
||||
Size (procps-2.0.2.tar.gz) = 181793 bytes
|
||||
SHA1 (patch-aa) = 1b2374757d7f55d70252f21559bcdd74e3872c46
|
||||
SHA1 (procps-3.2.6.tar.gz) = 91f44180eb50a94eb945c2598c0e849879e65893
|
||||
RMD160 (procps-3.2.6.tar.gz) = f0b09701ce48d9f6db1cbb209b02ba026ee58d09
|
||||
Size (procps-3.2.6.tar.gz) = 279084 bytes
|
||||
SHA1 (patch-aa) = 953dcd9c3287fec91ac7c585ad9dff4b7ec50cf7
|
||||
|
|
|
@ -1,41 +1,15 @@
|
|||
$NetBSD: patch-aa,v 1.2 1999/11/27 17:12:43 hubertf Exp $
|
||||
$NetBSD: patch-aa,v 1.3 2006/05/15 16:01:03 tron Exp $
|
||||
|
||||
--- watch.c.orig Sun Mar 21 18:49:20 1999
|
||||
+++ watch.c Sat Nov 27 18:10:34 1999
|
||||
@@ -6,7 +6,7 @@
|
||||
* Slighty modified, and corrected, Francois Pinard, 91-04.
|
||||
*/
|
||||
|
||||
-#include <ncurses.h>
|
||||
+#include <curses.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
@@ -17,10 +17,15 @@
|
||||
int die_flag;
|
||||
void die ();
|
||||
|
||||
+#ifdef __NetBSD__
|
||||
+#include <sys/types.h>
|
||||
+#include <time.h>
|
||||
+#else
|
||||
extern FILE *popen ();
|
||||
extern int pclose ();
|
||||
extern long time ();
|
||||
extern char *ctime ();
|
||||
+#endif
|
||||
|
||||
/*-----------------------------------------.
|
||||
* Decode parameters and launch execution. |
|
||||
@@ -38,7 +43,11 @@
|
||||
char buf[180];
|
||||
char cmd[128];
|
||||
int count = 1;
|
||||
+#ifdef __NetBSD__
|
||||
+ time_t timer;
|
||||
+#else
|
||||
long timer;
|
||||
+#endif
|
||||
int nsecs = 2;
|
||||
int total_chars;
|
||||
|
||||
--- watch.c.orig 2005-10-30 00:44:53.000000000 +0100
|
||||
+++ watch.c 2006-05-15 16:49:04.000000000 +0100
|
||||
@@ -164,9 +164,7 @@
|
||||
break;
|
||||
case 'n':
|
||||
{
|
||||
- char *str;
|
||||
- interval = strtof(optarg, &str);
|
||||
- if (!*optarg || *str)
|
||||
+ if (sscanf(optarg, "%f", &interval) != 1)
|
||||
do_usage();
|
||||
if(interval < 0.1)
|
||||
interval = 0.1;
|
||||
|
|
Loading…
Reference in a new issue