pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/misc/watch Made the package work again on Solaris.
details: https://anonhg.NetBSD.org/pkgsrc/rev/5b041bdba813
branches: trunk
changeset: 520694:5b041bdba813
user: rillig <rillig%pkgsrc.org@localhost>
date: Wed Oct 25 21:37:51 2006 +0000
description:
Made the package work again on Solaris.
diffstat:
misc/watch/Makefile | 11 ++++++-----
misc/watch/files/Makefile | 8 ++------
misc/watch/patches/patch-ab | 29 +++++++++++++++++++++++------
3 files changed, 31 insertions(+), 17 deletions(-)
diffs (95 lines):
diff -r ad8433cc5462 -r 5b041bdba813 misc/watch/Makefile
--- a/misc/watch/Makefile Wed Oct 25 21:33:59 2006 +0000
+++ b/misc/watch/Makefile Wed Oct 25 21:37:51 2006 +0000
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.8 2006/09/09 02:43:11 obache Exp $
+# $NetBSD: Makefile,v 1.9 2006/10/25 21:37:51 rillig Exp $
DISTNAME= procps-3.2.6
+PKGNAME= watch-3.2.6
PKGREVISION= 1
-PKGNAME= ${DISTNAME:S/procps/watch/}
CATEGORIES= misc
MASTER_SITES= http://procps.sourceforge.net/
@@ -10,9 +10,10 @@
COMMENT= Watch a program with update intervals
MAKE_FILE= ${FILESDIR}/Makefile
-MAKE_ENV+= BINOWN=${BINOWN:Q} BINGRP=${BINGRP:Q}
-MAKE_ENV+= MANOWN=${MANOWN:Q} MANGRP=${MANGRP:Q}
+MAKE_ENV+= ${BSD_MAKE_ENV}
+MAKE_ENV+= LIBS=${LIBS}
+
+LIBS.SunOS+= -lrt
.include "../../devel/ncurses/buildlink3.mk"
-
.include "../../mk/bsd.pkg.mk"
diff -r ad8433cc5462 -r 5b041bdba813 misc/watch/files/Makefile
--- a/misc/watch/files/Makefile Wed Oct 25 21:33:59 2006 +0000
+++ b/misc/watch/files/Makefile Wed Oct 25 21:37:51 2006 +0000
@@ -1,10 +1,6 @@
-# $NetBSD: Makefile,v 1.1.1.1 1999/06/16 01:32:51 simonb Exp $
+# $NetBSD: Makefile,v 1.2 2006/10/25 21:37:51 rillig Exp $
PROG= watch
-LDADD+= -lcurses
-DPADD+= ${LIBCURSES}
-
-BINDIR= ${PREFIX}/bin
-MANDIR= ${PREFIX}/man
+LDADD+= -lncurses ${LIBS}
.include <bsd.prog.mk>
diff -r ad8433cc5462 -r 5b041bdba813 misc/watch/patches/patch-ab
--- a/misc/watch/patches/patch-ab Wed Oct 25 21:33:59 2006 +0000
+++ b/misc/watch/patches/patch-ab Wed Oct 25 21:37:51 2006 +0000
@@ -1,8 +1,8 @@
-$NetBSD: patch-ab,v 1.1 2006/07/11 16:35:24 smb Exp $
+$NetBSD: patch-ab,v 1.2 2006/10/25 21:37:51 rillig Exp $
---- watch.c.orig 2006-07-09 20:58:47.000000000 -0400
-+++ watch.c 2006-07-09 21:01:56.000000000 -0400
-@@ -142,6 +142,7 @@
+--- watch.c.orig 2006-10-25 23:13:48.793523972 +0200
++++ watch.c 2006-10-25 23:25:56.542821832 +0200
+@@ -142,6 +142,7 @@ main(int argc, char *argv[])
option_differences_cumulative = 0,
option_help = 0, option_version = 0;
float interval = 2;
@@ -10,7 +10,7 @@
char *command;
int command_length = 0; /* not including final \0 */
-@@ -201,6 +202,9 @@
+@@ -199,6 +200,9 @@ main(int argc, char *argv[])
if (optind >= argc)
do_usage();
@@ -20,7 +20,24 @@
command = strdup(argv[optind++]);
command_length = strlen(command);
for (; optind < argc; optind++) {
-@@ -315,7 +319,7 @@
+@@ -246,10 +250,16 @@ main(int argc, char *argv[])
+ }
+
+ if (show_title) {
++#if defined(__sun)
++ header = malloc(width + 1);
++ if (!header) { perror("malloc"); do_exit(2); }
++ snprintf(header, width + 1, "Every %.1fs: %s", interval, command);
++#else
+ // left justify interval and command,
+ // right justify time, clipping all to fit window width
+ asprintf(&header, "Every %.1fs: %.*s",
+ interval, min(width - 1, command_length), command);
++#endif
+ mvaddstr(0, 0, header);
+ if (strlen(header) > (size_t) (width - tsl - 1))
+ mvaddstr(0, width - tsl - 4, "... ");
+@@ -313,7 +323,7 @@ main(int argc, char *argv[])
first_screen = 0;
refresh();
Home |
Main Index |
Thread Index |
Old Index