aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog12
-rw-r--r--NEWS2
-rw-r--r--configh.in3
-rwxr-xr-xconfigure8
-rw-r--r--configure.ac7
-rw-r--r--dfa.c12
-rw-r--r--doc/ChangeLog4
-rw-r--r--doc/gawk.info138
-rw-r--r--doc/gawk.texi4
-rw-r--r--doc/gawktexi.in4
-rw-r--r--main.c11
-rw-r--r--regcomp.c12
12 files changed, 96 insertions, 121 deletions
diff --git a/ChangeLog b/ChangeLog
index ff4760d9..f9f4549e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+2014-08-26 Arnold D. Robbins <arnold@skeeve.com>
+
+ Remove support for MirBSD. It uglified the code too much
+ for no discernable gain.
+
+ * configure.ac: Remove check for MirBSD and define of
+ LIBC_IS_BORKED.
+ * dfa.c: Remove code depending on LIBC_IS_BORKED.
+ * main.c: Ditto.
+ * regcomp.c: Ditto.
+ * NEWS: Updated.
+
2014-08-24 Arnold D. Robbins <arnold@skeeve.com>
* regex.h: Remove underscores in names of parameters in function
diff --git a/NEWS b/NEWS
index f8d9e55a..e1064220 100644
--- a/NEWS
+++ b/NEWS
@@ -32,6 +32,8 @@ Changes from 4.1.x to 4.2.0
7. Gawk now processes a maximum of two hexadecimal digits in \x
escape sequences inside strings.
+8. MirBSD is no longer supported.
+
Changes from 4.1.1 to 4.1.2
---------------------------
diff --git a/configh.in b/configh.in
index bfffd853..598852b4 100644
--- a/configh.in
+++ b/configh.in
@@ -317,9 +317,6 @@
/* Define to 1 if the system has the type `_Bool'. */
#undef HAVE__BOOL
-/* libc is broken for regex handling */
-#undef LIBC_IS_BORKED
-
/* disable lint checks */
#undef NO_LINT
diff --git a/configure b/configure
index 4dc9ce8d..99d5b9d2 100755
--- a/configure
+++ b/configure
@@ -5999,14 +5999,6 @@ then
CFLAGS="$CFLAGS -D_SYSV3"
fi
-case $host_os in
-mirbsd*)
-
-$as_echo "#define LIBC_IS_BORKED 1" >>confdefs.h
-
- ;;
-esac
-
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
diff --git a/configure.ac b/configure.ac
index e7e2d5f6..93514c6a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -119,13 +119,6 @@ dnl need -D_SYSV3 for ISC
CFLAGS="$CFLAGS -D_SYSV3"
fi
-dnl check for systems where libc is borked for regex handling
-case $host_os in
-mirbsd*)
- AC_DEFINE([LIBC_IS_BORKED], 1, [libc is broken for regex handling])
- ;;
-esac
-
dnl Set the programming language for checks. Fortunately,
dnl this only needs to be set once, since everything is in C.
AC_LANG([C])
diff --git a/dfa.c b/dfa.c
index 1a153785..2d0e7f20 100644
--- a/dfa.c
+++ b/dfa.c
@@ -77,14 +77,6 @@ is_blank (int c)
}
#endif /* GAWK */
-#ifdef LIBC_IS_BORKED
-extern int gawk_mb_cur_max;
-#undef MB_CUR_MAX
-#define MB_CUR_MAX gawk_mb_cur_max
-#undef mbrtowc
-#define mbrtowc(a, b, c, d) (-1)
-#endif
-
/* HPUX defines these as macros in sys/param.h. */
#ifdef setbit
# undef setbit
@@ -828,10 +820,6 @@ using_utf8 (void)
wchar_t wc;
mbstate_t mbs = { 0 };
utf8 = mbrtowc (&wc, "\xc4\x80", 2, &mbs) == 2 && wc == 0x100;
-#ifdef LIBC_IS_BORKED
- if (gawk_mb_cur_max == 1)
- utf8 = 0;
-#endif
}
return utf8;
}
diff --git a/doc/ChangeLog b/doc/ChangeLog
index 38b66d50..ddd2280e 100644
--- a/doc/ChangeLog
+++ b/doc/ChangeLog
@@ -1,3 +1,7 @@
+2014-08-26 Arnold D. Robbins <arnold@skeeve.com>
+
+ * gawktexi.in: Document that MirBSD is no longer supported.
+
2014-08-25 Arnold D. Robbins <arnold@skeeve.com>
* gawktexi.in: Exercises are excluded from print edition.
diff --git a/doc/gawk.info b/doc/gawk.info
index b1a3cbdb..ef7847df 100644
--- a/doc/gawk.info
+++ b/doc/gawk.info
@@ -26184,6 +26184,8 @@ the current version of `gawk'.
- Ultrix
+ * Support for MirBSD was removed at `gawk' version 4.2.
+

