misc fix including solaris support
This commit is contained in:
parent
0ac566cfff
commit
3bddbb4989
5 changed files with 42 additions and 10 deletions
|
@ -1,7 +1,8 @@
|
|||
# $NetBSD: Makefile,v 1.9 2013/04/10 10:46:24 wiz Exp $
|
||||
# $NetBSD: Makefile,v 1.10 2013/08/15 12:40:06 richard Exp $
|
||||
#
|
||||
|
||||
DISTNAME= tree-1.6.0
|
||||
PKGREVISION= 1
|
||||
CATEGORIES= sysutils
|
||||
MASTER_SITES= ftp://mama.indstate.edu/linux/tree/
|
||||
EXTRACT_SUFX= .tgz
|
||||
|
@ -12,6 +13,10 @@ COMMENT= Print a text or HTML tree diagram of a directory structure
|
|||
LICENSE= gnu-gpl-v2
|
||||
|
||||
USE_TOOLS+= gmake
|
||||
NO_CONFIGURE= yes
|
||||
|
||||
CFLAGS+= -Wall -fomit-frame-pointer
|
||||
CFLAGS.linux+= -DLINUX -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64
|
||||
|
||||
MAKE_FLAGS+= prefix=${PREFIX:Q}
|
||||
MAKE_FLAGS+= CFLAGS=${CFLAGS:Q}
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
$NetBSD: distinfo,v 1.7 2013/04/10 10:46:24 wiz Exp $
|
||||
$NetBSD: distinfo,v 1.8 2013/08/15 12:40:06 richard Exp $
|
||||
|
||||
SHA1 (tree-1.6.0.tgz) = 350f851f68859a011668362dd0e7ee81fd1b713a
|
||||
RMD160 (tree-1.6.0.tgz) = d0e89f49fa902c7a72056d1a4ef826ddfee6be15
|
||||
Size (tree-1.6.0.tgz) = 42706 bytes
|
||||
SHA1 (patch-Makefile) = b2b29766bfa46ff7e061bcd7bcd0fc88f954d236
|
||||
SHA1 (patch-Makefile) = 068bd63827393400262ac345f2ee43f5ad417670
|
||||
SHA1 (patch-tree.c) = 0a110bc38fb1b0e498748d17c6327a0289321075
|
||||
SHA1 (patch-tree.h) = fbcf8a76dadfd5ea2d102c4e4863d5ce464786bd
|
||||
|
|
|
@ -1,8 +1,4 @@
|
|||
$NetBSD: patch-Makefile,v 1.1 2013/04/10 10:46:26 wiz Exp $
|
||||
|
||||
Fix build on systems lacking strverscmp.
|
||||
Remove -O4 (doesn't exist in most compilers).
|
||||
Fix DESTDIR.
|
||||
$NetBSD: patch-Makefile,v 1.2 2013/08/15 12:40:06 richard Exp $
|
||||
|
||||
--- Makefile.orig 2011-06-24 14:25:27.000000000 +0000
|
||||
+++ Makefile
|
||||
|
@ -11,8 +7,9 @@ Fix DESTDIR.
|
|||
# Linux defaults:
|
||||
#CFLAGS=-ggdb -Wall -DLINUX -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64
|
||||
-CFLAGS=-O4 -Wall -DLINUX -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64
|
||||
+CFLAGS=-DLINUX -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64
|
||||
LDFLAGS=-s
|
||||
-LDFLAGS=-s
|
||||
+#CFLAGS=-DLINUX -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64
|
||||
+#LDFLAGS=-s
|
||||
|
||||
# Uncomment for FreeBSD:
|
||||
#CFLAGS=-O2 -Wall -fomit-frame-pointer
|
||||
|
|
13
sysutils/tree/patches/patch-tree.c
Normal file
13
sysutils/tree/patches/patch-tree.c
Normal file
|
@ -0,0 +1,13 @@
|
|||
$NetBSD: patch-tree.c,v 1.1 2013/08/15 12:40:06 richard Exp $
|
||||
|
||||
--- tree.c.orig 2011-06-24 14:26:30.000000000 +0000
|
||||
+++ tree.c
|
||||
@@ -45,7 +45,7 @@ int mb_cur_max;
|
||||
#ifdef __EMX__
|
||||
const u_short ifmt[]={ FILE_ARCHIVED, FILE_DIRECTORY, FILE_SYSTEM, FILE_HIDDEN, FILE_READONLY, 0};
|
||||
#else
|
||||
- #ifdef S_ISPORT
|
||||
+ #if defined(S_ISPORT) && defined(S_ISDOOR)
|
||||
const u_int ifmt[] = {S_IFREG, S_IFDIR, S_IFLNK, S_IFCHR, S_IFBLK, S_IFSOCK, S_IFIFO, S_ISDOOR, S_ISPORT, 0};
|
||||
const char fmt[] = "-dlcbspDP?";
|
||||
const char *ftype[] = {"file", "directory", "link", "char", "block", "socket", "fifo", "door", "port", "unknown", NULL};
|
15
sysutils/tree/patches/patch-tree.h
Normal file
15
sysutils/tree/patches/patch-tree.h
Normal file
|
@ -0,0 +1,15 @@
|
|||
$NetBSD: patch-tree.h,v 1.1 2013/08/15 12:40:06 richard Exp $
|
||||
|
||||
--- tree.h.orig 2011-06-24 12:55:58.000000000 +0000
|
||||
+++ tree.h
|
||||
@@ -59,6 +59,10 @@
|
||||
#define mbstowcs(w,m,x) mbsrtowcs(w,(const char**)(& #m),x,NULL)
|
||||
#endif
|
||||
|
||||
+#ifdef __sun
|
||||
+# undef S_ISDOOR
|
||||
+#endif
|
||||
+
|
||||
/* Should probably use strdup(), but we like our xmalloc() */
|
||||
#define scopy(x) strcpy(xmalloc(strlen(x)+1),(x))
|
||||
#define MINIT 30 /* number of dir entries to initially allocate */
|
Loading…
Reference in a new issue