diff options
author | Federico Ferri <mescalinum@gentoo.org> | 2009-09-09 23:57:42 +0000 |
---|---|---|
committer | Federico Ferri <mescalinum@gentoo.org> | 2009-09-09 23:57:42 +0000 |
commit | 569885ec6e2c258e981995b85157ce6d586a2f17 (patch) | |
tree | 9ac8a34dac0c17dd818ce7daf7986a0c8447fa2d /dev-tcltk | |
parent | Bug #270712: Fix build with non-Sun javac. (diff) | |
download | gentoo-2-569885ec6e2c258e981995b85157ce6d586a2f17.tar.gz gentoo-2-569885ec6e2c258e981995b85157ce6d586a2f17.tar.bz2 gentoo-2-569885ec6e2c258e981995b85157ce6d586a2f17.zip |
new package
(Portage version: 2.2_rc40/cvs/Linux x86_64)
Diffstat (limited to 'dev-tcltk')
-rw-r--r-- | dev-tcltk/tclCheck/ChangeLog | 10 | ||||
-rw-r--r-- | dev-tcltk/tclCheck/metadata.xml | 29 | ||||
-rw-r--r-- | dev-tcltk/tclCheck/tclCheck-1.1.13.ebuild | 33 |
3 files changed, 72 insertions, 0 deletions
diff --git a/dev-tcltk/tclCheck/ChangeLog b/dev-tcltk/tclCheck/ChangeLog new file mode 100644 index 000000000000..aeba49619fc2 --- /dev/null +++ b/dev-tcltk/tclCheck/ChangeLog @@ -0,0 +1,10 @@ +# ChangeLog for dev-tcltk/tclCheck +# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/dev-tcltk/tclCheck/ChangeLog,v 1.1 2009/09/09 23:57:42 mescalinum Exp $ + +*tclCheck-1.1.13 (09 Sep 2009) + + 09 Sep 2009; Federico Ferri <mescalinum@gentoo.org> + +tclCheck-1.1.13.ebuild, +metadata.xml: + new package: tclCheck + diff --git a/dev-tcltk/tclCheck/metadata.xml b/dev-tcltk/tclCheck/metadata.xml new file mode 100644 index 000000000000..e5e33eb1d214 --- /dev/null +++ b/dev-tcltk/tclCheck/metadata.xml @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<herd>tcltk</herd> +<maintainer> + <email>mescalinum@gentoo.org</email> +</maintainer> +<longdescription> +Missing/extra/wrong brackets are a common problem when creating a tcl/tk program (at least for me anyway). tclCheck is a VERY SIMPLE C program that carries out a sanity check for brackets and their nesting. Why a C program? The original was a tcl program but it was simply too slow when run on large files. + +tcl's rules for nesting and bracketing are pretty bizarre and are very context dependent, so tclCheck takes a rather conservative view and will flag things that may not in fact be errors. This generally occurs inside strings, so that ":-(" throws up an error on the (. If you want to shut tclCheck up put a \ in front of any troublesome characters. The program does try to recognise when it might be inside in a comment as people do seem to write things like : + +# 1) blah blah blah + +If you want to turn off this behaviour invoke tclCheck with the -c flag. + +Simple bracket matching is not all that useful for finding a missing bracket, so tclCheck provides two other flags that might help you track them down. The -s outputs onto stout a line numbered skeleton of the program. That is it outputs only leading whitespace on lines and any brackets that they may contain. Lines with no brackets will not be listed. The -m option provides the extra facility that where brackets pair up directly they will not be printed either, so the listing will only contain those brackets which are not matched on the line on which they occur. Note that the -sm picture may not be quite right where " " pairs occur next to each other. Even further compression of the output will be obtained by using or adding the -l flag which will remove nested lines which pair up. Using the -j flag is similar to -l but ignores any indentation scheme which might work better for you. + +tclCheck will now pop its bracket stack to find a match with } > ] > ). If you do not want this to happen specify the -g flag. + +The -i flag turns off error messages that begin "Inside a string". The -q option will generate output only when it detects a problem (except if any if the -jlms flags are set - the skeleton is always printed). + +tclCheck checks all the files passed on the command line or the standard input if this is empty. Messages about potential problems are sent to the standard output. + +I have run tclCheck over some of the larger packages in the archive and it seems to behave in a sensible manner. In fact it finds what appear to me to be errors in some of them. You may need to try various combinations of flags to locate particular errors. tclCheck is most definitely geared towards the way that I format programs and so it works well for me (particularly the -lms options). You may have a different style and if I can include this in some way let me know. + +Thanks to Hans Stoop (hast@wmt.nl) for the stack popping code (which I messed up but have now fixed....) +</longdescription> +</pkgmetadata> diff --git a/dev-tcltk/tclCheck/tclCheck-1.1.13.ebuild b/dev-tcltk/tclCheck/tclCheck-1.1.13.ebuild new file mode 100644 index 000000000000..b154df1a5702 --- /dev/null +++ b/dev-tcltk/tclCheck/tclCheck-1.1.13.ebuild @@ -0,0 +1,33 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-tcltk/tclCheck/tclCheck-1.1.13.ebuild,v 1.1 2009/09/09 23:57:42 mescalinum Exp $ + +EAPI=2 + +inherit toolchain-funcs + +DESCRIPTION="Check for missing/extra/wrong brackets in a Tcl script" +HOMEPAGE="http://catless.ncl.ac.uk/Programs/tclCheck/" +SRC_URI="ftp://catless.ncl.ac.uk/pub/${P}.tar.gz" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="" + +DEPEND="dev-lang/tcl" +RDEPEND="${DEPEND}" + +src_prepare() { + sed -i -e '/\$(CC)/s/\<-s\>//g' Makefile +} + +src_compile() { + emake CC="$(tc-getCC)" || die "emake failed" +} + +src_install() { + dobin tclCheck || die "install bin failed ($?)" + doman tclCheck.1 || die "install man error" + dodoc README || die "install doc error" +} |