initial import of nano 0.9.11; ok espie@

nano is a small and easy-to-use editor in the fashion of pico
This commit is contained in:
naddy 2000-06-24 14:31:37 +00:00
parent e0673fa6b0
commit 5d7f5588cd
10 changed files with 240 additions and 0 deletions

34
editors/nano/Makefile Normal file
View File

@ -0,0 +1,34 @@
# $OpenBSD: Makefile,v 1.1.1.1 2000/06/24 14:31:37 naddy Exp $
DISTNAME= nano-0.9.11
CATEGORIES= editors
NEED_VERSION= 1.308
HOMEPAGE= http://www.asty.org/nano/
MAINTAINER= danh@nfol.com
MASTER_SITES= ${HOMEPAGE}/dist/
PERMIT_PACKAGE_CDROM= Yes
PERMIT_PACKAGE_FTP= Yes
PERMIT_DISTFILES_CDROM= Yes
PERMIT_DISTFILES_FTP= Yes
FLAVORS= slang
FLAVOR?=
LIB_DEPENDS= intl.1::devel/gettext
.if ${FLAVOR:L:Mslang}
LIB_DEPENDS+= slang.14.1::devel/libslang
.endif
CONFIGURE_STYLE= gnu
CONFIGURE_ARGS= --without-included-gettext \
--includedir='${LOCALBASE}/include'
.if ${FLAVOR:L:Mslang}
CONFIGURE_ARGS+= --with-slang='${LOCALBASE}'
.else
CFLAGS+= -DHAVE_TABSIZE
.endif
.include <bsd.port.mk>

3
editors/nano/files/md5 Normal file
View File

@ -0,0 +1,3 @@
MD5 (nano-0.9.11.tar.gz) = 6a70dfd1faef042b9c5cdeba038e05de
RMD160 (nano-0.9.11.tar.gz) = 45b9fbcb12547e93ad48960362730e2f704a6483
SHA1 (nano-0.9.11.tar.gz) = 515c9378e4a7e1d5ad195bb67a13d9d84b04654b

View File

@ -0,0 +1,32 @@
$OpenBSD: patch-Makefile_in,v 1.1.1.1 2000/06/24 14:31:38 naddy Exp $
--- Makefile.in.orig Wed Jun 21 04:12:13 2000
+++ Makefile.in Sat Jun 24 04:00:02 2000
@@ -73,7 +73,7 @@ GT_YES = @GT_YES@
INCLUDE_LOCALE_H = @INCLUDE_LOCALE_H@
INSTOBJEXT = @INSTOBJEXT@
INTLDEPS = @INTLDEPS@
-INTLLIBS = @INTLLIBS@
+INTLLIBS = -L$(LOCALBASE)/lib -lintl
INTLOBJS = @INTLOBJS@
MAKEINFO = @MAKEINFO@
MKINSTALLDIRS = @MKINSTALLDIRS@
@@ -92,15 +92,16 @@ nano_SOURCES = cut.c files.c global.
man_MANS = nano.1
-nano_LDADD = @INTLLIBS@
+nano_LDADD = $(INTLLIBS)
EXTRA_DIST = AUTHORS BUGS COPYING ChangeLog INSTALL NEWS README TODO install-sh missing mkinstalldirs nano.1 nano.1.html
-SUBDIRS = po intl
+SUBDIRS = po
localedir = $(datadir)/locale
-INCLUDES = -Iintl -DLOCALEDIR=\"$(localedir)\" -I@includedir@
+INCLUDES = -I$(LOCALBASE)/share/gettext/intl -DLOCALEDIR=\"$(localedir)\" \
+ -I@includedir@
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
CONFIG_HEADER = config.h

View File

@ -0,0 +1,12 @@
$OpenBSD: patch-configure,v 1.1.1.1 2000/06/24 14:31:38 naddy Exp $
--- configure.orig Tue Jun 20 22:12:13 2000
+++ configure Fri Jun 23 11:57:36 2000
@@ -1453,7 +1453,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_l
#define USE_SLANG 1
EOF
slang_support=yes
- CURSES_LIB="-L${with_slang}/lib -lslang"
+ CURSES_LIB="-L${with_slang}/lib -lslang -ltermcap -lm"
CURSES_LIB_NAME=slang
else
echo "$ac_t""no" 1>&6

