[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gawk-diffs] [SCM] gawk branch, extgawk, updated. 62d890d4384a70c7550876
From: |
Andrew J. Schorr |
Subject: |
[gawk-diffs] [SCM] gawk branch, extgawk, updated. 62d890d4384a70c7550876c617b3a34e28dab234 |
Date: |
Sat, 26 May 2012 14:45:04 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "gawk".
The branch, extgawk has been updated
via 62d890d4384a70c7550876c617b3a34e28dab234 (commit)
from eec7101174a3b2807fb282272f75cc13d4b953c3 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.sv.gnu.org/cgit/gawk.git/commit/?id=62d890d4384a70c7550876c617b3a34e28dab234
commit 62d890d4384a70c7550876c617b3a34e28dab234
Author: Andrew J. Schorr <address@hidden>
Date: Sat May 26 10:44:07 2012 -0400
Install gawkapi.h, fix is_off_limits_var, and enhance ordchr test.
diff --git a/ChangeLog b/ChangeLog
index abdcf13..11d2067 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2012-05-26 Andrew J. Schorr <address@hidden>
+
+ * Makefile.am (include_HEADERS): Add so gawkapi.h will be installed.
+ (base_sources): Add gawkapi.h so that it is in dist tarball.
+ * TODO.xgawk: Update.
+ * main.c (is_off_limits_var): Stop returning true for everything
+ except PROCINFO.
+
2012-05-25 Arnold D. Robbins <address@hidden>
* main.c (is_off_limits_var): New function to check if a variable
diff --git a/Makefile.am b/Makefile.am
index b41c878..2568803 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -80,6 +80,7 @@ SUBDIRS = \
# what to make and install
bin_PROGRAMS = gawk
+include_HEADERS = gawkapi.h
# sources for both gawk and dgawk
base_sources = \
@@ -100,6 +101,7 @@ base_sources = \
floatcomp.c \
floatmagic.h \
gawkapi.c \
+ gawkapi.h \
gawkmisc.c \
getopt.c \
getopt.h \
diff --git a/Makefile.in b/Makefile.in
index b2c812b..1ebc3d7 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -38,6 +38,7 @@
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
USA
#
+
VPATH = @srcdir@
am__make_dryrun = \
{ \
@@ -75,12 +76,12 @@ build_triplet = @build@
host_triplet = @host@
bin_PROGRAMS = gawk$(EXEEXT)
subdir = .
-DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
- $(srcdir)/Makefile.in $(srcdir)/configh.in \
- $(top_srcdir)/configure ABOUT-NLS AUTHORS COPYING ChangeLog \
- INSTALL NEWS TODO awkgram.c command.c config.guess \
- config.rpath config.sub depcomp install-sh missing \
- mkinstalldirs ylwrap
+DIST_COMMON = README $(am__configure_deps) $(include_HEADERS) \
+ $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+ $(srcdir)/configh.in $(top_srcdir)/configure ABOUT-NLS AUTHORS \
+ COPYING ChangeLog INSTALL NEWS TODO awkgram.c command.c \
+ config.guess config.rpath config.sub depcomp install-sh \
+ missing mkinstalldirs ylwrap
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/arch.m4 \
$(top_srcdir)/m4/codeset.m4 $(top_srcdir)/m4/gettext.m4 \
@@ -101,7 +102,7 @@ mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
CONFIG_HEADER = config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
-am__installdirs = "$(DESTDIR)$(bindir)"
+am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(includedir)"
PROGRAMS = $(bin_PROGRAMS)
am__objects_1 = array.$(OBJEXT) awkgram.$(OBJEXT) builtin.$(OBJEXT) \
cint_array.$(OBJEXT) command.$(OBJEXT) debug.$(OBJEXT) \
@@ -144,6 +145,34 @@ am__can_run_installinfo = \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+ *) f=$$p;; \
+ esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+ for p in $$list; do echo "$$p $$p"; done | \
+ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+ if (++n[$$2] == $(am__install_max)) \
+ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+ END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+ test -z "$$files" \
+ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+ $(am__cd) "$$dir" && rm -f $$files; }; \
+ }
+HEADERS = $(include_HEADERS)
RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
distclean-recursive maintainer-clean-recursive
AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
@@ -379,6 +408,7 @@ SUBDIRS = \
extension \
test
+include_HEADERS = gawkapi.h
# sources for both gawk and dgawk
base_sources = \
@@ -399,6 +429,7 @@ base_sources = \
floatcomp.c \
floatmagic.h \
gawkapi.c \
+ gawkapi.h \
gawkmisc.c \
getopt.c \
getopt.h \
@@ -594,6 +625,27 @@ distclean-compile:
.y.c:
$(am__skipyacc) $(SHELL) $(YLWRAP) $< y.tab.c $@ y.tab.h `echo $@ |
$(am__yacc_c2h)` y.output $*.output -- $(YACCCOMPILE)
+install-includeHEADERS: $(include_HEADERS)
+ @$(NORMAL_INSTALL)
+ @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \
+ if test -n "$$list"; then \
+ echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \
+ $(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \
+ fi; \
+ for p in $$list; do \
+ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
+ echo "$$d$$p"; \
+ done | $(am__base_list) | \
+ while read files; do \
+ echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(includedir)'"; \
+ $(INSTALL_HEADER) $$files "$(DESTDIR)$(includedir)" || exit $$?; \
+ done
+
+uninstall-includeHEADERS:
+ @$(NORMAL_UNINSTALL)
+ @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \
+ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
+ dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir)
# This directory's subdirectories are mostly independent; you can cd
# into them and run 'make' without going through this Makefile.
@@ -944,10 +996,10 @@ distcleancheck: distclean
check-am: all-am
$(MAKE) $(AM_MAKEFLAGS) check-local
check: check-recursive
-all-am: Makefile $(PROGRAMS) config.h
+all-am: Makefile $(PROGRAMS) $(HEADERS) config.h
installdirs: installdirs-recursive
installdirs-am:
- for dir in "$(DESTDIR)$(bindir)"; do \
+ for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(includedir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-recursive
@@ -1007,7 +1059,7 @@ info: info-recursive
info-am:
-install-data-am:
+install-data-am: install-includeHEADERS
install-dvi: install-dvi-recursive
@@ -1055,7 +1107,7 @@ ps: ps-recursive
ps-am:
-uninstall-am: uninstall-binPROGRAMS
+uninstall-am: uninstall-binPROGRAMS uninstall-includeHEADERS
.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) all check-am \
cscopelist-recursive ctags-recursive install-am \
@@ -1072,13 +1124,14 @@ uninstall-am: uninstall-binPROGRAMS
info-am install install-am install-binPROGRAMS install-data \
install-data-am install-dvi install-dvi-am install-exec \
install-exec-am install-exec-hook install-html install-html-am \
- install-info install-info-am install-man install-pdf \
- install-pdf-am install-ps install-ps-am install-strip \
- installcheck installcheck-am installdirs installdirs-am \
- maintainer-clean maintainer-clean-generic mostlyclean \
- mostlyclean-compile mostlyclean-generic pdf pdf-am ps ps-am \
- tags tags-recursive uninstall uninstall-am \
- uninstall-binPROGRAMS
+ install-includeHEADERS install-info install-info-am \
+ install-man install-pdf install-pdf-am install-ps \
+ install-ps-am install-strip installcheck installcheck-am \
+ installdirs installdirs-am maintainer-clean \
+ maintainer-clean-generic mostlyclean mostlyclean-compile \
+ mostlyclean-generic pdf pdf-am ps ps-am tags tags-recursive \
+ uninstall uninstall-am uninstall-binPROGRAMS \
+ uninstall-includeHEADERS
# First, add a link from gawk to gawk-X.Y.Z.
diff --git a/TODO.xgawk b/TODO.xgawk
index 0746a66..3a600a7 100644
--- a/TODO.xgawk
+++ b/TODO.xgawk
@@ -1,6 +1,8 @@
To-do list for xgawk enhancements:
- Finish implementing new interface using gawkapi.h
+ - api_get_curfunc_param not honoring requested type in node_to_awk_value
+ - should api_sym_lookup also accept a type request?
- must update the API do_lint value when changed by set_LINT
- what is the proper return value for load_ext? It does not matter
unless called by the "extension" function that nobody uses.
@@ -12,11 +14,6 @@ To-do list for xgawk enhancements:
Rename existing gettimeofday by adding some underscores. Awaiting
confirmation of copyright assignment from FSF...
-- Running "make install" should install gawkapi.h in /usr/include.
-
-- Decide how to transition from the old extension API to the new one.
- When will the old approach be abandoned?
-
- Develop a libgawk shared library for use by extensions. Should this
be hosted in a separate project?
@@ -162,3 +159,5 @@ Done:
- Eliminate libtool from the top-level configure.ac. Create a separate
configure.ac in the extensions subdirectory, and hide all the libtool
stuff in there.
+
+- Running "make install" should install gawkapi.h in /usr/include.
diff --git a/main.c b/main.c
index e8f087c..e2f70d7 100644
--- a/main.c
+++ b/main.c
@@ -1202,12 +1202,11 @@ is_off_limits_var(const char *var)
const struct varinit *vp;
for (vp = varinit; vp->name != NULL; vp++) {
- if ( (vp->flags & NOT_OFF_LIMITS) != 0
- && strcmp(vp->name, var) == 0)
- return false;
+ if (strcmp(vp->name, var) == 0)
+ return !(vp->flags & NOT_OFF_LIMITS);
}
- return true;
+ return false;
}
/* get_spec_varname --- return the name of a special variable
diff --git a/test/ChangeLog b/test/ChangeLog
index 563f8e0..6031ca0 100644
--- a/test/ChangeLog
+++ b/test/ChangeLog
@@ -1,3 +1,11 @@
+2012-05-26 Andrew J. Schorr <address@hidden>
+
+ * Makefile.am (readfile): Revert previous patch, and add comment
+ explaining that we need to create readfile.ok on failure so that
+ "make diffout" will work properly.
+ (ordchr.awk, ordchr.ok): Add more tests to catch type conversion
+ problems.
+
2012-05-25 Arnold D. Robbins <address@hidden>
* Makefile.am (readfile): Don't copy the Makefile over readfile.ok
diff --git a/test/Makefile.am b/test/Makefile.am
index ea7e9a9..c0293ba 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -1552,10 +1552,11 @@ ordchr2::
@$(AWK) -l ordchr 'BEGIN {print chr(ord("z"))}' >_$@ 2>&1 || echo EXIT
CODE: $$? >>_$@
@-$(CMP) $(srcdir)/address@hidden _$@ && rm -f _$@
+# N.B. If the test fails, create readfile.ok so that "make diffout" will work
readfile::
@echo $@
@$(AWK) -l readfile 'BEGIN {printf "%s", readfile("Makefile")}' >_$@
2>&1 || echo EXIT CODE: $$? >>_$@
- @-$(CMP) Makefile _$@ && rm -f _$@
+ @-$(CMP) Makefile _$@ && rm -f _$@ || cp -p Makefile address@hidden
include2::
@echo $@
diff --git a/test/Makefile.in b/test/Makefile.in
index 34b7e93..683ba8a 100644
--- a/test/Makefile.in
+++ b/test/Makefile.in
@@ -1933,10 +1933,11 @@ ordchr2::
@$(AWK) -l ordchr 'BEGIN {print chr(ord("z"))}' >_$@ 2>&1 || echo EXIT
CODE: $$? >>_$@
@-$(CMP) $(srcdir)/address@hidden _$@ && rm -f _$@
+# N.B. If the test fails, create readfile.ok so that "make diffout" will work
readfile::
@echo $@
@$(AWK) -l readfile 'BEGIN {printf "%s", readfile("Makefile")}' >_$@
2>&1 || echo EXIT CODE: $$? >>_$@
- @-$(CMP) Makefile _$@ && rm -f _$@
+ @-$(CMP) Makefile _$@ && rm -f _$@ || cp -p Makefile address@hidden
include2::
@echo $@
diff --git a/test/ordchr.awk b/test/ordchr.awk
index abb793a..0295105 100644
--- a/test/ordchr.awk
+++ b/test/ordchr.awk
@@ -2,4 +2,9 @@
BEGIN {
print chr(ord("A"))
+ print chr(ord("0"))
+ print ord(chr(65))
+ # test if type conversion between strings and numbers is working properly
+ print chr(ord(0))
+ print ord(chr("65"))
}
diff --git a/test/ordchr.ok b/test/ordchr.ok
index f70f10e..86d901e 100644
--- a/test/ordchr.ok
+++ b/test/ordchr.ok
@@ -1 +1,5 @@
A
+0
+65
+0
+65
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 8 +++++
Makefile.am | 2 +
Makefile.in | 89 +++++++++++++++++++++++++++++++++++++++++++-----------
TODO.xgawk | 9 ++---
main.c | 7 ++--
test/ChangeLog | 8 +++++
test/Makefile.am | 3 +-
test/Makefile.in | 3 +-
test/ordchr.awk | 5 +++
test/ordchr.ok | 4 ++
10 files changed, 109 insertions(+), 29 deletions(-)
hooks/post-receive
--
gawk
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [gawk-diffs] [SCM] gawk branch, extgawk, updated. 62d890d4384a70c7550876c617b3a34e28dab234,
Andrew J. Schorr <=