unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
* [PATCH] [maint] Avoid no-op config-subst for libguile/guile-func-name-check.
@ 2010-06-25 12:11 Thien-Thi Nguyen
  2010-06-28 13:12 ` Andy Wingo
  0 siblings, 1 reply; 2+ messages in thread
From: Thien-Thi Nguyen @ 2010-06-25 12:11 UTC (permalink / raw)
  To: guile-devel

[-- Attachment #1: Type: text/plain, Size: 103 bytes --]

This is a very simple change.  I hope you like it.

thi

_____________________________________________

[-- Attachment #2: 0002-maint-Avoid-no-op-config-subst-for-libguile-guile-fu.patch --]
[-- Type: text/x-diff, Size: 8231 bytes --]

From ad52ea336b86933d33f36910b6bfbcbffbd9e76e Mon Sep 17 00:00:00 2001
From: Thien-Thi Nguyen <ttn@gnuvola.org>
Date: Thu, 17 Jun 2010 16:12:40 +0200
Subject: [PATCH 2/8] [maint] Avoid no-op config-subst for libguile/guile-func-name-check.
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit

* configure.ac (libguile/guile-func-name-check): Remove ‘GUILE_CONFIG_SCRIPT’.
* libguile/Makefile.am (.c.doc): Look in $(srcdir) for awk script.
* libguile/guile-func-name-check: Rename from guile-func-name-check.in.
---
 configure.ac                      |    1 -
 libguile/Makefile.am              |    8 ++--
 libguile/guile-func-name-check    |   65 +++++++++++++++++++++++++++++++++++++
 libguile/guile-func-name-check.in |   65 -------------------------------------
 4 files changed, 69 insertions(+), 70 deletions(-)
 create mode 100644 libguile/guile-func-name-check
 delete mode 100644 libguile/guile-func-name-check.in

diff --git a/configure.ac b/configure.ac
index ed69a9f..0a44265 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1656,7 +1656,6 @@ GUILE_CONFIG_SCRIPT([meta/gdb-uninstalled-guile])
 GUILE_CONFIG_SCRIPT([meta/guile-tools])
 GUILE_CONFIG_SCRIPT([libguile/guile-snarf])
 GUILE_CONFIG_SCRIPT([libguile/guile-doc-snarf])
-GUILE_CONFIG_SCRIPT([libguile/guile-func-name-check])
 GUILE_CONFIG_SCRIPT([libguile/guile-snarf-docs])
 GUILE_CONFIG_SCRIPT([test-suite/standalone/test-use-srfi])
 GUILE_CONFIG_SCRIPT([test-suite/standalone/test-fast-slot-ref])
diff --git a/libguile/Makefile.am b/libguile/Makefile.am
index 6a33473..5897d03 100644
--- a/libguile/Makefile.am
+++ b/libguile/Makefile.am
@@ -63,7 +63,7 @@ gen-scmconfig.$(OBJEXT): gen-scmconfig.c
 	fi
 
 ## Override default rule; this should run on BUILD host.
-gen-scmconfig$(EXEEXT): $(gen_scmconfig_OBJECTS) $(gen_scmconfig_DEPENDENCIES) 
+gen-scmconfig$(EXEEXT): $(gen_scmconfig_OBJECTS) $(gen_scmconfig_DEPENDENCIES)
 	$(AM_V_GEN) \
 	rm -f gen-scmconfig$(EXEEXT); \
 	if [ "$(cross_compiling)" = "yes" ]; then \
@@ -94,7 +94,7 @@ c-tokenize.$(OBJEXT): c-tokenize.c
 	fi
 
 ## Override default rule; this should run on BUILD host.
-guile_filter_doc_snarfage$(EXEEXT): $(guile_filter_doc_snarfage_OBJECTS) $(guile_filter_doc_snarfage_DEPENDENCIES) 
+guile_filter_doc_snarfage$(EXEEXT): $(guile_filter_doc_snarfage_OBJECTS) $(guile_filter_doc_snarfage_DEPENDENCIES)
 	$(AM_V_GEN) \
 	rm -f guile_filter_doc_snarfage$(EXEEXT); \
 	if [ "$(cross_compiling)" = "yes" ]; then \
@@ -466,7 +466,7 @@ endif HAVE_LD_VERSION_SCRIPT
 
 
 # These are headers visible as <guile/mumble.h>
-pkginclude_HEADERS = 
+pkginclude_HEADERS =
 
 # These are headers visible as <libguile/mumble.h>.
 modincludedir = $(pkgincludedir)/$(GUILE_EFFECTIVE_VERSION)/libguile
@@ -667,7 +667,7 @@ AM_V_FILTER_0 = @echo "  FILTER" $@;
 .c.x:
 	$(AM_V_SNARF)$(GUILE_SNARF) -o $@ $< $(snarfcppopts)
 .c.doc:
-	-$(AM_V_FILTER)$(AWK) -f ./guile-func-name-check $< && (./guile-snarf-docs $(snarfcppopts) $< | ./guile_filter_doc_snarfage$(EXEEXT) --filter-snarfage) > $@ || { rm $@; false; }
+	-$(AM_V_FILTER)$(AWK) -f $(srcdir)/guile-func-name-check $< && (./guile-snarf-docs $(snarfcppopts) $< | ./guile_filter_doc_snarfage$(EXEEXT) --filter-snarfage) > $@ || { rm $@; false; }
 
 $(DOT_X_FILES) $(EXTRA_DOT_X_FILES): scmconfig.h snarf.h guile-snarf.in
 
diff --git a/libguile/guile-func-name-check b/libguile/guile-func-name-check
new file mode 100644
index 0000000..8b4924e
--- /dev/null
+++ b/libguile/guile-func-name-check
@@ -0,0 +1,65 @@
+#!/usr/bin/awk -f
+#
+#  Copyright (C) 2000, 2001, 2006 Free Software Foundation, Inc.
+# 
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 3, or (at
+# your option) any later version.
+# 
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+# Lesser General Public License for more details.
+# 
+# You should have received a copy of the GNU Lesser General Public
+# License along with this software; see the file COPYING.LESSER.  If
+# not, write to the Free Software Foundation, Inc., 51 Franklin
+# Street, Fifth Floor, Boston, MA 02110-1301 USA
+#
+# Written by Greg J. Badros, <gjb@cs.washington.edu>
+# 11-Jan-2000
+
+BEGIN {
+  filename = ARGV[1];
+  in_a_func = 0;
+}
+
+/^SCM_DEFINE/ { 
+  func_name = $0;
+  sub(/^[^\(\n]*\([ \t]*/,"", func_name);
+  sub(/[ \t]*,.*/,"", func_name);
+#  print func_name;  # GJB:FIXME:: flag to do this to list primitives?
+  in_a_func = 1;
+}
+
+/^\{/ && in_a_func {
+  if (!match(last_line,/^#define[ \t]+FUNC_NAME[ \t]+/)) {
+    printf filename ":" NR ":***" > "/dev/stderr";
+    print "Missing or erroneous `#define FUNC_NAME s_" func_name "'" > "/dev/stderr";
+  } else {
+    sub(/^#define[ \t]+FUNC_NAME[ \t]+s_/, "", last_line);
+    sub(/[ \t]*$/,"",last_line);
+    if (last_line != func_name) {
+      printf filename ":" NR ":***" > "/dev/stderr";
+      print "Mismatching FUNC_NAME.  Should be: `#define FUNC_NAME s_" func_name "'" > "/dev/stderr";
+    }
+  }
+}
+
+1 == next_line_better_be_undef {
+  if (!match($0,/^#undef FUNC_NAME[ \t]*$/)) {
+    printf filename ":" NR ":***" > "/dev/stderr";
+    print "Missing or erroneous #undef for " func_name ": "
+          "Got `" $0 "' instead." > "/dev/stderr";
+  }
+  in_a_func = "";
+  func_name = "";
+  next_line_better_be_undef = 0;
+}
+
+/^\}/ && in_a_func {
+  next_line_better_be_undef = 1;
+}
+
+{ last_line = $0; }
diff --git a/libguile/guile-func-name-check.in b/libguile/guile-func-name-check.in
deleted file mode 100644
index 8b4924e..0000000
--- a/libguile/guile-func-name-check.in
+++ /dev/null
@@ -1,65 +0,0 @@
-#!/usr/bin/awk -f
-#
-#  Copyright (C) 2000, 2001, 2006 Free Software Foundation, Inc.
-# 
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License as
-# published by the Free Software Foundation; either version 3, or (at
-# your option) any later version.
-# 
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-# Lesser General Public License for more details.
-# 
-# You should have received a copy of the GNU Lesser General Public
-# License along with this software; see the file COPYING.LESSER.  If
-# not, write to the Free Software Foundation, Inc., 51 Franklin
-# Street, Fifth Floor, Boston, MA 02110-1301 USA
-#
-# Written by Greg J. Badros, <gjb@cs.washington.edu>
-# 11-Jan-2000
-
-BEGIN {
-  filename = ARGV[1];
-  in_a_func = 0;
-}
-
-/^SCM_DEFINE/ { 
-  func_name = $0;
-  sub(/^[^\(\n]*\([ \t]*/,"", func_name);
-  sub(/[ \t]*,.*/,"", func_name);
-#  print func_name;  # GJB:FIXME:: flag to do this to list primitives?
-  in_a_func = 1;
-}
-
-/^\{/ && in_a_func {
-  if (!match(last_line,/^#define[ \t]+FUNC_NAME[ \t]+/)) {
-    printf filename ":" NR ":***" > "/dev/stderr";
-    print "Missing or erroneous `#define FUNC_NAME s_" func_name "'" > "/dev/stderr";
-  } else {
-    sub(/^#define[ \t]+FUNC_NAME[ \t]+s_/, "", last_line);
-    sub(/[ \t]*$/,"",last_line);
-    if (last_line != func_name) {
-      printf filename ":" NR ":***" > "/dev/stderr";
-      print "Mismatching FUNC_NAME.  Should be: `#define FUNC_NAME s_" func_name "'" > "/dev/stderr";
-    }
-  }
-}
-
-1 == next_line_better_be_undef {
-  if (!match($0,/^#undef FUNC_NAME[ \t]*$/)) {
-    printf filename ":" NR ":***" > "/dev/stderr";
-    print "Missing or erroneous #undef for " func_name ": "
-          "Got `" $0 "' instead." > "/dev/stderr";
-  }
-  in_a_func = "";
-  func_name = "";
-  next_line_better_be_undef = 0;
-}
-
-/^\}/ && in_a_func {
-  next_line_better_be_undef = 1;
-}
-
-{ last_line = $0; }
-- 
1.6.3.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] [maint] Avoid no-op config-subst for libguile/guile-func-name-check.
  2010-06-25 12:11 [PATCH] [maint] Avoid no-op config-subst for libguile/guile-func-name-check Thien-Thi Nguyen
@ 2010-06-28 13:12 ` Andy Wingo
  0 siblings, 0 replies; 2+ messages in thread
From: Andy Wingo @ 2010-06-28 13:12 UTC (permalink / raw)
  To: Thien-Thi Nguyen; +Cc: guile-devel

On Fri 25 Jun 2010 14:11, Thien-Thi Nguyen <ttn@gnuvola.org> writes:

> This is a very simple change.  I hope you like it.
>
> Subject: [PATCH 2/8] [maint] Avoid no-op config-subst for libguile/guile-func-name-check.

Indeed, please push :-)

Andy
-- 
http://wingolog.org/



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-06-28 13:12 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-06-25 12:11 [PATCH] [maint] Avoid no-op config-subst for libguile/guile-func-name-check Thien-Thi Nguyen
2010-06-28 13:12 ` Andy Wingo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).