This repository has been archived by the owner on Nov 20, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[luadist-git] add regex-3.8a-Ubuntu-x86_64
- Loading branch information
0 parents
commit 2254ec3
Showing
6 changed files
with
244 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
type = "x86_64" | ||
arch = "Ubuntu" | ||
author = "Henry Spencer" | ||
desc = "Henry Spencer's regular expressions library" | ||
name = "regex" | ||
maintainer = "Peter Kapec" | ||
files = { | ||
Runtime = { | ||
[[lib/librxspencer.so]], | ||
} | ||
, | ||
Header = { | ||
[[include/regex.h]], | ||
} | ||
, | ||
Data = { | ||
[[share/regex/COPYRIGHT]], | ||
[[share/regex/README]], | ||
[[share/regex/WHATSNEW]], | ||
} | ||
, | ||
} | ||
|
||
license = "see COPYRIGHT" | ||
url = "http://arglist.com/regex/" | ||
version = "3.8a" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
#ifndef _REGEX_H_ | ||
#define _REGEX_H_ | ||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
typedef off_t regoff_t; | ||
typedef struct { | ||
int re_magic; | ||
size_t re_nsub; // number of parenthesized subexpressions | ||
const char *re_endp; // end pointer for REG_PEND | ||
struct re_guts *re_g; // none of your business :-) | ||
} regex_t; | ||
typedef struct { | ||
regoff_t rm_so; // start of match | ||
regoff_t rm_eo; // end of match | ||
} regmatch_t; | ||
extern int regcomp(regex_t *, const char *, int); | ||
#define REG_BASIC 0000 | ||
#define REG_EXTENDED 0001 | ||
#define REG_ICASE 0002 | ||
#define REG_NOSUB 0004 | ||
#define REG_NEWLINE 0010 | ||
#define REG_NOSPEC 0020 | ||
#define REG_PEND 0040 | ||
#define REG_DUMP 0200 | ||
#define REG_OKAY 0 | ||
#define REG_NOMATCH 1 | ||
#define REG_BADPAT 2 | ||
#define REG_ECOLLATE 3 | ||
#define REG_ECTYPE 4 | ||
#define REG_EESCAPE 5 | ||
#define REG_ESUBREG 6 | ||
#define REG_EBRACK 7 | ||
#define REG_EPAREN 8 | ||
#define REG_EBRACE 9 | ||
#define REG_BADBR 10 | ||
#define REG_ERANGE 11 | ||
#define REG_ESPACE 12 | ||
#define REG_BADRPT 13 | ||
#define REG_EMPTY 14 | ||
#define REG_ASSERT 15 | ||
#define REG_INVARG 16 | ||
#define REG_ATOI 255 // convert name to number (!) | ||
#define REG_ITOA 0400 // convert number to name (!) | ||
extern size_t regerror(int, const regex_t *, char *, size_t); | ||
extern int regexec(const regex_t *, const char *, size_t, \ | ||
regmatch_t [], int); | ||
#define REG_NOTBOL 00001 | ||
#define REG_NOTEOL 00002 | ||
#define REG_STARTEND 00004 | ||
#define REG_TRACE 00400 // tracing of execution | ||
#define REG_LARGE 01000 // force large representation | ||
#define REG_BACKR 02000 // force use of backref code | ||
extern void regfree(regex_t *); | ||
#ifdef __cplusplus | ||
} | ||
#endif | ||
#endif |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
Copyright 1992, 1993, 1994, 1997 Henry Spencer. All rights reserved. | ||
This software is not subject to any license of the American Telephone | ||
and Telegraph Company or of the Regents of the University of California. | ||
|
||
Permission is granted to anyone to use this software for any purpose on | ||
any computer system, and to alter it and redistribute it, subject | ||
to the following restrictions: | ||
|
||
1. The author is not responsible for the consequences of use of this | ||
software, no matter how awful, even if they arise from flaws in it. | ||
|
||
2. The origin of this software must not be misrepresented, either by | ||
explicit claim or by omission. Since few users ever read sources, | ||
credits must appear in the documentation. | ||
|
||
3. Altered versions must be plainly marked as such, and must not be | ||
misrepresented as being the original software. Since few users | ||
ever read sources, credits must appear in the documentation. | ||
|
||
4. This notice may not be removed or altered. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
alpha3.8 release. | ||
Tue Aug 10 15:51:48 EDT 1999 | ||
henry@spsystems.net (formerly henry@zoo.toronto.edu) | ||
|
||
See WHATSNEW for change listing. | ||
|
||
installation notes: | ||
-------- | ||
Read the comments at the beginning of Makefile before running. | ||
|
||
Utils.h contains some things that just might have to be modified on | ||
some systems, as well as a nested include (ugh) of <assert.h>. | ||
|
||
The "fake" directory contains quick-and-dirty fakes for some header | ||
files and routines that old systems may not have. Note also that | ||
-DUSEBCOPY will make utils.h substitute bcopy() for memmove(). | ||
|
||
After that, "make r" will build regcomp.o, regexec.o, regfree.o, | ||
and regerror.o (the actual routines), bundle them together into a test | ||
program, and run regression tests on them. No output is good output. | ||
|
||
"make lib" builds just the .o files for the actual routines (when | ||
you're happy with testing and have adjusted CFLAGS for production), | ||
and puts them together into libregex.a. You can pick up either the | ||
library or *.o ("make lib" makes sure there are no other .o files left | ||
around to confuse things). | ||
|
||
Main.c, debug.c, split.c are used for regression testing but are not part | ||
of the RE routines themselves. | ||
|
||
Regex.h goes in /usr/include. All other .h files are internal only. | ||
-------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
New in alpha3.8: Bug fix for signed/unsigned mixup, found and fixed | ||
by the FreeBSD folks. | ||
|
||
New in alpha3.7: A bit of cleanup aimed at maximizing portability, | ||
possibly at slight cost in efficiency. "ul" suffixes and "unsigned long" | ||
no longer appear, in particular. | ||
|
||
New in alpha3.6: A couple more portability glitches fixed. | ||
|
||
New in alpha3.5: Active development of this code has been stopped -- | ||
I'm working on a complete reimplementation -- but folks have found some | ||
minor portability glitches and the like, hence this release to fix them. | ||
One penalty: slightly reduced compatibility with old compilers, because | ||
the ANSI C `unsigned long' type and `ul' constant suffix are used in a | ||
few places (I could avoid this but it would be considerably more work). | ||
|
||
New in alpha3.4: The complex bug alluded to below has been fixed (in a | ||
slightly kludgey temporary way that may hurt efficiency a bit; this is | ||
another "get it out the door for 4.4" release). The tests at the end of | ||
the tests file have accordingly been uncommented. The primary sign of | ||
the bug was that something like a?b matching ab matched b rather than ab. | ||
(The bug was essentially specific to this exact situation, else it would | ||
have shown up earlier.) | ||
|
||
New in alpha3.3: The definition of word boundaries has been altered | ||
slightly, to more closely match the usual programming notion that "_" | ||
is an alphabetic. Stuff used for pre-ANSI systems is now in a subdir, | ||
and the makefile no longer alludes to it in mysterious ways. The | ||
makefile has generally been cleaned up some. Fixes have been made | ||
(again!) so that the regression test will run without -DREDEBUG, at | ||
the cost of weaker checking. A workaround for a bug in some folks' | ||
<assert.h> has been added. And some more things have been added to | ||
tests, including a couple right at the end which are commented out | ||
because the code currently flunks them (complex bug; fix coming). | ||
Plus the usual minor cleanup. | ||
|
||
New in alpha3.2: Assorted bits of cleanup and portability improvement | ||
(the development base is now a BSDI system using GCC instead of an ancient | ||
Sun system, and the newer compiler exposed some glitches). Fix for a | ||
serious bug that affected REs using many [] (including REG_ICASE REs | ||
because of the way they are implemented), *sometimes*, depending on | ||
memory-allocation patterns. The header-file prototypes no longer name | ||
the parameters, avoiding possible name conflicts. The possibility that | ||
some clot has defined CHAR_MIN as (say) `-128' instead of `(-128)' is | ||
now handled gracefully. "uchar" is no longer used as an internal type | ||
name (too many people have the same idea). Still the same old lousy | ||
performance, alas. | ||
|
||
New in alpha3.1: Basically nothing, this release is just a bookkeeping | ||
convenience. Stay tuned. | ||
|
||
New in alpha3.0: Performance is no better, alas, but some fixes have been | ||
made and some functionality has been added. (This is basically the "get | ||
it out the door in time for 4.4" release.) One bug fix: regfree() didn't | ||
free the main internal structure (how embarrassing). It is now possible | ||
to put NULs in either the RE or the target string, using (resp.) a new | ||
REG_PEND flag and the old REG_STARTEND flag. The REG_NOSPEC flag to | ||
regcomp() makes all characters ordinary, so you can match a literal | ||
string easily (this will become more useful when performance improves!). | ||
There are now primitives to match beginnings and ends of words, although | ||
the syntax is disgusting and so is the implementation. The REG_ATOI | ||
debugging interface has changed a bit. And there has been considerable | ||
internal cleanup of various kinds. | ||
|
||
New in alpha2.3: Split change list out of README, and moved flags notes | ||
into Makefile. Macro-ized the name of regex(7) in regex(3), since it has | ||
to change for 4.4BSD. Cleanup work in engine.c, and some new regression | ||
tests to catch tricky cases thereof. | ||
|
||
New in alpha2.2: Out-of-date manpages updated. Regerror() acquires two | ||
small extensions -- REG_ITOA and REG_ATOI -- which avoid debugging kludges | ||
in my own test program and might be useful to others for similar purposes. | ||
The regression test will now compile (and run) without REDEBUG. The | ||
BRE \$ bug is fixed. Most uses of "uchar" are gone; it's all chars now. | ||
Char/uchar parameters are now written int/unsigned, to avoid possible | ||
portability problems with unpromoted parameters. Some unsigned casts have | ||
been introduced to minimize portability problems with shifting into sign | ||
bits. | ||
|
||
New in alpha2.1: Lots of little stuff, cleanup and fixes. The one big | ||
thing is that regex.h is now generated, using mkh, rather than being | ||
supplied in the distribution; due to circularities in dependencies, | ||
you have to build regex.h explicitly by "make h". The two known bugs | ||
have been fixed (and the regression test now checks for them), as has a | ||
problem with assertions not being suppressed in the absence of REDEBUG. | ||
No performance work yet. | ||
|
||
New in alpha2: Backslash-anything is an ordinary character, not an | ||
error (except, of course, for the handful of backslashed metacharacters | ||
in BREs), which should reduce script breakage. The regression test | ||
checks *where* null strings are supposed to match, and has generally | ||
been tightened up somewhat. Small bug fixes in parameter passing (not | ||
harmful, but technically errors) and some other areas. Debugging | ||
invoked by defining REDEBUG rather than not defining NDEBUG. | ||
|
||
New in alpha+3: full prototyping for internal routines, using a little | ||
helper program, mkh, which extracts prototypes given in stylized comments. | ||
More minor cleanup. Buglet fix: it's CHAR_BIT, not CHAR_BITS. Simple | ||
pre-screening of input when a literal string is known to be part of the | ||
RE; this does wonders for performance. | ||
|
||
New in alpha+2: minor bits of cleanup. Notably, the number "32" for the | ||
word width isn't hardwired into regexec.c any more, the public header | ||
file prototypes the functions if __STDC__ is defined, and some small typos | ||
in the manpages have been fixed. | ||
|
||
New in alpha+1: improvements to the manual pages, and an important | ||
extension, the REG_STARTEND option to regexec(). |