aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArnold D. Robbins <arnold@skeeve.com>2015-04-30 10:07:33 +0300
committerArnold D. Robbins <arnold@skeeve.com>2015-04-30 10:07:33 +0300
commitd38a65f812c74acc859c8ea36e26c28cfbeffcc9 (patch)
tree0f4aa60e1fe39a04863657d94afff46a82215e09
parentf586cd49506935eb48a6afeaff6988087f947ed1 (diff)
parent665ec924795675c32d7178613367ec9f7a7d08e1 (diff)
downloadegawk-d38a65f812c74acc859c8ea36e26c28cfbeffcc9.tar.gz
egawk-d38a65f812c74acc859c8ea36e26c28cfbeffcc9.tar.bz2
egawk-d38a65f812c74acc859c8ea36e26c28cfbeffcc9.zip
Merge branch 'gawk-4.1-stable'
-rw-r--r--ChangeLog12
-rw-r--r--Checklist11
-rw-r--r--Makefile.am10
-rw-r--r--Makefile.in10
-rw-r--r--awkgram.c18
-rw-r--r--awkgram.y18
6 files changed, 56 insertions, 23 deletions
diff --git a/ChangeLog b/ChangeLog
index 7cc31645..83176952 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+2015-04-30 Arnold D. Robbins <arnold@skeeve.com>
+
+ * Makefile.am: Take --program-prefix into account when
+ installing/uninstalling the symlinks, especially 'awk'.
+ Thanks to Steffen Nurpmeso <sdaoden@yandex.com> for
+ the report.
+
+ Unrelated:
+
+ * awkgram.y (yylex): Yet Another Fix for parsing bracket
+ expressions. Thanks again to Andrew Schorr.
+
2015-04-29 Arnold D. Robbins <arnold@skeeve.com>
* 4.1.2: Release tar ball made.
diff --git a/Checklist b/Checklist
index e0e1ffec..cb9c4d24 100644
--- a/Checklist
+++ b/Checklist
@@ -1,4 +1,4 @@
-Fri Apr 4 11:43:29 IDT 2014
+Thu Apr 30 10:01:17 IDT 2015
============================
A checklist for making releases
@@ -57,3 +57,12 @@ run the following command just before rolling a new release:
Major releases:
- Rotate the ChangeLog and NEWS files.
+
+========== For Releasing ============
+
+To upload:
+ gnupload --to ftp.gnu.org:gawk gawk-Whatever.gz
+
+For doc:
+ Use the perl makeinfo to create the files.
+ Use gendocs.sh and gendoc_template from gnulib.
diff --git a/Makefile.am b/Makefile.am
index ac3b227b..43e0ee7a 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -155,17 +155,21 @@ RM = rm -f
# For GNU systems where gawk is awk, add a link to awk.
# (This is done universally, which may not always be right, but
# there's no easy way to distinguish GNU from non-GNU systems.)
+#
+# Use the transform, in case --program-prefix=XXX
install-exec-hook:
(cd $(DESTDIR)$(bindir); \
- $(LN) gawk$(EXEEXT) gawk-$(VERSION)$(EXEEXT) 2>/dev/null ; \
+ name=`echo gawk | sed '$(transform)'` ; \
+ $(LN) $${name}$(EXEEXT) gawk-$(VERSION)$(EXEEXT) 2>/dev/null ; \
if [ ! -f awk$(EXEEXT) ]; \
- then $(LN_S) gawk$(EXEEXT) awk$(EXEEXT); \
+ then $(LN_S) $${name}$(EXEEXT) awk$(EXEEXT); \
fi; exit 0)
# Undo the above when uninstalling
uninstall-links:
(cd $(DESTDIR)$(bindir); \
- if [ -f awk$(EXEEXT) ] && cmp awk$(EXEEXT) gawk$(EXEEXT) > /dev/null; then rm -f awk$(EXEEXT); fi ; \
+ name=`echo gawk | sed '$(transform)'` ; \
+ if [ -f awk$(EXEEXT) ] && cmp awk$(EXEEXT) $${name}$(EXEEXT) > /dev/null; then rm -f awk$(EXEEXT); fi ; \
rm -f gawk-$(VERSION)$(EXEEXT); exit 0)
uninstall-recursive: uninstall-links
diff --git a/Makefile.in b/Makefile.in
index 6d974d00..d286b1da 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1173,17 +1173,21 @@ uninstall-am: uninstall-binPROGRAMS uninstall-includeHEADERS
# For GNU systems where gawk is awk, add a link to awk.
# (This is done universally, which may not always be right, but
# there's no easy way to distinguish GNU from non-GNU systems.)
+#
+# Use the transform, in case --program-prefix=XXX
install-exec-hook:
(cd $(DESTDIR)$(bindir); \
- $(LN) gawk$(EXEEXT) gawk-$(VERSION)$(EXEEXT) 2>/dev/null ; \
+ name=`echo gawk | sed '$(transform)'` ; \
+ $(LN) $${name}$(EXEEXT) gawk-$(VERSION)$(EXEEXT) 2>/dev/null ; \
if [ ! -f awk$(EXEEXT) ]; \
- then $(LN_S) gawk$(EXEEXT) awk$(EXEEXT); \
+ then $(LN_S) $${name}$(EXEEXT) awk$(EXEEXT); \
fi; exit 0)
# Undo the above when uninstalling
uninstall-links:
(cd $(DESTDIR)$(bindir); \
- if [ -f awk$(EXEEXT) ] && cmp awk$(EXEEXT) gawk$(EXEEXT) > /dev/null; then rm -f awk$(EXEEXT); fi ; \
+ name=`echo gawk | sed '$(transform)'` ; \
+ if [ -f awk$(EXEEXT) ] && cmp awk$(EXEEXT) $${name}$(EXEEXT) > /dev/null; then rm -f awk$(EXEEXT); fi ; \
rm -f gawk-$(VERSION)$(EXEEXT); exit 0)
uninstall-recursive: uninstall-links
diff --git a/awkgram.c b/awkgram.c
index ea8c48d8..85e416da 100644
--- a/awkgram.c
+++ b/awkgram.c
@@ -5554,7 +5554,7 @@ yylex(void)
/*
* Here is what's ok with brackets:
*
- * [[] [^[] []] [^]] [.../...]
+ * [..[..] []] [^]] [.../...]
* [...\[...] [...\]...] [...\/...]
*
* (Remember that all of the above are inside /.../)
@@ -5562,7 +5562,7 @@ yylex(void)
* The code for \ handles \[, \] and \/.
*
* Otherwise, track the first open [ position, and if
- * an embedded [ or ] occurs, allow it to pass through
+ * an embedded ] occurs, allow it to pass through
* if it's right after the first [ or after [^.
*
* Whew!
@@ -5573,19 +5573,21 @@ yylex(void)
for (;;) {
c = nextc(false);
+ cur_index = tok - tokstart;
if (gawk_mb_cur_max == 1 || nextc_is_1stbyte) switch (c) {
case '[':
+ if (nextc(false) == ':' || in_brack == 0)
+ in_brack++;
+ pushback();
+ if (in_brack == 1)
+ b_index = tok - tokstart;
+ break;
case ']':
- cur_index = tok - tokstart;
if (in_brack > 0
&& (cur_index == b_index + 1
|| (cur_index == b_index + 2 && tok[-1] == '^')))
; /* do nothing */
- else if (c == '[') {
- in_brack++;
- if (in_brack == 1)
- b_index = tok - tokstart;
- } else {
+ else {
in_brack--;
if (in_brack == 0)
b_index = -1;
diff --git a/awkgram.y b/awkgram.y
index 3b555a6e..dde720cc 100644
--- a/awkgram.y
+++ b/awkgram.y
@@ -3222,7 +3222,7 @@ yylex(void)
/*
* Here is what's ok with brackets:
*
- * [[] [^[] []] [^]] [.../...]
+ * [..[..] []] [^]] [.../...]
* [...\[...] [...\]...] [...\/...]
*
* (Remember that all of the above are inside /.../)
@@ -3230,7 +3230,7 @@ yylex(void)
* The code for \ handles \[, \] and \/.
*
* Otherwise, track the first open [ position, and if
- * an embedded [ or ] occurs, allow it to pass through
+ * an embedded ] occurs, allow it to pass through
* if it's right after the first [ or after [^.
*
* Whew!
@@ -3241,19 +3241,21 @@ yylex(void)
for (;;) {
c = nextc(false);
+ cur_index = tok - tokstart;
if (gawk_mb_cur_max == 1 || nextc_is_1stbyte) switch (c) {
case '[':
+ if (nextc(false) == ':' || in_brack == 0)
+ in_brack++;
+ pushback();
+ if (in_brack == 1)
+ b_index = tok - tokstart;
+ break;
case ']':
- cur_index = tok - tokstart;
if (in_brack > 0
&& (cur_index == b_index + 1
|| (cur_index == b_index + 2 && tok[-1] == '^')))
; /* do nothing */
- else if (c == '[') {
- in_brack++;
- if (in_brack == 1)
- b_index = tok - tokstart;
- } else {
+ else {
in_brack--;
if (in_brack == 0)
b_index = -1;