View File

@ -0,0 +1,20 @@
$OpenBSD: patch-nano_c,v 1.1.1.1 2000/06/24 14:31:38 naddy Exp $
--- nano.c.orig Tue Jun 20 22:31:43 2000
+++ nano.c Thu Jun 22 23:22:07 2000
@@ -1708,12 +1708,10 @@ int main(int argc, char *argv[])
/* First back up the old settings so they can be restored, duh */
tcgetattr(0, &oldterm);
- /* Adam's code to blow away intr character so ^C can show cursor pos */
- tcgetattr(0, &term);
- for (i = 0; i < NCCS; i++) {
- if (term.c_cc[i] == CINTR || term.c_cc[i] == CQUIT)
- term.c_cc[i] = 0;
- }
+ term = oldterm;
+ term.c_cc[VINTR] = _POSIX_VDISABLE;
+ term.c_cc[VQUIT] = _POSIX_VDISABLE;
+ term.c_lflag &= ~IEXTEN;
tcsetattr(0, TCSANOW, &term);
/* now ncurses init stuff... */

View File

@ -0,0 +1,119 @@
$OpenBSD: patch-po_Makefile_in_in,v 1.1.1.1 2000/06/24 14:31:38 naddy Exp $
--- po/Makefile.in.in.orig Tue Jun 6 07:53:55 2000
+++ po/Makefile.in.in Sat Jun 24 03:18:13 2000
@@ -19,8 +19,9 @@ VPATH = @srcdir@
prefix = @prefix@
exec_prefix = @exec_prefix@
datadir = $(prefix)/@DATADIRNAME@
-localedir = $(datadir)/locale
+localedir = $(prefix)/share/locale
gnulocaledir = $(prefix)/share/locale
+gettextintldir = $(prefix)/share/gettext/intl
gettextsrcdir = $(prefix)/share/gettext/po
subdir = po
@@ -39,7 +40,7 @@ DEFS = @DEFS@
CFLAGS = @CFLAGS@
CPPFLAGS = @CPPFLAGS@
-INCLUDES = -I.. -I$(top_srcdir)/intl
+INCLUDES = -I$(LOCALBASE)/include -I$(gettextintldir)
COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS)
@@ -73,7 +74,7 @@ INSTOBJEXT = @INSTOBJEXT@
&& rm -f $$file && $(GMSGFMT) -o $$file $<
.po.cat:
- sed -f ../intl/po2msg.sed < $< > $*.msg \
+ sed -f $(gettextintldir)/po2msg.sed < $< > $*.msg \
&& rm -f $@ && $(GENCAT) $@ $*.msg
@@ -93,7 +94,7 @@ $(srcdir)/$(PACKAGE).pot: $(POTFILES)
$(srcdir)/cat-id-tbl.c: stamp-cat-id; @:
$(srcdir)/stamp-cat-id: $(PACKAGE).pot
rm -f cat-id-tbl.tmp
- sed -f ../intl/po2tbl.sed $(srcdir)/$(PACKAGE).pot \
+ sed -f $(gettextintldir)/po2tbl.sed $(srcdir)/$(PACKAGE).pot \
| sed -e "s/@PACKAGE NAME@/$(PACKAGE)/" > cat-id-tbl.tmp
if cmp -s cat-id-tbl.tmp $(srcdir)/cat-id-tbl.c; then \
rm cat-id-tbl.tmp; \
@@ -111,9 +112,9 @@ install-data: install-data-@USE_NLS@
install-data-no: all
install-data-yes: all
if test -r "$(MKINSTALLDIRS)"; then \
- $(MKINSTALLDIRS) $(datadir); \
+ $(MKINSTALLDIRS) $(DESTDIR)$(datadir); \
else \
- $(SHELL) $(top_srcdir)/mkinstalldirs $(datadir); \
+ $(SHELL) $(top_srcdir)/mkinstalldirs $(DESTDIR)$(datadir); \
fi
@catalogs='$(CATALOGS)'; \
for cat in $$catalogs; do \
@@ -125,27 +126,30 @@ install-data-yes: all
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
dir=$$destdir/$$lang/LC_MESSAGES; \
if test -r "$(MKINSTALLDIRS)"; then \
- $(MKINSTALLDIRS) $$dir; \
+ $(MKINSTALLDIRS) $(DESTDIR)$$dir; \
else \
- $(SHELL) $(top_srcdir)/mkinstalldirs $$dir; \
+ $(SHELL) $(top_srcdir)/mkinstalldirs $(DESTDIR)$$dir; \
fi; \
if test -r $$cat; then \
- $(INSTALL_DATA) $$cat $$dir/$(PACKAGE)$(INSTOBJEXT); \
- echo "installing $$cat as $$dir/$(PACKAGE)$(INSTOBJEXT)"; \
+ $(INSTALL_DATA) $$cat $(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT); \
+ echo "installing $$cat as" \
+ "$(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT)"; \
else \
- $(INSTALL_DATA) $(srcdir)/$$cat $$dir/$(PACKAGE)$(INSTOBJEXT); \
+ $(INSTALL_DATA) $(srcdir)/$$cat \
+ $(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT); \
echo "installing $(srcdir)/$$cat as" \
- "$$dir/$(PACKAGE)$(INSTOBJEXT)"; \
+ "$(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT)"; \
fi; \
if test -r $$cat.m; then \
- $(INSTALL_DATA) $$cat.m $$dir/$(PACKAGE)$(INSTOBJEXT).m; \
- echo "installing $$cat.m as $$dir/$(PACKAGE)$(INSTOBJEXT).m"; \
+ $(INSTALL_DATA) $$cat.m $(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT).m; \
+ echo "installing $$cat.m as" \
+ "$(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT).m"; \
else \
if test -r $(srcdir)/$$cat.m ; then \
$(INSTALL_DATA) $(srcdir)/$$cat.m \
- $$dir/$(PACKAGE)$(INSTOBJEXT).m; \
+ $(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT).m; \
echo "installing $(srcdir)/$$cat as" \
- "$$dir/$(PACKAGE)$(INSTOBJEXT).m"; \
+ "$(DESTDIR)$$dir/$(PACKAGE)$(INSTOBJEXT).m"; \
else \
true; \
fi; \
@@ -153,12 +157,12 @@ install-data-yes: all
done
if test "$(PACKAGE)" = "gettext"; then \
if test -r "$(MKINSTALLDIRS)"; then \
- $(MKINSTALLDIRS) $(gettextsrcdir); \
+ $(MKINSTALLDIRS) $(DESTDIR)$(gettextsrcdir); \
else \
- $(SHELL) $(top_srcdir)/mkinstalldirs $(gettextsrcdir); \
+ $(SHELL) $(top_srcdir)/mkinstalldirs $(DESTDIR)$(gettextsrcdir); \
fi; \
$(INSTALL_DATA) $(srcdir)/Makefile.in.in \
- $(gettextsrcdir)/Makefile.in.in; \
+ $(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
else \
: ; \
fi
@@ -180,7 +184,7 @@ uninstall:
check: all
-cat-id-tbl.o: ../intl/libgettext.h
+cat-id-tbl.o: $(gettextintldir)/libgettext.h
dvi info tags TAGS ID:

1
editors/nano/pkg/COMMENT Normal file
View File

@ -0,0 +1 @@
small, easy to use editor

5
editors/nano/pkg/DESCR Normal file
View File

@ -0,0 +1,5 @@
The editor formerly known as TIP (TIP Isn't Pico). The nano
project was started because of a few gripes with the
wonderfully easy-to-use and friendly Pico text editor.
WWW: ${HOMEPAGE}

8
editors/nano/pkg/PLIST Normal file
View File

@ -0,0 +1,8 @@
@comment $OpenBSD: PLIST,v 1.1.1.1 2000/06/24 14:31:38 naddy Exp $
bin/nano
man/man1/nano.1
share/locale/de/LC_MESSAGES/nano.mo
share/locale/es/LC_MESSAGES/nano.mo
share/locale/fr/LC_MESSAGES/nano.mo
share/locale/id/LC_MESSAGES/nano.mo
share/locale/it/LC_MESSAGES/nano.mo

View File

@ -0,0 +1,6 @@
$OpenBSD: SECURITY,v 1.1.1.1 2000/06/24 14:31:38 naddy Exp $
${WRKSRC}/nano.c (lines 1045, 1095)
tempnam(3) is used safely to create a prefix for a temporary file. The
file is eventually opened safely with a call to mkstemp(3).