diff options
author | marino <marino@FreeBSD.org> | 2016-02-05 20:02:37 +0800 |
---|---|---|
committer | marino <marino@FreeBSD.org> | 2016-02-05 20:02:37 +0800 |
commit | 08b3dbdf6469e0cb936e9875197eb9711164ca3c (patch) | |
tree | 02b7ad50454388f2ab9f3252f6e24fd01a8870c7 /net | |
parent | 01670fe8ec1b39dd0db54231b8072a263cdaed51 (diff) | |
download | freebsd-ports-gnome-08b3dbdf6469e0cb936e9875197eb9711164ca3c.tar.gz freebsd-ports-gnome-08b3dbdf6469e0cb936e9875197eb9711164ca3c.tar.zst freebsd-ports-gnome-08b3dbdf6469e0cb936e9875197eb9711164ca3c.zip |
net/cnd: document ncurses requirement (USES+=ncurses), respect LDFLAGS
Both patches got regenerated with makepatch in the process.
approved by: infrastructure blanket
Diffstat (limited to 'net')
-rw-r--r-- | net/cnd/Makefile | 1 | ||||
-rw-r--r-- | net/cnd/files/patch-Makefile | 6 | ||||
-rw-r--r-- | net/cnd/files/patch-main.c | 23 |
3 files changed, 15 insertions, 15 deletions
diff --git a/net/cnd/Makefile b/net/cnd/Makefile index bbdbf623a273..e40b88ef3c32 100644 --- a/net/cnd/Makefile +++ b/net/cnd/Makefile @@ -10,6 +10,7 @@ MASTER_SITES= http://www.bsd-geek.de/FreeBSD/distfiles/ MAINTAINER= lme@FreeBSD.org COMMENT= Console network display +USES= ncurses PLIST_FILES= bin/cnd do-install: diff --git a/net/cnd/files/patch-Makefile b/net/cnd/files/patch-Makefile index f71603ee1c27..a8a14f572503 100644 --- a/net/cnd/files/patch-Makefile +++ b/net/cnd/files/patch-Makefile @@ -1,5 +1,5 @@ ---- Makefile.orig 2005-03-03 08:59:05.000000000 +0300 -+++ Makefile 2014-10-02 18:10:01.000000000 +0400 +--- Makefile.orig 2005-03-03 05:59:05 UTC ++++ Makefile @@ -1,10 +1,10 @@ -CC = cc +CC ?= cc @@ -9,7 +9,7 @@ all: $(OBJS) - $(CC) $(CFLAGS) -o cnd $(OBJS) -lcurses -lkvm -+ $(CC) $(CFLAGS) -o cnd $(OBJS) -lcurses ++ $(CC) $(CFLAGS) -o cnd $(OBJS) $(LDFLAGS) -lncurses .c.o: $(CC) $(CFLAGS) -c -I/usr/include/ -o $@ $< .SUFFIXS: .c .o diff --git a/net/cnd/files/patch-main.c b/net/cnd/files/patch-main.c index ea4b09eaf177..f5c6fcebc800 100644 --- a/net/cnd/files/patch-main.c +++ b/net/cnd/files/patch-main.c @@ -1,5 +1,5 @@ ---- main.c.orig 2014-10-02 17:44:25.000000000 +0400 -+++ main.c 2014-10-02 18:08:23.000000000 +0400 +--- main.c.orig 2005-04-22 16:13:05 UTC ++++ main.c @@ -41,14 +41,13 @@ #include <sys/time.h> #include <stdarg.h> @@ -39,7 +39,7 @@ int winw,winh; WINDOW *mainw; -@@ -173,7 +161,6 @@ +@@ -173,7 +161,6 @@ void screen_init() { getmaxyx(stdscr,winh,winw); if(winh < 20 || winw < 20) { endwin(); @@ -47,7 +47,7 @@ fprintf(stderr,"Screen size is too small, sorry\n"); exit(1); } -@@ -241,35 +228,37 @@ +@@ -241,35 +228,37 @@ void screen_check() { return; } @@ -110,7 +110,7 @@ } int main(int argc, char *argv[]) { -@@ -280,9 +269,6 @@ +@@ -280,9 +269,6 @@ int main(int argc, char *argv[]) { unsigned long curo = 0; #define CURIS curi / timea.tv_sec #define CUROS curo / timea.tv_sec @@ -120,7 +120,7 @@ int i = 0; int x = 0; int j = 0; -@@ -393,48 +379,10 @@ +@@ -393,48 +379,10 @@ int main(int argc, char *argv[]) { argc -= optind; argv += optind; @@ -156,7 +156,7 @@ - } - if(kread(ifnetaddr,(char *)&foonet,sizeof foonet)) - return 1; -- + -#if __FreeBSD_version >= 501113 - strncpy(name,foonet.if_xname,sizeof(name)); -#else @@ -166,13 +166,12 @@ -#endif - - } -+ + readstat(&lasti, &lasto); + gettimeofday(&last,NULL); /* start curses */ initscr(); -@@ -486,37 +434,32 @@ +@@ -486,37 +434,32 @@ int main(int argc, char *argv[]) { } /* screen init.. */ screen_init(); @@ -218,7 +217,7 @@ in_total += curi; out_total += curo; -@@ -569,7 +512,6 @@ +@@ -569,7 +512,6 @@ int main(int argc, char *argv[]) { logi[i] = (unsigned int *)malloc(sizeof(unsigned int)); if(logi[i] == NULL) { fprintf(stderr,"error,allocating memory\n"); @@ -226,7 +225,7 @@ endwin(); exit(1); } -@@ -583,7 +525,6 @@ +@@ -583,7 +525,6 @@ int main(int argc, char *argv[]) { logo[i] = (unsigned int *)malloc(sizeof(unsigned int)); if(logo[i] == NULL) { fprintf(stderr,"error,allocating memory\n"); @@ -234,7 +233,7 @@ endwin(); exit(1); } -@@ -648,9 +589,8 @@ +@@ -648,9 +589,8 @@ int main(int argc, char *argv[]) { gettimeofday(&last,NULL); select(0,NULL,NULL,NULL,&timea); |