# Created by: Frank Laszlo # $FreeBSD: head/devel/readline/Makefile 562673 2021-01-26 14:01:34Z sunpoet $ PORTNAME= readline PORTVERSION= 8.1.${PATCHLEVEL} 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 PLIST_SUB= PORTVERSION=${PORTVERSION:R} PORTDOCS= CHANGES INSTALL README CPE_VENDOR= gnu CPE_VERSION= ${PORTVERSION:R} OPTIONS_DEFINE= DOCS # https://ftp.gnu.org/gnu/readline/readline-8.1-patches/ #PATCHES= 1 .if defined(PATCHES) CPE_UPDATE= ${PATCHLEVEL} PATCHLEVEL= ${PATCHES:O:[-1]} .for patch in ${PATCHES} PATCHFILES+= ${PORTNAME}${PORTVERSION:R:S|.||}-${patch:S|^|00|:S|.*(...)$|\1|} .endfor .else PATCHLEVEL= 0 .endif post-patch: @${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 ${STAGEDIR}${PREFIX}/lib/libreadline.so .include