File: gawk.info, Node: Feature History, Next: Common Extensions, Prev: POSIX/GNU, Up: Language History
@@ -34506,73 +34508,73 @@ Node: SVR41042317
Node: POSIX1043759
Node: BTL1045145
Node: POSIX/GNU1045879
-Node: Feature History1051595
-Node: Common Extensions1064686
-Node: Ranges and Locales1065998
-Ref: Ranges and Locales-Footnote-11070615
-Ref: Ranges and Locales-Footnote-21070642
-Ref: Ranges and Locales-Footnote-31070876
-Node: Contributors1071097
-Node: History summary1076522
-Node: Installation1077891
-Node: Gawk Distribution1078842
-Node: Getting1079326
-Node: Extracting1080150
-Node: Distribution contents1081792
-Node: Unix Installation1087562
-Node: Quick Installation1088179
-Node: Additional Configuration Options1090621
-Node: Configuration Philosophy1092359
-Node: Non-Unix Installation1094710
-Node: PC Installation1095168
-Node: PC Binary Installation1096479
-Node: PC Compiling1098327
-Ref: PC Compiling-Footnote-11101326
-Node: PC Testing1101431
-Node: PC Using1102607
-Node: Cygwin1106759
-Node: MSYS1107568
-Node: VMS Installation1108082
-Node: VMS Compilation1108878
-Ref: VMS Compilation-Footnote-11110100
-Node: VMS Dynamic Extensions1110158
-Node: VMS Installation Details1111531
-Node: VMS Running1113783
-Node: VMS GNV1116617
-Node: VMS Old Gawk1117340
-Node: Bugs1117810
-Node: Other Versions1121814
-Node: Installation summary1128041
-Node: Notes1129097
-Node: Compatibility Mode1129962
-Node: Additions1130744
-Node: Accessing The Source1131669
-Node: Adding Code1133105
-Node: New Ports1139283
-Node: Derived Files1143764
-Ref: Derived Files-Footnote-11148845
-Ref: Derived Files-Footnote-21148879
-Ref: Derived Files-Footnote-31149475
-Node: Future Extensions1149589
-Node: Implementation Limitations1150195
-Node: Extension Design1151443
-Node: Old Extension Problems1152597
-Ref: Old Extension Problems-Footnote-11154114
-Node: Extension New Mechanism Goals1154171
-Ref: Extension New Mechanism Goals-Footnote-11157531
-Node: Extension Other Design Decisions1157720
-Node: Extension Future Growth1159826
-Node: Old Extension Mechanism1160662
-Node: Notes summary1162424
-Node: Basic Concepts1163610
-Node: Basic High Level1164291
-Ref: figure-general-flow1164563
-Ref: figure-process-flow1165162
-Ref: Basic High Level-Footnote-11168391
-Node: Basic Data Typing1168576
-Node: Glossary1171904
-Node: Copying1197056
-Node: GNU Free Documentation License1234612
-Node: Index1259748
+Node: Feature History1051655
+Node: Common Extensions1064746
+Node: Ranges and Locales1066058
+Ref: Ranges and Locales-Footnote-11070675
+Ref: Ranges and Locales-Footnote-21070702
+Ref: Ranges and Locales-Footnote-31070936
+Node: Contributors1071157
+Node: History summary1076582
+Node: Installation1077951
+Node: Gawk Distribution1078902
+Node: Getting1079386
+Node: Extracting1080210
+Node: Distribution contents1081852
+Node: Unix Installation1087622
+Node: Quick Installation1088239
+Node: Additional Configuration Options1090681
+Node: Configuration Philosophy1092419
+Node: Non-Unix Installation1094770
+Node: PC Installation1095228
+Node: PC Binary Installation1096539
+Node: PC Compiling1098387
+Ref: PC Compiling-Footnote-11101386
+Node: PC Testing1101491
+Node: PC Using1102667
+Node: Cygwin1106819
+Node: MSYS1107628
+Node: VMS Installation1108142
+Node: VMS Compilation1108938
+Ref: VMS Compilation-Footnote-11110160
+Node: VMS Dynamic Extensions1110218
+Node: VMS Installation Details1111591
+Node: VMS Running1113843
+Node: VMS GNV1116677
+Node: VMS Old Gawk1117400
+Node: Bugs1117870
+Node: Other Versions1121874
+Node: Installation summary1128101
+Node: Notes1129157
+Node: Compatibility Mode1130022
+Node: Additions1130804
+Node: Accessing The Source1131729
+Node: Adding Code1133165
+Node: New Ports1139343
+Node: Derived Files1143824
+Ref: Derived Files-Footnote-11148905
+Ref: Derived Files-Footnote-21148939
+Ref: Derived Files-Footnote-31149535
+Node: Future Extensions1149649
+Node: Implementation Limitations1150255
+Node: Extension Design1151503
+Node: Old Extension Problems1152657
+Ref: Old Extension Problems-Footnote-11154174
+Node: Extension New Mechanism Goals1154231
+Ref: Extension New Mechanism Goals-Footnote-11157591
+Node: Extension Other Design Decisions1157780
+Node: Extension Future Growth1159886
+Node: Old Extension Mechanism1160722
+Node: Notes summary1162484
+Node: Basic Concepts1163670
+Node: Basic High Level1164351
+Ref: figure-general-flow1164623
+Ref: figure-process-flow1165222
+Ref: Basic High Level-Footnote-11168451
+Node: Basic Data Typing1168636
+Node: Glossary1171964
+Node: Copying1197116
+Node: GNU Free Documentation License1234672
+Node: Index1259808

