Skip to content

Commit

Permalink
textproc/chpp: Optional USES=makeinfo
Browse files Browse the repository at this point in the history
- Utilize USES=makeinfo only when used specially for DOCS only in this
  case.
- Utilize USES=localbase
- Pet portclippy
  • Loading branch information
5u623l20 committed Oct 20, 2023
1 parent e42223a commit bddac0b
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions textproc/chpp/Makefile
Expand Up @@ -15,17 +15,16 @@ LICENSE_FILE= ${WRKSRC}/COPYING
LIB_DEPENDS= libgc.so:devel/boehm-gc \
libgnuregex.so.6:devel/libgnuregex

USES= autoreconf gmake makeinfo
USES= autoreconf gmake localbase:ldflags

GNU_CONFIGURE= yes
CONFIGURE_ARGS= --libdir=${PREFIX}/share

CPPFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib

INFO= chpp

OPTIONS_DEFINE= DOCS EXAMPLES

DOCS_USES= makeinfo
DOCS_INFO= chpp

.include <bsd.port.pre.mk>

post-extract:
Expand All @@ -39,11 +38,15 @@ post-patch:
s| regex.c regex.h | | ; \
/LDADD/s| gc/gc.a | -lgc -lgnuregex | ; \
s|^YFLAGS|AM_YFLAGS|' ${WRKSRC}/Makefile.am
.for i in arrayops.c builtins.c stringops.c
.for i in arrayops.c stringops.c
@${REINPLACE_CMD} -e \
's|"../regex.h"|<gnu/regex.h>|' ${WRKSRC}/builtins/${i}
.endfor

post-patch-DOCS-off:
@${REINPLACE_CMD} -e \
'/SUBDIRS/s|doc||' ${WRKSRC}/Makefile.am

post-install-DOCS-on:
@${MKDIR} ${STAGEDIR}${DOCSDIR}
.for filename in AUTHORS NEWS README
Expand Down

0 comments on commit bddac0b

Please sign in to comment.