Sat Oct 15 08:28:21 2011 UTC ()
Pullup ticket #3556 - requested by dholland
devel/cxref: build fix

Revisions pulled up:
- devel/cxref/Makefile                                          1.14
- devel/cxref/distinfo                                          1.8-1.9
- devel/cxref/patches/patch-src_parse_l                         1.1

---
   Module Name:	pkgsrc
   Committed By:	dholland
   Date:		Thu Oct 13 21:30:00 UTC 2011

   Modified Files:
   	pkgsrc/devel/cxref: Makefile distinfo

   Log Message:
   Update to 1.6d.

   Version 1.6d of cxref released : Mon Oct 3 14:00:00 2011
   --------------------------------------------------------

   Bug fixes
    Updated for latest version of autoconf.
    Allow structure initialisers to have multiple components (e.g. a.b=1).
    Remove gcc warning messages.
    Change Makefile for better comptibility with FreeBSD.

   Version 1.6c of cxref released : Mon May 31 10:00:00 2010
   ---------------------------------------------------------

   Bug fixes
    Handle the gcc __builtin_offsetof() and offsetof() functions.
    Check that the lex/yacc programs actually exist at configure time.
    Handle ASM statements with named identifiers in them.

   Parsing changes
    Removed the char_varying type.

   Document changes
    Update web page links

---
   Module Name:	pkgsrc
   Committed By:	dholland
   Date:		Thu Oct 13 22:11:26 UTC 2011

   Modified Files:
   	pkgsrc/devel/cxref: distinfo
   Added Files:
   	pkgsrc/devel/cxref/patches: patch-src_parse_l

   Log Message:
   Patch the lexer to ignore _Pragma().


(tron)
diff -r1.13 -r1.13.24.1 pkgsrc/devel/cxref/Makefile
diff -r1.7 -r1.7.24.1 pkgsrc/devel/cxref/distinfo
diff -r0 -r1.1.2.2 pkgsrc/devel/cxref/patches/patch-src_parse_l

cvs diff -r1.13 -r1.13.24.1 pkgsrc/devel/cxref/Makefile (expand / switch to unified diff)

--- pkgsrc/devel/cxref/Makefile 2008/11/06 17:45:46 1.13
+++ pkgsrc/devel/cxref/Makefile 2011/10/15 08:28:21 1.13.24.1
@@ -1,16 +1,16 @@ @@ -1,16 +1,16 @@
1# $NetBSD: Makefile,v 1.13 2008/11/06 17:45:46 snj Exp $ 1# $NetBSD: Makefile,v 1.13.24.1 2011/10/15 08:28:21 tron Exp $
2 2
3DISTNAME= cxref-1.6b 3DISTNAME= cxref-1.6d
4CATEGORIES= devel lang 4CATEGORIES= devel lang
5MASTER_SITES= http://www.gedanken.demon.co.uk/download-cxref/ 5MASTER_SITES= http://www.gedanken.demon.co.uk/download-cxref/
6EXTRACT_SUFX= .tgz 6EXTRACT_SUFX= .tgz
7 7
8MAINTAINER= pkgsrc-users@NetBSD.org 8MAINTAINER= pkgsrc-users@NetBSD.org
9HOMEPAGE= http://www.gedanken.demon.co.uk/cxref/ 9HOMEPAGE= http://www.gedanken.demon.co.uk/cxref/
10COMMENT= C Cross Referencing & Documenting tool 10COMMENT= C Cross Referencing & Documenting tool
11 11
12PKG_DESTDIR_SUPPORT= user-destdir 12PKG_DESTDIR_SUPPORT= user-destdir
13 13
14GNU_CONFIGURE= yes 14GNU_CONFIGURE= yes
15CONFIGURE_ARGS+= --with-cxref-cpp 15CONFIGURE_ARGS+= --with-cxref-cpp
16CONFIGURE_ARGS+= PERL="" # Don't regenerate documentation 16CONFIGURE_ARGS+= PERL="" # Don't regenerate documentation

cvs diff -r1.7 -r1.7.24.1 pkgsrc/devel/cxref/distinfo (expand / switch to unified diff)

--- pkgsrc/devel/cxref/distinfo 2008/11/06 17:45:46 1.7
+++ pkgsrc/devel/cxref/distinfo 2011/10/15 08:28:21 1.7.24.1
@@ -1,6 +1,7 @@ @@ -1,6 +1,7 @@
1$NetBSD: distinfo,v 1.7 2008/11/06 17:45:46 snj Exp $ 1$NetBSD: distinfo,v 1.7.24.1 2011/10/15 08:28:21 tron Exp $
2 2
3SHA1 (cxref-1.6b.tgz) = b036b4f744dafca3091eee51c20c71ac57017c51 3SHA1 (cxref-1.6d.tgz) = b984d85da7b7fa39794932e6fe85a0657f6240bb
4RMD160 (cxref-1.6b.tgz) = 8cb5d13b58749714b14bd57dc8085c841d7f8772 4RMD160 (cxref-1.6d.tgz) = 3760f2f074ec26b6702efbd38f24f0bb231488e0
5Size (cxref-1.6b.tgz) = 393302 bytes 5Size (cxref-1.6d.tgz) = 415744 bytes
6SHA1 (patch-aa) = 0696dc7e2c027ebbbfb6747ff36ec9f9a36b7a88 6SHA1 (patch-aa) = 0696dc7e2c027ebbbfb6747ff36ec9f9a36b7a88
 7SHA1 (patch-src_parse_l) = 38638d7ac187ddebec2fb446f38adaace3ef3712

File Added: pkgsrc/devel/cxref/patches/patch-src_parse_l
$NetBSD: patch-src_parse_l,v 1.1.2.2 2011/10/15 08:28:21 tron Exp $

Recognize and ignore _Pragma(), needed for -current's headers.

--- src/parse.l~	2011-06-18 09:45:04.000000000 +0000
+++ src/parse.l
@@ -14,6 +14,7 @@ IS                      ((u|U|l|L)+|([iI
 %x CPP_INCLUDE CPP_INC_FILE CPP_INC_FLAGS
 %x CPP_DEFINE CPP_DEFINE_ARGP CPP_DEFINE_BODY CPP_DEFINE_ARGS
 %x GNU_LABEL GNU_VA_ARG GNU_ATTRIBUTE GNU_TYPEOF GNU_OFFSETOF
+%x C99_PRAGMA
 
 %{
 /***************************************
@@ -83,6 +84,9 @@ static int gnu_typ_depth=0;
 /*+ To get around the GCC __offsetof keyword, skip over matched () counted by this. +*/
 static int gnu_offset_depth=0;
 
+/*+ To get around the C99 _Pragma keyword, skip over matched () counted by this. +*/
+static int c99_prag_depth=0;
+
 /*+ If we see a comment immediately after a ',', ';', '};', '},' or ')' then push it before. +*/
 static int push_past=0;
 
@@ -311,6 +315,11 @@ static int push_past=0;
 "_Complex"              {  }
 "_Bool"                 { yylval="_Bool";    return(BOOL);     }
 
+("_Pragma") { c99_prag_depth=0; BEGIN(C99_PRAGMA); }
+<C99_PRAGMA>"("                    { c99_prag_depth++; }
+<C99_PRAGMA>[^()]+                 { }
+<C99_PRAGMA>")"                    { if(--c99_prag_depth==0) { BEGIN(INITIAL); } }
+
  /* C language keywords. */
 
 "auto"                  { yylval="auto"    ; return(AUTO);     }