pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Import nnn



Module Name:	pkgsrc-wip
Committed By:	Sijmen J. Mulder <ik%sjmulder.nl@localhost>
Pushed By:	sjmulder
Date:		Sun Dec 16 20:15:42 2018 +0100
Changeset:	e1f71dbd6716370cb0a1b1ac45ea3b9c42dfa9c2

Added Files:
	nnn/DESCR
	nnn/Makefile
	nnn/PLIST
	nnn/TODO
	nnn/distinfo
	nnn/patches/patch-Makefile

Log Message:
Import nnn

nnn is probably the fastest and most resource-sensitive file manager
you have ever used. It integrates seamlessly with your DE and favourite
GUI utilities, has a unique navigate-as-you-type mode with auto-select,
disk usage analyzer mode, bookmarks, contexts, application launcher,
familiar navigation shortcuts, subshell spawning and much more.

Integrate utilities like sxiv or fzy easily, transfer selected files
using lftp or use it as a (neo)vim plugin; nnn supports as many scripts
as you need!

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=e1f71dbd6716370cb0a1b1ac45ea3b9c42dfa9c2

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 nnn/DESCR                  |  8 +++++++
 nnn/Makefile               | 22 +++++++++++++++++++
 nnn/PLIST                  |  3 +++
 nnn/TODO                   |  7 ++++++
 nnn/distinfo               |  7 ++++++
 nnn/patches/patch-Makefile | 55 ++++++++++++++++++++++++++++++++++++++++++++++
 6 files changed, 102 insertions(+)

