nano: Fix hardcoded paths in manpages pkgsrc changes: --------------- * Add patches to substitute hardcoded /etc and /usr paths in manpages. * Bump revision.diff -r1.92 -r1.93 pkgsrc/editors/nano/Makefile
(triaxx)
@@ -1,16 +1,17 @@ | @@ -1,16 +1,17 @@ | |||
1 | # $NetBSD: Makefile,v 1.92 2021/01/24 17:13:42 nia Exp $ | 1 | # $NetBSD: Makefile,v 1.93 2021/02/05 17:25:52 triaxx Exp $ | |
2 | 2 | |||
3 | DISTNAME= nano-5.5 | 3 | DISTNAME= nano-5.5 | |
4 | PKGREVISION= 1 | |||
4 | CATEGORIES= editors | 5 | CATEGORIES= editors | |
5 | MASTER_SITES= https://www.nano-editor.org/dist/v${PKGVERSION_NOREV:C/\..*$//}/ | 6 | MASTER_SITES= https://www.nano-editor.org/dist/v${PKGVERSION_NOREV:C/\..*$//}/ | |
6 | EXTRACT_SUFX= .tar.xz | 7 | EXTRACT_SUFX= .tar.xz | |
7 | 8 | |||
8 | MAINTAINER= wiedi@frubar.net | 9 | MAINTAINER= wiedi@frubar.net | |
9 | HOMEPAGE= https://www.nano-editor.org/ | 10 | HOMEPAGE= https://www.nano-editor.org/ | |
10 | COMMENT= Small and friendly text editor (a free replacement for Pico) | 11 | COMMENT= Small and friendly text editor (a free replacement for Pico) | |
11 | LICENSE= gnu-gpl-v3 | 12 | LICENSE= gnu-gpl-v3 | |
12 | 13 | |||
13 | USE_PKGLOCALEDIR= yes | 14 | USE_PKGLOCALEDIR= yes | |
14 | USE_TOOLS+= msgfmt msgmerge xgettext gmake | 15 | USE_TOOLS+= msgfmt msgmerge xgettext gmake | |
15 | GNU_CONFIGURE= yes | 16 | GNU_CONFIGURE= yes | |
16 | CONFIGURE_ARGS+= --enable-color | 17 | CONFIGURE_ARGS+= --enable-color | |
@@ -23,19 +24,25 @@ INFO_FILES= yes | @@ -23,19 +24,25 @@ INFO_FILES= yes | |||
23 | # Looks like that IRIX 5.x lacks vsnprintf() functions, | 24 | # Looks like that IRIX 5.x lacks vsnprintf() functions, | |
24 | # which are required to make this work, so glib2 is used instead. | 25 | # which are required to make this work, so glib2 is used instead. | |
25 | .include "../../mk/bsd.prefs.mk" | 26 | .include "../../mk/bsd.prefs.mk" | |
26 | 27 | |||
27 | .if !empty(MACHINE_PLATFORM:MIRIX-5*) | 28 | .if !empty(MACHINE_PLATFORM:MIRIX-5*) | |
28 | . include "../../devel/glib2/buildlink3.mk" | 29 | . include "../../devel/glib2/buildlink3.mk" | |
29 | .endif | 30 | .endif | |
30 | 31 | |||
31 | .include "options.mk" | 32 | .include "options.mk" | |
32 | 33 | |||
33 | INSTALLATION_DIRS+= share/examples/nano | 34 | INSTALLATION_DIRS+= share/examples/nano | |
34 | CONF_FILES+= share/examples/nano/nanorc ${PKG_SYSCONFDIR}/nanorc | 35 | CONF_FILES+= share/examples/nano/nanorc ${PKG_SYSCONFDIR}/nanorc | |
35 | 36 | |||
37 | SUBST_CLASSES+= man | |||
38 | SUBST_STAGE.man= pre-configure | |||
39 | SUBST_MESSAGE.man= Fixing paths in manpages. | |||
40 | SUBST_FILES.man= doc/nano.1 doc/nanorc.5 | |||
41 | SUBST_VARS.man= PKG_SYSCONFDIR PREFIX | |||
42 | ||||
36 | post-install: | 43 | post-install: | |
37 | ${INSTALL_DATA} ${WRKSRC}/doc/sample.nanorc ${DESTDIR}${PREFIX}/share/examples/nano/nanorc | 44 | ${INSTALL_DATA} ${WRKSRC}/doc/sample.nanorc ${DESTDIR}${PREFIX}/share/examples/nano/nanorc | |
38 | 45 | |||
39 | .include "../../devel/gettext-lib/buildlink3.mk" | 46 | .include "../../devel/gettext-lib/buildlink3.mk" | |
40 | .include "../../mk/curses.buildlink3.mk" | 47 | .include "../../mk/curses.buildlink3.mk" | |
41 | .include "../../mk/bsd.pkg.mk" | 48 | .include "../../mk/bsd.pkg.mk" |
@@ -1,7 +1,9 @@ | @@ -1,7 +1,9 @@ | |||
1 | $NetBSD: distinfo,v 1.63 2021/01/24 17:13:42 nia Exp $ | 1 | $NetBSD: distinfo,v 1.64 2021/02/05 17:25:52 triaxx Exp $ | |
2 | 2 | |||
3 | SHA1 (nano-5.5.tar.xz) = b727bcd583498312f52307ed39b83d7515401c58 | 3 | SHA1 (nano-5.5.tar.xz) = b727bcd583498312f52307ed39b83d7515401c58 | |
4 | RMD160 (nano-5.5.tar.xz) = 0aaec99f60c214081608e3278ecd662e48f95825 | 4 | RMD160 (nano-5.5.tar.xz) = 0aaec99f60c214081608e3278ecd662e48f95825 | |
5 | SHA512 (nano-5.5.tar.xz) = cbd2b6e1dc7437caf4ec6b55252664430fb1d6243dcf51a7b29ca3683bd1e6a25809c7b9d514d42cc85eb1a615bf3365951c07bf7c3c183a8cbe71c8586d9481 | 5 | SHA512 (nano-5.5.tar.xz) = cbd2b6e1dc7437caf4ec6b55252664430fb1d6243dcf51a7b29ca3683bd1e6a25809c7b9d514d42cc85eb1a615bf3365951c07bf7c3c183a8cbe71c8586d9481 | |
6 | Size (nano-5.5.tar.xz) = 1427592 bytes | 6 | Size (nano-5.5.tar.xz) = 1427592 bytes | |
7 | SHA1 (patch-configure) = 5f34f74d20c9b18f21afa308ed5634daed98a25d | 7 | SHA1 (patch-configure) = 5f34f74d20c9b18f21afa308ed5634daed98a25d | |
8 | SHA1 (patch-doc_nano.1) = 28dcfb77046774d09128986783bbc434a708e212 | |||
9 | SHA1 (patch-doc_nanorc.5) = a1c2151152d08348263a6f36be43fa04fb4eee15 |
$NetBSD: patch-doc_nano.1,v 1.1 2021/02/05 17:25:52 triaxx Exp $
* Fix hard-coded pathes.
--- doc/nano.1.orig 2021-01-14 10:11:45.000000000 +0000
+++ doc/nano.1
@@ -383,7 +383,7 @@ or \fI~/.config/nano/nanorc\fR, whicheve
.BR nanorc (5)
for more information on the possible contents of those files.
.sp
-See \fI/usr/share/nano/\fR and \fI/usr/share/nano/extra/\fR
+See \fI@PREFIX@/share/nano/\fR and \fI@PREFIX@/share/nano/extra/\fR
for available syntax-coloring definitions.
.SH NOTES
@@ -420,4 +420,4 @@ the environment variable \fBNANO_NOCATCH
.SH SEE ALSO
.BR nanorc (5)
.sp
-\fI/usr/share/doc/nano/\fP (or equivalent on your system)
+\fI@PREFIX@/share/doc/nano/\fP (or equivalent on your system)
$NetBSD: patch-doc_nanorc.5,v 1.1 2021/02/05 17:25:52 triaxx Exp $
* Fix hard-coded pathes.
--- doc/nanorc.5.orig 2021-01-14 10:11:45.000000000 +0000
+++ doc/nanorc.5
@@ -25,7 +25,7 @@ nanorc \- GNU nano's configuration file
The \fInanorc\fP files contain the default settings for \fBnano\fP,
a small and friendly editor. During startup, if \fB\-\-rcfile\fR
is not given, \fBnano\fR will read two files: first the
-system-wide settings, from \fI/etc/nanorc\fP (the exact path might be
+system-wide settings, from \fI@PKG_SYSCONFDIR@/nanorc\fP (the exact path might be
different on your system), and then the user-specific settings, either
from \fI~/.nanorc\fR or from \fI$XDG_CONFIG_HOME/nano/nanorc\fR
or from \fI~/.config/nano/nanorc\fR, whichever is encountered first.
@@ -995,13 +995,13 @@ for \fBunbind\fR it means all menus wher
.SH FILES
.TP
-.I /etc/nanorc
+.I @PKG_SYSCONFDIR@/nanorc
System-wide configuration file.
.TP
.IR ~/.nanorc " or " $XDG_CONFIG_HOME/nano/nanorc " or " ~/.config/nano/nanorc
Per-user configuration file.
.TP
-.I /usr/share/nano/*
+.I @PREFIX@/share/nano/*
Syntax definitions for the syntax coloring of common file types
(and for less common file types in the \fIextra/\fR subdirectory).