aboutsummaryrefslogtreecommitdiffstats
path: root/textproc
diff options
context:
space:
mode:
authortijl <tijl@FreeBSD.org>2014-07-03 05:31:10 +0800
committertijl <tijl@FreeBSD.org>2014-07-03 05:31:10 +0800
commit185d9af108ac13bd7fd67250894ac72439207c6c (patch)
tree2159ca211937dbc33fff8925fe82aba99949466e /textproc
parentd4e59653a8d8a5632276fd4faf395cc824d40cbf (diff)
downloadfreebsd-ports-gnome-185d9af108ac13bd7fd67250894ac72439207c6c.tar.gz
freebsd-ports-gnome-185d9af108ac13bd7fd67250894ac72439207c6c.tar.zst
freebsd-ports-gnome-185d9af108ac13bd7fd67250894ac72439207c6c.zip
- USES=libtool tar:bzip2
- Use option helpers - Silence post-patch - Remove .error because it is dangerous - Use MAKE_CMD
Diffstat (limited to 'textproc')
-rw-r--r--textproc/libtre/Makefile52
-rw-r--r--textproc/libtre/pkg-plist2
2 files changed, 19 insertions, 35 deletions
diff --git a/textproc/libtre/Makefile b/textproc/libtre/Makefile
index 8589293d73c0..deac7069388a 100644
--- a/textproc/libtre/Makefile
+++ b/textproc/libtre/Makefile
@@ -3,7 +3,7 @@
PORTNAME= libtre
PORTVERSION= 0.8.0
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= textproc
MASTER_SITES= http://laurikari.net/tre/ \
LOCAL/bf
@@ -15,50 +15,34 @@ COMMENT= Lightweight fully POSIX compliant regexp matching library
LICENSE= BSD
LICENSE_FILE= ${WRKSRC}/LICENSE
-USE_BZIP2= yes
-USES= pathfix pkgconfig
-USE_AUTOTOOLS= libtool
-CONFIGURE_ARGS+= --enable-static
+USES= libtool pathfix pkgconfig tar:bzip2
+GNU_CONFIGURE= yes
+CONFIGURE_ARGS= --enable-static
USE_LDCONFIG= yes
CPPFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib
OPTIONS_DEFINE= NLS OPTIMIZED_CFLAGS PGO DOCS
-
-.include <bsd.port.options.mk>
-
-.if ${PORT_OPTIONS:MNLS}
-USES+= gettext
-PLIST_SUB+= NLS=""
-.else
-CONFIGURE_ARGS+= --disable-nls
-PLIST_SUB+= NLS="@comment "
-.endif
-
-.include <bsd.port.pre.mk>
-
-.if ${PORT_OPTIONS:MOPTIMIZED_CFLAGS}
-CFLAGS+= -Wuninitialized -ffast-math -finline-functions \
+OPTIONS_SUB= yes
+NLS_USES= gettext
+NLS_CONFIGURE_ENABLE= nls
+OPTIMIZED_CFLAGS_CFLAGS= \
+ -Wuninitialized -ffast-math -finline-functions \
-fomit-frame-pointer -fexpensive-optimizations \
-fforce-mem -fforce-addr -O3
-.endif
+PGO_CFLAGS= -fprofile-generate
+PGO_LDFLAGS= -fprofile-generate
-.if ${PORT_OPTIONS:MPGO}
-LDFLAGS+= -fprofile-generate
-CFLAGS+= -fprofile-generate
-.endif
+.include <bsd.port.options.mk>
-post-patch:
+post-patch: .SILENT
${MV} ${WRKSRC}/doc/agrep.1.in ${WRKSRC}/doc/tre_agrep.1.in
${REINPLACE_CMD} -e 's;agrep\.1;tre_agrep\.1;g' ${WRKSRC}/configure \
${WRKSRC}/tre.spec.in ${WRKSRC}/doc/Makefile.in
${REINPLACE_CMD} -e 's;agrep;tre_agrep;g' ${WRKSRC}/tests/agrep/*.ok
.if ${PORT_OPTIONS:MPGO}
-.if target(pre-build)
-.error Makefile error since pre-build target has already been defined
-.endif
pre-build: pgo
.endif
@@ -69,7 +53,7 @@ post-install:
.endfor
regression-test: build
- @(cd ${BUILD_WRKSRC} ; ${SETENV} ${MAKE_ENV} ${MAKE} check )
+ @(cd ${BUILD_WRKSRC} && ${SETENV} ${MAKE_ENV} ${MAKE_CMD} check )
.if ${PORT_OPTIONS:MPGO}
pgo: pgo-pre-build pgo-build pgo-run pgo-post-run pgo-clean
@@ -83,11 +67,11 @@ pgo-pre-build:
{} \;
pgo-build:
- @(cd ${BUILD_WRKSRC}; ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${_MAKE_JOBS} ${MAKE_ARGS} ${ALL_TARGET})
+ @(cd ${BUILD_WRKSRC} && ${SETENV} ${MAKE_ENV} ${MAKE_CMD} ${MAKE_FLAGS} ${MAKEFILE} ${_MAKE_JOBS} ${MAKE_ARGS} ${ALL_TARGET})
pgo-run:
# Check everything to generate profiling information.
- @-(cd ${BUILD_WRKSRC} ; ${SETENV} ${MAKE_ENV} ${MAKE} check)
+ @-(cd ${BUILD_WRKSRC} && ${SETENV} ${MAKE_ENV} ${MAKE_CMD} check)
pgo-post-run:
@${FIND} ${BUILD_WRKSRC} -type f -name Makefile -exec \
@@ -107,11 +91,11 @@ pgo-post-run:
pgo-clean:
# Selectively clean some directories.
. for dir in src tests
- @(cd ${BUILD_WRKSRC}/${dir}; ${SETENV} ${MAKE_ENV} ${MAKE} clean)
+ @(cd ${BUILD_WRKSRC}/${dir} && ${SETENV} ${MAKE_ENV} ${MAKE_CMD} clean)
. endfor
# Only remove some files from lib to preserve profiling information.
@${FIND} -E ${BUILD_WRKSRC}/lib -iregex ".*\.(a|la|lai|lo|o|so|so\..*)$$" \
-exec ${RM} -f {} \;
.endif # if ${PORT_OPTIONS:MPGO}
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>
diff --git a/textproc/libtre/pkg-plist b/textproc/libtre/pkg-plist
index 82d8e981b169..4b90e0bf9e90 100644
--- a/textproc/libtre/pkg-plist
+++ b/textproc/libtre/pkg-plist
@@ -3,9 +3,9 @@ include/tre/regex.h
include/tre/tre.h
include/tre/tre-config.h
lib/libtre.a
-lib/libtre.la
lib/libtre.so
lib/libtre.so.5
+lib/libtre.so.5.0.0
libdata/pkgconfig/tre.pc
man/man1/tre_agrep.1.gz
%%NLS%%share/locale/fi/LC_MESSAGES/tre.mo