summaryrefslogtreecommitdiff
path: root/devel/cqual
diff options
context:
space:
mode:
authorrillig <rillig>2006-07-17 22:16:55 +0000
committerrillig <rillig>2006-07-17 22:16:55 +0000
commitf2135450743ca7c1d067bacef1f3c7bb2a63bf9c (patch)
treeb91fd196f629492667dc3c417c3b018ccdae2d8e /devel/cqual
parent0f4db93f82efa97aacd0005a60b6ad6847588337 (diff)
downloadpkgsrc-f2135450743ca7c1d067bacef1f3c7bb2a63bf9c.tar.gz
Fixed an internal cqual error. Improved the gcqual program. Added a
debugging option. Bumped PKGREVISION.
Diffstat (limited to 'devel/cqual')
-rw-r--r--devel/cqual/Makefile6
-rw-r--r--devel/cqual/distinfo5
-rw-r--r--devel/cqual/options.mk13
-rw-r--r--devel/cqual/patches/patch-aa20
-rw-r--r--devel/cqual/patches/patch-ce36
5 files changed, 72 insertions, 8 deletions
diff --git a/devel/cqual/Makefile b/devel/cqual/Makefile
index c3a246d7d5f..0eecc09fe32 100644
--- a/devel/cqual/Makefile
+++ b/devel/cqual/Makefile
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.12 2006/06/29 10:59:23 rillig Exp $
+# $NetBSD: Makefile,v 1.13 2006/07/17 22:16:55 rillig Exp $
#
DISTNAME= cqual-0.991
-PKGREVISION= 6
+PKGREVISION= 7
CATEGORIES= devel
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=cqual/}
@@ -19,6 +19,8 @@ INFO_FILES= yes
INSTALLATION_DIRS= share/doc/cqual share/examples/cqual
+.include "options.mk"
+
.include "../../mk/bsd.prefs.mk"
.if ${OPSYS} == "SunOS" && ${OS_VERSION} == "5.8"
diff --git a/devel/cqual/distinfo b/devel/cqual/distinfo
index ea9a15e55ac..eed9a070bdf 100644
--- a/devel/cqual/distinfo
+++ b/devel/cqual/distinfo
@@ -1,9 +1,9 @@
-$NetBSD: distinfo,v 1.8 2006/07/02 09:34:01 rillig Exp $
+$NetBSD: distinfo,v 1.9 2006/07/17 22:16:55 rillig Exp $
SHA1 (cqual-0.991.tar.gz) = f559af6947465ca242f19c1f499c7cb004e713e4
RMD160 (cqual-0.991.tar.gz) = e3837a11c75f750196ec4be7f991ec519c1260f6
Size (cqual-0.991.tar.gz) = 1197696 bytes
-SHA1 (patch-aa) = d1477b709c9b3569fe4fa4e3e0afc1f8314892c2
+SHA1 (patch-aa) = 5ccdb7354ad0fc5b993133ca748a106d2f3dc30f
SHA1 (patch-ab) = 5ededa6979542cb83c53abd38fe9923495562a99
SHA1 (patch-ac) = 0aee16d388ff2d40ca176c0f313505d83ee3aa52
SHA1 (patch-ba) = 316aae97a0031bbe229baaa0519ad25a2b901663
@@ -23,3 +23,4 @@ SHA1 (patch-ca) = fb4806cfb3c2347fe5089f42e419c57bec7e2432
SHA1 (patch-cb) = 568df77eefeea982d9a7faa638c6be12a54fa284
SHA1 (patch-cc) = f30adeec491d999b63e1ad5abd2b34c287608e5e
SHA1 (patch-cd) = 1d9b0197b13f2414054d47e4a6ae3bf8920463bf
+SHA1 (patch-ce) = f9079f2c306bad8c9c0539759c4541b8bee7cda4
diff --git a/devel/cqual/options.mk b/devel/cqual/options.mk
new file mode 100644
index 00000000000..12808d86e34
--- /dev/null
+++ b/devel/cqual/options.mk
@@ -0,0 +1,13 @@
+# $NetBSD: options.mk,v 1.1 2006/07/17 22:16:55 rillig Exp $
+#
+
+PKG_SUPPORTED_OPTIONS= debug
+PKG_SUGGESTED_OPTIONS= # none
+PKG_OPTIONS_VAR= PKG_OPTIONS.cqual
+
+.include "../../mk/bsd.options.mk"
+
+.if !empty(PKG_OPTIONS:Mdebug)
+pre-configure:
+ ${ECHO} "Enable debugging" > ${WRKSRC}/TODO-LOCAL
+.endif
diff --git a/devel/cqual/patches/patch-aa b/devel/cqual/patches/patch-aa
index 4f9805332b5..25bb88bd6d5 100644
--- a/devel/cqual/patches/patch-aa
+++ b/devel/cqual/patches/patch-aa
@@ -1,9 +1,12 @@
-$NetBSD: patch-aa,v 1.2 2006/03/02 19:56:24 wiz Exp $
+$NetBSD: patch-aa,v 1.3 2006/07/17 22:16:55 rillig Exp $
Removed C++-style comments.
---- src/qtype.c.orig 2003-10-06 21:28:57.000000000 +0000
-+++ src/qtype.c
+Added the case of primitive types, since it had crashed when parsing the
+definition of fdopen().
+
+--- src/qtype.c.orig 2003-10-06 23:28:57.000000000 +0200
++++ src/qtype.c 2006-07-18 00:14:23.000000000 +0200
@@ -774,7 +774,7 @@ static void mktoplev_struct_cons_qtype(l
}
else if (exists_fieldflow_qual && fqt && (qtype_struct(qt) || qtype_union(qt))) {
@@ -22,7 +25,16 @@ Removed C++-style comments.
qtype result;
fname = field_decl_name(fdecl) ? field_decl_name(fdecl) : "(anonymous)";
-@@ -3352,8 +3352,6 @@ static bool mkXeq_qtype(location loc, qu
+@@ -2663,6 +2663,8 @@ aloc aloc_qtype(qtype qt)
+ qt = ecr_qtype(qt);
+ switch (qt->type->kind)
+ {
++ case tk_primitive:
++ return qt->type->u.prim.aloc;
+ case tk_pointer:
+ return qt->type->u.ptr.aloc;
+ case tk_pointer_loc:
+@@ -3352,8 +3354,6 @@ static bool mkXeq_qtype(location loc, qu
new_link = t1;
}
diff --git a/devel/cqual/patches/patch-ce b/devel/cqual/patches/patch-ce
new file mode 100644
index 00000000000..f88b34fb398
--- /dev/null
+++ b/devel/cqual/patches/patch-ce
@@ -0,0 +1,36 @@
+$NetBSD: patch-ce,v 1.1 2006/07/17 22:16:55 rillig Exp $
+
+- Use @CC@ instead of gcc for the compiler.
+- Prefer the installed cqual over the one in $PATH.
+- Error messages belong on stderr, not stdout.
+
+--- bin/gcqual.in.orig 2006-07-17 08:55:02.000000000 +0200
++++ bin/gcqual.in 2006-07-17 08:57:26.000000000 +0200
+@@ -22,10 +22,10 @@ use File::Basename;
+
+
+ # Global config options -- should probably do something smarter with $CC
+-$CC="gcc";
+-$cqual="cqual";
+-$pkgdatadir = "@prefix@/share/@PACKAGE@"; # Yuck. Is there a better way?
+-$scriptname = $0;
++my $CC = "@CC@";
++my $cqual = (-f "@prefix@/bin/cqual" ? "@prefix@/bin/cqual" : "cqual");
++my $pkgdatadir = "@prefix@/share/@PACKAGE@"; # Yuck. Is there a better way?
++my $scriptname = $0;
+
+ sub usage
+ {
+@@ -237,10 +237,10 @@ if ($#ifiles >= 0) {
+ }
+ print ("@cmd\n") if ($debug);
+ system(@cmd) == 0
+- or die "cqual failed: $?";
++ or die "cqual failed with exitcode " . ($?>>8) . ": $!";
+ }
+ else
+ {
+- print ("Could not parse command line args. No .c or .i files specified?\n");
++ print STDERR ("Could not parse command line args. No .c or .i files specified?\n");
+ usage();
+ }