diff --git a/devel/readline/Makefile b/devel/readline/Makefile index 34820ecedc0d..36a5590c925e 100644 --- a/devel/readline/Makefile +++ b/devel/readline/Makefile @@ -1,49 +1,49 @@ # Created by: Frank Laszlo # $FreeBSD$ PORTNAME= readline PORTVERSION= 8.0.${PATCHLEVEL} PORTREVISION= 1 CATEGORIES= devel MASTER_SITES= GNU DISTNAME= ${PORTNAME}-${PORTVERSION:R} PATCH_SITES= GNU/${PORTNAME}/${PORTNAME}-${PORTVERSION:R}-patches MAINTAINER= sunpoet@FreeBSD.org COMMENT= Library for editing command lines as they are typed LICENSE= GPLv3 LICENSE_FILE= ${WRKSRC}/COPYING USES= cpe GNU_CONFIGURE= yes USE_LDCONFIG= yes INFO= history readline rluserman PORTDOCS= CHANGES INSTALL README CPE_VENDOR= gnu CPE_VERSION= ${PORTVERSION:R} CPE_UPDATE= ${PATCHLEVEL} OPTIONS_DEFINE= DOCS PATCHES= 1 2 3 4 PATCHLEVEL= ${PATCHES:O:[-1]} #PATCHLEVEL= 0 .for patch in ${PATCHES} PATCHFILES+= ${PORTNAME}${PORTVERSION:R:S|.||}-${patch:S|^|00|:S|.*(...)$|\1|} .endfor post-patch: - @${REINPLACE_CMD} -e '/SYS_INPUTRC/ s|/etc/inputrc|${LOCALBASE}&|' ${WRKSRC}/rlconf.h + @${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|' ${WRKSRC}/rlconf.h .if exists(/usr/lib/libtermcapw.so) @${REINPLACE_CMD} 's|-ltermcap|-ltermcapw|g' ${WRKSRC}/configure .endif post-install: ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libhistory.so.8.0 ${STAGEDIR}${PREFIX}/lib/libreadline.so.8.0 .include diff --git a/devel/readline/files/patch-rlconf.h b/devel/readline/files/patch-rlconf.h new file mode 100644 index 000000000000..f4041ea580db --- /dev/null +++ b/devel/readline/files/patch-rlconf.h @@ -0,0 +1,11 @@ +--- rlconf.h.orig 2017-02-21 15:25:30 UTC ++++ rlconf.h +@@ -43,7 +43,7 @@ + #define DEFAULT_INPUTRC "~/.inputrc" + + /* The ultimate last-ditch filename for an init file -- system-wide. */ +-#define SYS_INPUTRC "/etc/inputrc" ++#define SYS_INPUTRC "%%PREFIX%%/etc/inputrc" + + /* If defined, expand tabs to spaces. */ + #define DISPLAY_TABS