From 912da8491dcff042e06e984c6853abb9cc8af23f Mon Sep 17 00:00:00 2001 From: minskim Date: Thu, 4 Jun 2009 21:49:18 +0000 Subject: Make misc/tmux build on SunOS. --- misc/tmux/distinfo | 6 ++++-- misc/tmux/patches/patch-aa | 36 +++++++++++++++++++++++++++--------- misc/tmux/patches/patch-ab | 14 ++++++++++++++ misc/tmux/patches/patch-ac | 14 ++++++++++++++ 4 files changed, 59 insertions(+), 11 deletions(-) create mode 100644 misc/tmux/patches/patch-ab create mode 100644 misc/tmux/patches/patch-ac (limited to 'misc/tmux') diff --git a/misc/tmux/distinfo b/misc/tmux/distinfo index 8acc99fc726..5d7621b6fa2 100644 --- a/misc/tmux/distinfo +++ b/misc/tmux/distinfo @@ -1,6 +1,8 @@ -$NetBSD: distinfo,v 1.4 2009/06/03 06:09:11 minskim Exp $ +$NetBSD: distinfo,v 1.5 2009/06/04 21:49:18 minskim Exp $ SHA1 (tmux-0.8.tar.gz) = 87a9db829ff36cc432114672f7354a74d673832b RMD160 (tmux-0.8.tar.gz) = 81f828e0af59a994e0b4ba86ab17421ffd7d7e98 Size (tmux-0.8.tar.gz) = 175515 bytes -SHA1 (patch-aa) = 74bbf3eb3a70e54645d3d0eb31cbcdfa7e1f0781 +SHA1 (patch-aa) = c634803fb173803ee7470eb29ad13eb0cb287a17 +SHA1 (patch-ab) = 713c4beb17bf2a250fdd26e458d8621c1bfb2c79 +SHA1 (patch-ac) = d99a96c138d4aea84f8d78ff947d6e5411fc0ecf diff --git a/misc/tmux/patches/patch-aa b/misc/tmux/patches/patch-aa index c722053199f..f44622a7f8b 100644 --- a/misc/tmux/patches/patch-aa +++ b/misc/tmux/patches/patch-aa @@ -1,21 +1,28 @@ -$NetBSD: patch-aa,v 1.4 2009/06/03 06:09:11 minskim Exp $ +$NetBSD: patch-aa,v 1.5 2009/06/04 21:49:18 minskim Exp $ ---- Makefile.orig 2009-04-27 17:38:18.000000000 +0200 +--- Makefile.orig 2009-04-21 13:10:22.000000000 -0700 +++ Makefile -@@ -81,6 +81,12 @@ LDFLAGS+= -pg +@@ -79,7 +79,18 @@ LDFLAGS+= -L/usr/local/lib + .ifdef PROFILE + LDFLAGS+= -pg .endif - LIBS+= -lutil -lncurses - +-LIBS+= -lutil -lncurses ++.if ${OS} == "SunOS" ++LIBS+= -lsocket -lnsl ++.else ++LIBS+= -lutil ++.endif ++LIBS+= -lncurses ++ +# Darwin +.if ${OS} == "Darwin" +SRCS+= compat/strtonum.c compat/vis.c +CFLAGS+= -DNO_SETPROCTITLE -DNO_STRTONUM -DNO_QUEUE_H -DNO_TREE_H +.endif -+ + # FreeBSD and DragonFly .if ${OS} == "FreeBSD" || ${OS} == "DragonFly" - INCDIRS+= -Icompat -@@ -91,10 +97,10 @@ LIBS+= -lcrypt +@@ -91,10 +102,21 @@ LIBS+= -lcrypt # NetBSD .if ${OS} == "NetBSD" @@ -25,10 +32,21 @@ $NetBSD: patch-aa,v 1.4 2009/06/03 06:09:11 minskim Exp $ LIBS+= -lcrypt -CFLAGS+=-DNO_STRTONUM +CFLAGS+=-DNO_STRTONUM -DNO_QUEUE_H -DNO_TREE_H ++.endif ++ ++# SunOS ++.if ${OS} == "SunOS" ++INCDIRS+= -Icompat ++SRCS+= compat/asprintf.c compat/daemon.c compat/fgetln.c \ ++ compat/forkpty-sunos.c compat/getopt_long.c compat/strtonum.c \ ++ compat/vis.c ++CFLAGS+= -DNO_ASPRINTF -DNO_CDEFS_H -DNO_DAEMON -DNO_FGETLN -DNO_FORKPTY \ ++ -DNO_PATHS_H -DNO_PROGNAME -DNO_QUEUE_H -DNO_SETPROCTITLE \ ++ -DNO_STRTONUM -DNO_TREE_H .endif OBJS= ${SRCS:S/.c/.o/:S/.y/.o/} -@@ -152,7 +158,7 @@ update-index.html: +@@ -152,7 +174,7 @@ update-index.html: sed "s/%%VERSION%%/${VERSION}/g" index.html.in >index.html install: all diff --git a/misc/tmux/patches/patch-ab b/misc/tmux/patches/patch-ab new file mode 100644 index 00000000000..74051aa6383 --- /dev/null +++ b/misc/tmux/patches/patch-ab @@ -0,0 +1,14 @@ +$NetBSD: patch-ab,v 1.3 2009/06/04 21:49:18 minskim Exp $ + +--- compat/getopt.h.orig 2009-03-31 21:21:36.000000000 +0000 ++++ compat/getopt.h +@@ -33,7 +33,9 @@ + #ifndef _GETOPT_H_ + #define _GETOPT_H_ + ++#ifndef NO_CDEFS_H + #include ++#endif + + /* + * GNU-like getopt_long() and 4.4BSD getsubopt()/optreset extensions diff --git a/misc/tmux/patches/patch-ac b/misc/tmux/patches/patch-ac new file mode 100644 index 00000000000..effc5a6268b --- /dev/null +++ b/misc/tmux/patches/patch-ac @@ -0,0 +1,14 @@ +$NetBSD: patch-ac,v 1.3 2009/06/04 21:49:18 minskim Exp $ + +--- compat/vis.h.orig 2009-03-31 21:21:28.000000000 +0000 ++++ compat/vis.h +@@ -71,7 +71,9 @@ + */ + #define UNVIS_END 1 /* no more characters */ + ++#ifndef NO_CDEFS_H + #include ++#endif + + char *vis(char *, int, int, int); + int strvis(char *, const char *, int); -- cgit v1.2.3