diffs:
diff --git a/nnn/DESCR b/nnn/DESCR
new file mode 100644
index 0000000000..f1e14db212
--- /dev/null
+++ b/nnn/DESCR
@@ -0,0 +1,8 @@
+nnn is probably the fastest and most resource-sensitive file manager you have
+ever used. It integrates seamlessly with your DE and favourite GUI utilities,
+has a unique navigate-as-you-type mode with auto-select, disk usage analyzer
+mode, bookmarks, contexts, application launcher, familiar navigation shortcuts,
+subshell spawning and much more.
+
+Integrate utilities like sxiv or fzy easily, transfer selected files using
+lftp or use it as a (neo)vim plugin; nnn supports as many scripts as you need!
diff --git a/nnn/Makefile b/nnn/Makefile
new file mode 100644
index 0000000000..8db570cf28
--- /dev/null
+++ b/nnn/Makefile
@@ -0,0 +1,22 @@
+# $NetBSD$
+
+DISTNAME=	nnn-2.1
+CATEGORIES=	sysutils
+MASTER_SITES=	${MASTER_SITE_GITHUB:=jarun/}
+GITHUB_TAG=	v${PKGVERSION_NOREV}
+
+MAINTAINER=	ik%sjmulder.nl@localhost
+HOMEPAGE=	https://github.com/jarun/nnn/
+COMMENT=	Optimized, feature-packed terminal file manager
+LICENSE=	2-clause-bsd
+
+USE_TOOLS+=	gmake pkg-config
+USE_CURSES=	wide
+
+MAKE_ENV+=	MANPREFIX=${PREFIX}/${PKGMANDIR}
+MAKE_ENV+=	CFLAGS_OPTIMIZATION=
+MAKE_ENV+=	CFLAGS_CURSES=${BUILDLINK_CFLAGS.curses}
+MAKE_ENV+=	LDLIBS_CURSES=${BUILDLINK_LDADD.curses}
+
+.include "../../mk/curses.buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/nnn/PLIST b/nnn/PLIST
new file mode 100644
index 0000000000..30f220d5fd
--- /dev/null
+++ b/nnn/PLIST
@@ -0,0 +1,3 @@
+@comment $NetBSD$
+bin/nnn
+man/man1/nnn.1
diff --git a/nnn/TODO b/nnn/TODO
new file mode 100644
index 0000000000..c32155b20d
--- /dev/null
+++ b/nnn/TODO
@@ -0,0 +1,7 @@
+Compiler warnings in NetBSD:
+
+ - wrong format string specifiers in show_stats()
+   https://github.com/jarun/nnn/issues/164
+
+ - "array subscript is above array bounds"
+   https://github.com/jarun/nnn/issues/165
diff --git a/nnn/distinfo b/nnn/distinfo
new file mode 100644
index 0000000000..5d3d9d7380
--- /dev/null
+++ b/nnn/distinfo
@@ -0,0 +1,7 @@
+$NetBSD$
+
+SHA1 (nnn-2.1.tar.gz) = 033413269dd31604c188fe4d1cd798290a071bac
+RMD160 (nnn-2.1.tar.gz) = ac391618655cfc6c1d3a605cc4b3c4218c5cc074
+SHA512 (nnn-2.1.tar.gz) = 4ce20944df613706545cffb70896b9c494ed0304a591b1ffdae4886ac3783c2c1ab321b336b9873bd8b1382bc9c6ae8e0226f7abb98fb461ed64b28e1302d8f2
+Size (nnn-2.1.tar.gz) = 48481 bytes
+SHA1 (patch-Makefile) = 93c64a8f2ff2034c464a0da7378f5a548fa38fd5
diff --git a/nnn/patches/patch-Makefile b/nnn/patches/patch-Makefile
new file mode 100644
index 0000000000..13d6dfe7bd
--- /dev/null
+++ b/nnn/patches/patch-Makefile
@@ -0,0 +1,55 @@
+$NetBSD$
+
+ - Remove CPPFLAGS since C++ is not used
+ - Make curses flags configurable
+ - Also use pkg-config for regular ncurses
+ - Make optimization flags configurable
+
+Upstream PR:
+https://github.com/jarun/nnn/pull/166
+
+--- Makefile
++++ Makefile
+@@ -6,16 +6,24 @@ STRIP ?= strip
+ PKG_CONFIG ?= pkg-config
+ INSTALL ?= install
+ 
+-CFLAGS ?= -O3
+-CFLAGS += -Wall -Wextra -Wno-unused-parameter
++CFLAGS_OPTIMIZATION ?= -O3
+ 
+ ifeq ($(shell $(PKG_CONFIG) ncursesw && echo 1),1)
+-	CFLAGS += $(shell $(PKG_CONFIG) --cflags ncursesw)
+-	LDLIBS += $(shell $(PKG_CONFIG) --libs   ncursesw)
++	CFLAGS_CURSES ?= $(shell $(PKG_CONFIG) --cflags ncursesw)
++	LDLIBS_CURSES ?= $(shell $(PKG_CONFIG) --libs   ncursesw)
++else ifeq ($(shell $(PKG_CONFIG) ncurses && echo 1),1)
++	CFLAGS_CURSES ?= $(shell $(PKG_CONFIG) --cflags ncurses)
++	LDLIBS_CURSES ?= $(shell $(PKG_CONFIG) --libs   ncurses)
+ else
+-	LDLIBS += -lncurses
++	LDLIBS_CURSES ?= -lncurses
+ endif
+ 
++CFLAGS += -Wall -Wextra -Wno-unused-parameter
++CFLAGS += $(CFLAGS_OPTIMIZATION)
++CFLAGS += $(CFLAGS_CURSES)
++
++LDLIBS += $(LDLIBS_CURSES)
++
+ DISTFILES = src nnn.1 Makefile README.md LICENSE
+ SRC = src/nnn.c
+ BIN = nnn
+@@ -25,10 +33,10 @@ all: $(BIN)
+ $(SRC): src/nnn.h
+ 
+ $(BIN): $(SRC)
+-	$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LDLIBS)
++	$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LDLIBS)
+ 
+ debug: $(SRC)
+-	$(CC) -DDEBUGMODE -g $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o $(BIN) $^ $(LDLIBS)
++	$(CC) -DDEBUGMODE -g $(CFLAGS) $(LDFLAGS) -o $(BIN) $^ $(LDLIBS)
+ 
+ install: all
+ 	$(INSTALL) -m 0755 -d $(DESTDIR)$(PREFIX)/bin


Home | Main Index | Thread Index | Old Index