End Tag Table
diff --git a/doc/gawk.texi b/doc/gawk.texi
index 1106679a..40e5c428 100644
--- a/doc/gawk.texi
+++ b/doc/gawk.texi
@@ -35484,6 +35484,10 @@ and the documentation for @command{gawk} @value{PVERSION} 4.1:
Ultrix
@end itemize
+@item
+@c FIXME: Verify the version here.
+Support for MirBSD was removed at @command{gawk} @value{PVERSION} 4.2.
+
@end itemize
@c XXX ADD MORE STUFF HERE
diff --git a/doc/gawktexi.in b/doc/gawktexi.in
index bc547917..4bf430a7 100644
--- a/doc/gawktexi.in
+++ b/doc/gawktexi.in
@@ -34582,6 +34582,10 @@ and the documentation for @command{gawk} @value{PVERSION} 4.1:
Ultrix
@end itemize
+@item
+@c FIXME: Verify the version here.
+Support for MirBSD was removed at @command{gawk} @value{PVERSION} 4.2.
+
@end itemize
@c XXX ADD MORE STUFF HERE
diff --git a/main.c b/main.c
index 49cdf51f..fc87d605 100644
--- a/main.c
+++ b/main.c
@@ -262,17 +262,6 @@ main(int argc, char **argv)
*/
gawk_mb_cur_max = MB_CUR_MAX;
/* Without MBS_SUPPORT, gawk_mb_cur_max is 1. */
-#ifdef LIBC_IS_BORKED
-{
- const char *env_lc;
-
- env_lc = getenv("LC_ALL");
- if (env_lc == NULL)
- env_lc = getenv("LANG");
- if (env_lc != NULL && env_lc[1] == '\0' && tolower(env_lc[0]) == 'c')
- gawk_mb_cur_max = 1;
-}
-#endif
/* init the cache for checking bytes if they're characters */
init_btowc_cache();
diff --git a/regcomp.c b/regcomp.c
index a62364c9..beb74bbf 100644
--- a/regcomp.c
+++ b/regcomp.c
@@ -856,10 +856,6 @@ init_dfa (re_dfa_t *dfa, size_t pat_len)
#ifndef _LIBC
char *codeset_name;
#endif
-#if defined(GAWK) && defined(LIBC_IS_BORKED)
- /* Needed for brain damaged systems */
- extern int gawk_mb_cur_max;
-#endif
memset (dfa, '\0', sizeof (re_dfa_t));
@@ -881,11 +877,7 @@ init_dfa (re_dfa_t *dfa, size_t pat_len)
dfa->state_table = calloc (sizeof (struct re_state_table_entry), table_size);
dfa->state_hash_mask = table_size - 1;
-#if defined(GAWK) && defined(LIBC_IS_BORKED)
- dfa->mb_cur_max = gawk_mb_cur_max;
-#else
dfa->mb_cur_max = MB_CUR_MAX;
-#endif
#ifdef _LIBC
if (dfa->mb_cur_max == 6
&& strcmp (_NL_CURRENT (LC_CTYPE, _NL_CTYPE_CODESET_NAME), "UTF-8") == 0)
@@ -920,10 +912,6 @@ init_dfa (re_dfa_t *dfa, size_t pat_len)
? codeset_name[4] == '8' && codeset_name[5] == '\0'
: codeset_name[3] == '8' && codeset_name[4] == '\0'))
dfa->is_utf8 = 1;
-#if defined(GAWK) && defined(LIBC_IS_BORKED)
- if (gawk_mb_cur_max == 1)
- dfa->is_utf8 = 0;
-#endif /* defined(GAWK) && defined(LIBC_IS_BORKED) */
#endif
/* We check exhaustively in the loop below if this charset is a