Honored PKGMANDIR and made it works on FreeBSD.

This commit is contained in:
Claudio M. Alessi 2008-02-23 14:36:41 +00:00 committed by Thomas Klausner
parent 0234bfb56f
commit cf8db382a2
4 changed files with 33 additions and 19 deletions

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.2 2008/02/23 13:50:52 smoppy Exp $
# $NetBSD: Makefile,v 1.3 2008/02/23 14:36:41 smoppy Exp $
DISTNAME= tmux-0.1
CATEGORIES= misc
@ -11,15 +11,6 @@ COMMENT= BSD-licensed terminal multiplexer (GNU Screen alternative)
NO_CONFIGURE= yes
USE_NCURSES= # uses ncurses internals
.if 0
# Makefile
SUBST_CLASSES= makefile
SUBST_STAGE.makefile= pre-build
SUBST_MESSAGE.makefile= Fixing distribution Makefile..
SUBST_FILES.makefile= ${MAKE_FILE}
SUBST_SED.makefile= -e "s,/man/,/${PKGMANDIR}/,"
# Preferences handling framework
.include "../../mk/bsd.prefs.mk"
@ -28,8 +19,6 @@ SUBST_SED.makefile= -e "s,/man/,/${PKGMANDIR}/,"
SUBST_SED.makefile+= -e 's/-g bin -o root/-o ${UNPRIVILEGED_USER} -g ${UNPRIVILEGED_GROUP}/g'
.endif
.endif
# compat/strtonum.c: replace "tmux.h" with "../tmux.h"
SUBST_CLASSES+= header
SUBST_STAGE.header= pre-build
@ -37,5 +26,9 @@ SUBST_MESSAGE.header= Fixing distribution headers..
SUBST_FILES.header= compat/strtonum.c
SUBST_SED.header= -e "s,tmux.h,../tmux.h,"
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/tmux ${DESTDIR}${PREFIX}/bin
${INSTALL_MAN} ${WRKSRC}/tmux.1 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1
.include "../../devel/ncurses/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"

View file

@ -1,7 +1,7 @@
$NetBSD: distinfo,v 1.2 2008/02/23 13:50:52 smoppy Exp $
$NetBSD: distinfo,v 1.3 2008/02/23 14:36:41 smoppy Exp $
SHA1 (tmux-0.1.tar.gz) = 4f370fc76eb106254db6e0f656b2c15ee9b7fd55
RMD160 (tmux-0.1.tar.gz) = 1a3b9e8a7497eea38c95faa9ff7ff4e07e45f3f9
Size (tmux-0.1.tar.gz) = 65968 bytes
SHA1 (patch-aa) = e7ab219e5d72e4262fc7ae9e61a1445573e6ca6f
SHA1 (patch-ab) = 530cf044fda20a7c76873b8b1883f097965d1350
SHA1 (patch-ab) = 6c387f34c97df7ec7513be70d345bca8ac50ba03

View file

@ -1,6 +1,6 @@
--- local.c.orig 2008-02-23 00:51:34.000000000 +0100
+++ local.c 2008-02-23 00:53:14.000000000 +0100
@@ -19,14 +19,18 @@
--- local.c.orig 2008-02-23 14:26:12.000000000 +0100
+++ local.c 2008-02-23 14:26:34.000000000 +0100
@@ -19,15 +19,19 @@
#include <sys/types.h>
#include <sys/ioctl.h>
@ -9,14 +9,15 @@
#include <fcntl.h>
#include <stdlib.h>
#include <string.h>
+#ifndef _KERNEL
+#if !defined(_KERNEL)
+# define _KERNEL
+#endif
#define TTYDEFCHARS
/* glibc requires unistd.h before termios.h for TTYDEFCHARS. */
#include <unistd.h>
#include <termios.h>
+#undef _KERNEL
#include <term.h>
+#undef _KERNEL
#include "tmux.h"

20
tmux/patches/patch-ab Normal file
View file

@ -0,0 +1,20 @@
--- Makefile.orig 2008-02-23 15:21:17.000000000 +0100
+++ Makefile 2008-02-23 15:22:03.000000000 +0100
@@ -29,7 +29,7 @@
cmd-switch-client.c
CC?= cc
-INCDIRS+= -I. -I- -I/usr/local/include
+INCDIRS+= -I. -I/usr/local/include
CFLAGS+= -DBUILD="\"$(VERSION) ($(DATE))\"" -DMETA="'${META}'"
.ifdef PROFILE
# Don't use ccache
@@ -61,7 +61,7 @@
CFLAGS+= -DUSE_LIBUTIL_H
.endif
-OBJS= ${SRCS:S/.c/.o/:S/.y/.o/}
+OBJS= ${SRCS:S/.c/.o/:S/.y/.o/} compat/strtonum.c
DISTDIR= ${PROG}-${VERSION}
DISTFILES= *.[chyl] Makefile GNUmakefile *.[1-9] NOTES TODO \