diff options
author | hubertf <hubertf> | 2001-03-15 13:06:40 +0000 |
---|---|---|
committer | hubertf <hubertf> | 2001-03-15 13:06:40 +0000 |
commit | 7dee27b6baa8414139ddc5cf8df7bfe2309bab76 (patch) | |
tree | b6cb818a9a688bcfcdc526443b44a8c1d97bf9f1 /textproc | |
parent | 7f27acae2d193b90c9853f456be2b0f61eb1fbb3 (diff) | |
download | pkgsrc-7dee27b6baa8414139ddc5cf8df7bfe2309bab76.tar.gz |
Add astyle-1.13.6.1: reindenter and reformatter of C++, C and Java source code
When indenting source code, we as programmers have a tendency to
use both spaces and tab characters to create the wanted indentation.
Moreover, some editors by default insert spaces instead of tabs
when pressing the tab key, and other editors (Emacs for example)
have the ability to "pretty up" lines by automatically setting up
the white space before the code on the line, possibly inserting
spaces in a code that up to now used only tabs for indentation.
Since the NUMBER of space characters showed on screen for each tab
character in the source code changes between editors (until the
user sets up the number to his liking...), one of the standard
problems facing programmers when moving from one source code editor
to another is that code containing both spaces and tabs that was
up to now perfectly indented, suddently becomes a mess to look at
when changing to another editor. Even if you as a programmer take
care to ONLY use spaces or tabs, looking at other peoples source
code can still be problematic.
To address this problem I have created Artistic Style - a series
of filters, written in C++, that automatically reindent & reformat
C/C++/Java source files. These can be used from a command line, or
it can be incorporated as classes in another C++ program.
Submitted in PR 12402 by Thomas Runge <runge@rostock.zgdv.de>
Diffstat (limited to 'textproc')
-rw-r--r-- | textproc/astyle/Makefile | 24 | ||||
-rw-r--r-- | textproc/astyle/files/md5 | 3 | ||||
-rw-r--r-- | textproc/astyle/files/patch-sum | 3 | ||||
-rw-r--r-- | textproc/astyle/patches/patch-aa | 24 | ||||
-rw-r--r-- | textproc/astyle/pkg/DESCR | 22 | ||||
-rw-r--r-- | textproc/astyle/pkg/PLIST | 6 |
6 files changed, 82 insertions, 0 deletions
diff --git a/textproc/astyle/Makefile b/textproc/astyle/Makefile new file mode 100644 index 00000000000..b7974216642 --- /dev/null +++ b/textproc/astyle/Makefile @@ -0,0 +1,24 @@ +# $NetBSD: Makefile,v 1.1.1.1 2001/03/15 13:06:40 hubertf Exp $ +# + +DISTNAME= astyle_1.13.6.1 +PKGNAME= astyle-1.13.6.1 +CATEGORIES= textproc +MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=astyle/} +EXTRACT_SUFX= .zip + +MAINTAINER= packages@netbsd.org +HOMEPAGE= http://astyle.sourceforge.net/ +COMMENT= reindenter and reformatter of C++, C and Java source code + +HTMLDIR= ${PREFIX}/share/doc/html/astyle + +post-extract: + ${MV} -f ${WRKSRC}/makefile ${WRKSRC}/Makefile + +post-install: + ${INSTALL_DATA_DIR} ${HTMLDIR} + cd ${WRKSRC}; ${INSTALL_DATA} astyle.html astyle_release_notes.html\ + license.html ${HTMLDIR} + +.include "../../mk/bsd.pkg.mk" diff --git a/textproc/astyle/files/md5 b/textproc/astyle/files/md5 new file mode 100644 index 00000000000..96380ebae97 --- /dev/null +++ b/textproc/astyle/files/md5 @@ -0,0 +1,3 @@ +$NetBSD: md5,v 1.1.1.1 2001/03/15 13:06:40 hubertf Exp $ + +SHA1 (astyle_1.13.6.1.zip) = 4e0172fe30986d68c61b4a7c1638a1fc42ea0675 diff --git a/textproc/astyle/files/patch-sum b/textproc/astyle/files/patch-sum new file mode 100644 index 00000000000..fa471ff4fdc --- /dev/null +++ b/textproc/astyle/files/patch-sum @@ -0,0 +1,3 @@ +$NetBSD: patch-sum,v 1.1.1.1 2001/03/15 13:06:40 hubertf Exp $ + +SHA1 (patch-aa) = 963338c21b5015fd7a5284a57419557026ee8093 diff --git a/textproc/astyle/patches/patch-aa b/textproc/astyle/patches/patch-aa new file mode 100644 index 00000000000..98398f137ec --- /dev/null +++ b/textproc/astyle/patches/patch-aa @@ -0,0 +1,24 @@ +$NetBSD: patch-aa,v 1.1.1.1 2001/03/15 13:06:40 hubertf Exp $ + +--- Makefile.orig Fri Feb 11 12:02:10 2000 ++++ Makefile Tue Mar 13 14:58:01 2001 +@@ -1,7 +1,12 @@ + # "Artistic Style" Makefile + + CPPFLAGS = -Wall -Wno-sign-compare -O2 +-OBJS = ASResource.o ASBeautifier.o ASFormatter.o astyle_main.o ++OBJS = asresource.o asbeautifier.o asformatter.o astyle_main.o ++ ++all: astyle ++ ++install: ++ install -s -c astyle ${LOCALBASE}/bin/ + + astyle: $(OBJS) + g++ $(CPPFLAGS) -o astyle $(OBJS) +@@ -11,4 +16,4 @@ + .SUFFIXES: .cpp .c .o + + clean: +- rm *.o ++ rm *.o astyle diff --git a/textproc/astyle/pkg/DESCR b/textproc/astyle/pkg/DESCR new file mode 100644 index 00000000000..ad4bb342019 --- /dev/null +++ b/textproc/astyle/pkg/DESCR @@ -0,0 +1,22 @@ +When indenting source code, we as programmers have a tendency to +use both spaces and tab characters to create the wanted indentation. +Moreover, some editors by default insert spaces instead of tabs +when pressing the tab key, and other editors (Emacs for example) +have the ability to "pretty up" lines by automatically setting up +the white space before the code on the line, possibly inserting +spaces in a code that up to now used only tabs for indentation. + +Since the NUMBER of space characters showed on screen for each tab +character in the source code changes between editors (until the +user sets up the number to his liking...), one of the standard +problems facing programmers when moving from one source code editor +to another is that code containing both spaces and tabs that was +up to now perfectly indented, suddently becomes a mess to look at +when changing to another editor. Even if you as a programmer take +care to ONLY use spaces or tabs, looking at other peoples source +code can still be problematic. + +To address this problem I have created Artistic Style - a series +of filters, written in C++, that automatically reindent & reformat +C/C++/Java source files. These can be used from a command line, or +it can be incorporated as classes in another C++ program. diff --git a/textproc/astyle/pkg/PLIST b/textproc/astyle/pkg/PLIST new file mode 100644 index 00000000000..df8ebb2a54f --- /dev/null +++ b/textproc/astyle/pkg/PLIST @@ -0,0 +1,6 @@ +@comment $NetBSD: PLIST,v 1.1.1.1 2001/03/15 13:06:40 hubertf Exp $ +bin/astyle +share/doc/html/astyle/astyle.html +share/doc/html/astyle/astyle_release_notes.html +share/doc/html/astyle/license.html +@dirrm share/doc/html/astyle |