From owner-svn-ports-all@FreeBSD.ORG Tue Jun 4 02:48:28 2013 Return-Path: Delivered-To: svn-ports-all@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id A5073EF9; Tue, 4 Jun 2013 02:48:28 +0000 (UTC) (envelope-from bf@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 87A601447; Tue, 4 Jun 2013 02:48:28 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r542mSfj088451; Tue, 4 Jun 2013 02:48:28 GMT (envelope-from bf@svn.freebsd.org) Received: (from bf@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r542mRev088449; Tue, 4 Jun 2013 02:48:27 GMT (envelope-from bf@svn.freebsd.org) Message-Id: <201306040248.r542mRev088449@svn.freebsd.org> From: Brendan Fabeny Date: Tue, 4 Jun 2013 02:48:27 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r319821 - head/devel/pcre X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jun 2013 02:48:28 -0000 Author: bf Date: Tue Jun 4 02:48:27 2013 New Revision: 319821 URL: http://svnweb.freebsd.org/changeset/ports/319821 Log: update to 8.33; add an option and some knobs to help users in environments with limited resources, and to fail more gracefully when encountering runaway recursions Modified: head/devel/pcre/Makefile head/devel/pcre/distinfo (contents, props changed) Modified: head/devel/pcre/Makefile ============================================================================== --- head/devel/pcre/Makefile Tue Jun 4 02:42:05 2013 (r319820) +++ head/devel/pcre/Makefile Tue Jun 4 02:48:27 2013 (r319821) @@ -2,7 +2,7 @@ # $FreeBSD$ PORTNAME= pcre -PORTVERSION= 8.32 +PORTVERSION= 8.33 CATEGORIES= devel MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTVERSION} \ ftp://ftp.csx.cam.ac.uk/pub/software/programming/%SUBDIR%/ \ @@ -23,6 +23,11 @@ USES= pathfix CONFIGURE_ARGS= --enable-utf --enable-unicode-properties \ --enable-pcre8 --enable-pcre16 --enable-pcre32 +OPTIONS_DEFINE= STACK_RECURSION +OPTIONS_DEFAULT= STACK_RECURSION + +STACK_RECURSION_DESC= Use the stack for recursion during matching + .include .if ${ARCH} != "sparc64" && ${ARCH} != "ia64" @@ -35,7 +40,11 @@ CONFIGURE_ARGS+= --disable-jit PORTDOCS= * .endif -.include +# Using the heap rather than the stack for recursion is slower but less +# prone to segfaults from stack exhaustion when matching certain patterns +.if !${PORT_OPTIONS:MSTACK_RECURSION} +CONFIGURE_ARGS+= --disable-stack-for-recursion +.endif # For FreeBSD 8.3 and above link pcretest against libedit .if ${OSVERSION} >= 803000 @@ -46,8 +55,31 @@ CONFIGURE_ARGS+= --enable-pcretest-libed CFLAGS+= -fPIC .endif +# Optional knobs that accept positive integer parameters (see pcrebuild(3)): + +# Allow the use of very large patterns (> 64K) with the 8- and 16-bit +# libraries, at the expense of longer load times (possible values: +# 2 (default), 3, and 4): .if defined(WITH_LINK_SIZE) -CONFIGURE_ARGS+=--with-link-size=${WITH_LINK_SIZE} +CONFIGURE_ARGS+= --with-link-size=${WITH_LINK_SIZE} +.endif + +# Control PCRE resource use by limiting the default number of times pcre_exec() +# can call match() during a single operation (default: 10 million): +.if defined(WITH_MATCH_LIMIT) +CONFIGURE_ARGS+= --with-match-limit=${WITH_MATCH_LIMIT} +.endif + +# Control PCRE resource use by limiting the default number of times pcre_exec() +# can call match() recursively during a single operation (default: 10 million): +.if defined(WITH_MATCH_LIMIT_RECURSION) +CONFIGURE_ARGS+= --with-match-limit-recursion=${WITH_MATCH_LIMIT_RECURSION} +.endif + +# Adjust the default maximum number of substrings that will be stored on the stack +# when the 8-bit library is called via the POSIX interface (default: 10): +.if defined(WITH_POSIX_MALLOC_THRESHOLD) +CONFIGURE_ARGS+= --with-posix-malloc-threshold=${WITH_POSIX_MALLOC_THRESHOLD} .endif MAN1= pcre-config.1 \ @@ -86,6 +118,7 @@ MAN3= pcre.3 \ pcrecallout.3 \ pcrecompat.3 \ pcrecpp.3 \ + pcredemo.3 \ pcrejit.3 \ pcrelimits.3 \ pcrematching.3 \ @@ -154,6 +187,7 @@ MLINKS+= pcre_assign_jit_stack.3 pcre16_ pcre_utf32_to_host_byte_order.3 pcre32_utf32_to_host_byte_order.3 \ pcre_version.3 pcre16_version.3 \ pcre_version.3 pcre32_version.3 + post-patch: .if !${PORT_OPTIONS:MDOCS} @${REINPLACE_CMD} -E -e '/^install-data-am/,/^$$/ s,install-(dist_doc|dist_html|html)DATA,,g' \ @@ -172,10 +206,13 @@ post-install: .ifndef(MAINTAINER_MODE) CORELIMIT?= /usr/bin/limits -Sc 0 .endif +TESTLOGS?= RunGrepTest RunTest pcre_jit_test pcre_scanner_unittest \ + pcre_stringpiece_unittest pcrecpp_unittest -check test: build - @cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${CORELIMIT} ${MAKE} ${MAKE_FLAGS} ${MAKEFILE} test - -regression-test: test +check regression-test test: build + @cd ${WRKSRC} ; \ + ${SETENV} ${MAKE_ENV} ${CORELIMIT} ${MAKE} ${MAKE_ARGS} check ; \ + for _l in ${TESTLOGS} ; do if ${TEST} -f $${_l}.log ; then \ + ${PRINTF} "\n\n$${_l}.log\n\n\n" ; ${CAT} $${_l}.log ; fi ; done -.include +.include Modified: head/devel/pcre/distinfo ============================================================================== --- head/devel/pcre/distinfo Tue Jun 4 02:42:05 2013 (r319820) +++ head/devel/pcre/distinfo Tue Jun 4 02:48:27 2013 (r319821) @@ -1,2 +1,2 @@ -SHA256 (pcre-8.32.tar.bz2) = a913fb9bd058ef380a2d91847c3c23fcf98e92dc3b47cd08a53c021c5cde0f55 -SIZE (pcre-8.32.tar.bz2) = 1361156 +SHA256 (pcre-8.33.tar.bz2) = c603957a4966811c04af5f6048c71cfb4966ec93312d7b3118116ed9f3bc0478 +SIZE (pcre-8.33.tar.bz2) = 1440869