diff options
| author | Robin Haberkorn <rhaberkorn@fmsbw.de> | 2026-06-21 22:10:44 +0200 |
|---|---|---|
| committer | Robin Haberkorn <rhaberkorn@fmsbw.de> | 2026-06-21 22:10:44 +0200 |
| commit | d2b12491df9e4fc6cdaddcd0af9b43b08d821775 (patch) | |
| tree | 84242560cc7189491787075978690a00f89bf9c5 | |
| parent | ba7d2c8e48711cf089c35745234d71574bc7ae7f (diff) | |
| download | terex-d2b12491df9e4fc6cdaddcd0af9b43b08d821775.tar.gz | |
renamed hsrex to terex
This will be the SciTECO regular expression engine and we have to fork
it permanently.
| -rw-r--r-- | Makefile | 6 | ||||
| -rw-r--r-- | README | 12 | ||||
| -rwxr-xr-x | regtest_terex.sh (renamed from regtest_hsrex.sh) | 11 |
3 files changed, 15 insertions, 14 deletions
@@ -6,11 +6,11 @@ CFLAGS = -Wall -DREGEX_STANDALONE -fPIC -DREG_DEBUG -g LDFLAGS = -shared SRCS = regcomp.c regexec.c regerror.c regfree.c OBJS = $(SRCS:.c=.o) -BINS = libhsrex.so libhsurex.so +BINS = libterex.so libteurex.so all: - make libhsrex.so + make libterex.so rm -f $(OBJS) - make "CFLAGS=$(CFLAGS) -DREGEX_UTF8" libhsurex.so + make "CFLAGS=$(CFLAGS) -DREGEX_UTF8" libteurex.so $(BINS): $(OBJS) $(CC) $(LDFLAGS) -o $@ $(OBJS) clean: @@ -8,18 +8,18 @@ possible. Some *.h files suffered dirty updates for the same reasons. To build and test make - ./regtest_hsrex.sh + ./regtest_terex.sh To rebuild make clean make To build against the other library uncomment the proper line in the file -regtest_hsrex.sh and execute again. +regtest_terex.sh and execute again. # Either this one - $CC -I. -I$H/inc -L. -lhsrex -o $rgbin $rgsrc + $CC -I. -I$H/inc -L. -lterex -o $rgbin $rgsrc # or this one - #$CC -I. -I$H/inc -L. -lhsurex -DREGEX_UTF8 -o $rgbin $rgsrc + #$CC -I. -I$H/inc -L. -lteurex -DREGEX_UTF8 -o $rgbin $rgsrc You would like to test with debuging information. Uncomment the proper line in the Makefile and rebuild. @@ -28,7 +28,7 @@ the Makefile and rebuild. # Or this one CFLAGS = -DREGEX_STANDALONE -fPIC -D_NDEBUG -O3 -Two libraries are provided, libhsrex.so and libhsurex.so. The first one is for +Two libraries are provided, libterex.so and libteurex.so. The first one is for ascii character code and the second one for wide characters. Both libraries were tested in Linux and Solaris. Compiling and runing in Window$ should be easy. @@ -43,7 +43,7 @@ It is pretty easy to add support for a regcomp() regexec() front end. That front end functions should take care of UTF-8 to wide charater conversion, for instance. -The regression test script regtest_hsrex.sh contains an example of how to use +The regression test script regtest_terex.sh contains an example of how to use the libraries. It just test cases I was interested on. Adding more use cases to that script should be easy. diff --git a/regtest_hsrex.sh b/regtest_terex.sh index 566a9f3..ca499d8 100755 --- a/regtest_hsrex.sh +++ b/regtest_terex.sh @@ -3,20 +3,21 @@ # Copyright (c) 2002, Stooges & Cueless CO., All rights reserved. # # Module: -# @(#)regtest_hsrex.sh 1.0 (Stooges & Clueless) 04/xx/02 +# @(#)regtest_terex.sh 1.0 (Stooges & Clueless) 04/xx/02 # Purpose: # @(#)Perform regression test to Henry Spencer's RE libary. # Author: # Walter Waldo # History: # 04/xx/02 (ww) Version 1.0 +# 06/xx/26 (rh) Adaptions for terex # #set -x H=$HOME me=`basename $0` -rgsrc=regtest_hsrex.c -rgbin=regtest_hsrex +rgsrc=regtest_terex.c +rgbin=regtest_terex datsrc=regtest_data.c datbin=regtest_data CC=gcc @@ -153,9 +154,9 @@ PATH=.:$PATH LD_LIBRARY_PATH=.:$LD_LIBRARY_PATH export PATH LD_LIBRARY_PATH # Either this one -#$CC -Wall -g -O0 -I. -I$H/inc -L. -lhsrex -o $rgbin $rgsrc # Test ascii ch +#$CC -Wall -g -O0 -I. -I$H/inc -L. -lterex -o $rgbin $rgsrc # Test ascii ch # Or this one -$CC -Wall -g -O0 -I. -I$H/inc -L. -lhsurex -DREGEX_UTF8 -o $rgbin $rgsrc # Test wide ch +$CC -Wall -g -O0 -I. -I$H/inc -L. -lteurex -DREGEX_UTF8 -o $rgbin $rgsrc # Test wide ch #----------------------------------- resp=`$rgbin 0 "clavo" "Pablito clavo un clavito" 2>&1` msg="Simple match" |
