summaryrefslogtreecommitdiff
path: root/devel
diff options
context:
space:
mode:
authorwiedi <wiedi>2016-12-13 17:07:22 +0000
committerwiedi <wiedi>2016-12-13 17:07:22 +0000
commit91a8299407ab239579ef362f789d92756dcd58b4 (patch)
tree67ec75abdfcbe81baca9038f8793de1d056790b3 /devel
parent4f605da687cb5223b7099ef4a3b127189681b3d3 (diff)
downloadpkgsrc-91a8299407ab239579ef362f789d92756dcd58b4.tar.gz
Pull in three commits from upstream
mainly related to https://github.com/westes/flex/issues/113 "v2.6.2 introduces behavior change that is incompatible with previous versions" This fixes at least doxygen
Diffstat (limited to 'devel')
-rw-r--r--devel/flex/Makefile4
-rw-r--r--devel/flex/distinfo4
-rw-r--r--devel/flex/patches/patch-src_flex.skl18
-rw-r--r--devel/flex/patches/patch-src_scan.l204
4 files changed, 227 insertions, 3 deletions
diff --git a/devel/flex/Makefile b/devel/flex/Makefile
index c6ba2ca4807..2c591e528df 100644
--- a/devel/flex/Makefile
+++ b/devel/flex/Makefile
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.53 2016/11/11 08:14:54 wiz Exp $
+# $NetBSD: Makefile,v 1.54 2016/12/13 17:07:22 wiedi Exp $
DISTNAME= flex-2.6.2
-PKGREVISION= 1
+PKGREVISION= 2
CATEGORIES= devel lang
MASTER_SITES= ${MASTER_SITE_GITHUB:=westes/}
GITHUB_RELEASE= v${PKGVERSION_NOREV}
diff --git a/devel/flex/distinfo b/devel/flex/distinfo
index 405ba9ce810..3205e3c3f2e 100644
--- a/devel/flex/distinfo
+++ b/devel/flex/distinfo
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.27 2016/11/11 08:14:54 wiz Exp $
+$NetBSD: distinfo,v 1.28 2016/12/13 17:07:22 wiedi Exp $
SHA1 (flex-2.6.2.tar.gz) = 9eab5eddb6efb34d420b3162fd619a01940b9438
RMD160 (flex-2.6.2.tar.gz) = f58dca039f2b77b9477e45ac92a57804a6458f13
@@ -6,5 +6,7 @@ SHA512 (flex-2.6.2.tar.gz) = 481fe3f1c370fe04d5a605a826c53dd0afa5b6ea655f0d14fa9
Size (flex-2.6.2.tar.gz) = 1402237 bytes
SHA1 (patch-configure) = dfd8bf7682d99991911b355af5015961f1333195
SHA1 (patch-src_FlexLexer.h) = 9a585219bc8f24c862070969045739d6a303b0bf
+SHA1 (patch-src_flex.skl) = be761bc5c5a1bc2c78f744575c28dec32e76ce51
+SHA1 (patch-src_scan.l) = 0311a0f679fb90b5e190460ec355a5112867a347
SHA1 (patch-tests_Makefile.am) = f30524f9b8c22a37cb04b4406ec142ea1ecb8e59
SHA1 (patch-tests_Makefile.in) = 709d5f117418bbcbcc54926f582bc808daf12f3b
diff --git a/devel/flex/patches/patch-src_flex.skl b/devel/flex/patches/patch-src_flex.skl
new file mode 100644
index 00000000000..4b3426e915e
--- /dev/null
+++ b/devel/flex/patches/patch-src_flex.skl
@@ -0,0 +1,18 @@
+$NetBSD: patch-src_flex.skl,v 1.1 2016/12/13 17:07:23 wiedi Exp $
+
+Pull in upstream commit:
+ - https://github.com/westes/flex/commit/347652c32b4614995acd4ee0d686499da2070d9e
+ fix backwards incompatible changes in 2.6.2.
+
+--- src/flex.skl.orig 2016-12-13 16:10:52.192258388 +0000
++++ src/flex.skl
+@@ -106,7 +106,8 @@ m4_ifdef( [[M4_YY_REENTRANT]], [[m4_def
+ m4_ifdef( [[M4_YY_PREFIX]],, [[m4_define([[M4_YY_PREFIX]], [[yy]])]])
+
+ m4preproc_define(`M4_GEN_PREFIX',
+- ``m4_define(yy[[$1]], [[M4_YY_PREFIX[[$1]]m4_ifelse($'`#,0,,[[($'`@)]])]])'')
++ ``[[#define yy$1 ]]M4_YY_PREFIX[[$1]]
++m4_define([[yy$1]], [[M4_YY_PREFIX[[$1]]m4_ifelse($'`#,0,,[[($'`@)]])]])'')
+
+ %if-c++-only
+ /* The c++ scanner is a mess. The FlexLexer.h header file relies on the
diff --git a/devel/flex/patches/patch-src_scan.l b/devel/flex/patches/patch-src_scan.l
new file mode 100644
index 00000000000..cd2e8a35734
--- /dev/null
+++ b/devel/flex/patches/patch-src_scan.l
@@ -0,0 +1,204 @@
+$NetBSD: patch-src_scan.l,v 1.1 2016/12/13 17:07:23 wiedi Exp $
+
+Pull in two upstream commits:
+ - https://github.com/westes/flex/commit/e1038db19a6fda98a19a1df4d5f62c74c63b57d5
+ "Fix another escaping bug"
+ - https://github.com/westes/flex/commit/c8ad3d682fb0ea39e30a70449c7f88b8cd8da6b4
+ "Fixes a major bug in Flex's own lexing of literals"
+
+--- src/scan.l.orig 2016-10-23 18:04:57.000000000 +0000
++++ src/scan.l
+@@ -102,20 +102,22 @@ extern const char *escaped_qstart, *esca
+ posix_compat = true;
+
+ #define START_CODEBLOCK(x) do { \
+- /* Emit the needed line directive... */\
+- if (indented_code == false) { \
+- linenum++; \
+- line_directive_out(NULL, 1); \
+- } \
+- add_action(M4QSTART); \
+- yy_push_state(CODEBLOCK); \
+- if ((indented_code = x)) ACTION_ECHO; \
+- } while(0)
++ /* Emit the needed line directive... */\
++ if (indented_code == false) { \
++ linenum++; \
++ line_directive_out(NULL, 1); \
++ } \
++ add_action(M4QSTART); \
++ yy_push_state(CODEBLOCK); \
++ if ((indented_code = x)) ACTION_ECHO; \
++} while(0)
++
+ #define END_CODEBLOCK do { \
+- yy_pop_state();\
++ yy_pop_state();\
+ add_action(M4QEND); \
+- if (!indented_code) line_directive_out(NULL, 0);\
+- } while (0)
++ if (!indented_code) line_directive_out(NULL, 0);\
++} while (0)
++
+ %}
+
+ %option caseless nodefault noreject stack noyy_top_state
+@@ -486,17 +488,18 @@ COMMENT,CODE_COMMENT>{
+
+ ^{WS} START_CODEBLOCK(true); /* indented code in prolog */
+
+- ^{NOT_WS}.* { /* non-indented code */
+- if ( bracelevel <= 0 )
+- { /* not in %{ ... %} */
+- yyless( 0 ); /* put it all back */
+- yy_set_bol( 1 );
+- mark_prolog();
+- BEGIN(SECT2);
+- }
+- else
+- ACTION_ECHO;
+- }
++ ^{NOT_WS}.* {
++ /* non-indented code */
++ if ( bracelevel <= 0 ) {
++ /* not in %{ ... %} */
++ yyless( 0 ); /* put it all back */
++ yy_set_bol( 1 );
++ mark_prolog();
++ BEGIN(SECT2);
++ } else {
++ START_CODEBLOCK(true);
++ }
++ }
+
+ . ACTION_ECHO;
+ {NL} ++linenum; ACTION_ECHO;
+@@ -903,30 +906,28 @@ nmstr[yyleng - 2 - end_is_ws] = '\0'; /
+ <ACTION>"/*" ACTION_ECHO; yy_push_state( CODE_COMMENT );
+
+ <CODEBLOCK,ACTION>{
+- "reject" {
+- ACTION_ECHO;
+- CHECK_REJECT(yytext);
+- }
+- "yymore" {
+- ACTION_ECHO;
+- CHECK_YYMORE(yytext);
+- }
++ "reject" {
++ ACTION_ECHO;
++ CHECK_REJECT(yytext);
++ }
++ "yymore" {
++ ACTION_ECHO;
++ CHECK_YYMORE(yytext);
++ }
+ }
+
+- . ACTION_ECHO;
+- {NL} {
+- ++linenum;
+- ACTION_ECHO;
+- if ( bracelevel == 0 ||
+- (doing_codeblock && indented_code) )
+- {
+- if ( doing_rule_action )
+- add_action( "\tYY_BREAK]""]\n" );
+-
+- doing_rule_action = doing_codeblock = false;
+- BEGIN(SECT2);
+- }
+- }
++ . ACTION_ECHO;
++ {NL} {
++ ++linenum;
++ ACTION_ECHO;
++ if (bracelevel == 0 || (doing_codeblock && indented_code)) {
++ if ( doing_rule_action )
++ add_action( "\tYY_BREAK]""]\n" );
++
++ doing_rule_action = doing_codeblock = false;
++ BEGIN(SECT2);
++ }
++ }
+ }
+
+
+@@ -935,38 +936,37 @@ nmstr[yyleng - 2 - end_is_ws] = '\0'; /
+ "{" ACTION_ECHO; ++bracelevel;
+ "}" ACTION_ECHO; --bracelevel;
+ [^[:alpha:]_{}\"'/\n\[\]]+ ACTION_ECHO;
+- [\[\]] ACTION_ECHO;
+- {NAME} ACTION_ECHO;
++ {NAME} ACTION_ECHO;
+ "'"([^\'\\\n]|\\.)"'" ACTION_ECHO; /* character constant */
+- "'" ACTION_ECHO; yy_push_state(CHARACTER_CONSTANT);
++ "'" ACTION_ECHO; BEGIN(CHARACTER_CONSTANT);
+ \" ACTION_ECHO; BEGIN(ACTION_STRING);
+- {NL} {
++ {NL} {
+ ++linenum;
+ ACTION_ECHO;
+- if ( bracelevel == 0 )
+- {
++ if (bracelevel == 0) {
+ if ( doing_rule_action )
+- add_action( "\tYY_BREAK]""]\n" );
++ add_action( "\tYY_BREAK]""]\n" );
+
+- doing_rule_action = false;
+- BEGIN(SECT2);
+- }
+- }
+- . ACTION_ECHO;
++ doing_rule_action = false;
++ BEGIN(SECT2);
++ }
++ }
++ . ACTION_ECHO;
+ }
+
+ <ACTION_STRING>{
+- [^\]\"\\\n\[MmY]+ ACTION_ECHO;
++ [^\[\]\"\\\n]+ ACTION_ECHO;
+ \" ACTION_ECHO; BEGIN(ACTION);
+ }
+ <CHARACTER_CONSTANT>{
+- [^\[\]\'\\\nMmY]+ ACTION_ECHO;
+- \' ACTION_ECHO; yy_pop_state();
++ [^\[\]\'\\\n]+ ACTION_ECHO;
++ \' ACTION_ECHO; BEGIN(ACTION);
+ }
+ <ACTION_STRING,CHARACTER_CONSTANT>{
+- \\. ACTION_ECHO;
+- {NL} ++linenum; ACTION_ECHO;
+- . ACTION_ECHO;
++ (\\\n)* ACTION_ECHO;
++ \\(\\\n)*. ACTION_ECHO;
++ {NL} ++linenum; ACTION_ECHO; BEGIN(ACTION);
++ . ACTION_ECHO;
+ }
+
+ <COMMENT,CODE_COMMENT,COMMENT_DISCARD,ACTION,ACTION_STRING,CHARACTER_CONSTANT><<EOF>> {
+@@ -991,8 +991,8 @@ nmstr[yyleng - 2 - end_is_ws] = '\0'; /
+ <SECT3>{
+ {M4QSTART} fputs(escaped_qstart, yyout);
+ {M4QEND} fputs(escaped_qend, yyout);
+- [^\[\]\n]*(\n?) ECHO;
+- .|\n ECHO;
++ [^\[\]]* ECHO;
++ [][] ECHO;
+ <<EOF>> {
+ sectnum = 0;
+ yyterminate();
+@@ -1001,8 +1001,8 @@ nmstr[yyleng - 2 - end_is_ws] = '\0'; /
+ <SECT3_NOESCAPE>{
+ {M4QSTART} fprintf(yyout, "[""[%s]""]", escaped_qstart);
+ {M4QEND} fprintf(yyout, "[""[%s]""]", escaped_qend);
+- [^\[\]\n]*(\n?) ECHO;
+- (.|\n) ECHO;
++ [^][]* ECHO;
++ [][] ECHO;
+ <<EOF>> {
+ sectnum = 0;
+ yyterminate();