A minor point: b4_basename doesn't really implement the full POSIX
basename, but it doesn't need to, so it can be simplified a bit to
avoid confusion. I installed this.
2006-07-08 Paul Eggert <[EMAIL PROTECTED]>
* data/c.m4 (b4_basename): Simplify a bit, since we don't
need the full POSIX semantics (and weren't implementing them
anyway).
--- data/c.m4 8 Jul 2006 20:38:14 -0000 1.60
+++ data/c.m4 9 Jul 2006 04:37:04 -0000
@@ -410,17 +410,16 @@ m4_define([b4_c_arg],
# b4_basename(NAME)
# -----------------
+# Similar to POSIX basename; the differences don't matter here.
# Beware that NAME is not evaluated.
m4_define([b4_basename],
-[m4_case([$1],
- [/], [/],
- [m4_bpatsubst([$1], [^.*/\([^/]+\)/?$], [\1])])])
-
+[m4_bpatsubst([$1], [^.*/\([^/]+\)/*$], [\1])])
+
# b4_syncline(LINE, FILE)
# -----------------------
m4_define([b4_syncline],
-[b4_flag_if([synclines],
+[b4_flag_if([synclines],
[/* Line __line__ of b4_basename(m4_quote(__file__)). */
[#]line $1 $2])])