guile-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Guile-commits] GNU Guile branch, string_abstraction2, updated. release_


From: Michael Gran
Subject: [Guile-commits] GNU Guile branch, string_abstraction2, updated. release_1-9-0-77-gbeb7d5f
Date: Sat, 27 Jun 2009 10:05:16 +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 "GNU Guile".

http://git.savannah.gnu.org/cgit/guile.git/commit/?id=beb7d5f249b1c20f5c75ab0a6ad7322dd48b1599

The branch, string_abstraction2 has been updated
       via  beb7d5f249b1c20f5c75ab0a6ad7322dd48b1599 (commit)
       via  6dca3dad314889ff38d465acd33396a90765adf6 (commit)
       via  8bcd35fff2c7f642656c08ea4ab17e73b46d73e0 (commit)
       via  cfb4702f5886f2df197521cc47b6ca86547b165e (commit)
       via  438974d08dcb96a01fe62ea9b0446b8420e703c4 (commit)
       via  404bb5f87b66709206507acdf7b899101185a7a0 (commit)
       via  2d34e9244b8b35f62d086a88db749718a2a1a3b4 (commit)
       via  d64fc8b039fd686a5f8f33458ba1193dc584b2a9 (commit)
       via  5c27902e5e01a94b22ebc51288500a3d36253293 (commit)
       via  fe2400b2141fbde17eab517794773203fc19f952 (commit)
       via  4e432dab1f02f5d497a352c1ea9392fc6db0f1f2 (commit)
       via  e63d888ef64c9c96177d841fa9a1ee4e697db81d (commit)
       via  6370a6ad25ab0bc47e2f165937db8c7955b2b595 (commit)
       via  cf6d8d344c8717629279f01acbb785e0d35a12a5 (commit)
       via  c60be0404dd07fb9e9747c02fabc45d38380ed17 (commit)
       via  4574ec212aad4df9571463ee4d45beb2607e51ad (commit)
       via  8806afa7dd0582f774daadafbe6ec8163b2deea8 (commit)
       via  179fe3363241ea1aeb48f1f63d13d2dd12196dcf (commit)
       via  89cb70a0d5f365ebdfcc0257d6cab4a80a9f6a74 (commit)
       via  74fdb02e5eaf31b4af337d8d101300493cc7f281 (commit)
       via  fc5b616b5816a425863fd06c50f41513c31693f8 (commit)
       via  f4bf64b4d422bb093a3e857380d99e4f08b9c8af (commit)
       via  23044464c2e26649329b422380a6850d53eec725 (commit)
       via  93617170fa8dc30378ee09b1c24827975f895406 (commit)
       via  8141fc3b4633993fe37fef19a81a823cf727b90b (commit)
       via  b57501c3b7afa0378e3142cc415cfd02a374a77e (commit)
       via  25b82b3485e9e44d8d6268d3774b0b81d0d501b2 (commit)
       via  ffca4c2203d85bc4d9e348d77053d21112e665af (commit)
       via  5b55e29320449c8c68112129e1cadbfa7944af11 (commit)
       via  ce471ab8b083a345af0f49e08f51f22dbfe58efe (commit)
       via  96b73e84bbb6d88c73a99bf46450642d79612be0 (commit)
       via  159399850de811f23e45d439aecf452b0137d847 (commit)
       via  81e002fcb90c99ac2840dcde81f286772b1fb1a2 (commit)
       via  0ba0b3848913ca871235ad4b2f8ef184bf8f552b (commit)
       via  55bf8cb7af47cde26e6a70dae056752c8265508d (commit)
       via  b242715b288b8f076d1617668e77f1ef44dfeeb3 (commit)
       via  fa1804e94394d92b9999eaee769653ed423474b3 (commit)
       via  b82a8b48507f67b6dbffdd048dc088e084d1413e (commit)
       via  83ba2d3750ea105d8193fcb1b7162539160cf91c (commit)
       via  1b34e26a20aedd43ac5d6e87f5be7d10e1bb4f5f (commit)
       via  53befeb700c31dec58cec2c8f6f34535541a2f39 (commit)
       via  a89cafc0562942680db63fe8ddf89f466ba2f7af (commit)
       via  5aaccd35a24eb67d5c489bda4e1e5faf1b22744e (commit)
       via  39b94fee4304d56babf5bd62e10c5786a79f4389 (commit)
       via  f856c2b6d77633366f154cb38cd4edb384b4892d (commit)
       via  62e9a9b704524edfad98dd84ac5a11abd48d0b27 (commit)
       via  dffd0672faf3db4fa46042e447e62dff22a9e4e9 (commit)
      from  4d93adbe1c810fc04b660f6619ede686b41b2445 (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 -----------------------------------------------------------------
commit beb7d5f249b1c20f5c75ab0a6ad7322dd48b1599
Author: Michael Gran <address@hidden>
Date:   Sat Jun 27 03:03:59 2009 -0700

    use sparse, Unicode-capable character sets
    
    The old character set format was a binary map, which was fine for a
    limited range of characters, but which would be too memory intensive
    to use on the full Unicode character set.  A replacement character set
    format, where each charset is a list of pairs that indicate ranges of
    contiguous characters, is implemented.  This uses more memory for the
    8-bit character case, but, is sufficient for the full Unicode case.
    
        * chars.h (SCM_CODEPOINT_MAX): new range macro
    
        * srfi-14.h (scm_t_char_set, scm_t_char_set_cursor)
        (scm_t_char_range): new types.
    
        New declarations for scm_i_charset_get, scm_i_charset_set,
        scm_i_charset_unset.
    
        * srfi-14.c:
        (scm_i_charset_get): new function
        (scm_i_charset_set): new function
        (scm_i_charset_unset): new function
        (charsets_equal): new function
        (charsets_leq): new function
        (charsets_union): new function
        (charsets_intersection): new function
        (charsets_complement): new function
        (charsets_xor): new function
        (charset_print): Use new charset struct.  Shorten output.
        (charset_free): Use new charset struct.
        (charset_cursor_print): new function
        (charset_cursor_free): new function
        (scm_debug_char_set): new function
        (scm_srfi_14_compute_char_sets): add max character parameter
        (CSET_PUNCT_PRED, etc.): all CSET macros now use libunistring
        functions
        (scm_unicode_char_sets): new function
        (scm_char_set_cursor, char_set_ref): use new cursor struct
        (scm_char_set_cursor_next, end-of-char-set?): use new cursor struct
    
        The modified charset data is used in almost every function in this
        module.

commit 6dca3dad314889ff38d465acd33396a90765adf6
Author: Michael Gran <address@hidden>
Date:   Mon Jun 22 23:29:37 2009 -0700

    Use SCM_SUBR_NAME (renamed from SCM_SNAME)
    
            * print.c (iprin1): Use new form SCM_SUBR_NAME for old SCM_SNAME
    
            * __scm.h (SCM_WTA_DISPATCH_1_SUBR): Use new form SCM_SUBR_NAME
            for old SCM_SNAME

commit 8bcd35fff2c7f642656c08ea4ab17e73b46d73e0
Merge: 4d93adbe1c810fc04b660f6619ede686b41b2445 
cfb4702f5886f2df197521cc47b6ca86547b165e
Author: Michael Gran <address@hidden>
Date:   Mon Jun 22 06:24:46 2009 -0700

    Merge branch 'master' into string_abstraction2
    
    Conflicts:
        libguile/eval.c
        libguile/eval.i.c
        libguile/print.c
        libguile/r6rs-ports.c
        libguile/read.c

commit cfb4702f5886f2df197521cc47b6ca86547b165e
Author: Ludovic Courtès <address@hidden>
Date:   Mon Jun 22 00:56:00 2009 +0200

    Always create the bytevector SMOB type.
    
    * libguile/bytevectors.c (scm_tc16_bytevector, print_bytevector,
      bytevector_equal_p, free_bytevector): Don't use the snarfing macros.
      (scm_bootstrap_bytevectors): New.
      (scm_init_bytevectors): No longer initialize SCM_NULL_BYTEVECTOR,
      which is done by `scm_bootstrap_bytevectors ()'.
    
    * libguile/bytevectors.h (scm_bootstrap_bytevectors): New declaration.
      (scm_init_bytevectors): Made internal.  This can be done because we
      explicitly register it with `scm_c_register_extension ()' in
      `scm_bootstrap_bytevectors ()'.
    
    * libguile/init.c (scm_i_init_guile): Call `scm_bootstrap_bytevectors ()'.
      This is so that expressions like "(generalized-vector-length #vu8())"
      work even when `(rnrs bytevector)' hasn't been loaded.

commit 438974d08dcb96a01fe62ea9b0446b8420e703c4
Author: Ludovic Courtès <address@hidden>
Date:   Mon Jun 22 00:51:08 2009 +0200

    Make bytevectors accessible using the generalized-vector API.
    
    As a side effect, this allows compilation of literal bytevectors
    ("#vu8(...)"), which gets done by the generic array handling
    of the GLIL->assembly compiler.
    
    * doc/ref/api-compound.texi (Generalized Vectors): Mention bytevectors.
      (Arrays, Array Syntax): Likewise.
    
    * doc/ref/api-data.texi (Bytevectors as Generalized Vectors): New node.
    
    * libguile/bytevectors.c (scm_i_bytevector_generalized_set_x): New.
    
    * libguile/bytevectors.h (scm_i_bytevector_generalized_set_x): New
      declaration.
    
    * libguile/srfi-4.c (scm_i_generalized_vector_type,
      scm_array_handle_uniform_element_size,
      scm_array_handle_uniform_writable_elements): Add support for
      bytevectors.
    
    * libguile/unif.c (type_creator_table): Add `vu8'.
      (bytevector_ref, bytevector_set): New functions.
      (memoize_ref, memoize_set): Add support for bytevectors.
    
    * libguile/vectors.c (scm_is_generalized_vector,
      scm_c_generalized_vector_length, scm_c_generalized_vector_ref,
      scm_c_generalized_vector_set_x): Add support for bytevectors.
    
    * test-suite/tests/bytevectors.test ("Generalized Vectors"): New test
      set.

commit 404bb5f87b66709206507acdf7b899101185a7a0
Author: Ludovic Courtès <address@hidden>
Date:   Sun Jun 21 23:16:57 2009 +0200

    bytevectors: Add a C-friendly API.
    
    * doc/ref/api-data.texi (Bytevector Manipulation): Add
      `scm_is_bytevector ()', `scm_c_bytevector_length ()',
      `scm_c_bytevector_length ()', and `scm_c_bytevector_set_x ()'.
    
    * libguile/bytevectors.c (scm_is_bytevector, scm_c_bytevector_length,
      scm_c_bytevector_ref, scm_c_bytevector_set_x): New functions.
      (scm_bytevector_p): Use `scm_is_bytevector ()'.
      (scm_bytevector_length): Use `scm_c_bytevector_length ()'.
    
    * libguile/bytevectors.h (scm_is_bytevector, scm_c_bytevector_length,
      scm_c_bytevector_ref, scm_c_bytevector_set_x): New declarations.

commit 2d34e9244b8b35f62d086a88db749718a2a1a3b4
Author: Ludovic Courtès <address@hidden>
Date:   Sun Jun 21 16:55:58 2009 +0200

    bytevectors: Use `size_t' rather than `unsigned' for sizes.
    
    * doc/ref/api-data.texi (Bytevector Manipulation): Update.
    
    * libguile/bytevectors.c (INTEGER_ACCESSOR_PROLOGUE,
      make_bytevector_from_buffer, scm_c_make_bytevector,
      scm_c_take_bytevector, scm_i_shrink_bytevector): Use `size_t' for
      bytevector lengths.

commit d64fc8b039fd686a5f8f33458ba1193dc584b2a9
Author: Ludovic Courtès <address@hidden>
Date:   Sun Jun 21 23:32:19 2009 +0200

    Fix documentation of `make-bytevector'.
    
    * doc/ref/api-data.texi (Bytevector Manipulation): Fix documentation of
      the FILL argument of `make-bytevector'.

commit 5c27902e5e01a94b22ebc51288500a3d36253293
Author: Andy Wingo <address@hidden>
Date:   Sun Jun 21 14:53:33 2009 +0200

    add brainfuck->tree-il compiler
    
    * module/Makefile.am (BRAINFUCK_LANG_SOURCES): Compile at the end. Add
      compile-tree-il.scm.
    
    * module/language/brainfuck/compile-tree-il.scm: New compiler, compiles
      to tree-il instead of scheme. I thought it would be more illustrative,
      though there are some uncommented bits.
    
    * module/language/brainfuck/parse.scm: Modify not to put a header on the
      scheme representation. After all, we don't put <scheme> before scheme
      code, do we? :)
    
    * module/language/brainfuck/spec.scm: Add tree-il compiler.
    
    * module/language/tree-il.scm: Understand (set! (lexical foo) ...).
    
    * module/system/base/language.scm: Update license. Actually, updates
      licenses on all these.

commit fe2400b2141fbde17eab517794773203fc19f952
Author: Andy Wingo <address@hidden>
Date:   Sun Jun 21 13:36:39 2009 +0200

    formatting changes to (language brainfuck compile-scheme)
    
    * module/language/brainfuck/compile-scheme.scm: Standalone comments
      should have more than one semicolon, and update copyright to LGPLv3+.

commit 4e432dab1f02f5d497a352c1ea9392fc6db0f1f2
Author: Andy Wingo <address@hidden>
Date:   Sun Jun 21 13:10:56 2009 +0200

    link to brainfuck wikipedia page
    
    * doc/ref/compiler.texi: Point to more info on Brainfuck. Patch by
      Daniel Kraft.

commit e63d888ef64c9c96177d841fa9a1ee4e697db81d
Author: Daniel Kraft <address@hidden>
Date:   Sat May 23 09:58:54 2009 +0200

    added documenting comments to the brainfuck compiler and mention it in the 
VM documentation.
    
    * doc/ref/compiler.texi: Mention the new brainfuck compiler as an example.
    * module/language/brainfuck/compile-scheme.scm: Add a lot of documentation 
comments.
    * module/language/brainfuck/parse.scm: Ditto.
    * module/language/brainfuck/spec.scm: Ditto.

commit 6370a6ad25ab0bc47e2f165937db8c7955b2b595
Author: Daniel Kraft <address@hidden>
Date:   Sat May 23 09:58:54 2009 +0200

    basic brainfuck -> scheme example compiler.
    
    * module/Makefile.am: Install the brainfuck compiler modules.
    * module/language/brainfuck/spec.scm: New file.
    * module/language/brainfuck/parse.scm: New file.
    * module/language/brainfuck/compile-scheme.scm: New file.

commit cf6d8d344c8717629279f01acbb785e0d35a12a5
Author: Andy Wingo <address@hidden>
Date:   Sun Jun 21 12:57:55 2009 +0200

    remove obsolete guile-vm.texi
    
    * doc/guile-vm.texi: Remove, has been folded into the Guile manual for a
      while now.
    
    * doc/Makefile.am: Remove guile-vm.texi.

commit c60be0404dd07fb9e9747c02fabc45d38380ed17
Author: Andy Wingo <address@hidden>
Date:   Sun Jun 21 12:51:16 2009 +0200

    update .gitignore
    
    * .gitignore: Update.

commit 4574ec212aad4df9571463ee4d45beb2607e51ad
Author: Neil Jerram <address@hidden>
Date:   Sun Jun 21 13:31:20 2009 +0100

    Deterministic test for the r6rs-ports.test segmentation fault
    
    * test-suite/tests/r6rs-ports.test ("7.2.7 Input Ports"): Add (gc), to
      test the (ex-)bug in cbp_mark () when marking a closed port.

commit 8806afa7dd0582f774daadafbe6ec8163b2deea8
Author: Andy Wingo <address@hidden>
Date:   Sun Jun 21 12:41:46 2009 +0200

    Fix crash when marking closed custom bytevector port
    
    * libguile/r6rs-ports.c (cbp_mark): A closed port will have had its
      stream destroyed, so don't dereference the stream in that case. Patch by
      Mike Gran.

commit 179fe3363241ea1aeb48f1f63d13d2dd12196dcf
Author: Andy Wingo <address@hidden>
Date:   Sat Jun 20 14:26:54 2009 +0200

    put autocompiled files into ~/.cache or $XDG_CACHE_HOME
    
    * module/system/base/compile.scm (compiled-file-name): Remove unneeded
      path separator.
    
    * libguile/load.c (scm_init_load_path): Change so the default cache path
      is ~/.cache/guile/ccache/1.9, and respect $XDG_CACHE_HOME.

commit 89cb70a0d5f365ebdfcc0257d6cab4a80a9f6a74
Author: Andy Wingo <address@hidden>
Date:   Sat Jun 20 12:41:11 2009 +0200

    fix source information lossage for (define (foo) ...) lambda sugar
    
    * module/ice-9/psyntax.scm (source-wrap): Use decorate-source, for
      clarity.
      (syntax-type): When turning the RHS of (define (foo) ...) into a
      lambda, decorate the resulting lambda expression with source
      information, as the RHS later goes to chi-expr, which receives no
      source information. Perhaps that is a bug. In any case, fixes some
      source location lossage, reported by Jao.
    
    * module/ice-9/psyntax-pp.scm: Regenerated.

commit 74fdb02e5eaf31b4af337d8d101300493cc7f281
Author: Andy Wingo <address@hidden>
Date:   Sat Jun 20 11:41:50 2009 +0200

    better error in make_objcode_by_mmap
    
    * libguile/objcodes.c (make_objcode_by_mmap): Better error when the
      object header is incorrect.

commit fc5b616b5816a425863fd06c50f41513c31693f8
Author: Andy Wingo <address@hidden>
Date:   Sat Jun 20 10:47:37 2009 +0200

    source information for the interpreter
    
    * module/ice-9/psyntax.scm: Try to propagate source information when
      generating output for the interpreter.
    
    * module/ice-9/psyntax-pp.scm: Regenerate.

commit f4bf64b4d422bb093a3e857380d99e4f08b9c8af
Author: Ludovic Courtès <address@hidden>
Date:   Fri Jun 19 22:46:07 2009 +0200

    Make `cond-expand' compilable.
    
    * module/ice-9/boot-9.scm (cond-expand): Changed into a `define-macro'
      macro.

commit 23044464c2e26649329b422380a6850d53eec725
Author: Ludovic Courtès <address@hidden>
Date:   Fri Jun 19 22:01:56 2009 +0200

    Fix copyright year and authorship of `guile-tools'.

commit 93617170fa8dc30378ee09b1c24827975f895406
Author: Ludovic Courtès <address@hidden>
Date:   Fri Jun 19 21:55:53 2009 +0200

    Slightly improve `NEWS'.

commit 8141fc3b4633993fe37fef19a81a823cf727b90b
Author: Ludovic Courtès <address@hidden>
Date:   Fri Jun 19 21:54:51 2009 +0200

    Fix "guile-tools disassemble".
    
    * module/scripts/disassemble.scm (disassemble): Accept a variable number
      of arguments.  Invoke the right `disassemble' procedure.

commit b57501c3b7afa0378e3142cc415cfd02a374a77e
Author: Andy Wingo <address@hidden>
Date:   Fri Jun 19 14:27:56 2009 +0200

    don't autocompile at installcheck
    
    * examples/Makefile.am: Don't autocompile our tests at installcheck
      time.

commit 25b82b3485e9e44d8d6268d3774b0b81d0d501b2
Author: Andy Wingo <address@hidden>
Date:   Fri Jun 19 14:26:47 2009 +0200

    new function: canonicalize-path. use when autocompiling
    
    * libguile/filesys.h:
    * libguile/filesys.c (scm_canonicalize_path): New function,
      canonicalize-path.
    
    * module/system/base/compile.scm (compiled-file-name): Canonicalize the
      filename so that compiling e.g. ../foo.scm doesn't compile to
      ~/.guile-ccache/1.9/../foo.scm.

commit ffca4c2203d85bc4d9e348d77053d21112e665af
Author: Andy Wingo <address@hidden>
Date:   Fri Jun 19 13:01:11 2009 +0200

    gnulib-tool --import canonicalize-lgpl

commit 5b55e29320449c8c68112129e1cadbfa7944af11
Author: Andy Wingo <address@hidden>
Date:   Fri Jun 19 12:32:01 2009 +0200

    generate changelogs at dist time
    
    * Makefile.am: Add rule to make a ChangeLog at dist-time. The rule comes
      from coreutils.
    
    * build-aux/gitlog-to-changelog: New helper script, from gnulib.

commit ce471ab8b083a345af0f49e08f51f22dbfe58efe
Author: Andy Wingo <address@hidden>
Date:   Fri Jun 19 11:20:34 2009 +0200

    rename SCM_SNAME to SCM_SUBR_NAME
    
    * libguile/procs.h: Rename SCM_SNAME to SCM_SUBR_NAME.
    
    * libguile/debug.c:
    * libguile/eval.c:
    * libguile/eval.i.c:
    * libguile/goops.c:
    * libguile/gsubr.c:
    * libguile/print.c:
    * libguile/procs.c: Update callers.

commit 96b73e84bbb6d88c73a99bf46450642d79612be0
Author: Andy Wingo <address@hidden>
Date:   Fri Jun 19 11:19:34 2009 +0200

    another draft of NEWS
    
    * NEWS: Another draft.

commit 159399850de811f23e45d439aecf452b0137d847
Author: Ludovic Courtès <address@hidden>
Date:   Fri Jun 19 02:35:57 2009 +0200

    Fix decompilation of the `load-array' instruction.
    
    This allows, e.g., ",c #u8(1 2 3)" at the REPL to actually work instead
    of failing to decode `load-array'.
    
    * module/language/assembly/decompile-bytecode.scm (decode-bytecode):
      Account for the `load-array' instruction, which is followed by a
      bytevector instead of a string.  We should find a more elegant way to
      do that.

commit 81e002fcb90c99ac2840dcde81f286772b1fb1a2
Author: Ludovic Courtès <address@hidden>
Date:   Fri Jun 19 02:14:22 2009 +0200

    Fix the REPL's `,compile' command.
    
    * module/system/repl/command.scm (compile): Use `guile:disassemble'
      instead of the former `disassemble-objcode'.

commit 0ba0b3848913ca871235ad4b2f8ef184bf8f552b
Author: Ludovic Courtès <address@hidden>
Date:   Fri Jun 19 00:47:11 2009 +0200

    Implement R6RS bytevector read syntax.
    
    * libguile/read.c (scm_read_bytevector): New function.
      (scm_read_sharp): Add `v' case for bytevectors.
    
    * test-suite/lib.scm (exception:read-error): New variable.
    
    * test-suite/tests/bytevectors.test ("Datum Syntax"): New test set.

commit 55bf8cb7af47cde26e6a70dae056752c8265508d
Author: Ludovic Courtès <address@hidden>
Date:   Fri Jun 19 00:10:21 2009 +0200

    Fix `equal?' on bytevectors.
    
    * libguile/bytevectors.c (bytevector_equal_p): New function.
    
    * test-suite/tests/bytevectors.test ("2.3 Operations on Bytes and
      Octets")["equal?"]: New test.

commit b242715b288b8f076d1617668e77f1ef44dfeeb3
Author: Ludovic Courtès <address@hidden>
Date:   Thu May 28 23:57:31 2009 +0200

    Import documentation for the R6RS bytevector and port APIs.
    
    * doc/ref/api-compound.texi (Uniform Numeric Vectors): Add xref to the
      bytevector API.
    
    * doc/ref/api-data.texi (Bytevectors): New node.
    
    * doc/ref/api-io.texi (R6RS I/O Ports): New node.

commit fa1804e94394d92b9999eaee769653ed423474b3
Author: Andy Wingo <address@hidden>
Date:   Thu Jun 18 23:02:51 2009 +0200

    update NEWS, THANKS
    
    * NEWS: Update, but only partially. I wanted to push out this
      incomplete, not yet organized draft for review, if anyone had
      comments. I'll pick it up tomorrow morning.
    
    * THANKS: Add Juhani, whose last name changed?

commit b82a8b48507f67b6dbffdd048dc088e084d1413e
Author: Neil Jerram <address@hidden>
Date:   Wed Jun 17 22:35:30 2009 +0100

    Change guile-readline license to GPLv3+

commit 83ba2d3750ea105d8193fcb1b7162539160cf91c
Author: Neil Jerram <address@hidden>
Date:   Wed Jun 17 22:30:26 2009 +0100

    Complete changing license to LGPLv3+
    
    (Still guile-readline to do, but that will all be GPLv3+.)

commit 1b34e26a20aedd43ac5d6e87f5be7d10e1bb4f5f
Author: Neil Jerram <address@hidden>
Date:   Wed Jun 17 21:34:38 2009 +0100

    Reinstate lines removed by mistake from chars.test

commit 53befeb700c31dec58cec2c8f6f34535541a2f39
Author: Neil Jerram <address@hidden>
Date:   Wed Jun 17 00:22:09 2009 +0100

    Change Guile license to LGPLv3+
    
    (Not quite finished, the following will be done tomorrow.
       module/srfi/*.scm
       module/rnrs/*.scm
       module/scripts/*.scm
       testsuite/*.scm
       guile-readline/*
    )

commit a89cafc0562942680db63fe8ddf89f466ba2f7af
Author: Neil Jerram <address@hidden>
Date:   Sun Jun 14 18:41:50 2009 +0100

    Update README on using libraries in non-standard locations
    
    * README: Update instructions on using libraries in non-standard
      locations.  Also change expected next stable release number from
      1.10.0 to 2.0.0.

commit 5aaccd35a24eb67d5c489bda4e1e5faf1b22744e
Author: Neil Jerram <address@hidden>
Date:   Sun Jun 14 18:07:01 2009 +0100

    Add Tex and texinfo output and auxiliary suffixes to .gitignore

commit 39b94fee4304d56babf5bd62e10c5786a79f4389
Author: Neil Jerram <address@hidden>
Date:   Sun Jun 14 17:58:15 2009 +0100

    Provide easier configure options for GMP and readline
    
    This patch uses the AC_LIB_LINKFLAGS macro, provided by Gnulib's
    havelib module, to provide --with-gmp-prefix and
    --with-readline-prefix configure options.  Many thanks to Bruno Haible
    for suggesting and explaining this to me.
    
    * configure.in (top level): Add AC_LIB_LINKFLAGS(gmp).
    
    * guile-readline/configure.in (AC_CONFIG_AUX_DIR): Change to
      ../build-aux, to share the main build-aux directory and so avoid
      having to distribute multiple copies of config.rpath.
      (top level): Add AC_LIB_LINKFLAGS(readline).
    
    * lib/Makefile.am, m4/gnulib-cache.m4: Regenerated by gnulib-tool for
      new import of the `havelib' module.

commit f856c2b6d77633366f154cb38cd4edb384b4892d
Author: Neil Jerram <address@hidden>
Date:   Sat Jun 13 10:45:45 2009 +0100

    Fix for make distcheck
    
    * examples/Makefile.am (AM_CFLAGS, AM_LIBS): Set PATH so that
      guile-config can find guile.

commit 62e9a9b704524edfad98dd84ac5a11abd48d0b27
Author: Neil Jerram <address@hidden>
Date:   Fri Jun 12 23:04:48 2009 +0100

    Fix `make distcheck'
    
    * libguile/r6rs-ports.c (scm_init_r6rs_ports): Add libguile/ to
      included .x file name.

commit dffd0672faf3db4fa46042e447e62dff22a9e4e9
Author: Neil Jerram <address@hidden>
Date:   Thu Jun 11 23:24:34 2009 +0100

    Note Andy as a contributor

-----------------------------------------------------------------------

Summary of changes:
 .gitignore                                         |   33 +
 COPYING                                            |  674 ++
 COPYING.LESSER                                     |  659 +--
 LICENSE                                            |    2 +-
 Makefile.am                                        |   30 +-
 NEWS                                               |  516 ++-
 README                                             |   53 +-
 THANKS                                             |    2 +
 am/Makefile.am                                     |   16 +-
 am/maintainer-dirs                                 |   10 +-
 am/pre-inst-guile                                  |   10 +-
 benchmark-suite/benchmarks/bytevectors.bm          |   15 +-
 benchmark-suite/benchmarks/read.bm                 |   18 +-
 benchmark-suite/benchmarks/subr.bm                 |   18 +-
 benchmark-suite/benchmarks/uniform-vector-read.bm  |   18 +-
 benchmark-suite/guile-benchmark                    |   18 +-
 benchmark-suite/lib.scm                            |   18 +-
 build-aux/gitlog-to-changelog                      |  183 +
 configure.in                                       |   25 +-
 doc/Makefile.am                                    |   20 +-
 doc/example-smob/image-type.c                      |   24 +-
 doc/example-smob/myguile.c                         |   24 +-
 doc/goops/Makefile.am                              |   20 +-
 doc/groupings.alist                                |   22 +-
 doc/guile-vm.texi                                  | 1042 ---
 doc/maint/docstring.el                             |   26 +-
 doc/oldfmt.c                                       |   21 +-
 doc/r5rs/Makefile.am                               |   20 +-
 doc/ref/Makefile.am                                |   16 +-
 doc/ref/api-compound.texi                          |   30 +-
 doc/ref/api-data.texi                              |  440 ++-
 doc/ref/api-io.texi                                |  266 +-
 doc/ref/compiler.texi                              |   16 +-
 doc/ref/intro.texi                                 |   12 +-
 doc/ref/preface.texi                               |    6 +-
 doc/tutorial/Makefile.am                           |   20 +-
 emacs/Makefile.am                                  |   16 +-
 emacs/gds-scheme.el                                |    3 +-
 emacs/gds-server.el                                |    3 +-
 emacs/gds.el                                       |    3 +-
 emacs/gud-guile.el                                 |   28 +-
 emacs/guile-c.el                                   |   28 +-
 emacs/guile-emacs.scm                              |   28 +-
 emacs/guile-scheme.el                              |   28 +-
 emacs/guile.el                                     |   28 +-
 emacs/multistring.el                               |   30 +-
 emacs/patch.el                                     |   28 +-
 emacs/ppexpand.el                                  |   30 +-
 emacs/update-changelog.el                          |   28 +-
 examples/Makefile.am                               |   25 +-
 examples/box-dynamic-module/box.c                  |   24 +-
 examples/box-dynamic/box.c                         |   24 +-
 examples/box-module/box.c                          |   24 +-
 examples/box/box.c                                 |   24 +-
 examples/compat/compat.h                           |    9 +-
 gc-benchmarks/gc-profile.scm                       |   18 +-
 gc-benchmarks/run-benchmark.scm                    |   18 +-
 guile-readline/Makefile.am                         |   20 +-
 guile-readline/configure.in                        |    3 +-
 guile-readline/ice-9/Makefile.am                   |   20 +-
 guile-readline/ice-9/readline.scm                  |    2 +-
 guile-readline/readline.c                          |    2 +-
 guile-readline/readline.h                          |    2 +-
 lang/Makefile.am                                   |   20 +-
 lib/Makefile.am                                    |   37 +-
 lib/canonicalize-lgpl.c                            |  362 +
 lib/canonicalize.h                                 |   52 +
 lib/malloca.c                                      |  137 +
 lib/malloca.h                                      |  134 +
 lib/malloca.valgrind                               |    7 +
 lib/pathmax.h                                      |   47 +
 lib/readlink.c                                     |   49 +
 lib/string.in.h                                    |   17 +-
 libguile.h                                         |   13 +-
 libguile/Makefile.am                               |   16 +-
 libguile/__scm.h                                   |   15 +-
 libguile/_scm.h                                    |   13 +-
 libguile/alist.c                                   |   13 +-
 libguile/alist.h                                   |   13 +-
 libguile/arbiters.c                                |   13 +-
 libguile/arbiters.h                                |   13 +-
 libguile/async.c                                   |   13 +-
 libguile/async.h                                   |   13 +-
 libguile/backtrace.c                               |   13 +-
 libguile/backtrace.h                               |   13 +-
 libguile/boolean.c                                 |   13 +-
 libguile/boolean.h                                 |   13 +-
 libguile/bytevectors.c                             |  135 +-
 libguile/bytevectors.h                             |   30 +-
 libguile/chars.c                                   |   13 +-
 libguile/chars.h                                   |   20 +-
 libguile/continuations.c                           |   13 +-
 libguile/continuations.h                           |   13 +-
 libguile/convert.c                                 |   13 +-
 libguile/convert.h                                 |   13 +-
 libguile/debug-malloc.c                            |   13 +-
 libguile/debug-malloc.h                            |   13 +-
 libguile/debug.c                                   |   15 +-
 libguile/debug.h                                   |   13 +-
 libguile/deprecated.c                              |   13 +-
 libguile/deprecated.h                              |   13 +-
 libguile/deprecation.c                             |   16 +-
 libguile/deprecation.h                             |   13 +-
 libguile/discouraged.c                             |   13 +-
 libguile/discouraged.h                             |   13 +-
 libguile/dynl.c                                    |   13 +-
 libguile/dynl.h                                    |   13 +-
 libguile/dynwind.c                                 |   13 +-
 libguile/dynwind.h                                 |   13 +-
 libguile/environments.c                            |   13 +-
 libguile/environments.h                            |   13 +-
 libguile/eq.c                                      |   13 +-
 libguile/eq.h                                      |   13 +-
 libguile/error.c                                   |   13 +-
 libguile/error.h                                   |   13 +-
 libguile/eval.c                                    |   13 +-
 libguile/eval.h                                    |   13 +-
 libguile/eval.i.c                                  |   13 +-
 libguile/evalext.c                                 |   13 +-
 libguile/evalext.h                                 |   13 +-
 libguile/extensions.c                              |   13 +-
 libguile/extensions.h                              |   13 +-
 libguile/feature.c                                 |   13 +-
 libguile/feature.h                                 |   13 +-
 libguile/filesys.c                                 |   35 +-
 libguile/filesys.h                                 |   14 +-
 libguile/fluids.c                                  |   13 +-
 libguile/fluids.h                                  |   13 +-
 libguile/fports.c                                  |   13 +-
 libguile/fports.h                                  |   13 +-
 libguile/frames.c                                  |   13 +-
 libguile/frames.h                                  |   13 +-
 libguile/futures.c                                 |   13 +-
 libguile/futures.h                                 |   13 +-
 libguile/gc-card.c                                 |   13 +-
 libguile/gc-freelist.c                             |   13 +-
 libguile/gc-malloc.c                               |   13 +-
 libguile/gc-mark.c                                 |   13 +-
 libguile/gc-segment-table.c                        |   13 +-
 libguile/gc-segment.c                              |   13 +-
 libguile/gc.c                                      |   13 +-
 libguile/gc.h                                      |   13 +-
 libguile/gdb_interface.h                           |   27 +-
 libguile/gdbint.c                                  |   13 +-
 libguile/gdbint.h                                  |   13 +-
 libguile/gettext.c                                 |   13 +-
 libguile/gettext.h                                 |   13 +-
 libguile/goops.c                                   |   17 +-
 libguile/goops.h                                   |   13 +-
 libguile/gsubr.c                                   |   27 +-
 libguile/gsubr.h                                   |   13 +-
 libguile/guardians.c                               |   13 +-
 libguile/guardians.h                               |   13 +-
 libguile/guile-doc-snarf.in                        |   26 +-
 libguile/guile-func-name-check.in                  |   22 +-
 libguile/guile-snarf-docs.in                       |   22 +-
 libguile/guile-snarf.awk.in                        |   22 +-
 libguile/guile-snarf.in                            |   26 +-
 libguile/guile.c                                   |   13 +-
 libguile/hash.c                                    |   13 +-
 libguile/hash.h                                    |   13 +-
 libguile/hashtab.c                                 |   13 +-
 libguile/hashtab.h                                 |   13 +-
 libguile/hooks.c                                   |   13 +-
 libguile/hooks.h                                   |   13 +-
 libguile/i18n.c                                    |   13 +-
 libguile/i18n.h                                    |   13 +-
 libguile/init.c                                    |   15 +-
 libguile/init.h                                    |   13 +-
 libguile/inline.c                                  |   13 +-
 libguile/inline.h                                  |   13 +-
 libguile/instructions.c                            |   13 +-
 libguile/instructions.h                            |   13 +-
 libguile/ioext.c                                   |   13 +-
 libguile/ioext.h                                   |   13 +-
 libguile/iselect.h                                 |   13 +-
 libguile/keywords.c                                |   13 +-
 libguile/keywords.h                                |   13 +-
 libguile/lang.c                                    |   13 +-
 libguile/lang.h                                    |   13 +-
 libguile/list.c                                    |   13 +-
 libguile/list.h                                    |   13 +-
 libguile/load.c                                    |   49 +-
 libguile/load.h                                    |   13 +-
 libguile/locale-categories.h                       |   13 +-
 libguile/macros.c                                  |   13 +-
 libguile/macros.h                                  |   13 +-
 libguile/mallocs.c                                 |   13 +-
 libguile/mallocs.h                                 |   13 +-
 libguile/modules.c                                 |   13 +-
 libguile/modules.h                                 |   13 +-
 libguile/net_db.c                                  |   13 +-
 libguile/net_db.h                                  |   13 +-
 libguile/null-threads.c                            |   13 +-
 libguile/null-threads.h                            |   13 +-
 libguile/numbers.c                                 |   13 +-
 libguile/numbers.h                                 |   13 +-
 libguile/objcodes.c                                |   17 +-
 libguile/objcodes.h                                |   15 +-
 libguile/objects.c                                 |   13 +-
 libguile/objects.h                                 |   13 +-
 libguile/objprop.c                                 |   13 +-
 libguile/objprop.h                                 |   13 +-
 libguile/options.c                                 |   13 +-
 libguile/options.h                                 |   13 +-
 libguile/pairs.c                                   |   13 +-
 libguile/pairs.h                                   |   13 +-
 libguile/ports.c                                   |   13 +-
 libguile/ports.h                                   |   13 +-
 libguile/posix.c                                   |   13 +-
 libguile/posix.h                                   |   13 +-
 libguile/print.c                                   |   15 +-
 libguile/print.h                                   |   13 +-
 libguile/private-gc.h                              |   13 +-
 libguile/private-options.h                         |   13 +-
 libguile/procprop.c                                |   13 +-
 libguile/procprop.h                                |   13 +-
 libguile/procs.c                                   |   19 +-
 libguile/procs.h                                   |   15 +-
 libguile/programs.c                                |   13 +-
 libguile/programs.h                                |   13 +-
 libguile/properties.c                              |   13 +-
 libguile/properties.h                              |   13 +-
 libguile/pthread-threads.h                         |   13 +-
 libguile/putenv.c                                  |   13 +-
 libguile/r6rs-ports.c                              |   17 +-
 libguile/r6rs-ports.h                              |   13 +-
 libguile/ramap.c                                   |   13 +-
 libguile/ramap.h                                   |   13 +-
 libguile/random.c                                  |   13 +-
 libguile/random.h                                  |   13 +-
 libguile/rdelim.c                                  |   13 +-
 libguile/rdelim.h                                  |   13 +-
 libguile/read.c                                    |   42 +-
 libguile/read.h                                    |   13 +-
 libguile/regex-posix.c                             |   13 +-
 libguile/regex-posix.h                             |   13 +-
 libguile/root.c                                    |   13 +-
 libguile/root.h                                    |   13 +-
 libguile/rw.c                                      |   13 +-
 libguile/rw.h                                      |   13 +-
 libguile/scmconfig.h.top                           |   13 +-
 libguile/scmsigs.c                                 |   13 +-
 libguile/scmsigs.h                                 |   13 +-
 libguile/script.c                                  |   13 +-
 libguile/script.h                                  |   13 +-
 libguile/simpos.c                                  |   13 +-
 libguile/simpos.h                                  |   13 +-
 libguile/smob.c                                    |   13 +-
 libguile/smob.h                                    |   13 +-
 libguile/snarf.h                                   |   13 +-
 libguile/socket.c                                  |   13 +-
 libguile/socket.h                                  |   13 +-
 libguile/sort.c                                    |   13 +-
 libguile/sort.h                                    |   13 +-
 libguile/srcprop.c                                 |   13 +-
 libguile/srcprop.h                                 |   13 +-
 libguile/srfi-13.c                                 |   13 +-
 libguile/srfi-13.h                                 |   13 +-
 libguile/srfi-14.c                                 | 1322 +++--
 libguile/srfi-14.h                                 |   50 +-
 libguile/srfi-4.c                                  |   22 +-
 libguile/srfi-4.h                                  |   13 +-
 libguile/stackchk.c                                |   13 +-
 libguile/stackchk.h                                |   13 +-
 libguile/stacks.c                                  |   13 +-
 libguile/stacks.h                                  |   13 +-
 libguile/stime.c                                   |   13 +-
 libguile/stime.h                                   |   13 +-
 libguile/strerror.c                                |   27 +-
 libguile/strings.c                                 |   13 +-
 libguile/strings.h                                 |   13 +-
 libguile/strorder.c                                |   13 +-
 libguile/strorder.h                                |   13 +-
 libguile/strports.c                                |   13 +-
 libguile/strports.h                                |   13 +-
 libguile/struct.c                                  |   13 +-
 libguile/struct.h                                  |   13 +-
 libguile/symbols.c                                 |   13 +-
 libguile/symbols.h                                 |   13 +-
 libguile/tags.h                                    |   13 +-
 libguile/threads.c                                 |   13 +-
 libguile/threads.h                                 |   13 +-
 libguile/throw.c                                   |   13 +-
 libguile/throw.h                                   |   13 +-
 libguile/unif.c                                    |   44 +-
 libguile/unif.h                                    |   13 +-
 libguile/validate.h                                |   13 +-
 libguile/values.c                                  |   13 +-
 libguile/values.h                                  |   13 +-
 libguile/variable.c                                |   13 +-
 libguile/variable.h                                |   13 +-
 libguile/vectors.c                                 |   27 +-
 libguile/vectors.h                                 |   13 +-
 libguile/version.c                                 |   13 +-
 libguile/version.h.in                              |   13 +-
 libguile/vm-bootstrap.h                            |   13 +-
 libguile/vm-engine.c                               |   13 +-
 libguile/vm-engine.h                               |   13 +-
 libguile/vm-expand.h                               |   13 +-
 libguile/vm-i-loader.c                             |   13 +-
 libguile/vm-i-scheme.c                             |   13 +-
 libguile/vm-i-system.c                             |   13 +-
 libguile/vm.c                                      |   13 +-
 libguile/vm.h                                      |   13 +-
 libguile/vports.c                                  |   13 +-
 libguile/vports.h                                  |   13 +-
 libguile/weaks.c                                   |   13 +-
 libguile/weaks.h                                   |   13 +-
 libguile/win32-dirent.c                            |   13 +-
 libguile/win32-dirent.h                            |   13 +-
 libguile/win32-socket.c                            |   13 +-
 libguile/win32-socket.h                            |   13 +-
 libguile/win32-uname.c                             |   13 +-
 libguile/win32-uname.h                             |   13 +-
 m4/canonicalize-lgpl.m4                            |   35 +
 m4/eealloc.m4                                      |   32 +
 m4/gnulib-cache.m4                                 |    4 +-
 m4/gnulib-comp.m4                                  |   18 +
 m4/malloca.m4                                      |   14 +
 m4/pathmax.m4                                      |   12 +
 m4/readlink.m4                                     |   29 +
 m4/string_h.m4                                     |    6 +-
 meta/Makefile.am                                   |   16 +-
 meta/gdb-uninstalled-guile.in                      |   16 +-
 meta/guile-config                                  |    7 +-
 meta/guile-tools                                   |   11 +-
 meta/guile.in                                      |   16 +-
 meta/guile.m4                                      |    9 +-
 meta/uninstalled-env.in                            |   11 +-
 module/Makefile.am                                 |   23 +-
 module/ice-9/and-let-star.scm                      |    2 +-
 module/ice-9/arrays.scm                            |   21 +-
 module/ice-9/boot-9.scm                            |  125 +-
 module/ice-9/buffered-input.scm                    |    2 +-
 module/ice-9/calling.scm                           |    2 +-
 module/ice-9/channel.scm                           |   26 +-
 module/ice-9/common-list.scm                       |    2 +-
 module/ice-9/debug.scm                             |    2 +-
 module/ice-9/debugger.scm                          |   26 +-
 module/ice-9/debugger/command-loop.scm             |   26 +-
 module/ice-9/debugger/commands.scm                 |   26 +-
 module/ice-9/debugger/state.scm                    |   26 +-
 module/ice-9/debugger/trc.scm                      |   26 +-
 module/ice-9/debugging/breakpoints.scm             |   26 +-
 module/ice-9/debugging/steps.scm                   |   26 +-
 module/ice-9/debugging/trace.scm                   |   26 +-
 module/ice-9/debugging/traps.scm                   |   26 +-
 module/ice-9/debugging/trc.scm                     |   26 +-
 module/ice-9/deprecated.scm                        |    2 +-
 module/ice-9/documentation.scm                     |    2 +-
 module/ice-9/emacs.scm                             |    2 +-
 module/ice-9/expect.scm                            |    2 +-
 module/ice-9/ftw.scm                               |    2 +-
 module/ice-9/gap-buffer.scm                        |   26 +-
 module/ice-9/gds-server.scm                        |   26 +-
 module/ice-9/getopt-long.scm                       |   26 +-
 module/ice-9/hcons.scm                             |    2 +-
 module/ice-9/history.scm                           |    2 +-
 module/ice-9/i18n.scm                              |    6 +-
 module/ice-9/lineio.scm                            |    2 +-
 module/ice-9/list.scm                              |   26 +-
 module/ice-9/ls.scm                                |    2 +-
 module/ice-9/mapping.scm                           |    2 +-
 module/ice-9/match.scm                             |    2 +-
 module/ice-9/networking.scm                        |    2 +-
 module/ice-9/null.scm                              |    2 +-
 module/ice-9/occam-channel.scm                     |   26 +-
 module/ice-9/optargs.scm                           |    2 +-
 module/ice-9/poe.scm                               |    2 +-
 module/ice-9/popen.scm                             |    2 +-
 module/ice-9/posix.scm                             |    2 +-
 module/ice-9/pretty-print.scm                      |    2 +-
 module/ice-9/psyntax-pp.scm                        | 7556 ++++++++++----------
 module/ice-9/psyntax.scm                           |   73 +-
 module/ice-9/q.scm                                 |    2 +-
 module/ice-9/r4rs.scm                              |    2 +-
 module/ice-9/r5rs.scm                              |    2 +-
 module/ice-9/rdelim.scm                            |    2 +-
 module/ice-9/receive.scm                           |   26 +-
 module/ice-9/regex.scm                             |    2 +-
 module/ice-9/runq.scm                              |    2 +-
 module/ice-9/rw.scm                                |    2 +-
 module/ice-9/safe-r5rs.scm                         |    2 +-
 module/ice-9/safe.scm                              |    2 +-
 module/ice-9/serialize.scm                         |    2 +-
 module/ice-9/session.scm                           |    2 +-
 module/ice-9/slib.scm                              |    6 +-
 module/ice-9/stack-catch.scm                       |    2 +-
 module/ice-9/streams.scm                           |    2 +-
 module/ice-9/string-fun.scm                        |    2 +-
 module/ice-9/syncase.scm                           |    2 +-
 module/ice-9/test.scm                              |   26 +-
 module/ice-9/threads.scm                           |    2 +-
 module/ice-9/time.scm                              |    2 +-
 module/ice-9/weak-vector.scm                       |    2 +-
 module/language/assembly.scm                       |   27 +-
 module/language/assembly/compile-bytecode.scm      |   27 +-
 module/language/assembly/decompile-bytecode.scm    |   46 +-
 module/language/assembly/disassemble.scm           |   27 +-
 module/language/assembly/spec.scm                  |   27 +-
 module/language/brainfuck/compile-scheme.scm       |  126 +
 module/language/brainfuck/compile-tree-il.scm      |  153 +
 module/language/brainfuck/parse.scm                |   91 +
 module/language/brainfuck/spec.scm                 |   44 +
 module/language/bytecode/spec.scm                  |   27 +-
 module/language/ecmascript/array.scm               |   27 +-
 module/language/ecmascript/base.scm                |   27 +-
 module/language/ecmascript/compile-ghil.scm        |   27 +-
 module/language/ecmascript/function.scm            |   27 +-
 module/language/ecmascript/impl.scm                |   27 +-
 module/language/ecmascript/parse-lalr.scm          |   25 +-
 module/language/ecmascript/parse.scm               |   27 +-
 module/language/ecmascript/spec.scm                |   27 +-
 module/language/ecmascript/tokenize.scm            |   27 +-
 module/language/elisp/spec.scm                     |   27 +-
 module/language/ghil.scm                           |   27 +-
 module/language/ghil/compile-glil.scm              |   27 +-
 module/language/ghil/spec.scm                      |   27 +-
 module/language/glil.scm                           |   27 +-
 module/language/glil/compile-assembly.scm          |   27 +-
 module/language/glil/decompile-assembly.scm        |   27 +-
 module/language/glil/spec.scm                      |   27 +-
 module/language/objcode.scm                        |   27 +-
 module/language/objcode/spec.scm                   |   27 +-
 module/language/r5rs/core.il                       |   27 +-
 module/language/r5rs/expand.scm                    |   27 +-
 module/language/r5rs/null.il                       |   27 +-
 module/language/r5rs/spec.scm                      |   27 +-
 module/language/scheme/compile-ghil.scm            |   27 +-
 module/language/scheme/compile-tree-il.scm         |   27 +-
 module/language/scheme/decompile-tree-il.scm       |   27 +-
 module/language/scheme/inline.scm                  |   27 +-
 module/language/scheme/spec.scm                    |   27 +-
 module/language/tree-il.scm                        |    5 +-
 module/language/tree-il/analyze.scm                |   27 +-
 module/language/tree-il/compile-glil.scm           |   27 +-
 module/language/tree-il/optimize.scm               |   27 +-
 module/language/tree-il/primitives.scm             |   26 +-
 module/language/tree-il/spec.scm                   |   27 +-
 module/language/value/spec.scm                     |   27 +-
 module/oop/goops.scm                               |    2 +-
 module/oop/goops/accessors.scm                     |   21 +-
 module/oop/goops/active-slot.scm                   |    2 +-
 module/oop/goops/compile.scm                       |    2 +-
 module/oop/goops/composite-slot.scm                |    2 +-
 module/oop/goops/describe.scm                      |    2 +-
 module/oop/goops/dispatch.scm                      |    2 +-
 module/oop/goops/internal.scm                      |    2 +-
 module/oop/goops/save.scm                          |    2 +-
 module/oop/goops/simple.scm                        |    2 +-
 module/oop/goops/stklos.scm                        |    2 +-
 module/oop/goops/util.scm                          |    2 +-
 module/rnrs/bytevector.scm                         |    2 +-
 module/rnrs/io/ports.scm                           |    2 +-
 module/scripts/PROGRAM.scm                         |   14 +-
 module/scripts/api-diff.scm                        |   14 +-
 module/scripts/autofrisk.scm                       |   14 +-
 module/scripts/compile.scm                         |   14 +-
 module/scripts/disassemble.scm                     |   27 +-
 module/scripts/display-commentary.scm              |   14 +-
 module/scripts/doc-snarf.scm                       |   14 +-
 module/scripts/frisk.scm                           |   14 +-
 module/scripts/generate-autoload.scm               |   14 +-
 module/scripts/lint.scm                            |   14 +-
 module/scripts/punify.scm                          |   14 +-
 module/scripts/read-rfc822.scm                     |   14 +-
 module/scripts/read-scheme-source.scm              |   14 +-
 module/scripts/read-text-outline.scm               |   14 +-
 module/scripts/scan-api.scm                        |   14 +-
 module/scripts/snarf-check-and-output-texi.scm     |   14 +-
 module/scripts/snarf-guile-m4-docs.scm             |   14 +-
 module/scripts/summarize-guile-TODO.scm            |   14 +-
 module/scripts/use2dot.scm                         |   14 +-
 module/srfi/Makefile.am                            |   20 +-
 module/srfi/srfi-1.scm                             |    2 +-
 module/srfi/srfi-10.scm                            |    2 +-
 module/srfi/srfi-11.scm                            |    2 +-
 module/srfi/srfi-13.scm                            |    2 +-
 module/srfi/srfi-14.scm                            |    2 +-
 module/srfi/srfi-16.scm                            |    2 +-
 module/srfi/srfi-17.scm                            |    2 +-
 module/srfi/srfi-18.scm                            |    2 +-
 module/srfi/srfi-19.scm                            |    2 +-
 module/srfi/srfi-2.scm                             |    2 +-
 module/srfi/srfi-26.scm                            |    2 +-
 module/srfi/srfi-31.scm                            |    2 +-
 module/srfi/srfi-34.scm                            |    2 +-
 module/srfi/srfi-35.scm                            |    2 +-
 module/srfi/srfi-37.scm                            |    2 +-
 module/srfi/srfi-39.scm                            |    2 +-
 module/srfi/srfi-4.scm                             |    2 +-
 module/srfi/srfi-6.scm                             |    2 +-
 module/srfi/srfi-60.scm                            |    2 +-
 module/srfi/srfi-69.scm                            |    2 +-
 module/srfi/srfi-8.scm                             |    2 +-
 module/srfi/srfi-88.scm                            |    2 +-
 module/srfi/srfi-9.scm                             |    2 +-
 module/srfi/srfi-98.scm                            |    2 +-
 module/system/base/compile.scm                     |    6 +-
 module/system/base/language.scm                    |   24 +-
 module/system/repl/command.scm                     |    2 +-
 qt/Makefile.am                                     |   20 +-
 qt/md/Makefile.am                                  |   20 +-
 qt/time/Makefile.am                                |   20 +-
 srfi/Makefile.am                                   |   16 +-
 srfi/srfi-1.c                                      |   13 +-
 srfi/srfi-1.h                                      |   13 +-
 srfi/srfi-13.c                                     |   13 +-
 srfi/srfi-13.h                                     |   13 +-
 srfi/srfi-14.c                                     |   13 +-
 srfi/srfi-14.h                                     |   13 +-
 srfi/srfi-4.c                                      |   13 +-
 srfi/srfi-4.h                                      |   13 +-
 srfi/srfi-60.c                                     |   13 +-
 srfi/srfi-60.h                                     |   13 +-
 test-suite/Makefile.am                             |   24 +-
 test-suite/guile-test                              |   18 +-
 test-suite/lib.scm                                 |   23 +-
 test-suite/standalone/Makefile.am                  |   24 +-
 test-suite/standalone/test-asmobs-lib.c            |   13 +-
 test-suite/standalone/test-conversion.c            |   13 +-
 test-suite/standalone/test-extensions-lib.c        |   13 +-
 test-suite/standalone/test-fast-slot-ref.in        |   21 +-
 test-suite/standalone/test-list.c                  |   13 +-
 test-suite/standalone/test-num2integral.c          |   13 +-
 test-suite/standalone/test-round.c                 |   13 +-
 test-suite/standalone/test-scm-c-read.c            |   13 +-
 .../standalone/test-scm-take-locale-symbol.c       |   13 +-
 test-suite/standalone/test-scm-with-guile.c        |   13 +-
 test-suite/standalone/test-unwind.c                |   13 +-
 test-suite/standalone/test-use-srfi.in             |   21 +-
 test-suite/standalone/test-with-guile-module.c     |   13 +-
 test-suite/tests/alist.test                        |    2 +-
 test-suite/tests/and-let-star.test                 |   25 +-
 test-suite/tests/arbiters.test                     |    2 +-
 test-suite/tests/asm-to-bytecode.test              |    2 +-
 test-suite/tests/bit-operations.test               |    2 +-
 test-suite/tests/bytevectors.test                  |  138 +-
 test-suite/tests/c-api.test                        |   21 +-
 test-suite/tests/chars.test                        |   22 +-
 test-suite/tests/common-list.test                  |    2 +-
 test-suite/tests/compiler.test                     |    2 +-
 test-suite/tests/continuations.test                |   21 +-
 test-suite/tests/dynamic-scope.test                |   21 +-
 test-suite/tests/elisp.test                        |    2 +-
 test-suite/tests/environments.test                 |    2 +-
 test-suite/tests/eval.test                         |    2 +-
 test-suite/tests/exceptions.test                   |    2 +-
 test-suite/tests/filesys.test                      |    2 +-
 test-suite/tests/format.test                       |   21 +-
 test-suite/tests/fractions.test                    |   23 +-
 test-suite/tests/ftw.test                          |    2 +-
 test-suite/tests/gc.test                           |    2 +-
 test-suite/tests/getopt-long.test                  |   25 +-
 test-suite/tests/goops.test                        |   21 +-
 test-suite/tests/guardians.test                    |   21 +-
 test-suite/tests/hash.test                         |    2 +-
 test-suite/tests/hooks.test                        |    2 +-
 test-suite/tests/i18n.test                         |    6 +-
 test-suite/tests/import.test                       |    2 +-
 test-suite/tests/interp.test                       |   21 +-
 test-suite/tests/list.test                         |    2 +-
 test-suite/tests/load.test                         |   21 +-
 test-suite/tests/modules.test                      |    6 +-
 test-suite/tests/multilingual.nottest              |   21 +-
 test-suite/tests/numbers.test                      |    2 +-
 test-suite/tests/optargs.test                      |   21 +-
 test-suite/tests/options.test                      |   21 +-
 test-suite/tests/pairs.test                        |   21 +-
 test-suite/tests/poe.test                          |    2 +-
 test-suite/tests/popen.test                        |    2 +-
 test-suite/tests/ports.test                        |   21 +-
 test-suite/tests/posix.test                        |   25 +-
 test-suite/tests/procprop.test                     |   25 +-
 test-suite/tests/q.test                            |    2 +-
 test-suite/tests/r4rs.test                         |    2 +-
 test-suite/tests/r5rs_pitfall.test                 |    2 +-
 test-suite/tests/r6rs-ports.test                   |    7 +-
 test-suite/tests/ramap.test                        |    2 +-
 test-suite/tests/reader.test                       |    6 +-
 test-suite/tests/receive.test                      |   25 +-
 test-suite/tests/regexp.test                       |   21 +-
 test-suite/tests/socket.test                       |    2 +-
 test-suite/tests/sort.test                         |   21 +-
 test-suite/tests/srcprop.test                      |    2 +-
 test-suite/tests/srfi-1.test                       |   25 +-
 test-suite/tests/srfi-10.test                      |   21 +-
 test-suite/tests/srfi-11.test                      |   25 +-
 test-suite/tests/srfi-13.test                      |   25 +-
 test-suite/tests/srfi-14.test                      |   21 +-
 test-suite/tests/srfi-17.test                      |   21 +-
 test-suite/tests/srfi-18.test                      |   21 +-
 test-suite/tests/srfi-19.test                      |   25 +-
 test-suite/tests/srfi-31.test                      |    2 +-
 test-suite/tests/srfi-34.test                      |   25 +-
 test-suite/tests/srfi-35.test                      |   25 +-
 test-suite/tests/srfi-37.test                      |   25 +-
 test-suite/tests/srfi-39.test                      |   21 +-
 test-suite/tests/srfi-4.test                       |   21 +-
 test-suite/tests/srfi-6.test                       |   25 +-
 test-suite/tests/srfi-60.test                      |   25 +-
 test-suite/tests/srfi-69.test                      |   25 +-
 test-suite/tests/srfi-88.test                      |   25 +-
 test-suite/tests/srfi-9.test                       |   21 +-
 test-suite/tests/srfi-98.test                      |   25 +-
 test-suite/tests/streams.test                      |   21 +-
 test-suite/tests/strings.test                      |   21 +-
 test-suite/tests/structs.test                      |   25 +-
 test-suite/tests/symbols.test                      |   21 +-
 test-suite/tests/syncase.test                      |   21 +-
 test-suite/tests/syntax.test                       |   21 +-
 test-suite/tests/threads.test                      |   25 +-
 test-suite/tests/time.test                         |   21 +-
 test-suite/tests/tree-il.test                      |    6 +-
 test-suite/tests/unif.test                         |    2 +-
 test-suite/tests/vectors.test                      |   21 +-
 test-suite/tests/version.test                      |   21 +-
 test-suite/tests/weaks.test                        |    2 +-
 testsuite/run-vm-tests.scm                         |   12 +-
 620 files changed, 13156 insertions(+), 9862 deletions(-)
 create mode 100644 COPYING
 create mode 100755 build-aux/gitlog-to-changelog
 delete mode 100644 doc/guile-vm.texi
 create mode 100644 lib/canonicalize-lgpl.c
 create mode 100644 lib/canonicalize.h
 create mode 100644 lib/malloca.c
 create mode 100644 lib/malloca.h
 create mode 100644 lib/malloca.valgrind
 create mode 100644 lib/pathmax.h
 create mode 100644 lib/readlink.c
 create mode 100644 m4/canonicalize-lgpl.m4
 create mode 100644 m4/eealloc.m4
 create mode 100644 m4/malloca.m4
 create mode 100644 m4/pathmax.m4
 create mode 100644 m4/readlink.m4
 create mode 100644 module/language/brainfuck/compile-scheme.scm
 create mode 100644 module/language/brainfuck/compile-tree-il.scm
 create mode 100644 module/language/brainfuck/parse.scm
 create mode 100644 module/language/brainfuck/spec.scm

diff --git a/.gitignore b/.gitignore
index 0b2ff7c..29f29be 100644
--- a/.gitignore
+++ b/.gitignore
@@ -75,3 +75,36 @@ cscope.out
 cscope.files
 *.log
 INSTALL
+*.aux
+*.cp
+*.cps
+*.dvi
+*.fn
+*.fns
+*.ky
+*.pg
+*.toc
+*.tp
+*.vr
+*.tps
+*.vrs
+*.pgs
+*.rn
+*.rns
+/meta/gdb-uninstalled-guile
+/meta/guile
+/meta/uninstalled-env
+/examples/box-module/box
+/examples/box/box
+/lib/alloca.h
+/lib/charset.alias
+/lib/configmake.h
+/lib/ref-add.sed
+/lib/ref-del.sed
+/lib/stdlib.h
+/lib/string.h
+/lib/strings.h
+/lib/sys/file.h
+/lib/time.h
+/lib/unistd.h
+/lib/unistr/.dirstamp
diff --git a/COPYING b/COPYING
new file mode 100644
index 0000000..94a9ed0
--- /dev/null
+++ b/COPYING
@@ -0,0 +1,674 @@
+                    GNU GENERAL PUBLIC LICENSE
+                       Version 3, 29 June 2007
+
+ Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+                            Preamble
+
+  The GNU General Public License is a free, copyleft license for
+software and other kinds of works.
+
+  The licenses for most software and other practical works are designed
+to take away your freedom to share and change the works.  By contrast,
+the GNU General Public License is intended to guarantee your freedom to
+share and change all versions of a program--to make sure it remains free
+software for all its users.  We, the Free Software Foundation, use the
+GNU General Public License for most of our software; it applies also to
+any other work released this way by its authors.  You can apply it to
+your programs, too.
+
+  When we speak of free software, we are referring to freedom, not
+price.  Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+them if you wish), that you receive source code or can get it if you
+want it, that you can change the software or use pieces of it in new
+free programs, and that you know you can do these things.
+
+  To protect your rights, we need to prevent others from denying you
+these rights or asking you to surrender the rights.  Therefore, you have
+certain responsibilities if you distribute copies of the software, or if
+you modify it: responsibilities to respect the freedom of others.
+
+  For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must pass on to the recipients the same
+freedoms that you received.  You must make sure that they, too, receive
+or can get the source code.  And you must show them these terms so they
+know their rights.
+
+  Developers that use the GNU GPL protect your rights with two steps:
+(1) assert copyright on the software, and (2) offer you this License
+giving you legal permission to copy, distribute and/or modify it.
+
+  For the developers' and authors' protection, the GPL clearly explains
+that there is no warranty for this free software.  For both users' and
+authors' sake, the GPL requires that modified versions be marked as
+changed, so that their problems will not be attributed erroneously to
+authors of previous versions.
+
+  Some devices are designed to deny users access to install or run
+modified versions of the software inside them, although the manufacturer
+can do so.  This is fundamentally incompatible with the aim of
+protecting users' freedom to change the software.  The systematic
+pattern of such abuse occurs in the area of products for individuals to
+use, which is precisely where it is most unacceptable.  Therefore, we
+have designed this version of the GPL to prohibit the practice for those
+products.  If such problems arise substantially in other domains, we
+stand ready to extend this provision to those domains in future versions
+of the GPL, as needed to protect the freedom of users.
+
+  Finally, every program is threatened constantly by software patents.
+States should not allow patents to restrict development and use of
+software on general-purpose computers, but in those that do, we wish to
+avoid the special danger that patents applied to a free program could
+make it effectively proprietary.  To prevent this, the GPL assures that
+patents cannot be used to render the program non-free.
+
+  The precise terms and conditions for copying, distribution and
+modification follow.
+
+                       TERMS AND CONDITIONS
+
+  0. Definitions.
+
+  "This License" refers to version 3 of the GNU General Public License.
+
+  "Copyright" also means copyright-like laws that apply to other kinds of
+works, such as semiconductor masks.
+
+  "The Program" refers to any copyrightable work licensed under this
+License.  Each licensee is addressed as "you".  "Licensees" and
+"recipients" may be individuals or organizations.
+
+  To "modify" a work means to copy from or adapt all or part of the work
+in a fashion requiring copyright permission, other than the making of an
+exact copy.  The resulting work is called a "modified version" of the
+earlier work or a work "based on" the earlier work.
+
+  A "covered work" means either the unmodified Program or a work based
+on the Program.
+
+  To "propagate" a work means to do anything with it that, without
+permission, would make you directly or secondarily liable for
+infringement under applicable copyright law, except executing it on a
+computer or modifying a private copy.  Propagation includes copying,
+distribution (with or without modification), making available to the
+public, and in some countries other activities as well.
+
+  To "convey" a work means any kind of propagation that enables other
+parties to make or receive copies.  Mere interaction with a user through
+a computer network, with no transfer of a copy, is not conveying.
+
+  An interactive user interface displays "Appropriate Legal Notices"
+to the extent that it includes a convenient and prominently visible
+feature that (1) displays an appropriate copyright notice, and (2)
+tells the user that there is no warranty for the work (except to the
+extent that warranties are provided), that licensees may convey the
+work under this License, and how to view a copy of this License.  If
+the interface presents a list of user commands or options, such as a
+menu, a prominent item in the list meets this criterion.
+
+  1. Source Code.
+
+  The "source code" for a work means the preferred form of the work
+for making modifications to it.  "Object code" means any non-source
+form of a work.
+
+  A "Standard Interface" means an interface that either is an official
+standard defined by a recognized standards body, or, in the case of
+interfaces specified for a particular programming language, one that
+is widely used among developers working in that language.
+
+  The "System Libraries" of an executable work include anything, other
+than the work as a whole, that (a) is included in the normal form of
+packaging a Major Component, but which is not part of that Major
+Component, and (b) serves only to enable use of the work with that
+Major Component, or to implement a Standard Interface for which an
+implementation is available to the public in source code form.  A
+"Major Component", in this context, means a major essential component
+(kernel, window system, and so on) of the specific operating system
+(if any) on which the executable work runs, or a compiler used to
+produce the work, or an object code interpreter used to run it.
+
+  The "Corresponding Source" for a work in object code form means all
+the source code needed to generate, install, and (for an executable
+work) run the object code and to modify the work, including scripts to
+control those activities.  However, it does not include the work's
+System Libraries, or general-purpose tools or generally available free
+programs which are used unmodified in performing those activities but
+which are not part of the work.  For example, Corresponding Source
+includes interface definition files associated with source files for
+the work, and the source code for shared libraries and dynamically
+linked subprograms that the work is specifically designed to require,
+such as by intimate data communication or control flow between those
+subprograms and other parts of the work.
+
+  The Corresponding Source need not include anything that users
+can regenerate automatically from other parts of the Corresponding
+Source.
+
+  The Corresponding Source for a work in source code form is that
+same work.
+
+  2. Basic Permissions.
+
+  All rights granted under this License are granted for the term of
+copyright on the Program, and are irrevocable provided the stated
+conditions are met.  This License explicitly affirms your unlimited
+permission to run the unmodified Program.  The output from running a
+covered work is covered by this License only if the output, given its
+content, constitutes a covered work.  This License acknowledges your
+rights of fair use or other equivalent, as provided by copyright law.
+
+  You may make, run and propagate covered works that you do not
+convey, without conditions so long as your license otherwise remains
+in force.  You may convey covered works to others for the sole purpose
+of having them make modifications exclusively for you, or provide you
+with facilities for running those works, provided that you comply with
+the terms of this License in conveying all material for which you do
+not control copyright.  Those thus making or running the covered works
+for you must do so exclusively on your behalf, under your direction
+and control, on terms that prohibit them from making any copies of
+your copyrighted material outside their relationship with you.
+
+  Conveying under any other circumstances is permitted solely under
+the conditions stated below.  Sublicensing is not allowed; section 10
+makes it unnecessary.
+
+  3. Protecting Users' Legal Rights From Anti-Circumvention Law.
+
+  No covered work shall be deemed part of an effective technological
+measure under any applicable law fulfilling obligations under article
+11 of the WIPO copyright treaty adopted on 20 December 1996, or
+similar laws prohibiting or restricting circumvention of such
+measures.
+
+  When you convey a covered work, you waive any legal power to forbid
+circumvention of technological measures to the extent such circumvention
+is effected by exercising rights under this License with respect to
+the covered work, and you disclaim any intention to limit operation or
+modification of the work as a means of enforcing, against the work's
+users, your or third parties' legal rights to forbid circumvention of
+technological measures.
+
+  4. Conveying Verbatim Copies.
+
+  You may convey verbatim copies of the Program's source code as you
+receive it, in any medium, provided that you conspicuously and
+appropriately publish on each copy an appropriate copyright notice;
+keep intact all notices stating that this License and any
+non-permissive terms added in accord with section 7 apply to the code;
+keep intact all notices of the absence of any warranty; and give all
+recipients a copy of this License along with the Program.
+
+  You may charge any price or no price for each copy that you convey,
+and you may offer support or warranty protection for a fee.
+
+  5. Conveying Modified Source Versions.
+
+  You may convey a work based on the Program, or the modifications to
+produce it from the Program, in the form of source code under the
+terms of section 4, provided that you also meet all of these conditions:
+
+    a) The work must carry prominent notices stating that you modified
+    it, and giving a relevant date.
+
+    b) The work must carry prominent notices stating that it is
+    released under this License and any conditions added under section
+    7.  This requirement modifies the requirement in section 4 to
+    "keep intact all notices".
+
+    c) You must license the entire work, as a whole, under this
+    License to anyone who comes into possession of a copy.  This
+    License will therefore apply, along with any applicable section 7
+    additional terms, to the whole of the work, and all its parts,
+    regardless of how they are packaged.  This License gives no
+    permission to license the work in any other way, but it does not
+    invalidate such permission if you have separately received it.
+
+    d) If the work has interactive user interfaces, each must display
+    Appropriate Legal Notices; however, if the Program has interactive
+    interfaces that do not display Appropriate Legal Notices, your
+    work need not make them do so.
+
+  A compilation of a covered work with other separate and independent
+works, which are not by their nature extensions of the covered work,
+and which are not combined with it such as to form a larger program,
+in or on a volume of a storage or distribution medium, is called an
+"aggregate" if the compilation and its resulting copyright are not
+used to limit the access or legal rights of the compilation's users
+beyond what the individual works permit.  Inclusion of a covered work
+in an aggregate does not cause this License to apply to the other
+parts of the aggregate.
+
+  6. Conveying Non-Source Forms.
+
+  You may convey a covered work in object code form under the terms
+of sections 4 and 5, provided that you also convey the
+machine-readable Corresponding Source under the terms of this License,
+in one of these ways:
+
+    a) Convey the object code in, or embodied in, a physical product
+    (including a physical distribution medium), accompanied by the
+    Corresponding Source fixed on a durable physical medium
+    customarily used for software interchange.
+
+    b) Convey the object code in, or embodied in, a physical product
+    (including a physical distribution medium), accompanied by a
+    written offer, valid for at least three years and valid for as
+    long as you offer spare parts or customer support for that product
+    model, to give anyone who possesses the object code either (1) a
+    copy of the Corresponding Source for all the software in the
+    product that is covered by this License, on a durable physical
+    medium customarily used for software interchange, for a price no
+    more than your reasonable cost of physically performing this
+    conveying of source, or (2) access to copy the
+    Corresponding Source from a network server at no charge.
+
+    c) Convey individual copies of the object code with a copy of the
+    written offer to provide the Corresponding Source.  This
+    alternative is allowed only occasionally and noncommercially, and
+    only if you received the object code with such an offer, in accord
+    with subsection 6b.
+
+    d) Convey the object code by offering access from a designated
+    place (gratis or for a charge), and offer equivalent access to the
+    Corresponding Source in the same way through the same place at no
+    further charge.  You need not require recipients to copy the
+    Corresponding Source along with the object code.  If the place to
+    copy the object code is a network server, the Corresponding Source
+    may be on a different server (operated by you or a third party)
+    that supports equivalent copying facilities, provided you maintain
+    clear directions next to the object code saying where to find the
+    Corresponding Source.  Regardless of what server hosts the
+    Corresponding Source, you remain obligated to ensure that it is
+    available for as long as needed to satisfy these requirements.
+
+    e) Convey the object code using peer-to-peer transmission, provided
+    you inform other peers where the object code and Corresponding
+    Source of the work are being offered to the general public at no
+    charge under subsection 6d.
+
+  A separable portion of the object code, whose source code is excluded
+from the Corresponding Source as a System Library, need not be
+included in conveying the object code work.
+
+  A "User Product" is either (1) a "consumer product", which means any
+tangible personal property which is normally used for personal, family,
+or household purposes, or (2) anything designed or sold for incorporation
+into a dwelling.  In determining whether a product is a consumer product,
+doubtful cases shall be resolved in favor of coverage.  For a particular
+product received by a particular user, "normally used" refers to a
+typical or common use of that class of product, regardless of the status
+of the particular user or of the way in which the particular user
+actually uses, or expects or is expected to use, the product.  A product
+is a consumer product regardless of whether the product has substantial
+commercial, industrial or non-consumer uses, unless such uses represent
+the only significant mode of use of the product.
+
+  "Installation Information" for a User Product means any methods,
+procedures, authorization keys, or other information required to install
+and execute modified versions of a covered work in that User Product from
+a modified version of its Corresponding Source.  The information must
+suffice to ensure that the continued functioning of the modified object
+code is in no case prevented or interfered with solely because
+modification has been made.
+
+  If you convey an object code work under this section in, or with, or
+specifically for use in, a User Product, and the conveying occurs as
+part of a transaction in which the right of possession and use of the
+User Product is transferred to the recipient in perpetuity or for a
+fixed term (regardless of how the transaction is characterized), the
+Corresponding Source conveyed under this section must be accompanied
+by the Installation Information.  But this requirement does not apply
+if neither you nor any third party retains the ability to install
+modified object code on the User Product (for example, the work has
+been installed in ROM).
+
+  The requirement to provide Installation Information does not include a
+requirement to continue to provide support service, warranty, or updates
+for a work that has been modified or installed by the recipient, or for
+the User Product in which it has been modified or installed.  Access to a
+network may be denied when the modification itself materially and
+adversely affects the operation of the network or violates the rules and
+protocols for communication across the network.
+
+  Corresponding Source conveyed, and Installation Information provided,
+in accord with this section must be in a format that is publicly
+documented (and with an implementation available to the public in
+source code form), and must require no special password or key for
+unpacking, reading or copying.
+
+  7. Additional Terms.
+
+  "Additional permissions" are terms that supplement the terms of this
+License by making exceptions from one or more of its conditions.
+Additional permissions that are applicable to the entire Program shall
+be treated as though they were included in this License, to the extent
+that they are valid under applicable law.  If additional permissions
+apply only to part of the Program, that part may be used separately
+under those permissions, but the entire Program remains governed by
+this License without regard to the additional permissions.
+
+  When you convey a copy of a covered work, you may at your option
+remove any additional permissions from that copy, or from any part of
+it.  (Additional permissions may be written to require their own
+removal in certain cases when you modify the work.)  You may place
+additional permissions on material, added by you to a covered work,
+for which you have or can give appropriate copyright permission.
+
+  Notwithstanding any other provision of this License, for material you
+add to a covered work, you may (if authorized by the copyright holders of
+that material) supplement the terms of this License with terms:
+
+    a) Disclaiming warranty or limiting liability differently from the
+    terms of sections 15 and 16 of this License; or
+
+    b) Requiring preservation of specified reasonable legal notices or
+    author attributions in that material or in the Appropriate Legal
+    Notices displayed by works containing it; or
+
+    c) Prohibiting misrepresentation of the origin of that material, or
+    requiring that modified versions of such material be marked in
+    reasonable ways as different from the original version; or
+
+    d) Limiting the use for publicity purposes of names of licensors or
+    authors of the material; or
+
+    e) Declining to grant rights under trademark law for use of some
+    trade names, trademarks, or service marks; or
+
+    f) Requiring indemnification of licensors and authors of that
+    material by anyone who conveys the material (or modified versions of
+    it) with contractual assumptions of liability to the recipient, for
+    any liability that these contractual assumptions directly impose on
+    those licensors and authors.
+
+  All other non-permissive additional terms are considered "further
+restrictions" within the meaning of section 10.  If the Program as you
+received it, or any part of it, contains a notice stating that it is
+governed by this License along with a term that is a further
+restriction, you may remove that term.  If a license document contains
+a further restriction but permits relicensing or conveying under this
+License, you may add to a covered work material governed by the terms
+of that license document, provided that the further restriction does
+not survive such relicensing or conveying.
+
+  If you add terms to a covered work in accord with this section, you
+must place, in the relevant source files, a statement of the
+additional terms that apply to those files, or a notice indicating
+where to find the applicable terms.
+
+  Additional terms, permissive or non-permissive, may be stated in the
+form of a separately written license, or stated as exceptions;
+the above requirements apply either way.
+
+  8. Termination.
+
+  You may not propagate or modify a covered work except as expressly
+provided under this License.  Any attempt otherwise to propagate or
+modify it is void, and will automatically terminate your rights under
+this License (including any patent licenses granted under the third
+paragraph of section 11).
+
+  However, if you cease all violation of this License, then your
+license from a particular copyright holder is reinstated (a)
+provisionally, unless and until the copyright holder explicitly and
+finally terminates your license, and (b) permanently, if the copyright
+holder fails to notify you of the violation by some reasonable means
+prior to 60 days after the cessation.
+
+  Moreover, your license from a particular copyright holder is
+reinstated permanently if the copyright holder notifies you of the
+violation by some reasonable means, this is the first time you have
+received notice of violation of this License (for any work) from that
+copyright holder, and you cure the violation prior to 30 days after
+your receipt of the notice.
+
+  Termination of your rights under this section does not terminate the
+licenses of parties who have received copies or rights from you under
+this License.  If your rights have been terminated and not permanently
+reinstated, you do not qualify to receive new licenses for the same
+material under section 10.
+
+  9. Acceptance Not Required for Having Copies.
+
+  You are not required to accept this License in order to receive or
+run a copy of the Program.  Ancillary propagation of a covered work
+occurring solely as a consequence of using peer-to-peer transmission
+to receive a copy likewise does not require acceptance.  However,
+nothing other than this License grants you permission to propagate or
+modify any covered work.  These actions infringe copyright if you do
+not accept this License.  Therefore, by modifying or propagating a
+covered work, you indicate your acceptance of this License to do so.
+
+  10. Automatic Licensing of Downstream Recipients.
+
+  Each time you convey a covered work, the recipient automatically
+receives a license from the original licensors, to run, modify and
+propagate that work, subject to this License.  You are not responsible
+for enforcing compliance by third parties with this License.
+
+  An "entity transaction" is a transaction transferring control of an
+organization, or substantially all assets of one, or subdividing an
+organization, or merging organizations.  If propagation of a covered
+work results from an entity transaction, each party to that
+transaction who receives a copy of the work also receives whatever
+licenses to the work the party's predecessor in interest had or could
+give under the previous paragraph, plus a right to possession of the
+Corresponding Source of the work from the predecessor in interest, if
+the predecessor has it or can get it with reasonable efforts.
+
+  You may not impose any further restrictions on the exercise of the
+rights granted or affirmed under this License.  For example, you may
+not impose a license fee, royalty, or other charge for exercise of
+rights granted under this License, and you may not initiate litigation
+(including a cross-claim or counterclaim in a lawsuit) alleging that
+any patent claim is infringed by making, using, selling, offering for
+sale, or importing the Program or any portion of it.
+
+  11. Patents.
+
+  A "contributor" is a copyright holder who authorizes use under this
+License of the Program or a work on which the Program is based.  The
+work thus licensed is called the contributor's "contributor version".
+
+  A contributor's "essential patent claims" are all patent claims
+owned or controlled by the contributor, whether already acquired or
+hereafter acquired, that would be infringed by some manner, permitted
+by this License, of making, using, or selling its contributor version,
+but do not include claims that would be infringed only as a
+consequence of further modification of the contributor version.  For
+purposes of this definition, "control" includes the right to grant
+patent sublicenses in a manner consistent with the requirements of
+this License.
+
+  Each contributor grants you a non-exclusive, worldwide, royalty-free
+patent license under the contributor's essential patent claims, to
+make, use, sell, offer for sale, import and otherwise run, modify and
+propagate the contents of its contributor version.
+
+  In the following three paragraphs, a "patent license" is any express
+agreement or commitment, however denominated, not to enforce a patent
+(such as an express permission to practice a patent or covenant not to
+sue for patent infringement).  To "grant" such a patent license to a
+party means to make such an agreement or commitment not to enforce a
+patent against the party.
+
+  If you convey a covered work, knowingly relying on a patent license,
+and the Corresponding Source of the work is not available for anyone
+to copy, free of charge and under the terms of this License, through a
+publicly available network server or other readily accessible means,
+then you must either (1) cause the Corresponding Source to be so
+available, or (2) arrange to deprive yourself of the benefit of the
+patent license for this particular work, or (3) arrange, in a manner
+consistent with the requirements of this License, to extend the patent
+license to downstream recipients.  "Knowingly relying" means you have
+actual knowledge that, but for the patent license, your conveying the
+covered work in a country, or your recipient's use of the covered work
+in a country, would infringe one or more identifiable patents in that
+country that you have reason to believe are valid.
+
+  If, pursuant to or in connection with a single transaction or
+arrangement, you convey, or propagate by procuring conveyance of, a
+covered work, and grant a patent license to some of the parties
+receiving the covered work authorizing them to use, propagate, modify
+or convey a specific copy of the covered work, then the patent license
+you grant is automatically extended to all recipients of the covered
+work and works based on it.
+
+  A patent license is "discriminatory" if it does not include within
+the scope of its coverage, prohibits the exercise of, or is
+conditioned on the non-exercise of one or more of the rights that are
+specifically granted under this License.  You may not convey a covered
+work if you are a party to an arrangement with a third party that is
+in the business of distributing software, under which you make payment
+to the third party based on the extent of your activity of conveying
+the work, and under which the third party grants, to any of the
+parties who would receive the covered work from you, a discriminatory
+patent license (a) in connection with copies of the covered work
+conveyed by you (or copies made from those copies), or (b) primarily
+for and in connection with specific products or compilations that
+contain the covered work, unless you entered into that arrangement,
+or that patent license was granted, prior to 28 March 2007.
+
+  Nothing in this License shall be construed as excluding or limiting
+any implied license or other defenses to infringement that may
+otherwise be available to you under applicable patent law.
+
+  12. No Surrender of Others' Freedom.
+
+  If conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License.  If you cannot convey a
+covered work so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you may
+not convey it at all.  For example, if you agree to terms that obligate you
+to collect a royalty for further conveying from those to whom you convey
+the Program, the only way you could satisfy both those terms and this
+License would be to refrain entirely from conveying the Program.
+
+  13. Use with the GNU Affero General Public License.
+
+  Notwithstanding any other provision of this License, you have
+permission to link or combine any covered work with a work licensed
+under version 3 of the GNU Affero General Public License into a single
+combined work, and to convey the resulting work.  The terms of this
+License will continue to apply to the part which is the covered work,
+but the special requirements of the GNU Affero General Public License,
+section 13, concerning interaction through a network will apply to the
+combination as such.
+
+  14. Revised Versions of this License.
+
+  The Free Software Foundation may publish revised and/or new versions of
+the GNU General Public License from time to time.  Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+  Each version is given a distinguishing version number.  If the
+Program specifies that a certain numbered version of the GNU General
+Public License "or any later version" applies to it, you have the
+option of following the terms and conditions either of that numbered
+version or of any later version published by the Free Software
+Foundation.  If the Program does not specify a version number of the
+GNU General Public License, you may choose any version ever published
+by the Free Software Foundation.
+
+  If the Program specifies that a proxy can decide which future
+versions of the GNU General Public License can be used, that proxy's
+public statement of acceptance of a version permanently authorizes you
+to choose that version for the Program.
+
+  Later license versions may give you additional or different
+permissions.  However, no additional obligations are imposed on any
+author or copyright holder as a result of your choosing to follow a
+later version.
+
+  15. Disclaimer of Warranty.
+
+  THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
+APPLICABLE LAW.  EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
+HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
+OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
+THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE.  THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
+IS WITH YOU.  SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
+ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
+
+  16. Limitation of Liability.
+
+  IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
+THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
+GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
+USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
+DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
+PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
+EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
+SUCH DAMAGES.
+
+  17. Interpretation of Sections 15 and 16.
+
+  If the disclaimer of warranty and limitation of liability provided
+above cannot be given local legal effect according to their terms,
+reviewing courts shall apply local law that most closely approximates
+an absolute waiver of all civil liability in connection with the
+Program, unless a warranty or assumption of liability accompanies a
+copy of the Program in return for a fee.
+
+                     END OF TERMS AND CONDITIONS
+
+            How to Apply These Terms to Your New Programs
+
+  If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+  To do so, attach the following notices to the program.  It is safest
+to attach them to the start of each source file to most effectively
+state the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+    <one line to give the program's name and a brief idea of what it does.>
+    Copyright (C) <year>  <name of author>
+
+    This program is free software: you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation, either version 3 of the License, 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 General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+Also add information on how to contact you by electronic and paper mail.
+
+  If the program does terminal interaction, make it output a short
+notice like this when it starts in an interactive mode:
+
+    <program>  Copyright (C) <year>  <name of author>
+    This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+    This is free software, and you are welcome to redistribute it
+    under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License.  Of course, your program's commands
+might be different; for a GUI interface, you would use an "about box".
+
+  You should also get your employer (if you work as a programmer) or school,
+if any, to sign a "copyright disclaimer" for the program, if necessary.
+For more information on this, and how to apply and follow the GNU GPL, see
+<http://www.gnu.org/licenses/>.
+
+  The GNU General Public License does not permit incorporating your program
+into proprietary programs.  If your program is a subroutine library, you
+may consider it more useful to permit linking proprietary applications with
+the library.  If this is what you want to do, use the GNU Lesser General
+Public License instead of this License.  But first, please read
+<http://www.gnu.org/philosophy/why-not-lgpl.html>.
diff --git a/COPYING.LESSER b/COPYING.LESSER
index 8add30a..cca7fc2 100644
--- a/COPYING.LESSER
+++ b/COPYING.LESSER
@@ -1,504 +1,165 @@
-                 GNU LESSER GENERAL PUBLIC LICENSE
-                      Version 2.1, February 1999
+                  GNU LESSER GENERAL PUBLIC LICENSE
+                       Version 3, 29 June 2007
 
- Copyright (C) 1991, 1999 Free Software Foundation, Inc.
-     51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+ Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
  Everyone is permitted to copy and distribute verbatim copies
  of this license document, but changing it is not allowed.
 
-[This is the first released version of the Lesser GPL.  It also counts
- as the successor of the GNU Library Public License, version 2, hence
- the version number 2.1.]
-
-                           Preamble
-
-  The licenses for most software are designed to take away your
-freedom to share and change it.  By contrast, the GNU General Public
-Licenses are intended to guarantee your freedom to share and change
-free software--to make sure the software is free for all its users.
-
-  This license, the Lesser General Public License, applies to some
-specially designated software packages--typically libraries--of the
-Free Software Foundation and other authors who decide to use it.  You
-can use it too, but we suggest you first think carefully about whether
-this license or the ordinary General Public License is the better
-strategy to use in any particular case, based on the explanations below.
-
-  When we speak of free software, we are referring to freedom of use,
-not price.  Our General Public Licenses are designed to make sure that
-you have the freedom to distribute copies of free software (and charge
-for this service if you wish); that you receive source code or can get
-it if you want it; that you can change the software and use pieces of
-it in new free programs; and that you are informed that you can do
-these things.
-
-  To protect your rights, we need to make restrictions that forbid
-distributors to deny you these rights or to ask you to surrender these
-rights.  These restrictions translate to certain responsibilities for
-you if you distribute copies of the library or if you modify it.
-
-  For example, if you distribute copies of the library, whether gratis
-or for a fee, you must give the recipients all the rights that we gave
-you.  You must make sure that they, too, receive or can get the source
-code.  If you link other code with the library, you must provide
-complete object files to the recipients, so that they can relink them
-with the library after making changes to the library and recompiling
-it.  And you must show them these terms so they know their rights.
-
-  We protect your rights with a two-step method: (1) we copyright the
-library, and (2) we offer you this license, which gives you legal
-permission to copy, distribute and/or modify the library.
-
-  To protect each distributor, we want to make it very clear that
-there is no warranty for the free library.  Also, if the library is
-modified by someone else and passed on, the recipients should know
-that what they have is not the original version, so that the original
-author's reputation will not be affected by problems that might be
-introduced by others.
-
-  Finally, software patents pose a constant threat to the existence of
-any free program.  We wish to make sure that a company cannot
-effectively restrict the users of a free program by obtaining a
-restrictive license from a patent holder.  Therefore, we insist that
-any patent license obtained for a version of the library must be
-consistent with the full freedom of use specified in this license.
-
-  Most GNU software, including some libraries, is covered by the
-ordinary GNU General Public License.  This license, the GNU Lesser
-General Public License, applies to certain designated libraries, and
-is quite different from the ordinary General Public License.  We use
-this license for certain libraries in order to permit linking those
-libraries into non-free programs.
-
-  When a program is linked with a library, whether statically or using
-a shared library, the combination of the two is legally speaking a
-combined work, a derivative of the original library.  The ordinary
-General Public License therefore permits such linking only if the
-entire combination fits its criteria of freedom.  The Lesser General
-Public License permits more lax criteria for linking other code with
-the library.
-
-  We call this license the "Lesser" General Public License because it
-does Less to protect the user's freedom than the ordinary General
-Public License.  It also provides other free software developers Less
-of an advantage over competing non-free programs.  These disadvantages
-are the reason we use the ordinary General Public License for many
-libraries.  However, the Lesser license provides advantages in certain
-special circumstances.
-
-  For example, on rare occasions, there may be a special need to
-encourage the widest possible use of a certain library, so that it becomes
-a de-facto standard.  To achieve this, non-free programs must be
-allowed to use the library.  A more frequent case is that a free
-library does the same job as widely used non-free libraries.  In this
-case, there is little to gain by limiting the free library to free
-software only, so we use the Lesser General Public License.
-
-  In other cases, permission to use a particular library in non-free
-programs enables a greater number of people to use a large body of
-free software.  For example, permission to use the GNU C Library in
-non-free programs enables many more people to use the whole GNU
-operating system, as well as its variant, the GNU/Linux operating
-system.
-
-  Although the Lesser General Public License is Less protective of the
-users' freedom, it does ensure that the user of a program that is
-linked with the Library has the freedom and the wherewithal to run
-that program using a modified version of the Library.
-
-  The precise terms and conditions for copying, distribution and
-modification follow.  Pay close attention to the difference between a
-"work based on the library" and a "work that uses the library".  The
-former contains code derived from the library, whereas the latter must
-be combined with the library in order to run.
-
-                 GNU LESSER GENERAL PUBLIC LICENSE
-   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
-
-  0. This License Agreement applies to any software library or other
-program which contains a notice placed by the copyright holder or
-other authorized party saying it may be distributed under the terms of
-this Lesser General Public License (also called "this License").
-Each licensee is addressed as "you".
-
-  A "library" means a collection of software functions and/or data
-prepared so as to be conveniently linked with application programs
-(which use some of those functions and data) to form executables.
-
-  The "Library", below, refers to any such software library or work
-which has been distributed under these terms.  A "work based on the
-Library" means either the Library or any derivative work under
-copyright law: that is to say, a work containing the Library or a
-portion of it, either verbatim or with modifications and/or translated
-straightforwardly into another language.  (Hereinafter, translation is
-included without limitation in the term "modification".)
-
-  "Source code" for a work means the preferred form of the work for
-making modifications to it.  For a library, complete source code means
-all the source code for all modules it contains, plus any associated
-interface definition files, plus the scripts used to control compilation
-and installation of the library.
-
-  Activities other than copying, distribution and modification are not
-covered by this License; they are outside its scope.  The act of
-running a program using the Library is not restricted, and output from
-such a program is covered only if its contents constitute a work based
-on the Library (independent of the use of the Library in a tool for
-writing it).  Whether that is true depends on what the Library does
-and what the program that uses the Library does.
-  
-  1. You may copy and distribute verbatim copies of the Library's
-complete source code as you receive it, in any medium, provided that
-you conspicuously and appropriately publish on each copy an
-appropriate copyright notice and disclaimer of warranty; keep intact
-all the notices that refer to this License and to the absence of any
-warranty; and distribute a copy of this License along with the
-Library.
-
-  You may charge a fee for the physical act of transferring a copy,
-and you may at your option offer warranty protection in exchange for a
-fee.
-
-  2. You may modify your copy or copies of the Library or any portion
-of it, thus forming a work based on the Library, and copy and
-distribute such modifications or work under the terms of Section 1
-above, provided that you also meet all of these conditions:
-
-    a) The modified work must itself be a software library.
-
-    b) You must cause the files modified to carry prominent notices
-    stating that you changed the files and the date of any change.
-
-    c) You must cause the whole of the work to be licensed at no
-    charge to all third parties under the terms of this License.
-
-    d) If a facility in the modified Library refers to a function or a
-    table of data to be supplied by an application program that uses
-    the facility, other than as an argument passed when the facility
-    is invoked, then you must make a good faith effort to ensure that,
-    in the event an application does not supply such function or
-    table, the facility still operates, and performs whatever part of
-    its purpose remains meaningful.
-
-    (For example, a function in a library to compute square roots has
-    a purpose that is entirely well-defined independent of the
-    application.  Therefore, Subsection 2d requires that any
-    application-supplied function or table used by this function must
-    be optional: if the application does not supply it, the square
-    root function must still compute square roots.)
-
-These requirements apply to the modified work as a whole.  If
-identifiable sections of that work are not derived from the Library,
-and can be reasonably considered independent and separate works in
-themselves, then this License, and its terms, do not apply to those
-sections when you distribute them as separate works.  But when you
-distribute the same sections as part of a whole which is a work based
-on the Library, the distribution of the whole must be on the terms of
-this License, whose permissions for other licensees extend to the
-entire whole, and thus to each and every part regardless of who wrote
-it.
-
-Thus, it is not the intent of this section to claim rights or contest
-your rights to work written entirely by you; rather, the intent is to
-exercise the right to control the distribution of derivative or
-collective works based on the Library.
-
-In addition, mere aggregation of another work not based on the Library
-with the Library (or with a work based on the Library) on a volume of
-a storage or distribution medium does not bring the other work under
-the scope of this License.
-
-  3. You may opt to apply the terms of the ordinary GNU General Public
-License instead of this License to a given copy of the Library.  To do
-this, you must alter all the notices that refer to this License, so
-that they refer to the ordinary GNU General Public License, version 2,
-instead of to this License.  (If a newer version than version 2 of the
-ordinary GNU General Public License has appeared, then you can specify
-that version instead if you wish.)  Do not make any other change in
-these notices.
-
-  Once this change is made in a given copy, it is irreversible for
-that copy, so the ordinary GNU General Public License applies to all
-subsequent copies and derivative works made from that copy.
-
-  This option is useful when you wish to copy part of the code of
-the Library into a program that is not a library.
-
-  4. You may copy and distribute the Library (or a portion or
-derivative of it, under Section 2) in object code or executable form
-under the terms of Sections 1 and 2 above provided that you accompany
-it with the complete corresponding machine-readable source code, which
-must be distributed under the terms of Sections 1 and 2 above on a
-medium customarily used for software interchange.
-
-  If distribution of object code is made by offering access to copy
-from a designated place, then offering equivalent access to copy the
-source code from the same place satisfies the requirement to
-distribute the source code, even though third parties are not
-compelled to copy the source along with the object code.
-
-  5. A program that contains no derivative of any portion of the
-Library, but is designed to work with the Library by being compiled or
-linked with it, is called a "work that uses the Library".  Such a
-work, in isolation, is not a derivative work of the Library, and
-therefore falls outside the scope of this License.
-
-  However, linking a "work that uses the Library" with the Library
-creates an executable that is a derivative of the Library (because it
-contains portions of the Library), rather than a "work that uses the
-library".  The executable is therefore covered by this License.
-Section 6 states terms for distribution of such executables.
-
-  When a "work that uses the Library" uses material from a header file
-that is part of the Library, the object code for the work may be a
-derivative work of the Library even though the source code is not.
-Whether this is true is especially significant if the work can be
-linked without the Library, or if the work is itself a library.  The
-threshold for this to be true is not precisely defined by law.
-
-  If such an object file uses only numerical parameters, data
-structure layouts and accessors, and small macros and small inline
-functions (ten lines or less in length), then the use of the object
-file is unrestricted, regardless of whether it is legally a derivative
-work.  (Executables containing this object code plus portions of the
-Library will still fall under Section 6.)
-
-  Otherwise, if the work is a derivative of the Library, you may
-distribute the object code for the work under the terms of Section 6.
-Any executables containing that work also fall under Section 6,
-whether or not they are linked directly with the Library itself.
-
-  6. As an exception to the Sections above, you may also combine or
-link a "work that uses the Library" with the Library to produce a
-work containing portions of the Library, and distribute that work
-under terms of your choice, provided that the terms permit
-modification of the work for the customer's own use and reverse
-engineering for debugging such modifications.
-
-  You must give prominent notice with each copy of the work that the
-Library is used in it and that the Library and its use are covered by
-this License.  You must supply a copy of this License.  If the work
-during execution displays copyright notices, you must include the
-copyright notice for the Library among them, as well as a reference
-directing the user to the copy of this License.  Also, you must do one
-of these things:
-
-    a) Accompany the work with the complete corresponding
-    machine-readable source code for the Library including whatever
-    changes were used in the work (which must be distributed under
-    Sections 1 and 2 above); and, if the work is an executable linked
-    with the Library, with the complete machine-readable "work that
-    uses the Library", as object code and/or source code, so that the
-    user can modify the Library and then relink to produce a modified
-    executable containing the modified Library.  (It is understood
-    that the user who changes the contents of definitions files in the
-    Library will not necessarily be able to recompile the application
-    to use the modified definitions.)
-
-    b) Use a suitable shared library mechanism for linking with the
-    Library.  A suitable mechanism is one that (1) uses at run time a
-    copy of the library already present on the user's computer system,
-    rather than copying library functions into the executable, and (2)
-    will operate properly with a modified version of the library, if
-    the user installs one, as long as the modified version is
-    interface-compatible with the version that the work was made with.
-
-    c) Accompany the work with a written offer, valid for at
-    least three years, to give the same user the materials
-    specified in Subsection 6a, above, for a charge no more
-    than the cost of performing this distribution.
-
-    d) If distribution of the work is made by offering access to copy
-    from a designated place, offer equivalent access to copy the above
-    specified materials from the same place.
-
-    e) Verify that the user has already received a copy of these
-    materials or that you have already sent this user a copy.
-
-  For an executable, the required form of the "work that uses the
-Library" must include any data and utility programs needed for
-reproducing the executable from it.  However, as a special exception,
-the materials to be distributed need not include anything that is
-normally distributed (in either source or binary form) with the major
-components (compiler, kernel, and so on) of the operating system on
-which the executable runs, unless that component itself accompanies
-the executable.
-
-  It may happen that this requirement contradicts the license
-restrictions of other proprietary libraries that do not normally
-accompany the operating system.  Such a contradiction means you cannot
-use both them and the Library together in an executable that you
-distribute.
-
-  7. You may place library facilities that are a work based on the
-Library side-by-side in a single library together with other library
-facilities not covered by this License, and distribute such a combined
-library, provided that the separate distribution of the work based on
-the Library and of the other library facilities is otherwise
-permitted, and provided that you do these two things:
-
-    a) Accompany the combined library with a copy of the same work
-    based on the Library, uncombined with any other library
-    facilities.  This must be distributed under the terms of the
-    Sections above.
-
-    b) Give prominent notice with the combined library of the fact
-    that part of it is a work based on the Library, and explaining
-    where to find the accompanying uncombined form of the same work.
-
-  8. You may not copy, modify, sublicense, link with, or distribute
-the Library except as expressly provided under this License.  Any
-attempt otherwise to copy, modify, sublicense, link with, or
-distribute the Library is void, and will automatically terminate your
-rights under this License.  However, parties who have received copies,
-or rights, from you under this License will not have their licenses
-terminated so long as such parties remain in full compliance.
-
-  9. You are not required to accept this License, since you have not
-signed it.  However, nothing else grants you permission to modify or
-distribute the Library or its derivative works.  These actions are
-prohibited by law if you do not accept this License.  Therefore, by
-modifying or distributing the Library (or any work based on the
-Library), you indicate your acceptance of this License to do so, and
-all its terms and conditions for copying, distributing or modifying
-the Library or works based on it.
-
-  10. Each time you redistribute the Library (or any work based on the
-Library), the recipient automatically receives a license from the
-original licensor to copy, distribute, link with or modify the Library
-subject to these terms and conditions.  You may not impose any further
-restrictions on the recipients' exercise of the rights granted herein.
-You are not responsible for enforcing compliance by third parties with
-this License.
-
-  11. If, as a consequence of a court judgment or allegation of patent
-infringement or for any other reason (not limited to patent issues),
-conditions are imposed on you (whether by court order, agreement or
-otherwise) that contradict the conditions of this License, they do not
-excuse you from the conditions of this License.  If you cannot
-distribute so as to satisfy simultaneously your obligations under this
-License and any other pertinent obligations, then as a consequence you
-may not distribute the Library at all.  For example, if a patent
-license would not permit royalty-free redistribution of the Library by
-all those who receive copies directly or indirectly through you, then
-the only way you could satisfy both it and this License would be to
-refrain entirely from distribution of the Library.
-
-If any portion of this section is held invalid or unenforceable under any
-particular circumstance, the balance of the section is intended to apply,
-and the section as a whole is intended to apply in other circumstances.
-
-It is not the purpose of this section to induce you to infringe any
-patents or other property right claims or to contest validity of any
-such claims; this section has the sole purpose of protecting the
-integrity of the free software distribution system which is
-implemented by public license practices.  Many people have made
-generous contributions to the wide range of software distributed
-through that system in reliance on consistent application of that
-system; it is up to the author/donor to decide if he or she is willing
-to distribute software through any other system and a licensee cannot
-impose that choice.
-
-This section is intended to make thoroughly clear what is believed to
-be a consequence of the rest of this License.
-
-  12. If the distribution and/or use of the Library is restricted in
-certain countries either by patents or by copyrighted interfaces, the
-original copyright holder who places the Library under this License may add
-an explicit geographical distribution limitation excluding those countries,
-so that distribution is permitted only in or among countries not thus
-excluded.  In such case, this License incorporates the limitation as if
-written in the body of this License.
-
-  13. The Free Software Foundation may publish revised and/or new
-versions of the Lesser General Public License from time to time.
-Such new versions will be similar in spirit to the present version,
-but may differ in detail to address new problems or concerns.
-
-Each version is given a distinguishing version number.  If the Library
-specifies a version number of this License which applies to it and
-"any later version", you have the option of following the terms and
-conditions either of that version or of any later version published by
-the Free Software Foundation.  If the Library does not specify a
-license version number, you may choose any version ever published by
-the Free Software Foundation.
-
-  14. If you wish to incorporate parts of the Library into other free
-programs whose distribution conditions are incompatible with these,
-write to the author to ask for permission.  For software which is
-copyrighted by the Free Software Foundation, write to the Free
-Software Foundation; we sometimes make exceptions for this.  Our
-decision will be guided by the two goals of preserving the free status
-of all derivatives of our free software and of promoting the sharing
-and reuse of software generally.
-
-                           NO WARRANTY
-
-  15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
-WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
-EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
-OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
-KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-PURPOSE.  THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
-LIBRARY IS WITH YOU.  SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
-THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
-
-  16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
-WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
-AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
-FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
-CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
-LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
-RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
-FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
-SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
-DAMAGES.
-
-                    END OF TERMS AND CONDITIONS
-
-           How to Apply These Terms to Your New Libraries
-
-  If you develop a new library, and you want it to be of the greatest
-possible use to the public, we recommend making it free software that
-everyone can redistribute and change.  You can do so by permitting
-redistribution under these terms (or, alternatively, under the terms of the
-ordinary General Public License).
-
-  To apply these terms, attach the following notices to the library.  It is
-safest to attach them to the start of each source file to most effectively
-convey the exclusion of warranty; and each file should have at least the
-"copyright" line and a pointer to where the full notice is found.
-
-    <one line to give the library's name and a brief idea of what it does.>
-    Copyright (C) <year>  <name of author>
-
-    This library 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 2.1 of the License, or (at your option) any later version.
-
-    This library 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 library; if not, write to the Free Software
-    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
-
-Also add information on how to contact you by electronic and paper mail.
-
-You should also get your employer (if you work as a programmer) or your
-school, if any, to sign a "copyright disclaimer" for the library, if
-necessary.  Here is a sample; alter the names:
-
-  Yoyodyne, Inc., hereby disclaims all copyright interest in the
-  library `Frob' (a library for tweaking knobs) written by James Random Hacker.
-
-  <signature of Ty Coon>, 1 April 1990
-  Ty Coon, President of Vice
-
-That's all there is to it!
-
 
+  This version of the GNU Lesser General Public License incorporates
+the terms and conditions of version 3 of the GNU General Public
+License, supplemented by the additional permissions listed below.
+
+  0. Additional Definitions.
+
+  As used herein, "this License" refers to version 3 of the GNU Lesser
+General Public License, and the "GNU GPL" refers to version 3 of the GNU
+General Public License.
+
+  "The Library" refers to a covered work governed by this License,
+other than an Application or a Combined Work as defined below.
+
+  An "Application" is any work that makes use of an interface provided
+by the Library, but which is not otherwise based on the Library.
+Defining a subclass of a class defined by the Library is deemed a mode
+of using an interface provided by the Library.
+
+  A "Combined Work" is a work produced by combining or linking an
+Application with the Library.  The particular version of the Library
+with which the Combined Work was made is also called the "Linked
+Version".
+
+  The "Minimal Corresponding Source" for a Combined Work means the
+Corresponding Source for the Combined Work, excluding any source code
+for portions of the Combined Work that, considered in isolation, are
+based on the Application, and not on the Linked Version.
+
+  The "Corresponding Application Code" for a Combined Work means the
+object code and/or source code for the Application, including any data
+and utility programs needed for reproducing the Combined Work from the
+Application, but excluding the System Libraries of the Combined Work.
+
+  1. Exception to Section 3 of the GNU GPL.
+
+  You may convey a covered work under sections 3 and 4 of this License
+without being bound by section 3 of the GNU GPL.
+
+  2. Conveying Modified Versions.
+
+  If you modify a copy of the Library, and, in your modifications, a
+facility refers to a function or data to be supplied by an Application
+that uses the facility (other than as an argument passed when the
+facility is invoked), then you may convey a copy of the modified
+version:
+
+   a) under this License, provided that you make a good faith effort to
+   ensure that, in the event an Application does not supply the
+   function or data, the facility still operates, and performs
+   whatever part of its purpose remains meaningful, or
+
+   b) under the GNU GPL, with none of the additional permissions of
+   this License applicable to that copy.
+
+  3. Object Code Incorporating Material from Library Header Files.
+
+  The object code form of an Application may incorporate material from
+a header file that is part of the Library.  You may convey such object
+code under terms of your choice, provided that, if the incorporated
+material is not limited to numerical parameters, data structure
+layouts and accessors, or small macros, inline functions and templates
+(ten or fewer lines in length), you do both of the following:
+
+   a) Give prominent notice with each copy of the object code that the
+   Library is used in it and that the Library and its use are
+   covered by this License.
+
+   b) Accompany the object code with a copy of the GNU GPL and this license
+   document.
+
+  4. Combined Works.
+
+  You may convey a Combined Work under terms of your choice that,
+taken together, effectively do not restrict modification of the
+portions of the Library contained in the Combined Work and reverse
+engineering for debugging such modifications, if you also do each of
+the following:
+
+   a) Give prominent notice with each copy of the Combined Work that
+   the Library is used in it and that the Library and its use are
+   covered by this License.
+
+   b) Accompany the Combined Work with a copy of the GNU GPL and this license
+   document.
+
+   c) For a Combined Work that displays copyright notices during
+   execution, include the copyright notice for the Library among
+   these notices, as well as a reference directing the user to the
+   copies of the GNU GPL and this license document.
+
+   d) Do one of the following:
+
+       0) Convey the Minimal Corresponding Source under the terms of this
+       License, and the Corresponding Application Code in a form
+       suitable for, and under terms that permit, the user to
+       recombine or relink the Application with a modified version of
+       the Linked Version to produce a modified Combined Work, in the
+       manner specified by section 6 of the GNU GPL for conveying
+       Corresponding Source.
+
+       1) Use a suitable shared library mechanism for linking with the
+       Library.  A suitable mechanism is one that (a) uses at run time
+       a copy of the Library already present on the user's computer
+       system, and (b) will operate properly with a modified version
+       of the Library that is interface-compatible with the Linked
+       Version.
+
+   e) Provide Installation Information, but only if you would otherwise
+   be required to provide such information under section 6 of the
+   GNU GPL, and only to the extent that such information is
+   necessary to install and execute a modified version of the
+   Combined Work produced by recombining or relinking the
+   Application with a modified version of the Linked Version. (If
+   you use option 4d0, the Installation Information must accompany
+   the Minimal Corresponding Source and Corresponding Application
+   Code. If you use option 4d1, you must provide the Installation
+   Information in the manner specified by section 6 of the GNU GPL
+   for conveying Corresponding Source.)
+
+  5. Combined Libraries.
+
+  You may place library facilities that are a work based on the
+Library side by side in a single library together with other library
+facilities that are not Applications and are not covered by this
+License, and convey such a combined library under terms of your
+choice, if you do both of the following:
+
+   a) Accompany the combined library with a copy of the same work based
+   on the Library, uncombined with any other library facilities,
+   conveyed under the terms of this License.
+
+   b) Give prominent notice with the combined library that part of it
+   is a work based on the Library, and explaining where to find the
+   accompanying uncombined form of the same work.
+
+  6. Revised Versions of the GNU Lesser General Public License.
+
+  The Free Software Foundation may publish revised and/or new versions
+of the GNU Lesser General Public License from time to time. Such new
+versions will be similar in spirit to the present version, but may
+differ in detail to address new problems or concerns.
+
+  Each version is given a distinguishing version number. If the
+Library as you received it specifies that a certain numbered version
+of the GNU Lesser General Public License "or any later version"
+applies to it, you have the option of following the terms and
+conditions either of that published version or of any later version
+published by the Free Software Foundation. If the Library as you
+received it does not specify a version number of the GNU Lesser
+General Public License, you may choose any version of the GNU Lesser
+General Public License ever published by the Free Software Foundation.
+
+  If the Library as you received it specifies that a proxy can decide
+whether future versions of the GNU Lesser General Public License shall
+apply, that proxy's public statement of acceptance of any version is
+permanent authorization for you to choose that version for the
+Library.
diff --git a/LICENSE b/LICENSE
index 213e34a..3961579 100644
--- a/LICENSE
+++ b/LICENSE
@@ -1,2 +1,2 @@
 Guile is covered under the terms of the GNU Lesser General Public
-License, version 2.1.  See COPYING.LESSER.
+License, version 3 or later.  See COPYING.LESSER and COPYING.
diff --git a/Makefile.am b/Makefile.am
index a82143b..c0fd8c3 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,23 +1,23 @@
 ## Process this file with automake to produce Makefile.in.
 ##
-##     Copyright (C) 1998, 1999, 2000, 2001, 2002, 2006, 2007, 2008 Free 
Software Foundation, Inc.
+##     Copyright (C) 1998, 1999, 2000, 2001, 2002, 2006, 2007, 2008, 2009 Free 
Software Foundation, Inc.
 ##
 ##   This file is part of GUILE.
 ##
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
 ##
 ##   GUILE 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 General Public License for more details.
+##   GNU Lesser General Public License for more details.
 ##
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 # want automake 1.10 or higher so that AM_GNU_GETTEXT can tell automake that
 # config.rpath is needed
@@ -40,4 +40,16 @@ ACLOCAL_AMFLAGS = -I m4
 
 DISTCLEANFILES = check-guile.log
 
+dist-hook: gen-ChangeLog
+
+gen_start_rev = 61db429e251bfd2f75cb4632972e0238056eb24b
+.PHONY: gen-ChangeLog
+gen-ChangeLog:
+       if test -d .git; then                                           \
+         $(top_srcdir)/build-aux/gitlog-to-changelog                   \
+           $(gen_start_rev)..HEAD > $(distdir)/cl-t;                   \
+         rm -f $(distdir)/ChangeLog;                                   \
+         mv $(distdir)/cl-t $(distdir)/ChangeLog;                      \
+       fi
+
 # Makefile.am ends here
diff --git a/NEWS b/NEWS
index 9aca5d9..5175a09 100644
--- a/NEWS
+++ b/NEWS
@@ -5,29 +5,491 @@ See the end for copying conditions.
 Please send Guile bug reports to address@hidden
 
 
-Changes in 1.9.0:
+Changes in 1.9.0 (changes since the 1.8.x series):
 
 * New modules (see the manual for details)
 
-** `(srfi srfi-18)', multithreading support
-** The `(ice-9 i18n)' module provides internationalization support
+** `(srfi srfi-18)', more sophisticated multithreading support
+** `(ice-9 i18n)', internationalization support
+** `(rnrs bytevector)', the R6RS bytevector API
+** `(rnrs io ports)', a subset of the R6RS I/O port API
+** `(system xref)', a cross-referencing facility (FIXME undocumented)
 
-* Changes to the distribution
+* Changes to the stand-alone interpreter
 
-** Guile now uses Gnulib as a portability aid
+** Guile now can compile Scheme to bytecode for a custom virtual machine.
+
+Compiled code loads much faster than Scheme source code, and runs around
+3 or 4 times as fast, generating much less garbage in the process.
+
+** The stack limit is now initialized from the environment.
+
+If getrlimit(2) is available and a stack limit is set, Guile will set
+its stack limit to 80% of the rlimit. Otherwise the limit is 160000
+words, a four-fold increase from the earlier default limit.
+
+** New environment variables: GUILE_LOAD_COMPILED_PATH,
+   GUILE_SYSTEM_LOAD_COMPILED_PATH
+
+GUILE_LOAD_COMPILED_PATH is for compiled files what GUILE_LOAD_PATH is
+for source files. It is a different path, however, because compiled
+files are architecture-specific. GUILE_SYSTEM_LOAD_COMPILED_PATH is like
+GUILE_SYSTEM_PATH.
+
+** New read-eval-print loop (REPL) implementation
+
+Running Guile with no arguments drops the user into the new REPL. While
+it is self-documenting to an extent, the new REPL has not yet been
+documented in the manual. This will be fixed before 2.0.
+
+** New `guile-tools' commands: `compile', `disassemble'
+
+Pass the `--help' command-line option to these commands for more
+information.
 
-* Changes to the stand-alone interpreter
 * Changes to Scheme functions and syntax
 
-** A new 'memoize-symbol evaluator trap has been added.  This trap can
-be used for efficiently implementing a Scheme code coverage.
+** Procedure removed: `the-environment'
+
+This procedure was part of the interpreter's execution model, and does
+not apply to the compiler.
+
+** Files loaded with `primitive-load-path' will now be compiled
+   automatically.
+
+If a compiled .go file corresponding to a .scm file is not found or is
+not fresh, the .scm file will be compiled on the fly, and the resulting
+.go file stored away. An advisory note will be printed on the console.
+
+Note that this mechanism depends on preservation of the .scm and .go
+modification times; if the .scm or .go files are moved after
+installation, care should be taken to preserve their original
+timestamps.
+
+Autocompiled files will be stored in the user's ~/.guile-ccache
+directory, which will be created if needed. This is analogous to
+ccache's behavior for C files.
+
+To inhibit autocompilation, set the GUILE_AUTO_COMPILE environment
+variable to 0, or pass --no-autocompile on the Guile command line.
+
+Note that there is currently a bug here: automatic compilation will
+sometimes be attempted when it shouldn't.
+
+For example, the old (lang elisp) modules are meant to be interpreted,
+not compiled. This bug will be fixed before 2.0. FIXME 2.0: Should say
+something here about module-transformer called for compile.
+
+** New POSIX procedures: `getrlimit' and `setrlimit'
+
+Note however that the interface of these functions is likely to change
+in the next prerelease.
+
+** New procedure in `(oops goops)': `method-formals'
+
+** BUG: (procedure-property func 'arity) does not work on compiled
+   procedures
+
+This will be fixed one way or another before 2.0.
+
+** New procedures in (ice-9 session): `add-value-help-handler!',
+   `remove-value-help-handler!', `add-name-help-handler!'
+   `remove-name-help-handler!', `procedure-arguments',
+
+The value and name help handlers provide some minimal extensibility to
+the help interface. Guile-lib's `(texinfo reflection)' uses them, for
+example, to make stexinfo help documentation available. See those
+procedures' docstrings for more information.
+
+`procedure-arguments' describes the arguments that a procedure can take,
+combining arity and formals. For example:
+
+  (procedure-arguments resolve-interface)
+  => ((required . (name)) (rest . args))
+
+Additionally, `module-commentary' is now publically exported from
+`(ice-9 session).
+
+** Deprecated: `procedure->memoizing-macro', `procedure->syntax'
+
+These procedures will not work with syncase expansion, and indeed are
+not used in the normal course of Guile. They are still used by the old
+Emacs Lisp support, however.
+
+** New language: ECMAScript
+
+Guile now ships with one other high-level language supported,
+ECMAScript. The goal is to support all of version 3.1 of the standard,
+but not all of the libraries are there yet. This support is not yet
+documented; ask on the mailing list if you are interested.
+
+** Defmacros may now have docstrings.
+
+Indeed, any macro may have a docstring. `object-documentation' from
+`(ice-9 documentation)' may be used to retrieve the docstring, once you
+have a macro value -- but see the above note about first-class macros.
+Docstrings are associated with the syntax transformer procedures.
+
+** The psyntax expander now knows how to interpret the @ and @@ special
+   forms.
+
+** The psyntax expander is now hygienic with respect to modules.
+
+Free variables in a macro are scoped in the module that the macro was
+defined in, not in the module the macro is used in. For example, code
+like this works now:
+
+   (define-module (foo) #:export (bar))
+   (define (helper x) ...)
+   (define-syntax bar
+     (syntax-rules () ((_ x) (helper x))))
+
+   (define-module (baz) #:use-module (foo))
+   (bar qux)
+
+It used to be you had to export `helper' from `(foo)' as well.
+Thankfully, this has been fixed.
+
+** New function, `procedure-module'
+
+While useful on its own, `procedure-module' is used by psyntax on syntax
+transformers to determine the module in which to scope introduced
+identifiers.
+
+** `eval-case' has been deprecated, and replaced by `eval-when'.
+
+The semantics of `eval-when' are easier to understand. It is still
+missing documentation, however.
+
+** Guile is now more strict about prohibiting definitions in expression
+   contexts.
+
+Although previous versions of Guile accepted it, the following
+expression is not valid, in R5RS or R6RS:
+
+  (if test (define foo 'bar) (define foo 'baz))
+
+In this specific case, it would be better to do:
+
+  (define foo (if test 'bar 'baz))
+
+It is certainly possible to circumvent this resriction with e.g.
+`(module-define! (current-module) 'foo 'baz)'. We would appreciate
+feedback about this change (a consequence of using psyntax as the
+default expander), and may choose to revisit this situation before 2.0
+in response to user feedback.
+
+** Defmacros must now produce valid Scheme expressions.
+
+It used to be that defmacros could unquote in Scheme values, as a way of
+supporting partial evaluation, and avoiding some hygiene issues. For
+example:
+
+  (define (helper x) ...)
+  (define-macro (foo bar)
+    `(,helper ,bar))
+
+Assuming this macro is in the `(baz)' module, the direct translation of
+this code would be:
+
+  (define (helper x) ...)
+  (define-macro (foo bar)
+    `((@@ (baz) helper) ,bar))
+
+Of course, one could just use a hygienic macro instead:
+
+  (define-syntax foo
+    (syntax-rules ()
+      ((_ bar) (helper bar))))
+
+** Guile's psyntax now supports docstrings and internal definitions.
+
+The following Scheme is not strictly legal:
+
+  (define (foo)
+    "bar"
+    (define (baz) ...)
+    (baz))
+
+However its intent is fairly clear. Guile interprets "bar" to be the
+docstring of `foo', and the definition of `baz' is still in definition
+context.
+
+** Macros need to be defined before their first use.
+
+It used to be that with lazy memoization, this might work:
+
+  (define (foo x)
+    (ref x))
+  (define-macro (ref x) x)
+  (foo 1) => 1
+
+But now, the body of `foo' is interpreted to mean a call to the toplevel
+`ref' function, instead of a macro expansion. The solution is to define
+macros before code that uses them.
+
+** Functions needed by macros at expand-time need to be present at
+   expand-time.
+
+For example, this code will work at the REPL:
+
+  (define (double-helper x) (* x x))
+  (define-macro (double-literal x) (double-helper x))
+  (double-literal 2) => 4
+
+But it will not work when a file is compiled, because the definition of
+`double-helper' is not present at expand-time. The solution is to wrap
+the definition of `double-helper' in `eval-when':
+
+  (eval-when (load compile eval)
+    (define (double-helper x) (* x x)))
+  (define-macro (double-literal x) (double-helper x))
+  (double-literal 2) => 4
+
+See the (currently missing) documentation for eval-when for more
+information.
+
+** New variable, %pre-modules-transformer
+
+Need to document this one some more.
+
+** Temporarily removed functions: `macroexpand', `macroexpand-1'
+
+`macroexpand' will be added back before 2.0. It is unclear how to
+implement `macroexpand-1' with syntax-case, though PLT Scheme does prove
+that it is possible.
+
+** New reader macros: #' #` #, #,@
+
+These macros translate, respectively, to `syntax', `quasisyntax',
+`unsyntax', and `unsyntax-splicing'. See the R6RS for more information.
+These reader macros may be overridden by `read-hash-extend'.
+
+** Incompatible change to #'
+
+Guile did have a #' hash-extension, by default, which just returned the
+subsequent datum: #'foo => foo. In the unlikely event that anyone
+actually used this, this behavior may be reinstated via the
+`read-hash-extend' mechanism.
+
+** Scheme expresssions may be commented out with #;
+
+#; comments out an entire expression.  See SRFI-62 or the R6RS for more
+information.
+
+** `make-stack' with a tail-called procedural narrowing argument no longer
+   works (with compiled procedures)
+
+It used to be the case that a captured stack could be narrowed to select
+calls only up to or from a certain procedure, even if that procedure
+already tail-called another procedure. This was because the debug
+information from the original procedure was kept on the stack.
+
+Now with the new compiler, the stack only contains active frames from
+the current continuation. A narrow to a procedure that is not in the
+stack will result in an empty stack. To fix this, narrow to a procedure
+that is active in the current continuation, or narrow to a specific
+number of stack frames.
+
+** backtraces through compiled procedures only show procedures that are
+   active in the current continuation
+
+Similarly to the previous issue, backtraces in compiled code may be
+different from backtraces in interpreted code. There are no semantic
+differences, however. Please mail address@hidden if you see any
+deficiencies with Guile's backtraces.
+
+** syntax-rules and syntax-case macros now propagate source information
+   through to the expanded code
+
+This should result in better backtraces.
+
+** The currying behavior of `define' has been removed.
+
+Before, `(define ((f a) b) (* a b))' would translate to
+
+  (define f (lambda (a) (lambda (b) (* a b))))
+
+Now a syntax error is signaled, as this syntax is not supported by
+default. If there is sufficient demand, this syntax can be supported
+again by default.
+
+** All modules have names now
+
+Before, you could have anonymous modules: modules without names. Now,
+because of hygiene and macros, all modules have names. If a module was
+created without a name, the first time `module-name' is called on it, a
+fresh name will be lazily generated for it.
+
+** Many syntax errors have different texts now
+
+Syntax errors still throw to the `syntax-error' key, but the arguments
+are often different now. Perhaps in the future, Guile will switch to
+using standard SRFI-35 conditions.
+
+** Returning multiple values to compiled code will silently truncate the
+   values to the expected number
+
+For example, the interpreter would raise an error evaluating the form,
+`(+ (values 1 2) (values 3 4))', because it would see the operands as
+being two compound "values" objects, to which `+' does not apply.
+
+The compiler, on the other hand, receives multiple values on the stack,
+not as a compound object. Given that it must check the number of values
+anyway, if too many values are provided for a continuation, it chooses
+to truncate those values, effectively evaluating `(+ 1 3)' instead.
+
+The idea is that the semantics that the compiler implements is more
+intuitive, and the use of the interpreter will fade out with time.
+This behavior is allowed both by the R5RS and the R6RS.
+
+** Multiple values in compiled code are not represented by compound
+   objects
+
+This change may manifest itself in the following situation:
+
+  (let ((val (foo))) (do-something) val)
+
+In the interpreter, if `foo' returns multiple values, multiple values
+are produced from the `let' expression. In the compiler, those values
+are truncated to the first value, and that first value is returned. In
+the compiler, if `foo' returns no values, an error will be raised, while
+the interpreter would proceed.
+
+Both of these behaviors are allowed by R5RS and R6RS. The compiler's
+behavior is more correct, however. If you wish to preserve a potentially
+multiply-valued return, you will need to set up a multiple-value
+continuation, using `call-with-values'.
+
+** Defmacros are now implemented in terms of syntax-case.
+
+The practical ramification of this is that the `defmacro?' predicate has
+been removed, along with `defmacro-transformer', `macro-table',
+`xformer-table', `assert-defmacro?!', `set-defmacro-transformer!' and
+`defmacro:transformer'. This is because defmacros are simply macros. If
+any of these procedures provided useful facilities to you, we encourage
+you to contact the Guile developers.
+
+** psyntax is now the default expander
+
+Scheme code is now expanded by default by the psyntax hygienic macro
+expander. Expansion is performed completely before compilation or
+interpretation.
+
+Notably, syntax errors will be signalled before interpretation begins.
+In the past, many syntax errors were only detected at runtime if the
+code in question was memoized.
+
+As part of its expansion, psyntax renames all lexically-bound
+identifiers. Original identifier names are preserved and given to the
+compiler, but the interpreter will see the renamed variables, e.g.,
+`x432' instead of `x'.
+
+Note that the psyntax that Guile uses is a fork, as Guile already had
+modules before incompatible modules were added to psyntax -- about 10
+years ago! Thus there are surely a number of bugs that have been fixed
+in psyntax since then. If you find one, please notify address@hidden
+
+** syntax-rules and syntax-case are available by default.
+
+There is no longer any need to import the `(ice-9 syncase)' module
+(which is now deprecated). The expander may be invoked directly via
+`sc-expand', though it is normally searched for via the current module
+transformer.
+
+Also, the helper routines for syntax-case are available in the default
+environment as well: `syntax->datum', `datum->syntax',
+`bound-identifier=?', `free-identifier=?', `generate-temporaries',
+`identifier?', and `syntax-violation'. See the R6RS for documentation.
+
+** Lexical bindings introduced by hygienic macros may not be referenced
+   by nonhygienic macros.
+
+If a lexical binding is introduced by a hygienic macro, it may not be
+referenced by a nonhygienic macro. For example, this works:
+
+  (let ()
+    (define-macro (bind-x val body)
+      `(let ((x ,val)) ,body))
+    (define-macro (ref x)
+      x)
+    (bind-x 10 (ref x)))
+
+But this does not:
+
+  (let ()
+    (define-syntax bind-x
+      (syntax-rules ()
+        ((_ val body) (let ((x val)) body))))
+    (define-macro (ref x)
+      x)
+    (bind-x 10 (ref x)))
+
+It is not normal to run into this situation with existing code. However,
+as code is ported over from defmacros to syntax-case, it is possible to
+run into situations like this. In the future, Guile will probably port
+its `while' macro to syntax-case, which makes this issue one to know
+about.
+
+** Macros may no longer be referenced as first-class values.
+
+In the past, you could evaluate e.g. `if', and get its macro value. Now,
+expanding this form raises a syntax error.
+
+Macros still /exist/ as first-class values, but they must be
+/referenced/ via the module system, e.g. `(module-ref (current-module)
+'if)'.
+
+This decision may be revisited before the 2.0 release. Feedback welcome
+to address@hidden (subscription required) or address@hidden (no
+subscription required).
+
+** New macro type: syncase-macro
+
+XXX Need to decide whether to document this for 2.0, probably should:
+make-syncase-macro, make-extended-syncase-macro, macro-type,
+syncase-macro-type, syncase-macro-binding
+
+** A new `memoize-symbol' evaluator trap has been added.
+
+This trap can be used for efficiently implementing a Scheme code
+coverage.
 
 ** Duplicate bindings among used modules are resolved lazily.
+
 This slightly improves program startup times.
 
 ** New thread cancellation and thread cleanup API
+
 See `cancel-thread', `set-thread-cleanup!', and `thread-cleanup'.
 
+** Fix bad interaction between `false-if-exception' and stack-call.
+
+Exceptions thrown by `false-if-exception' were erronously causing the
+stack to be saved, causing later errors to show the incorrectly-saved
+backtrace. This has been fixed.
+
+** New global variables: %load-compiled-path, %load-compiled-extensions
+
+These are analogous to %load-path and %load-extensions.
+
+** New procedure, `make-promise'
+
+`(make-promise (lambda () foo))' is equivalent to `(delay foo)'.
+
+** New entry into %guile-build-info: `ccachedir'
+
+** Fix bug in `module-bound?'.
+
+`module-bound?' was returning true if a module did have a local
+variable, but one that was unbound, but another imported module bound
+the variable. This was an error, and was fixed.
+
+** `(ice-9 syncase)' has been deprecated.
+
+As syntax-case is available by default, importing `(ice-9 syncase)' has
+no effect, and will trigger a deprecation warning.
+
 * Changes to the C interface
 
 ** The GH interface (deprecated in version 1.6, 2001) was removed.
@@ -40,12 +502,40 @@ application code.
 ** Functions for handling `scm_option' now no longer require an argument
 indicating length of the `scm_t_option' array.
 
-** Primitive procedures (aka. "subrs") are now stored in double cells
-This removes the subr table and simplifies the code.
+** scm_primitive_load_path has additional argument, exception_on_error
+
+** New C function: scm_module_public_interface
+
+This procedure corresponds to Scheme's `module-public-interface'.
+
+** `scm_stat' has an additional argument, `exception_on_error'
+** `scm_primitive_load_path' has an additional argument 
`exception_on_not_found'
+
+* Changes to the distribution
+
+** Guile's license is now LGPLv3+
+
+In other words the GNU Lesser General Public License, version 3 or
+later (at the discretion of each person that chooses to redistribute
+part of Guile).
+
+** `guile-config' will be deprecated in favor of `pkg-config'
+
+`guile-config' has been rewritten to get its information from
+`pkg-config', so this should be a transparent change.  Note however that
+guile.m4 has yet to be modified to call pkg-config instead of
+guile-config.
+
+** New installation directory: $(pkglibdir)/1.9/ccache
+
+If $(libdir) is /usr/lib, for example, Guile will install its .go files
+to /usr/lib/guile/1.9/ccache. These files are architecture-specific.
+
+** New dependency: GNU libunistring.
+
+See http://www.gnu.org/software/libunistring/. We hope to merge in
+Unicode support in the next prerelease.
 
-** Primitive procedures with more than 3 arguments (aka. "gsubrs") are
-no longer implemented using the "compiled closure" mechanism.  This
-simplifies code and reduces both the storage and run-time overhead.
 
 
 Changes in 1.8.7 (since 1.8.6)
diff --git a/README b/README
index 4950229..1f71b8a 100644
--- a/README
+++ b/README
@@ -14,7 +14,7 @@ Guile versions with an odd middle number, i.e. 1.9.* are 
unstable
 development versions.  Even middle numbers indicate stable versions.
 This has been the case since the 1.3.* series.
 
-The next stable release will likely be version 1.10.0.
+The next stable release will likely be version 2.0.0.
 
 Please send bug reports to address@hidden
 
@@ -27,24 +27,38 @@ Generic instructions for configuring and compiling Guile 
can be found
 in the INSTALL file.  Guile specific information and configure options
 can be found below, including instructions for installing SLIB.
 
-Guile requires a few external packages and can optionally use a number
-of external packages such as `readline' when they are available.
-Guile expects to be able to find these packages in the default
-compiler setup, it does not try to make any special arrangements
-itself.  For example, for the `readline' package, Guile expects to be
-able to find the include file <readline/readline.h>, without passing
-any special `-I' options to the compiler.
-
-If you installed an external package, and you used the --prefix
-installation option to install it somewhere else than /usr/local, you
-must arrange for your compiler to find it by default.  If that
-compiler is gcc, one convenient way of making such arrangements is to
-use the --with-local-prefix option during installation, naming the
-same directory as you used in the --prefix option of the package.  In
-particular, it is not good enough to use the same --prefix option when
-you install gcc and the package; you need to use the
---with-local-prefix option as well.  See the gcc documentation for
-more details.
+Guile depends on the following external libraries.
+- libgmp
+- libiconv
+- libintl
+- libltdl
+- libunistring
+It will also use the libreadline library if it is available.  For each
+of these there is a corresponding --with-XXX-prefix option that you
+can use when invoking ./configure, if you have these libraries
+installed in a location other than the standard places (/usr and
+/usr/local).
+
+These options are provided by the Gnulib `havelib' module, and details
+of how they work are documented in `Searching for Libraries' in the
+Gnulib manual (http://www.gnu.org/software/gnulib/manual).  The extent
+to which they work on a given OS depends on whether that OS supports
+encoding full library path names in executables (aka `rpath').  Also
+note that using these options, and hence hardcoding full library path
+names (where that is supported), makes it impossible to later move the
+built executables and libraries to an installation location other than
+the one that was specified at build time.
+
+Another possible approach is to set CPPFLAGS and LDFLAGS before
+running configure, so that they include -I options for all the
+non-standard places where you have installed header files and -L
+options for all the non-standard places where you have installed
+libraries.  This will allow configure and make to find those headers
+and libraries during the build.  The locations found will not be
+hardcoded into the build executables and libraries, so with this
+approach you will probably also need to set LD_LIBRARY_PATH
+correspondingly, to allow Guile to find the necessary libraries again
+at runtime.
 
 
 Required External Packages ================================================
@@ -309,6 +323,7 @@ About This Distribution 
==============================================
 Interesting files include:
 
 - LICENSE, which contains the exact terms of the Guile license.
+- COPYING.LESSER, which contains the terms of the GNU Lesser General Public 
License.
 - COPYING, which contains the terms of the GNU General Public License.
 - INSTALL, which contains general instructions for building/installing Guile.
 - NEWS, which describes user-visible changes since the last release of Guile.
diff --git a/THANKS b/THANKS
index 748605c..90ccd87 100644
--- a/THANKS
+++ b/THANKS
@@ -13,6 +13,7 @@ Contributors since the last release:
          Kevin Ryde
           Bill Schottstaedt
         Richard Todd
+           Andy Wingo
 
 Sponsors since the last release:
 
@@ -84,6 +85,7 @@ For fixes or providing information which led to a fix:
           David Pirotte
          Carlos Pita
             Ken Raeburn
+         Juhani Rantanen
         Andreas Rottmann
            Hugh Sasse
          Werner Scheinast
diff --git a/am/Makefile.am b/am/Makefile.am
index 2c49adb..d1b7ecc 100644
--- a/am/Makefile.am
+++ b/am/Makefile.am
@@ -4,20 +4,20 @@
 ##
 ##   This file is part of GUILE.
 ##
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
 ##
 ##   GUILE 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 General Public License for more details.
+##   GNU Lesser General Public License for more details.
 ##
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 AUTOMAKE_OPTIONS = gnu
 
diff --git a/am/maintainer-dirs b/am/maintainer-dirs
index c64268d..f1b741b 100644
--- a/am/maintainer-dirs
+++ b/am/maintainer-dirs
@@ -5,17 +5,17 @@
 ##   This file is part of GUILE.
 ##
 ##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   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.
 ##
 ##   GUILE 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 General Public License for more details.
+##   GNU Lesser General Public License for more details.
 ##
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not, write
 ##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
 ##   Floor, Boston, MA 02110-1301 USA
 
diff --git a/am/pre-inst-guile b/am/pre-inst-guile
index 353908d..7993d15 100644
--- a/am/pre-inst-guile
+++ b/am/pre-inst-guile
@@ -5,17 +5,17 @@
 ##   This file is part of GUILE.
 ##
 ##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   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.
 ##
 ##   GUILE 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 General Public License for more details.
+##   GNU Lesser General Public License for more details.
 ##
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not, write
 ##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
 ##   Floor, Boston, MA 02110-1301 USA
 
diff --git a/benchmark-suite/benchmarks/bytevectors.bm 
b/benchmark-suite/benchmarks/bytevectors.bm
index 9547a71..a686a08 100644
--- a/benchmark-suite/benchmarks/bytevectors.bm
+++ b/benchmark-suite/benchmarks/bytevectors.bm
@@ -4,19 +4,20 @@
 ;;; Copyright 2009  Ludovic Courtès <address@hidden>
 ;;;
 ;;;
-;;; This program is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2 of the License, or
+;;; 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 General Public License for more details.
+;;; GNU Lesser General Public License for more details.
 ;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with this program; if not, write to the Free Software
-;;; Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
+;;; 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
 
 (define-module (benchmarks bytevector)
   :use-module (rnrs bytevector)
diff --git a/benchmark-suite/benchmarks/read.bm 
b/benchmark-suite/benchmarks/read.bm
index cb876b5..f11ca68 100644
--- a/benchmark-suite/benchmarks/read.bm
+++ b/benchmark-suite/benchmarks/read.bm
@@ -2,20 +2,20 @@
 ;;;
 ;;; Copyright (C) 2008 Free Software Foundation, Inc.
 ;;;
-;;; This program is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
+;;; 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 General Public License for more details.
+;;; GNU Lesser General Public License for more details.
 ;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with this software; see the file COPYING.  If not, write to
-;;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;;; Boston, MA 02110-1301 USA
+;;; 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
 
 (define-module (benchmarks read)
   :use-module (benchmark-suite lib))
diff --git a/benchmark-suite/benchmarks/subr.bm 
b/benchmark-suite/benchmarks/subr.bm
index 9c87a99..ea00456 100644
--- a/benchmark-suite/benchmarks/subr.bm
+++ b/benchmark-suite/benchmarks/subr.bm
@@ -2,20 +2,20 @@
 ;;;
 ;;; Copyright (C) 2009 Free Software Foundation, Inc.
 ;;;
-;;; This program is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
+;;; 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 General Public License for more details.
+;;; GNU Lesser General Public License for more details.
 ;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with this software; see the file COPYING.  If not, write to
-;;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;;; Boston, MA 02110-1301 USA
+;;; 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
 
 (define-module (benchmarks subrs)
   :use-module (benchmark-suite lib))
diff --git a/benchmark-suite/benchmarks/uniform-vector-read.bm 
b/benchmark-suite/benchmarks/uniform-vector-read.bm
index d288f0b..d188b2b 100644
--- a/benchmark-suite/benchmarks/uniform-vector-read.bm
+++ b/benchmark-suite/benchmarks/uniform-vector-read.bm
@@ -2,20 +2,20 @@
 ;;;
 ;;; Copyright (C) 2008 Free Software Foundation, Inc.
 ;;;
-;;; This program is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
+;;; 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 General Public License for more details.
+;;; GNU Lesser General Public License for more details.
 ;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with this software; see the file COPYING.  If not, write to
-;;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;;; Boston, MA 02110-1301 USA
+;;; 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
 
 (define-module (benchmarks uniform-vector-read)
   :use-module (benchmark-suite lib)
diff --git a/benchmark-suite/guile-benchmark b/benchmark-suite/guile-benchmark
index c4c6f23..41cae06 100755
--- a/benchmark-suite/guile-benchmark
+++ b/benchmark-suite/guile-benchmark
@@ -7,20 +7,20 @@
 ;;;;
 ;;;; Copyright (C) 2002, 2006 Free Software Foundation, Inc.
 ;;;;
-;;;; This program is free software; you can redistribute it and/or modify
-;;;; it under the terms of the GNU General Public License as published by
-;;;; the Free Software Foundation; either version 2, or (at your option)
-;;;; any later version.
+;;;; 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 General Public License for more details.
+;;;; GNU Lesser General Public License for more details.
 ;;;;
-;;;; You should have received a copy of the GNU General Public License
-;;;; along with this software; see the file COPYING.  If not, write to
-;;;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;;;; Boston, MA 02110-1301 USA
+;;;; 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
 
 
 ;;;; Usage: [guile -e main -s] guile-benchmark [OPTIONS] [BENCHMARK ...]
diff --git a/benchmark-suite/lib.scm b/benchmark-suite/lib.scm
index 65491d7..65253c5 100644
--- a/benchmark-suite/lib.scm
+++ b/benchmark-suite/lib.scm
@@ -1,20 +1,20 @@
 ;;;; benchmark-suite/lib.scm --- generic support for benchmarking
 ;;;; Copyright (C) 2002, 2006 Free Software Foundation, Inc.
 ;;;;
-;;;; This program is free software; you can redistribute it and/or modify
-;;;; it under the terms of the GNU General Public License as published by
-;;;; the Free Software Foundation; either version 2, or (at your option)
-;;;; any later version.
+;;;; 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 General Public License for more details.
+;;;; GNU Lesser General Public License for more details.
 ;;;;
-;;;; You should have received a copy of the GNU General Public License
-;;;; along with this software; see the file COPYING.  If not, write to
-;;;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;;;; Boston, MA 02110-1301 USA
+;;;; 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
 
 (define-module (benchmark-suite lib)
   :export (
diff --git a/build-aux/gitlog-to-changelog b/build-aux/gitlog-to-changelog
new file mode 100755
index 0000000..1cc53eb
--- /dev/null
+++ b/build-aux/gitlog-to-changelog
@@ -0,0 +1,183 @@
+#!/usr/bin/perl
+# Convert git log output to ChangeLog format.
+
+my $VERSION = '2009-06-04 08:53'; # UTC
+# The definition above must lie within the first 8 lines in order
+# for the Emacs time-stamp write hook (at end) to update it.
+# If you change this file with Emacs, please let the write hook
+# do its job.  Otherwise, update this string manually.
+
+# Copyright (C) 2008, 2009 Free Software Foundation, Inc.
+
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, 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 General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+# Written by Jim Meyering
+
+use strict;
+use warnings;
+use Getopt::Long;
+use POSIX qw(strftime);
+
+(my $ME = $0) =~ s|.*/||;
+
+# use File::Coda; # http://meyering.net/code/Coda/
+END {
+  defined fileno STDOUT or return;
+  close STDOUT and return;
+  warn "$ME: failed to close standard output: $!\n";
+  $? ||= 1;
+}
+
+sub usage ($)
+{
+  my ($exit_code) = @_;
+  my $STREAM = ($exit_code == 0 ? *STDOUT : *STDERR);
+  if ($exit_code != 0)
+    {
+      print $STREAM "Try `$ME --help' for more information.\n";
+    }
+  else
+    {
+      print $STREAM <<EOF;
+Usage: $ME [OPTIONS] [ARGS]
+
+Convert git log output to ChangeLog format.  If present, any ARGS
+are passed to "git log".  To avoid ARGS being parsed as options to
+$ME, they may be preceded by '--'.
+
+OPTIONS:
+
+   --since=DATE convert only the logs since DATE;
+                  the default is to convert all log entries.
+
+   --help       display this help and exit
+   --version    output version information and exit
+
+EXAMPLE:
+
+  $ME --since=2008-01-01 > ChangeLog
+  $ME -- -n 5 foo > last-5-commits-to-branch-foo
+
+EOF
+    }
+  exit $exit_code;
+}
+
+# If the string $S is a well-behaved file name, simply return it.
+# If it contains white space, quotes, etc., quote it, and return the new 
string.
+sub shell_quote($)
+{
+  my ($s) = @_;
+  if ($s =~ m![^\w+/.,-]!)
+    {
+      # Convert each single quote to '\''
+      $s =~ s/\'/\'\\\'\'/g;
+      # Then single quote the string.
+      $s = "'$s'";
+    }
+  return $s;
+}
+
+sub quoted_cmd(@)
+{
+  return join (' ', map {shell_quote $_} @_);
+}
+
+{
+  my $since_date = '1970-01-01 UTC';
+  GetOptions
+    (
+     help => sub { usage 0 },
+     version => sub { print "$ME version $VERSION\n"; exit },
+     'since=s' => \$since_date,
+    ) or usage 1;
+
+  my @cmd = (qw (git log --log-size), "--since=$since_date",
+             '--pretty=format:%ct  %an  <%ae>%n%n%s%n%b%n', @ARGV);
+  open PIPE, '-|', @cmd
+    or die ("$ME: failed to run `". quoted_cmd (@cmd) ."': $!\n"
+            . "(Is your Git too old?  Version 1.5.1 or later is required.)\n");
+
+  my $prev_date_line = '';
+  while (1)
+    {
+      defined (my $in = <PIPE>)
+        or last;
+      $in =~ /^log size (\d+)$/
+        or die "$ME:$.: Invalid line (expected log size):\n$in";
+      my $log_nbytes = $1;
+
+      my $log;
+      my $n_read = read PIPE, $log, $log_nbytes;
+      $n_read == $log_nbytes
+        or die "$ME:$.: unexpected EOF\n";
+
+      my @line = split "\n", $log;
+      my $author_line = shift @line;
+      defined $author_line
+        or die "$ME:$.: unexpected EOF\n";
+      $author_line =~ /^(\d+)  (.*>)$/
+        or die "$ME:$.: Invalid line "
+          . "(expected date/author/email):\n$author_line\n";
+
+      my $date_line = sprintf "%s  $2\n", strftime ("%F", localtime ($1));
+      # If this line would be the same as the previous date/name/email
+      # line, then arrange not to print it.
+      if ($date_line ne $prev_date_line)
+        {
+          $prev_date_line eq ''
+            or print "\n";
+          print $date_line;
+        }
+      $prev_date_line = $date_line;
+
+      # Omit "Signed-off-by..." lines.
+      @line = grep !/^Signed-off-by: .*>$/, @line;
+
+      # If there were any lines
+      if (@line == 0)
+        {
+          warn "$ME: warning: empty commit message:\n  $date_line\n";
+        }
+      else
+        {
+          # Remove leading and trailing blank lines.
+          while ($line[0] =~ /^\s*$/) { shift @line; }
+          while ($line[$#line] =~ /^\s*$/) { pop @line; }
+
+          # Prefix each non-empty line with a TAB.
+          @line = map { length $_ ? "\t$_" : '' } @line;
+
+          print "\n", join ("\n", @line), "\n";
+        }
+
+      defined ($in = <PIPE>)
+        or last;
+      $in ne "\n"
+        and die "$ME:$.: unexpected line:\n$in";
+    }
+
+  close PIPE
+    or die "$ME: error closing pipe from " . quoted_cmd (@cmd) . "\n";
+  # FIXME-someday: include $PROCESS_STATUS in the diagnostic
+}
+
+# Local Variables:
+# indent-tabs-mode: nil
+# eval: (add-hook 'write-file-hooks 'time-stamp)
+# time-stamp-start: "my $VERSION = '"
+# time-stamp-format: "%:y-%02m-%02d %02H:%02M"
+# time-stamp-time-zone: "UTC"
+# time-stamp-end: "'; # UTC"
+# End:
diff --git a/configure.in b/configure.in
index 08ef31c..d43de12 100644
--- a/configure.in
+++ b/configure.in
@@ -8,20 +8,20 @@ Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 
2006, 2007, 2008,
 
 This file is part of GUILE
 
-GUILE is free software; you can redistribute it and/or modify it
-under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your
-option) any later version.
+GUILE 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.
 
-GUILE 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
-General Public License for more details.
+GUILE 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 General Public License
-along with GUILE; see the file COPYING.  If not, write to the
-Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-Boston, MA 02110-1301, USA.
+You should have received a copy of the GNU Lesser General Public
+License along with GUILE; see the file COPYING.LESSER.  If not, write
+to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
+Floor, Boston, MA 02110-1301, USA.
 
 ]])
 
@@ -827,6 +827,7 @@ fi
 
 
 dnl GMP tests
+AC_LIB_LINKFLAGS(gmp)
 AC_CHECK_LIB([gmp], [__gmpz_init], ,
   [AC_MSG_ERROR([GNU MP not found, see README])])
 
diff --git a/doc/Makefile.am b/doc/Makefile.am
index f4e0718..0a6b14e 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -1,23 +1,23 @@
 ## Process this file with Automake to create Makefile.in
 ##
-##     Copyright (C) 1998, 2002, 2006, 2008 Free Software Foundation, Inc.
+##     Copyright (C) 1998, 2002, 2006, 2008, 2009 Free Software Foundation, 
Inc.
 ##
 ##   This file is part of GUILE.
 ##
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
 ##
 ##   GUILE 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 General Public License for more details.
+##   GNU Lesser General Public License for more details.
 ##
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 AUTOMAKE_OPTIONS = gnu
 
@@ -43,5 +43,3 @@ include $(top_srcdir)/am/maintainer-dirs
 guile-api.alist: guile-api.alist-FORCE
        ( cd $(top_builddir) ; $(mscripts)/update-guile-api.alist )
 guile-api.alist-FORCE:
-
-info_TEXINFOS = guile-vm.texi
diff --git a/doc/example-smob/image-type.c b/doc/example-smob/image-type.c
index 68ecded..8dd998a 100644
--- a/doc/example-smob/image-type.c
+++ b/doc/example-smob/image-type.c
@@ -2,20 +2,20 @@
  * 
  *     Copyright (C) 1998, 2000, 2004, 2006 Free Software Foundation, Inc.
  * 
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * 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 General Public License for more details.
+ * 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 General Public License
- * along with this software; see the file COPYING.  If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- * Boston, MA 02110-1301 USA
+ * 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
  */
 
 #include <stdlib.h>
diff --git a/doc/example-smob/myguile.c b/doc/example-smob/myguile.c
index 9df3cf3..30200dd 100644
--- a/doc/example-smob/myguile.c
+++ b/doc/example-smob/myguile.c
@@ -2,20 +2,20 @@
  * 
  *     Copyright (C) 1998, 2006 Free Software Foundation, Inc.
  * 
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * 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 General Public License for more details.
+ * 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 General Public License
- * along with this software; see the file COPYING.  If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- * Boston, MA 02110-1301 USA
+ * 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
  */
 
 #include <libguile.h>
diff --git a/doc/goops/Makefile.am b/doc/goops/Makefile.am
index 03794c4..49bfb29 100644
--- a/doc/goops/Makefile.am
+++ b/doc/goops/Makefile.am
@@ -4,20 +4,20 @@
 ##
 ##   This file is part of GUILE.
 ##   
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
-##   
+##
 ##   GUILE 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 General Public License for more details.
-##   
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   GNU Lesser General Public License for more details.
+##
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 AUTOMAKE_OPTIONS = gnu
 
diff --git a/doc/groupings.alist b/doc/groupings.alist
index ed5bb1f..a174819 100644
--- a/doc/groupings.alist
+++ b/doc/groupings.alist
@@ -3,19 +3,19 @@
 ;;     Copyright (C) 2002, 2006 Free Software Foundation, Inc.
 ;;
 ;; This program is free software; you can redistribute it and/or
-;; modify it under the terms of the GNU General Public License as
-;; published by the Free Software Foundation; either version 2, 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
+;; 
+;; 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
-;; General Public License for more details.
-;;
-;; You should have received a copy of the GNU General Public License
-;; along with this software; see the file COPYING.  If not, write to
-;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;; Boston, MA 02110-1301 USA
+;; 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
 
 ;;; Commentary:
 
diff --git a/doc/guile-vm.texi b/doc/guile-vm.texi
deleted file mode 100644
index 927c09e..0000000
--- a/doc/guile-vm.texi
+++ /dev/null
@@ -1,1042 +0,0 @@
-\input texinfo  @c -*-texinfo-*-
address@hidden %**start of header
address@hidden guile-vm.info
address@hidden Guile VM Specification
address@hidden end
address@hidden odd
address@hidden %**end of header
-
address@hidden EDITION 0.6
address@hidden VERSION 0.6
address@hidden UPDATED 2005-04-26
-
address@hidden Macro for instruction definitions.
address@hidden insn{}
-Instruction
address@hidden macro
-
address@hidden For Scheme procedure definitions.
address@hidden scmproc{}
-Scheme Procedure
address@hidden macro
-
address@hidden Scheme records.
address@hidden scmrec{}
-Record
address@hidden macro
-
address@hidden
address@hidden Scheme Programming
address@hidden
-* Guile VM: (guile-vm).         Guile's Virtual Machine.
address@hidden direntry
-
-This file documents Guile VM.
-
-Copyright @copyright{} 2000 Keisuke Nishida
-Copyright @copyright{} 2005 Ludovic Court`es
-
-Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
address@hidden
-Permission is granted to process this file through TeX and print the
-results, provided the printed document carries a copying permission
-notice identical to this one except for the removal of this paragraph
-(this paragraph not being relevant to the printed manual).
-
address@hidden ignore
-Permission is granted to copy and distribute modified versions of this
-manual under the conditions for verbatim copying, provided that the
-entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
-Permission is granted to copy and distribute translations of this manual
-into another language, under the above conditions for modified versions,
-except that this permission notice may be stated in a translation
-approved by the Free Software Foundation.
address@hidden ifinfo
-
address@hidden
address@hidden Guile VM Specification
address@hidden for Guile VM @value{VERSION}
address@hidden Keisuke Nishida
-
address@hidden
address@hidden 0pt plus 1filll
-Edition @value{EDITION} @*
-Updated for Guile VM @value{VERSION} @*
address@hidden @*
-
-Copyright @copyright{} 2000 Keisuke Nishida
-Copyright @copyright{} 2005 Ludovic Court`es
-
-Permission is granted to make and distribute verbatim copies of this
-manual provided the copyright notice and this permission notice are
-preserved on all copies.
-
-Permission is granted to copy and distribute modified versions of this
-manual under the conditions for verbatim copying, provided that the
-entire resulting derived work is distributed under the terms of a
-permission notice identical to this one.
-
-Permission is granted to copy and distribute translations of this manual
-into another language, under the above conditions for modified versions,
-except that this permission notice may be stated in a translation
-approved by the Free Software Foundation.
address@hidden titlepage
-
address@hidden
-
address@hidden 
*********************************************************************
address@hidden Top, Introduction, (dir), (dir)
address@hidden Guile VM Specification
-
-This document would like to correspond to Guile VM @value{VERSION}.
-However, be warned that important parts still correspond to version
-0.0 and are not valid anymore.
-
address@hidden
-* Introduction::                
-* Variable Management::         
-* Instruction Set::             
-* The Compiler::                
-* Concept Index::               
-* Function and Instruction Index::  
-* Command and Variable Index::  
-
address@hidden
- --- The Detailed Node Listing ---
-
-Instruction Set
-
-* Environment Control Instructions::  
-* Branch Instructions::         
-* Subprogram Control Instructions::  
-* Data Control Instructions::   
-
-The Compiler
-
-* Overview::                    
-* The Language Front-Ends::     
-* GHIL::                        
-* Compiling Scheme Code::       
-* GLIL::                        
-* The Assembler::               
-
address@hidden detailmenu
address@hidden menu
-
address@hidden 
*********************************************************************
address@hidden Introduction, Variable Management, Top, Top
address@hidden What is Guile VM?
-
-A Guile VM has a set of registers and its own stack memory.  Guile may
-have more than one VM's.  Each VM may execute at most one program at a
-time.  Guile VM is a CISC system so designed as to execute Scheme and
-other languages efficiently.
-
address@hidden Registers
-
address@hidden
address@hidden pc - Program counter    ;; ip (instruction poiner) is better?
address@hidden sp - Stack pointer
address@hidden bp - Base pointer
address@hidden ac - Accumulator
address@hidden itemize
-
address@hidden Engine
-
-A VM may have one of three engines: reckless, regular, or debugging.
-Reckless engine is fastest but dangerous.  Regular engine is normally
-fail-safe and reasonably fast.  Debugging engine is safest and
-functional but very slow.
-
address@hidden Memory
-
-Stack is the only memory that each VM owns.  The other memory is shared
-memory that is shared among every VM and other part of Guile.
-
address@hidden Program
-
-A VM program consists of a bytecode that is executed and an environment
-in which execution is done.  Each program is allocated in the shared
-memory and may be executed by any VM.  A program may call other programs
-within a VM.
-
address@hidden Instruction
-
-Guile VM has dozens of system instructions and (possibly) hundreds of
-functional instructions.  Some Scheme procedures such as cons and car
-are implemented as VM's builtin functions, which are very efficient.
-Other procedures defined outside of the VM are also considered as VM's
-functional features, since they do not change the state of VM.
-Procedures defined within the VM are called subprograms.
-
-Most instructions deal with the accumulator (ac).  The VM stores all
-results from functions in ac, instead of pushing them into the stack.
-I'm not sure whether this is a good thing or not.
-
address@hidden Variable Management, Instruction Set, Introduction, Top
address@hidden Variable Management
-
-FIXME:  This chapter needs to be reviewed so that it matches reality.
-A more up-to-date description of the mechanisms described in this
-section is given in @ref{Instruction Set}.
-
-A program may have access to local variables, external variables, and
-top-level variables.
-
address@hidden Local/external variables
-
-A stack is logically divided into several blocks during execution.  A
-"block" is such a unit that maintains local variables and dynamic chain.
-A "frame" is an upper level unit that maintains subprogram calls.
-
address@hidden
-             Stack
-  dynamic |          |  |        |
-    chain +==========+  -        =
-        | |local vars|  |        |
-        `-|block data|  | block  |
-         /|frame data|  |        |
-        | +----------+  -        |
-        | |local vars|  |        | frame
-        `-|block data|  |        |
-         /+----------+  -        |
-        | |local vars|  |        |
-        `-|block data|  |        |
-         /+==========+  -        =
-        | |local vars|  |        |
-        `-|block data|  |        |
-         /|frame data|  |        |
-        | +----------+  -        |
-        | |          |  |        |
address@hidden example
-
-The first block of each frame may look like this:
-
address@hidden
-       Address  Data
-       -------  ----
-       xxx0028  Local variable 2
-       xxx0024  Local variable 1
-  bp ->xxx0020  Local variable 0
-       xxx001c  Local link       (block data)
-       xxx0018  External link    (block data)
-       xxx0014  Stack pointer    (block data)
-       xxx0010  Return address   (frame data)
-       xxx000c  Parent program   (frame data)
address@hidden example
-
-The base pointer (bp) always points to the lowest address of local
-variables of the recent block.  Local variables are referred as "bp[n]".
-The local link field has a pointer to the dynamic parent of the block.
-The parent's variables are referred as "bp[-1][n]", and grandparent's
-are "bp[-1][-1][n]".  Thus, any local variable is represented by its
-depth and offset from the current bp.
-
-A variable may be "external", which is allocated in the shared memory.
-The external link field of a block has a pointer to such a variable set,
-which I call "fragment" (what should I call?).  A fragment has a set of
-variables and its own chain.
-
address@hidden
-    local                    external
-    chain|     |              chain
-       | +-----+     .--------, |
-       `-|block|--+->|external|-'
-        /+-----+  |  `--------'\,
-       `-|block|--'             |
-        /+-----+     .--------, |
-       `-|block|---->|external|-'
-         +-----+     `--------'
-         |     |
address@hidden example
-
-An external variable is referred as "bp[-2]->variables[n]" or
-"bp[-2]->link->...->variables[n]".  This is also represented by a pair
-of depth and offset.  At any point of execution, the value of bp
-determines the current local link and external link, and thus the
-current environment of a program.
-
-Other data fields are described later.
-
address@hidden Top-level variables
-
-Guile VM uses the same top-level variables as the regular Guile.  A
-program may have direct access to vcells.  Currently this is done by
-calling scm_intern0, but a program is possible to have any top-level
-environment defined by the current module.
-
address@hidden Scheme and VM variable
-
-Let's think about the following Scheme code as an example:
-
address@hidden
-  (define (foo a)
-    (lambda (b) (list foo a b)))
address@hidden example
-
-In the lambda expression, "foo" is a top-level variable, "a" is an
-external variable, and "b" is a local variable.
-
-When a VM executes foo, it allocates a block for "a".  Since "a" may be
-externally referred from the closure, the VM creates a fragment with a
-copy of "a" in it.  When the VM evaluates the lambda expression, it
-creates a subprogram (closure), associating the fragment with the
-subprogram as its external environment.  When the closure is executed,
-its environment will look like this:
-
address@hidden
-      block          Top-level: foo
-  +-------------+
-  |local var: b |       fragment
-  +-------------+     .-----------,
-  |external link|---->|variable: a|
-  +-------------+     `-----------'
address@hidden example
-
-The fragment remains as long as the closure exists.
-
address@hidden Addressing mode
-
-Guile VM has five addressing modes:
-
address@hidden
address@hidden Real address
address@hidden Local position
address@hidden External position
address@hidden Top-level location
address@hidden Constant object
address@hidden itemize
-
-Real address points to the address in the real program and is only used
-with the program counter (pc).
-
-Local position and external position are represented as a pair of depth
-and offset from bp, as described above.  These are base relative
-addresses, and the real address may vary during execution.
-
-Top-level location is represented as a Guile's vcell.  This location is
-determined at loading time, so the use of this address is efficient.
-
-Constant object is not an address but gives an instruction an Scheme
-object directly.
-
-[ We'll also need dynamic scope addressing to support Emacs Lisp? ]
-
-
-Overall procedure:
-
address@hidden
address@hidden A source program is compiled into a bytecode.
address@hidden A bytecode is given an environment and becomes a program.
address@hidden A VM starts execution, creating a frame for it.
address@hidden Whenever a program calls a subprogram, a new frame is created 
for it.
address@hidden When a program finishes execution, it returns a value, and the VM
-      continues execution of the parent program.
address@hidden When all programs terminated, the VM returns the final value and 
stops.
address@hidden enumerate
-
-
address@hidden Instruction Set, The Compiler, Variable Management, Top
address@hidden Instruction Set
-
-The Guile VM instruction set is roughly divided two groups: system
-instructions and functional instructions.  System instructions control
-the execution of programs, while functional instructions provide many
-useful calculations.
-
address@hidden
-* Environment Control Instructions::  
-* Branch Instructions::         
-* Subprogram Control Instructions::  
-* Data Control Instructions::   
address@hidden menu
-
address@hidden Environment Control Instructions, Branch Instructions, 
Instruction Set, Instruction Set
address@hidden Environment Control Instructions
-
address@hidden @insn{} link binding-name
-Look up @var{binding-name} (a string) in the current environment and
-push the corresponding variable object onto the stack.  If
address@hidden is not bound yet, then create a new binding and
-push its variable object.
address@hidden deffn
-
address@hidden @insn{} variable-ref
-Dereference the variable object which is on top of the stack and
-replace it by the value of the variable it represents.
address@hidden deffn
-
address@hidden @insn{} variable-set
-Set the value of the variable on top of the stack (at @code{sp[0]}) to
-the object located immediately before (at @code{sp[-1]}).
address@hidden deffn
-
-As an example, let us look at what a simple function call looks like:
-
address@hidden
-(+ 2 3)
address@hidden example
-
-This call yields the following sequence of instructions:
-
address@hidden
-(link "+")      ;; lookup binding "+"
-(variable-ref)  ;; dereference it
-(make-int8 2)   ;; push immediate value `2'
-(make-int8 3)   ;; push immediate value `3'
-(tail-call 2)   ;; call the proc at sp[-3] with two args
address@hidden example
-
address@hidden @insn{} local-ref offset
-Push onto the stack the value of the local variable located at
address@hidden within the current stack frame.
address@hidden deffn
-
address@hidden @insn{} local-set offset
-Pop the Scheme object located on top of the stack and make it the new
-value of the local variable located at @var{offset} within the current
-stack frame.
address@hidden deffn
-
address@hidden @insn{} external-ref offset
-Push the value of the closure variable located at position
address@hidden within the program's list of external variables.
address@hidden deffn
-
address@hidden @insn{} external-set offset
-Pop the Scheme object located on top of the stack and make it the new
-value of the closure variable located at @var{offset} within the
-program's list of external variables.
address@hidden deffn
-
address@hidden @insn{} make-closure
-Pop the program object from the stack and assign it the current
-closure variable list as its closure.  Push the result program
-object.
address@hidden deffn
-
-Let's illustrate this:
-
address@hidden
-(let ((x 2))
-  (lambda ()
-    (let ((x++ (+ 1 x)))
-      (set! x x++)
-      x++)))
address@hidden example
-
-The resulting program has one external (closure) variable, i.e. its
address@hidden is set to 1 (@pxref{Subprogram Control Instructions}).
-This yields the following code:
-
address@hidden
-   ;; the traditional program prologue with NLOCS = 0 and NEXTS = 1
-
-   0    (make-int8 2)
-   2    (external-set 0)
-   4    (make-int8 4)
-   6    (link "+")     ;; lookup `+'
-   9    (vector 1)     ;; create the external variable vector for
-                       ;; later use by `object-ref' and `object-set'
-        ...
-  40    (load-program ##34#)
-  59    (make-closure) ;; assign the current closure to the program
-                       ;; just pushed by `load-program'
-  60    (return)
address@hidden example
-
-The program loaded here by @var{load-program} contains the following
-sequence of instructions:
-
address@hidden
-   0    (object-ref 0)     ;; push the variable for `+'
-   2    (variable-ref)     ;; dereference `+'
-   3    (make-int8:1)      ;; push 1
-   4    (external-ref 0)   ;; push the value of `x'
-   6    (call 2)           ;; call `+' and push the result
-   8    (local-set 0)      ;; make it the new value of `x++'
-  10    (local-ref 0)      ;; push the value of `x++'
-  12    (external-set 0)   ;; make it the new value of `x'
-  14    (local-ref 0)      ;; push the value of `x++'
-  16    (return)           ;; return it
address@hidden example
-
-At this point, you should know pretty much everything about the three
-types of variables a program may need to access.
-
-
address@hidden Branch Instructions, Subprogram Control Instructions, 
Environment Control Instructions, Instruction Set
address@hidden Branch Instructions
-
-All the conditional branch instructions described below work in the
-same way:
-
address@hidden
address@hidden They take the Scheme object located on the stack and use it as
-the branch condition;
address@hidden If the condition if false, then program execution continues with
-the next instruction;
address@hidden If the condition is true, then the instruction pointer is
-increased by the offset passed as an argument to the branch
-instruction;
address@hidden Finally, when the instruction finished, the condition object is
-removed from the stack.
address@hidden itemize
-
-Note that the offset passed to the instruction is encoded on two 8-bit
-integers which are then combined by the VM as one 16-bit integer.
-
address@hidden @insn{} br offset
-Jump to @var{offset}.
address@hidden deffn
-
address@hidden @insn{} br-if offset
-Jump to @var{offset} if the condition on the stack is not false.
address@hidden deffn
-
address@hidden @insn{} br-if-not offset
-Jump to @var{offset} if the condition on the stack is false.
address@hidden deffn
-
address@hidden @insn{} br-if-eq offset
-Jump to @var{offset} if the two objects located on the stack are
-equal in the sense of @var{eq?}.  Note that, for this instruction, the
-stack pointer is decremented by two Scheme objects instead of only
-one.
address@hidden deffn
-
address@hidden @insn{} br-if-not-eq offset
-Same as @var{br-if-eq} for non-equal objects.
address@hidden deffn
-
address@hidden @insn{} br-if-null offset
-Jump to @var{offset} if the object on the stack is @code{'()}.
address@hidden deffn
-
address@hidden @insn{} br-if-not-null offset
-Jump to @var{offset} if the object on the stack is not @code{'()}.
address@hidden deffn
-
-
address@hidden Subprogram Control Instructions, Data Control Instructions, 
Branch Instructions, Instruction Set
address@hidden Subprogram Control Instructions
-
-Programs (read: ``compiled procedure'') may refer to external
-bindings, like variables or functions defined outside the program
-itself, in the environment in which it will evaluate at run-time.  In
-a sense, a program's environment and its bindings are an implicit
-parameter of every program.
-
address@hidden object table
-In order to handle such bindings, each program has an @dfn{object
-table} associated to it.  This table (actually a Scheme vector)
-contains all constant objects referenced by the program.  The object
-table of a program is initialized right before a program is loaded
-with @var{load-program}.
-
-Variable objects are one such type of constant object: when a global
-binding is defined, a variable object is associated to it and that
-object will remain constant over time, even if the value bound to it
-changes.  Therefore, external bindings only need to be looked up once
-when the program is loaded.  References to the corresponding external
-variables from within the program are then performed via the
address@hidden instruction and are almost as fast as local variable
-references.
-
-Let us consider the following program (procedure) which references
-external bindings @code{frob} and @var{%magic}:
-
address@hidden
-(lambda (x)
-  (frob x %magic))
address@hidden example
-
-This yields the following assembly code:
-
address@hidden
-(make-int8 64)   ;; number of args, vars, etc. (see below)
-(link "frob")
-(link "%magic")
-(vector 2)       ;; object table (external bindings)
-...
-(load-program #u8(20 0 23 21 0 20 1 23 36 2))
-(return)
address@hidden example
-
-All the instructions occurring before @var{load-program} (some were
-omitted for simplicity) form a @dfn{prologue} which, among other
-things, pushed an object table (a vector) that contains the variable
-objects for the variables bound to @var{frob} and @var{%magic}.  This
-vector and other data pushed onto the stack are then popped by the
address@hidden instruction.
-
-Besides, the @var{load-program} instruction takes one explicit
-argument which is the bytecode of the program itself.  Disassembled,
-this bytecode looks like:
-
address@hidden
-(object-ref 0)  ;; push the variable object of `frob'
-(variable-ref)  ;; dereference it
-(local-ref 0)   ;; push the value of `x'
-(object-ref 1)  ;; push the variable object of `%magic'
-(variable-ref)  ;; dereference it
-(tail-call 2)   ;; call `frob' with two parameters
address@hidden example
-
-This clearly shows that there is little difference between references
-to local variables and references to externally bound variables since
-lookup of externally bound variables if performed only once before the
-program is run.
-
address@hidden @insn{} load-program bytecode
-Load the program whose bytecode is @var{bytecode} (a u8vector), pop
-its meta-information from the stack, and push a corresponding program
-object onto the stack.  The program's meta-information may consist of
-(in the order in which it should be pushed onto the stack):
-
address@hidden
address@hidden optionally, a pair representing meta-data (see the
address@hidden procedure); [FIXME: explain their meaning]
address@hidden optionally, a vector which is the program's object table (a
-program that does not reference external bindings does not need an
-object table);
address@hidden either one immediate integer or four immediate integers
-representing respectively the number of arguments taken by the
-function (@var{nargs}), the number of @dfn{rest arguments}
-(@var{nrest}, 0 or 1), the number of local variables (@var{nlocs}) and
-the number of external variables (@var{nexts}) (@pxref{Environment
-Control Instructions}).
address@hidden itemize
-
address@hidden deffn
-
address@hidden @insn{} object-ref offset
-Push the variable object for the external variable located at
address@hidden within the program's object table.
address@hidden deffn
-
address@hidden @insn{} return
-Free the program's frame.
address@hidden deffn
-
address@hidden @insn{} call nargs
-Call the procedure, continuation or program located at
address@hidden with the @var{nargs} arguments located from
address@hidden to @code{sp[-nargs + 1]}.  The
-procedure/continuation/program and its arguments are dropped from the
-stack and the result is pushed.  When calling a program, the
address@hidden instruction reserves room for its local variables on the
-stack, and initializes its list of closure variables and its vector of
-externally bound variables.
address@hidden deffn
-
address@hidden @insn{} tail-call nargs
-Same as @code{call} except that, for tail-recursive calls to a
-program, the current stack frame is re-used, as required by RnRS.
-This instruction is otherwise similar to @code{call}.
address@hidden deffn
-
-
address@hidden Data Control Instructions,  , Subprogram Control Instructions, 
Instruction Set
address@hidden Data Control Instructions
-
address@hidden @insn{} make-int8 value
-Push @var{value}, an 8-bit integer, onto the stack.
address@hidden deffn
-
address@hidden @insn{} make-int8:0
-Push the immediate value @code{0} onto the stack.
address@hidden deffn
-
address@hidden @insn{} make-int8:1
-Push the immediate value @code{1} onto the stack.
address@hidden deffn
-
address@hidden @insn{} make-false
-Push @code{#f} onto the stack.
address@hidden deffn
-
address@hidden @insn{} make-true
-Push @code{#t} onto the stack.
address@hidden deffn
-
address@hidden
address@hidden %push
address@hidden %pushi
address@hidden %pushl, %pushl:0:0, %pushl:0:1, %pushl:0:2, %pushl:0:3
address@hidden %pushe, %pushe:0:0, %pushe:0:1, %pushe:0:2, %pushe:0:3
address@hidden %pusht
address@hidden itemize
-
address@hidden
address@hidden %loadi
address@hidden %loadl, %loadl:0:0, %loadl:0:1, %loadl:0:2, %loadl:0:3
address@hidden %loade, %loade:0:0, %loade:0:1, %loade:0:2, %loade:0:3
address@hidden %loadt
address@hidden itemize
-
address@hidden
address@hidden %savei
address@hidden %savel, %savel:0:0, %savel:0:1, %savel:0:2, %savel:0:3
address@hidden %savee, %savee:0:0, %savee:0:1, %savee:0:2, %savee:0:3
address@hidden %savet
address@hidden itemize
-
address@hidden Flow control instructions
-
address@hidden
address@hidden %br-if
address@hidden %br-if-not
address@hidden %jump
address@hidden itemize
-
address@hidden Function call instructions
-
address@hidden
address@hidden %func, %func0, %func1, %func2
address@hidden itemize
-
address@hidden Scheme built-in functions
-
address@hidden
address@hidden cons
address@hidden car
address@hidden cdr
address@hidden itemize
-
address@hidden Mathematical buitin functions
-
address@hidden
address@hidden 1+
address@hidden 1-
address@hidden add, add2
address@hidden sub, sub2, minus
address@hidden mul2
address@hidden div2
address@hidden lt2
address@hidden gt2
address@hidden le2
address@hidden ge2
address@hidden num-eq2
address@hidden itemize
-
-
-
address@hidden The Compiler, Concept Index, Instruction Set, Top
address@hidden The Compiler
-
-This section describes Guile-VM's compiler and the compilation process
-to produce bytecode executable by the VM itself (@pxref{Instruction
-Set}).
-
address@hidden
-* Overview::                    
-* The Language Front-Ends::     
-* GHIL::                        
-* Compiling Scheme Code::       
-* GLIL::                        
-* The Assembler::               
address@hidden menu
-
address@hidden Overview, The Language Front-Ends, The Compiler, The Compiler
address@hidden Overview
-
-Compilation in Guile-VM is a three-stage process:
-
address@hidden intermediate language
address@hidden assembler
address@hidden compiler
address@hidden GHIL
address@hidden GLIL
address@hidden bytecode
-
address@hidden
address@hidden the source programming language (e.g. R5RS Scheme) is read and
-translated into GHIL, @dfn{Guile's High-Level Intermediate Language};
address@hidden GHIL code is then translated into a lower-level intermediate
-language call GLIL, @dfn{Guile's Low-Level Intermediate Language};
address@hidden finally, GLIL is @dfn{assembled} into the VM's assembly language
-(@pxref{Instruction Set}) and bytecode.
address@hidden enumerate
-
-The use of two separate intermediate languages eases the
-implementation of front-ends since the gap between high-level
-languages like Scheme and GHIL is relatively small.
-
address@hidden guilec
-From an end-user viewpoint, compiling a Guile program into bytecode
-can be done either by using the @command{guilec} command-line tool, or
-by using the @code{compile-file} procedure exported by the
address@hidden(system base compile)} module.
-
address@hidden @scmproc{} compile-file file . opts
-Compile Scheme source code from file @var{file} using compilation
-options @var{opts}.  The resulting file, a Guile object file, will be
-name according the application of the @code{compiled-file-name}
-procedure to @var{file}.  The possible values for @var{opts} are the
-same as for the @code{compile-in} procedure (see below, @pxref{The Language
-Front-Ends}).
address@hidden deffn
-
address@hidden @scmproc{} compiled-file-name file
-Given source file name @var{file} (a string), return a string that
-denotes the name of the Guile object file corresponding to
address@hidden  By default, the file name returned is @var{file} minus
-its extension and plus the @code{.go} file extension.
address@hidden deffn
-
address@hidden self-hosting
-It is worth noting, as you might have already guessed, that Guile-VM's
-compiler is written in Guile Scheme and is @dfn{self-hosted}: it can
-compile itself.
-
address@hidden The Language Front-Ends, GHIL, Overview, The Compiler
address@hidden The Language Front-Ends
-
-Guile-VM comes with a number of @dfn{language front-ends}, that is,
-code that can read a given high-level programming language like R5RS
-Scheme, and translate it into a lower-level representation suitable to
-the compiler.
-
-Each language front-end provides a @dfn{specification} and a
address@hidden to GHIL.  Both of them come in the @code{language}
-module hierarchy.  As an example, the front-end for Scheme is located
-in the @code{(language scheme spec)} and @code{(language scheme
-translate)} modules.  Language front-ends can then be retrieved using
-the @code{lookup-language} procedure of the @code{(system base
-language)} module.
-
address@hidden @scmrec{} <language> name title version reader printer read-file 
expander translator evaluator environment
-Denotes a language front-end specification a various methods used by
-the compiler to handle source written in that language.  Of particular
-interest is the @code{translator} slot (@pxref{GHIL}).
address@hidden deftp
-
address@hidden @scmproc{} lookup-language lang
-Look for a language front-end named @var{lang}, a symbol (e.g,
address@hidden), and return the @code{<language>} record describing it
-if found.  If @var{lang} does not denote a language front-end, an
-error is raised.  Note that this procedure assumes that language
address@hidden exists if there exist a @code{(language @var{lang} spec)}
-module.
address@hidden deffn
-
-The @code{(system base compile)} module defines a procedure similar to
address@hidden but that is not limited to the Scheme language:
-
address@hidden @scmproc{} compile-in expr env lang . opts
-Compile expression @var{expr}, which is written in language @var{lang}
-(a @code{<language>} object), using compilation options @var{opts},
-and return bytecode as produced by the assembler (@pxref{The
-Assembler}).
-
-Options @var{opts} may contain the following keywords:
-
address@hidden @code
address@hidden :e
-compilation will stop after the code expansion phase.
address@hidden :t
-compilation will stop after the code translation phase, i.e. after
-code in the source language @var{lang} has been translated into GHIL
-(@pxref{GHIL}).
address@hidden :c
-compilation will stop after the compilation phase and before the
-assembly phase, i.e. once GHIL has been translated into GLIL
-(@pxref{GLIL}).
address@hidden table
-
-Additionally, @var{opts} may contain any option understood by the
-GHIL-to-GLIL compiler described in @xref{GLIL}.
address@hidden deffn
-
-
address@hidden GHIL, Compiling Scheme Code, The Language Front-Ends, The 
Compiler
address@hidden Guile's High-Level Intermediate Language
-
-GHIL has constructs almost equivalent to those found in Scheme.
-However, unlike Scheme, it is meant to be read only by the compiler
-itself.  Therefore, a sequence of GHIL code is only a sequence of GHIL
address@hidden (records), as opposed to symbols, each of which
-represents a particular language feature.  These records are all
-defined in the @code{(system il ghil)} module and are named
address@hidden<ghil-*>}.
-
-Each GHIL record has at least two fields: one containing the
-environment (Guile module) in which it is considered, and one
-containing its location [FIXME: currently seems to be unused].  Below
-is a list of the main GHIL object types and their fields:
-
address@hidden
-;; Objects
-(<ghil-void> env loc)
-(<ghil-quote> env loc obj)
-(<ghil-quasiquote> env loc exp)
-(<ghil-unquote> env loc exp)
-(<ghil-unquote-splicing> env loc exp)
-;; Variables
-(<ghil-ref> env loc var)
-(<ghil-set> env loc var val)
-(<ghil-define> env loc var val)
-;; Controls
-(<ghil-if> env loc test then else)
-(<ghil-and> env loc exps)
-(<ghil-or> env loc exps)
-(<ghil-begin> env loc exps)
-(<ghil-bind> env loc vars vals body)
-(<ghil-lambda> env loc vars rest body)
-(<ghil-call> env loc proc args)
-(<ghil-inline> env loc inline args)
address@hidden example
-
-As can be seen from this examples, the constructs in GHIL are pretty
-close to the fundamental primitives of Scheme.
-
-It is the role of front-end language translators (@pxref{The Language
-Front-Ends}) to produce a sequence of GHIL objects from the
-human-readable, source programming language.  The next section
-describes the translator for the Scheme language.
-
address@hidden Compiling Scheme Code, GLIL, GHIL, The Compiler
address@hidden Compiling Scheme Code
-
-The language object for Scheme, as returned by @code{(lookup-language
-'scheme)} (@pxref{The Language Front-Ends}), defines a translator
-procedure that returns a sequence of GHIL objects given Scheme code.
-Before actually performing this operation, the Scheme translator
-expands macros in the original source code.
-
-The macros that may be expanded can come from different sources:
-
address@hidden
address@hidden core Guile macros, such as @code{false-if-exception};
address@hidden macros defined in modules used by the module being compiled,
-e.g., @code{receive} in @code{(ice-9 receive)};
address@hidden macros defined within the module being compiled.
address@hidden itemize
-
address@hidden macro
address@hidden syntax transformer
address@hidden define-macro
address@hidden defmacro
-The main complexity in handling macros at compilation time is that
-Guile's macros are first-class objects.  For instance, when using
address@hidden, one actually defines a @emph{procedure} that
-returns code; of course, unlike a ``regular'' procedure, it is
-executed when an S-exp is @dfn{memoized} by the evaluator, i.e.,
-before the actual evaluation takes place.  Worse, it is possible to
-turn a procedure into a macro, or @dfn{syntax transformer}, thus
-removing, to some extent, the boundary between the macro expansion and
-evaluation phases, @inforef{Internal Macros, , guile}.
-
-[FIXME: explain limitations, etc.]
-
-
address@hidden GLIL, The Assembler, Compiling Scheme Code, The Compiler
address@hidden Guile's Low-Level Intermediate Language
-
-A GHIL instruction sequence can be compiled into GLIL using the
address@hidden procedure exported by the @code{(system il compile)}
-module.  During this translation process, various optimizations may
-also be performed.
-
-The module @code{(system il glil)} defines record types representing
-various low-level abstractions.  Compared to GHIL, the flow control
-primitives in GLIL are much more low-level:  only @code{<glil-label>},
address@hidden<glil-branch>} and @code{<glil-call>} are available, no
address@hidden, @code{if}, etc.
-
-
address@hidden @scmproc{} compile ghil environment . opts
-Compile @var{ghil}, a GHIL instruction sequence, within
-environment/module @var{environment}, and return the resulting GLIL
-instruction sequence.  The option list @var{opts} may be either the
-empty list or a list containing the @code{:O} keyword in which case
address@hidden will first go through an optimization stage of
address@hidden
-
-Note that the @code{:O} option may be passed at a higher-level to the
address@hidden and @code{compile-in} procedures (@pxref{The
-Language Front-Ends}).
address@hidden deffn
-
address@hidden @scmproc{} pprint-glil glil . port
-Print @var{glil}, a GLIL sequence instructions, in a human-readable
-form.  If @var{port} is passed, it will be used as the output port.
address@hidden deffn
-
-
-Let's consider the following Scheme expression:
-
address@hidden
-(lambda (x) (+ x 1))
address@hidden example
-
-The corresponding (unoptimized) GLIL code, as shown by
address@hidden, looks like this:
-
address@hidden
-(@@asm (0 0 0 0)
-  (@@asm (1 0 0 0)           ;; expect one arg.
-    (@@bind (x argument 0))  ;; debugging info
-    (module-ref #f +)       ;; lookup `+'
-    (argument-ref 0)        ;; push the argument onto
-                            ;; the stack
-    (const 1)               ;; push `1'
-    (tail-call 2)           ;; call `+', with 2 args,
-                            ;; using the same stack frame
-    (@@source 15 33))        ;; additional debugging info
-  (return 0))
address@hidden example
-
-This is not unlike the VM's assembly language described in
address@hidden Set}.
-
address@hidden The Assembler,  , GLIL, The Compiler
address@hidden The Assembler
-
address@hidden code->bytes
-
-The final compilation step consists in converting the GLIL instruction
-sequence into VM bytecode.  This is what the @code{assemble} procedure
-defined in the @code{(system vm assemble)} module is for.  It relies
-on the @code{code->bytes} procedure of the @code{(system vm conv)}
-module to convert instructions (represented as lists whose @code{car}
-is a symbol naming the instruction, e.g. @code{object-ref},
address@hidden Set}) into binary code, or @dfn{bytecode}.
-Bytecode itself is represented using SRFI-4 byte vectors,
address@hidden, SRFI-4 homogeneous numeric vectors, guile}.
-
-
address@hidden @scmproc{} assemble glil environment . opts
-Return a binary representation of @var{glil} (bytecode), either in the
-form of an SRFI-4 @code{u8vector} or a @code{<bytespec>} object.
-[FIXME:  Why is that?]
address@hidden deffn
-
-
-
address@hidden 
*********************************************************************
address@hidden Concept Index, Function and Instruction Index, The Compiler, Top
address@hidden Concept Index
address@hidden cp
-
address@hidden Function and Instruction Index, Command and Variable Index, 
Concept Index, Top
address@hidden Function and Instruction Index
address@hidden fn
-
address@hidden Command and Variable Index,  , Function and Instruction Index, 
Top
address@hidden Command and Variable Index
address@hidden vr
-
address@hidden
-
address@hidden Local Variables:
address@hidden ispell-local-dictionary: "american";
address@hidden End:
-
address@hidden  LocalWords:  bytecode
diff --git a/doc/maint/docstring.el b/doc/maint/docstring.el
index 2b5639e..ef27193 100644
--- a/doc/maint/docstring.el
+++ b/doc/maint/docstring.el
@@ -2,22 +2,22 @@
 ;;;
 ;;; Copyright (C) 2001, 2004 Neil Jerram
 ;;;
-;;; This file is not part of GNU Emacs, but the same permissions apply.
+;;; This file is not part of GUILE, but the same permissions apply.
 ;;;
-;;; GNU Emacs is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
+;;; GUILE 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.
 ;;;
-;;; GNU Emacs 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 General Public License for more details.
+;;; GUILE 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 General Public License
-;;; along with GNU Emacs; see the file COPYING.  If not, write to the
-;;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;;; Boston, MA 02110-1301, USA.
+;;; You should have received a copy of the GNU Lesser General Public
+;;; License along with GUILE; see the file COPYING.LESSER.  If not,
+;;; write to the Free Software Foundation, Inc., 51 Franklin Street,
+;;; Fifth Floor, Boston, MA 02110-1301, USA.
 
 ;;; Commentary:
 
diff --git a/doc/oldfmt.c b/doc/oldfmt.c
index fc82ba9..f60afed 100644
--- a/doc/oldfmt.c
+++ b/doc/oldfmt.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2000,2001, 2006, 2008 Free Software Foundation, Inc.
  * 
- * This library 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 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * 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
  */
 
 
diff --git a/doc/r5rs/Makefile.am b/doc/r5rs/Makefile.am
index 4af0c95..c64e4ff 100644
--- a/doc/r5rs/Makefile.am
+++ b/doc/r5rs/Makefile.am
@@ -4,20 +4,20 @@
 ##
 ##   This file is part of GUILE.
 ##   
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
-##   
+##
 ##   GUILE 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 General Public License for more details.
-##   
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   GNU Lesser General Public License for more details.
+##
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 AUTOMAKE_OPTIONS = gnu
 
diff --git a/doc/ref/Makefile.am b/doc/ref/Makefile.am
index 9d73e5d..abf42ed 100644
--- a/doc/ref/Makefile.am
+++ b/doc/ref/Makefile.am
@@ -4,20 +4,20 @@
 ##
 ##   This file is part of GUILE.
 ##
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
 ##
 ##   GUILE 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 General Public License for more details.
+##   GNU Lesser General Public License for more details.
 ##
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 AUTOMAKE_OPTIONS = gnu
 
diff --git a/doc/ref/api-compound.texi b/doc/ref/api-compound.texi
index f3fe958..8d0e02f 100644
--- a/doc/ref/api-compound.texi
+++ b/doc/ref/api-compound.texi
@@ -1,6 +1,6 @@
 @c -*-texinfo-*-
 @c This is part of the GNU Guile Reference Manual.
address@hidden Copyright (C)  1996, 1997, 2000, 2001, 2002, 2003, 2004, 2005, 
2006, 2007
address@hidden Copyright (C)  1996, 1997, 2000, 2001, 2002, 2003, 2004, 2005, 
2006, 2007, 2009
 @c   Free Software Foundation, Inc.
 @c See the file guile.texi for copying conditions.
 
@@ -1405,6 +1405,12 @@ C}), but returns a pointer to the elements of a uniform 
numeric vector
 of the indicated kind.
 @end deftypefn
 
+Uniform numeric vectors can be written to and read from input/output
+ports using the procedures listed below.  However, bytevectors may often
+be more convenient for binary input/output since they provide more
+flexibility in the interpretation of raw byte sequences
+(@pxref{Bytevectors}).
+
 @deffn {Scheme Procedure} uniform-vector-read! uvec [port_or_fd [start [end]]]
 @deffnx {C Function} scm_uniform_vector_read_x (uvec, port_or_fd, start, end)
 Fill the elements of @var{uvec} by reading
@@ -1643,9 +1649,9 @@ and writing.
 @subsection Generalized Vectors
 
 Guile has a number of data types that are generally vector-like:
-strings, uniform numeric vectors, bitvectors, and of course ordinary
-vectors of arbitrary Scheme values.  These types are disjoint: a
-Scheme value belongs to at most one of the four types listed above.
+strings, uniform numeric vectors, bytevectors, bitvectors, and of course
+ordinary vectors of arbitrary Scheme values.  These types are disjoint:
+a Scheme value belongs to at most one of the four types listed above.
 
 If you want to gloss over this distinction and want to treat all four
 types with common code, you can use the procedures in this section.
@@ -1743,9 +1749,9 @@ matrix with zero columns and 3 rows is different from a 
matrix with 3
 columns and zero rows, which again is different from a vector of
 length zero.
 
-Generalized vectors, such as strings, uniform numeric vectors, bit
-vectors and ordinary vectors, are the special case of one dimensional
-arrays.
+Generalized vectors, such as strings, uniform numeric vectors,
+bytevectors, bit vectors and ordinary vectors, are the special case of
+one dimensional arrays.
 
 @menu
 * Array Syntax::                
@@ -1828,6 +1834,16 @@ is a rank-zero array with contents 12.
 
 @end table
 
+In addition, bytevectors are also arrays, but use a different syntax
+(@pxref{Bytevectors}):
+
address@hidden @code
+
address@hidden #vu8(1 2 3)
+is a 3-byte long bytevector, with contents 1, 2, 3.
+
address@hidden table
+
 @node Array Procedures
 @subsubsection Array Procedures
 
diff --git a/doc/ref/api-data.texi b/doc/ref/api-data.texi
index b529199..4401ef1 100755
--- a/doc/ref/api-data.texi
+++ b/doc/ref/api-data.texi
@@ -1,6 +1,6 @@
 @c -*-texinfo-*-
 @c This is part of the GNU Guile Reference Manual.
address@hidden Copyright (C)  1996, 1997, 2000, 2001, 2002, 2003, 2004, 2006, 
2007, 2008
address@hidden Copyright (C)  1996, 1997, 2000, 2001, 2002, 2003, 2004, 2006, 
2007, 2008, 2009
 @c   Free Software Foundation, Inc.
 @c See the file guile.texi for copying conditions.
 
@@ -45,6 +45,7 @@ For the documentation of such @dfn{compound} data types, see
 * Characters::                  Single characters.
 * Character Sets::              Sets of characters.
 * Strings::                     Sequences of characters.
+* Bytevectors::                 Sequences of bytes.
 * Regular Expressions::         Pattern matching and substitution.
 * Symbols::                     Symbols.
 * Keywords::                    Self-quoting, customizable display keywords.
@@ -3746,6 +3747,443 @@ is larger than @var{max_len}, only @var{max_len} bytes 
have been
 stored and you probably need to try again with a larger buffer.
 @end deftypefn
 
address@hidden Bytevectors
address@hidden Bytevectors
+
address@hidden bytevector
address@hidden R6RS
+
+A @dfn{bytevector} is a raw bit string.  The @code{(rnrs bytevector)}
+module provides the programming interface specified by the
address@hidden://www.r6rs.org/, Revised Report^6 on the Algorithmic Language
+Scheme (R6RS)}.  It contains procedures to manipulate bytevectors and
+interpret their contents in a number of ways: bytevector contents can be
+accessed as signed or unsigned integer of various sizes and endianness,
+as IEEE-754 floating point numbers, or as strings.  It is a useful tool
+to encode and decode binary data.
+
+The R6RS (Section 4.3.4) specifies an external representation for
+bytevectors, whereby the octets (integers in the range 0--255) contained
+in the bytevector are represented as a list prefixed by @code{#vu8}:
+
address@hidden
+#vu8(1 53 204)
address@hidden lisp
+
+denotes a 3-byte bytevector containing the octets 1, 53, and 204.  Like
+string literals, booleans, etc., bytevectors are ``self-quoting'', i.e.,
+they do not need to be quoted:
+
address@hidden
+#vu8(1 53 204)
address@hidden #vu8(1 53 204)
address@hidden lisp
+
+Bytevectors can be used with the binary input/output primitives of the
+R6RS (@pxref{R6RS I/O Ports}).
+
address@hidden
+* Bytevector Endianness::       Dealing with byte order.
+* Bytevector Manipulation::     Creating, copying, manipulating bytevectors.
+* Bytevectors as Integers::     Interpreting bytes as integers.
+* Bytevectors and Integer Lists::  Converting to/from an integer list.
+* Bytevectors as Floats::       Interpreting bytes as real numbers.
+* Bytevectors as Strings::      Interpreting bytes as Unicode strings.
+* Bytevectors as Generalized Vectors::  Guile extension to the bytevector API.
address@hidden menu
+
address@hidden Bytevector Endianness
address@hidden Endianness
+
address@hidden endianness
address@hidden byte order
address@hidden word order
+
+Some of the following procedures take an @var{endianness} parameter.
+The @dfn{endianness} is defined is defined as the order of bytes in
+multi-byte numbers: numbers encoded in @dfn{big endian} have their most
+significant bytes written first, whereas numbers encoded in @dfn{little
+endian} have their least significant bytes address@hidden and little
+endian are the most common ``endiannesses'' but others exist.  For
+instance, the GNU MP library allows @dfn{word order} to be specified
+independently of @dfn{byte order} (@pxref{Integer Import and Export,,,
+gmp, The GNU Multiple Precision Arithmetic Library Manual}).}  Little
+endian is the native endianness of the IA32 architecture and its
+derivatives, while big endian is native to SPARC and PowerPC, among
+others.  The @code{native-endianness} procedure returns the native
+endianness of the machine it runs on.
+
address@hidden {Scheme Procedure} native-endianness
address@hidden {C Function} scm_native_endianness ()
+Return a value denoting the native endianness of the host machine.
address@hidden deffn
+
address@hidden {Scheme Macro} endianness symbol
+Return an object denoting the endianness specified by @var{symbol}.  If
address@hidden is neither @code{big} nor @code{little} then a compile-time
+error is raised.
address@hidden deffn
+
address@hidden {C Variable} scm_endianness_big
address@hidden {C Variable} scm_endianness_little
+The objects denoting big (resp. little) endianness.
address@hidden defvr
+
+
address@hidden Bytevector Manipulation
address@hidden Manipulating Bytevectors
+
+Bytevectors can be created, copied, and analyzed with the following
+procedures and C functions.
+
address@hidden {Scheme Procedure} make-bytevector len [fill]
address@hidden {C Function} scm_make_bytevector (len, fill)
address@hidden {C Function} scm_c_make_bytevector (size_t len)
+Return a new bytevector of @var{len} bytes.  Optionally, if @var{fill}
+is given, fill it with @var{fill}; @var{fill} must be in the range
+[-128,255].
address@hidden deffn
+
address@hidden {Scheme Procedure} bytevector? obj
address@hidden {C Function} scm_bytevector_p (obj)
+Return true if @var{obj} is a bytevector.
address@hidden deffn
+
address@hidden {C Function} int scm_is_bytevector (SCM obj)
+Equivalent to @code{scm_is_true (scm_bytevector_p (obj))}.
address@hidden deftypefn
+
address@hidden {Scheme Procedure} bytevector-length bv
address@hidden {C Function} scm_bytevector_length (bv)
+Return the length in bytes of bytevector @var{bv}.
address@hidden deffn
+
address@hidden {C Function} size_t scm_c_bytevector_length (SCM bv)
+Likewise, return the length in bytes of bytevector @var{bv}.
address@hidden deftypefn
+
address@hidden {Scheme Procedure} bytevector=? bv1 bv2
address@hidden {C Function} scm_bytevector_eq_p (bv1, bv2)
+Return is @var{bv1} equals to @var{bv2}---i.e., if they have the same
+length and contents.
address@hidden deffn
+
address@hidden {Scheme Procedure} bytevector-fill! bv fill
address@hidden {C Function} scm_bytevector_fill_x (bv, fill)
+Fill bytevector @var{bv} with @var{fill}, a byte.
address@hidden deffn
+
address@hidden {Scheme Procedure} bytevector-copy! source source-start target 
target-start len
address@hidden {C Function} scm_bytevector_copy_x (source, source_start, 
target, target_start, len)
+Copy @var{len} bytes from @var{source} into @var{target}, starting
+reading from @var{source-start} (a positive index within @var{source})
+and start writing at @var{target-start}.
address@hidden deffn
+
address@hidden {Scheme Procedure} bytevector-copy bv
address@hidden {C Function} scm_bytevector_copy (bv)
+Return a newly allocated copy of @var{bv}.
address@hidden deffn
+
address@hidden {C Function} scm_t_uint8 scm_c_bytevector_ref (SCM bv, size_t 
index)
+Return the byte at @var{index} in bytevector @var{bv}.
address@hidden deftypefn
+
address@hidden {C Function} void scm_c_bytevector_set_x (SCM bv, size_t index, 
scm_t_uint8 value)
+Set the byte at @var{index} in @var{bv} to @var{value}.
address@hidden deftypefn
+
+Low-level C macros are available.  They do not perform any
+type-checking; as such they should be used with care.
+
address@hidden {C Macro} size_t SCM_BYTEVECTOR_LENGTH (bv)
+Return the length in bytes of bytevector @var{bv}.
address@hidden deftypefn
+
address@hidden {C Macro} {signed char *} SCM_BYTEVECTOR_CONTENTS (bv)
+Return a pointer to the contents of bytevector @var{bv}.
address@hidden deftypefn
+
+
address@hidden Bytevectors as Integers
address@hidden Interpreting Bytevector Contents as Integers
+
+The contents of a bytevector can be interpreted as a sequence of
+integers of any given size, sign, and endianness.
+
address@hidden
+(let ((bv (make-bytevector 4)))
+  (bytevector-u8-set! bv 0 #x12)
+  (bytevector-u8-set! bv 1 #x34)
+  (bytevector-u8-set! bv 2 #x56)
+  (bytevector-u8-set! bv 3 #x78)
+
+  (map (lambda (number)
+         (number->string number 16))
+       (list (bytevector-u8-ref bv 0)
+             (bytevector-u16-ref bv 0 (endianness big))
+             (bytevector-u32-ref bv 0 (endianness little)))))
+
address@hidden ("12" "1234" "78563412")
address@hidden lisp
+
+The most generic procedures to interpret bytevector contents as integers
+are described below.
+
address@hidden {Scheme Procedure} bytevector-uint-ref bv index endianness size
address@hidden {Scheme Procedure} bytevector-sint-ref bv index endianness size
address@hidden {C Function} scm_bytevector_uint_ref (bv, index, endianness, 
size)
address@hidden {C Function} scm_bytevector_sint_ref (bv, index, endianness, 
size)
+Return the @var{size}-byte long unsigned (resp. signed) integer at
+index @var{index} in @var{bv}, decoded according to @var{endianness}.
address@hidden deffn
+
address@hidden {Scheme Procedure} bytevector-uint-set! bv index value 
endianness size
address@hidden {Scheme Procedure} bytevector-sint-set! bv index value 
endianness size
address@hidden {C Function} scm_bytevector_uint_set_x (bv, index, value, 
endianness, size)
address@hidden {C Function} scm_bytevector_sint_set_x (bv, index, value, 
endianness, size)
+Set the @var{size}-byte long unsigned (resp. signed) integer at
address@hidden to @var{value}, encoded according to @var{endianness}.
address@hidden deffn
+
+The following procedures are similar to the ones above, but specialized
+to a given integer size:
+
address@hidden {Scheme Procedure} bytevector-u8-ref bv index
address@hidden {Scheme Procedure} bytevector-s8-ref bv index
address@hidden {Scheme Procedure} bytevector-u16-ref bv index endianness
address@hidden {Scheme Procedure} bytevector-s16-ref bv index endianness
address@hidden {Scheme Procedure} bytevector-u32-ref bv index endianness
address@hidden {Scheme Procedure} bytevector-s32-ref bv index endianness
address@hidden {Scheme Procedure} bytevector-u64-ref bv index endianness
address@hidden {Scheme Procedure} bytevector-s64-ref bv index endianness
address@hidden {C Function} scm_bytevector_u8_ref (bv, index)
address@hidden {C Function} scm_bytevector_s8_ref (bv, index)
address@hidden {C Function} scm_bytevector_u16_ref (bv, index, endianness)
address@hidden {C Function} scm_bytevector_s16_ref (bv, index, endianness)
address@hidden {C Function} scm_bytevector_u32_ref (bv, index, endianness)
address@hidden {C Function} scm_bytevector_s32_ref (bv, index, endianness)
address@hidden {C Function} scm_bytevector_u64_ref (bv, index, endianness)
address@hidden {C Function} scm_bytevector_s64_ref (bv, index, endianness)
+Return the unsigned @var{n}-bit (signed) integer (where @var{n} is 8,
+16, 32 or 64) from @var{bv} at @var{index}, decoded according to
address@hidden
address@hidden deffn
+
address@hidden {Scheme Procedure} bytevector-u8-set! bv index value
address@hidden {Scheme Procedure} bytevector-s8-set! bv index value
address@hidden {Scheme Procedure} bytevector-u16-set! bv index value endianness
address@hidden {Scheme Procedure} bytevector-s16-set! bv index value endianness
address@hidden {Scheme Procedure} bytevector-u32-set! bv index value endianness
address@hidden {Scheme Procedure} bytevector-s32-set! bv index value endianness
address@hidden {Scheme Procedure} bytevector-u64-set! bv index value endianness
address@hidden {Scheme Procedure} bytevector-s64-set! bv index value endianness
address@hidden {C Function} scm_bytevector_u8_set_x (bv, index, value)
address@hidden {C Function} scm_bytevector_s8_set_x (bv, index, value)
address@hidden {C Function} scm_bytevector_u16_set_x (bv, index, value, 
endianness)
address@hidden {C Function} scm_bytevector_s16_set_x (bv, index, value, 
endianness)
address@hidden {C Function} scm_bytevector_u32_set_x (bv, index, value, 
endianness)
address@hidden {C Function} scm_bytevector_s32_set_x (bv, index, value, 
endianness)
address@hidden {C Function} scm_bytevector_u64_set_x (bv, index, value, 
endianness)
address@hidden {C Function} scm_bytevector_s64_set_x (bv, index, value, 
endianness)
+Store @var{value} as an @var{n}-bit (signed) integer (where @var{n} is
+8, 16, 32 or 64) in @var{bv} at @var{index}, encoded according to
address@hidden
address@hidden deffn
+
+Finally, a variant specialized for the host's endianness is available
+for each of these functions (with the exception of the @code{u8}
+accessors, for obvious reasons):
+
address@hidden {Scheme Procedure} bytevector-u16-native-ref bv index
address@hidden {Scheme Procedure} bytevector-s16-native-ref bv index
address@hidden {Scheme Procedure} bytevector-u32-native-ref bv index
address@hidden {Scheme Procedure} bytevector-s32-native-ref bv index
address@hidden {Scheme Procedure} bytevector-u64-native-ref bv index
address@hidden {Scheme Procedure} bytevector-s64-native-ref bv index
address@hidden {C Function} scm_bytevector_u16_native_ref (bv, index)
address@hidden {C Function} scm_bytevector_s16_native_ref (bv, index)
address@hidden {C Function} scm_bytevector_u32_native_ref (bv, index)
address@hidden {C Function} scm_bytevector_s32_native_ref (bv, index)
address@hidden {C Function} scm_bytevector_u64_native_ref (bv, index)
address@hidden {C Function} scm_bytevector_s64_native_ref (bv, index)
+Return the unsigned @var{n}-bit (signed) integer (where @var{n} is 8,
+16, 32 or 64) from @var{bv} at @var{index}, decoded according to the
+host's native endianness.
address@hidden deffn
+
address@hidden {Scheme Procedure} bytevector-u16-native-set! bv index value
address@hidden {Scheme Procedure} bytevector-s16-native-set! bv index value
address@hidden {Scheme Procedure} bytevector-u32-native-set! bv index value
address@hidden {Scheme Procedure} bytevector-s32-native-set! bv index value
address@hidden {Scheme Procedure} bytevector-u64-native-set! bv index value
address@hidden {Scheme Procedure} bytevector-s64-native-set! bv index value
address@hidden {C Function} scm_bytevector_u16_native_set_x (bv, index, value)
address@hidden {C Function} scm_bytevector_s16_native_set_x (bv, index, value)
address@hidden {C Function} scm_bytevector_u32_native_set_x (bv, index, value)
address@hidden {C Function} scm_bytevector_s32_native_set_x (bv, index, value)
address@hidden {C Function} scm_bytevector_u64_native_set_x (bv, index, value)
address@hidden {C Function} scm_bytevector_s64_native_set_x (bv, index, value)
+Store @var{value} as an @var{n}-bit (signed) integer (where @var{n} is
+8, 16, 32 or 64) in @var{bv} at @var{index}, encoded according to the
+host's native endianness.
address@hidden deffn
+
+
address@hidden Bytevectors and Integer Lists
address@hidden Converting Bytevectors to/from Integer Lists
+
+Bytevector contents can readily be converted to/from lists of signed or
+unsigned integers:
+
address@hidden
+(bytevector->sint-list (u8-list->bytevector (make-list 4 255))
+                       (endianness little) 2)
address@hidden (-1 -1)
address@hidden lisp
+
address@hidden {Scheme Procedure} bytevector->u8-list bv
address@hidden {C Function} scm_bytevector_to_u8_list (bv)
+Return a newly allocated list of unsigned 8-bit integers from the
+contents of @var{bv}.
address@hidden deffn
+
address@hidden {Scheme Procedure} u8-list->bytevector lst
address@hidden {C Function} scm_u8_list_to_bytevector (lst)
+Return a newly allocated bytevector consisting of the unsigned 8-bit
+integers listed in @var{lst}.
address@hidden deffn
+
address@hidden {Scheme Procedure} bytevector->uint-list bv endianness size
address@hidden {Scheme Procedure} bytevector->sint-list bv endianness size
address@hidden {C Function} scm_bytevector_to_uint_list (bv, endianness, size)
address@hidden {C Function} scm_bytevector_to_sint_list (bv, endianness, size)
+Return a list of unsigned (resp. signed) integers of @var{size} bytes
+representing the contents of @var{bv}, decoded according to
address@hidden
address@hidden deffn
+
address@hidden {Scheme Procedure} uint-list->bytevector lst endianness size
address@hidden {Scheme Procedure} sint-list->bytevector lst endianness size
address@hidden {C Function} scm_uint_list_to_bytevector (lst, endianness, size)
address@hidden {C Function} scm_sint_list_to_bytevector (lst, endianness, size)
+Return a new bytevector containing the unsigned (resp. signed) integers
+listed in @var{lst} and encoded on @var{size} bytes according to
address@hidden
address@hidden deffn
+
address@hidden Bytevectors as Floats
address@hidden Interpreting Bytevector Contents as Floating Point Numbers
+
address@hidden IEEE-754 floating point numbers
+
+Bytevector contents can also be accessed as IEEE-754 single- or
+double-precision floating point numbers (respectively 32 and 64-bit
+long) using the procedures described here.
+
address@hidden {Scheme Procedure} bytevector-ieee-single-ref bv index endianness
address@hidden {Scheme Procedure} bytevector-ieee-double-ref bv index endianness
address@hidden {C Function} scm_bytevector_ieee_single_ref (bv, index, 
endianness)
address@hidden {C Function} scm_bytevector_ieee_double_ref (bv, index, 
endianness)
+Return the IEEE-754 single-precision floating point number from @var{bv}
+at @var{index} according to @var{endianness}.
address@hidden deffn
+
address@hidden {Scheme Procedure} bytevector-ieee-single-set! bv index value 
endianness
address@hidden {Scheme Procedure} bytevector-ieee-double-set! bv index value 
endianness
address@hidden {C Function} scm_bytevector_ieee_single_set_x (bv, index, value, 
endianness)
address@hidden {C Function} scm_bytevector_ieee_double_set_x (bv, index, value, 
endianness)
+Store real number @var{value} in @var{bv} at @var{index} according to
address@hidden
address@hidden deffn
+
+Specialized procedures are also available:
+
address@hidden {Scheme Procedure} bytevector-ieee-single-native-ref bv index
address@hidden {Scheme Procedure} bytevector-ieee-double-native-ref bv index
address@hidden {C Function} scm_bytevector_ieee_single_native_ref (bv, index)
address@hidden {C Function} scm_bytevector_ieee_double_native_ref (bv, index)
+Return the IEEE-754 single-precision floating point number from @var{bv}
+at @var{index} according to the host's native endianness.
address@hidden deffn
+
address@hidden {Scheme Procedure} bytevector-ieee-single-native-set! bv index 
value
address@hidden {Scheme Procedure} bytevector-ieee-double-native-set! bv index 
value
address@hidden {C Function} scm_bytevector_ieee_single_native_set_x (bv, index, 
value)
address@hidden {C Function} scm_bytevector_ieee_double_native_set_x (bv, index, 
value)
+Store real number @var{value} in @var{bv} at @var{index} according to
+the host's native endianness.
address@hidden deffn
+
+
address@hidden Bytevectors as Strings
address@hidden Interpreting Bytevector Contents as Unicode Strings
+
address@hidden Unicode string encoding
+
+Bytevector contents can also be interpreted as Unicode strings encoded
+in one of the most commonly available encoding address@hidden
+1.8 does @emph{not} support Unicode strings.  Therefore, the procedures
+described here assume that Guile strings are internally encoded
+according to the current locale.  For instance, if @code{$LC_CTYPE} is
address@hidden, then @code{string->utf-8} @i{et al.} will
+assume that Guile strings are Latin-1-encoded.}.
+
address@hidden
+(utf8->string (u8-list->bytevector '(99 97 102 101)))
address@hidden "cafe"
+
+(string->utf8 "caf@'e") ;; SMALL LATIN LETTER E WITH ACUTE ACCENT
address@hidden #vu8(99 97 102 195 169)
address@hidden lisp
+
address@hidden {Scheme Procedure} string->utf8 str
address@hidden {Scheme Procedure} string->utf16 str
address@hidden {Scheme Procedure} string->utf32 str
address@hidden {C Function} scm_string_to_utf8 (str)
address@hidden {C Function} scm_string_to_utf16 (str)
address@hidden {C Function} scm_string_to_utf32 (str)
+Return a newly allocated bytevector that contains the UTF-8, UTF-16, or
+UTF-32 (aka. UCS-4) encoding of @var{str}.
address@hidden deffn
+
address@hidden {Scheme Procedure} utf8->string utf
address@hidden {Scheme Procedure} utf16->string utf
address@hidden {Scheme Procedure} utf32->string utf
address@hidden {C Function} scm_utf8_to_string (utf)
address@hidden {C Function} scm_utf16_to_string (utf)
address@hidden {C Function} scm_utf32_to_string (utf)
+Return a newly allocated string that contains from the UTF-8-, UTF-16-,
+or UTF-32-decoded contents of bytevector @var{utf}.
address@hidden deffn
+
address@hidden Bytevectors as Generalized Vectors
address@hidden Accessing Bytevectors with the Generalized Vector API
+
+As an extension to the R6RS, Guile allows bytevectors to be manipulated
+with the @dfn{generalized vector} procedures (@pxref{Generalized
+Vectors}).  This also allows bytevectors to be accessed using the
+generic @dfn{array} procedures (@pxref{Array Procedures}).  When using
+these APIs, bytes are accessed one at a time as 8-bit unsigned integers:
+
address@hidden
+(define bv #vu8(0 1 2 3))
+
+(generalized-vector? bv)
address@hidden #t
+
+(generalized-vector-ref bv 2)
address@hidden 2
+
+(generalized-vector-set! bv 2 77)
+(array-ref bv 2)
address@hidden 77
+
+(array-type bv)
address@hidden vu8
address@hidden example
+
+
 @node Regular Expressions
 @subsection Regular Expressions
 @tpindex Regular expressions
diff --git a/doc/ref/api-io.texi b/doc/ref/api-io.texi
index f69d07e..12c19b7 100644
--- a/doc/ref/api-io.texi
+++ b/doc/ref/api-io.texi
@@ -1,6 +1,6 @@
 @c -*-texinfo-*-
 @c This is part of the GNU Guile Reference Manual.
address@hidden Copyright (C)  1996, 1997, 2000, 2001, 2002, 2003, 2004, 2007
address@hidden Copyright (C)  1996, 1997, 2000, 2001, 2002, 2003, 2004, 2007, 
2009
 @c   Free Software Foundation, Inc.
 @c See the file guile.texi for copying conditions.
 
@@ -18,6 +18,7 @@
 * Block Reading and Writing::   Reading and writing blocks of text.
 * Default Ports::               Defaults for input, output and errors.
 * Port Types::                  Types of port and how to make them.
+* R6RS I/O Ports::              The R6RS port API.
 * I/O Extensions::              Using and extending ports in C.
 @end menu
 
@@ -1023,6 +1024,269 @@ documentation for @code{open-file} in @ref{File Ports}.
 @end deffn
 
 
address@hidden R6RS I/O Ports
address@hidden R6RS I/O Ports
+
address@hidden R6RS
address@hidden R6RS ports
+
+The I/O port API of the @uref{http://www.r6rs.org/, Revised Report^6 on
+the Algorithmic Language Scheme (R6RS)} is provided by the @code{(rnrs
+io ports)} module.  It provides features, such as binary I/O and Unicode
+string I/O, that complement or refine Guile's historical port API
+presented above (@pxref{Input and Output}).
+
address@hidden FIXME: Update description when implemented.
address@hidden: The implementation of this R6RS API is currently far from
+complete, notably due to the lack of support for Unicode I/O and strings.
+
address@hidden
+* R6RS End-of-File::            The end-of-file object.
+* R6RS Port Manipulation::      Manipulating R6RS ports.
+* R6RS Binary Input::           Binary input.
+* R6RS Binary Output::          Binary output.
address@hidden menu
+
address@hidden R6RS End-of-File
address@hidden The End-of-File Object
+
address@hidden EOF
address@hidden end-of-file
+
+R5RS' @code{eof-object?} procedure is provided by the @code{(rnrs io
+ports)} module:
+
address@hidden {Scheme Procedure} eof-object? obj
address@hidden {C Function} scm_eof_object_p (obj)
+Return true if @var{obj} is the end-of-file (EOF) object.
address@hidden deffn
+
+In addition, the following procedure is provided:
+
address@hidden {Scheme Procedure} eof-object
address@hidden {C Function} scm_eof_object ()
+Return the end-of-file (EOF) object.
+
address@hidden
+(eof-object? (eof-object))
address@hidden #t
address@hidden lisp
address@hidden deffn
+
+
address@hidden R6RS Port Manipulation
address@hidden Port Manipulation
+
+The procedures listed below operate on any kind of R6RS I/O port.
+
address@hidden {Scheme Procedure} port-position port
+If @var{port} supports it (see below), return the offset (an integer)
+indicating where the next octet will be read from/written to in
address@hidden  If @var{port} does not support this operation, an error
+condition is raised.
+
+This is similar to Guile's @code{seek} procedure with the
address@hidden argument (@pxref{Random Access}).
address@hidden deffn
+
address@hidden {Scheme Procedure} port-has-port-position? port
+Return @code{#t} is @var{port} supports @code{port-position}.
address@hidden deffn
+
address@hidden {Scheme Procedure} set-port-position! port offset
+If @var{port} supports it (see below), set the position where the next
+octet will be read from/written to @var{port} to @var{offset} (an
+integer).  If @var{port} does not support this operation, an error
+condition is raised.
+
+This is similar to Guile's @code{seek} procedure with the
address@hidden argument (@pxref{Random Access}).
address@hidden deffn
+
address@hidden {Scheme Procedure} port-has-set-port-position!? port
+Return @code{#t} is @var{port} supports @code{set-port-position!}.
address@hidden deffn
+
address@hidden {Scheme Procedure} call-with-port port proc
+Call @var{proc}, passing it @var{port} and closing @var{port} upon exit
+of @var{proc}.  Return the return values of @var{proc}.
address@hidden deffn
+
+
address@hidden R6RS Binary Input
address@hidden Binary Input
+
address@hidden binary input
+
+R6RS binary input ports can be created with the procedures described
+below.
+
address@hidden {Scheme Procedure} open-bytevector-input-port bv [transcoder]
address@hidden {C Function} scm_open_bytevector_input_port (bv, transcoder)
+Return an input port whose contents are drawn from bytevector @var{bv}
+(@pxref{Bytevectors}).
+
address@hidden FIXME: Update description when implemented.
+The @var{transcoder} argument is currently not supported.
address@hidden deffn
+
address@hidden custom binary input ports
+
address@hidden {Scheme Procedure} make-custom-binary-input-port id read! 
get-position set-position! close
address@hidden {C Function} scm_make_custom_binary_input_port (id, read!, 
get-position, set-position!, close)
+Return a new custom binary input address@hidden is similar in spirit
+to Guile's @dfn{soft ports} (@pxref{Soft Ports}).} named @var{id} (a
+string) whose input is drained by invoking @var{read!} and passing it a
+bytevector, an index where bytes should be written, and the number of
+bytes to read.  The @code{read!}  procedure must return an integer
+indicating the number of bytes read, or @code{0} to indicate the
+end-of-file.
+
+Optionally, if @var{get-position} is not @code{#f}, it must be a thunk
+that will be called when @var{port-position} is invoked on the custom
+binary port and should return an integer indicating the position within
+the underlying data stream; if @var{get-position} was not supplied, the
+returned port does not support @var{port-position}.
+
+Likewise, if @var{set-position!} is not @code{#f}, it should be a
+one-argument procedure.  When @var{set-port-position!} is invoked on the
+custom binary input port, @var{set-position!} is passed an integer
+indicating the position of the next byte is to read.
+
+Finally, if @var{close} is not @code{#f}, it must be a thunk.  It is
+invoked when the custom binary input port is closed.
+
+Using a custom binary input port, the @code{open-bytevector-input-port}
+procedure could be implemented as follows:
+
address@hidden
+(define (open-bytevector-input-port source)
+  (define position 0)
+  (define length (bytevector-length source))
+
+  (define (read! bv start count)
+    (let ((count (min count (- length position))))
+      (bytevector-copy! source position
+                        bv start count)
+      (set! position (+ position count))
+      count))
+
+  (define (get-position) position)
+
+  (define (set-position! new-position)
+    (set! position new-position))
+
+  (make-custom-binary-input-port "the port" read!
+                                  get-position
+                                  set-position!))
+
+(read (open-bytevector-input-port (string->utf8 "hello")))
address@hidden hello
address@hidden lisp
address@hidden deffn
+
address@hidden binary input
+Binary input is achieved using the procedures below:
+
address@hidden {Scheme Procedure} get-u8 port
address@hidden {C Function} scm_get_u8 (port)
+Return an octet read from @var{port}, a binary input port, blocking as
+necessary, or the end-of-file object.
address@hidden deffn
+
address@hidden {Scheme Procedure} lookahead-u8 port
address@hidden {C Function} scm_lookahead_u8 (port)
+Like @code{get-u8} but does not update @var{port}'s position to point
+past the octet.
address@hidden deffn
+
address@hidden {Scheme Procedure} get-bytevector-n port count
address@hidden {C Function} scm_get_bytevector_n (port, count)
+Read @var{count} octets from @var{port}, blocking as necessary and
+return a bytevector containing the octets read.  If fewer bytes are
+available, a bytevector smaller than @var{count} is returned.
address@hidden deffn
+
address@hidden {Scheme Procedure} get-bytevector-n! port bv start count
address@hidden {C Function} scm_get_bytevector_n_x (port, bv, start, count)
+Read @var{count} bytes from @var{port} and store them in @var{bv}
+starting at index @var{start}.  Return either the number of bytes
+actually read or the end-of-file object.
address@hidden deffn
+
address@hidden {Scheme Procedure} get-bytevector-some port
address@hidden {C Function} scm_get_bytevector_some (port)
+Read from @var{port}, blocking as necessary, until data are available or
+and end-of-file is reached.  Return either a new bytevector containing
+the data read or the end-of-file object.
address@hidden deffn
+
address@hidden {Scheme Procedure} get-bytevector-all port
address@hidden {C Function} scm_get_bytevector_all (port)
+Read from @var{port}, blocking as necessary, until the end-of-file is
+reached.  Return either a new bytevector containing the data read or the
+end-of-file object (if no data were available).
address@hidden deffn
+
address@hidden R6RS Binary Output
address@hidden Binary Output
+
+Binary output ports can be created with the procedures below.
+
address@hidden {Scheme Procedure} open-bytevector-output-port [transcoder]
address@hidden {C Function} scm_open_bytevector_output_port (transcoder)
+Return two values: a binary output port and a procedure.  The latter
+should be called with zero arguments to obtain a bytevector containing
+the data accumulated by the port, as illustrated below.
+
address@hidden
+(call-with-values
+  (lambda ()
+    (open-bytevector-output-port))
+  (lambda (port get-bytevector)
+    (display "hello" port)
+    (get-bytevector)))
+
address@hidden #vu8(104 101 108 108 111)
address@hidden lisp
+
address@hidden FIXME: Update description when implemented.
+The @var{transcoder} argument is currently not supported.
address@hidden deffn
+
address@hidden custom binary output ports
+
address@hidden {Scheme Procedure} make-custom-binary-output-port id write! 
get-position set-position! close
address@hidden {C Function} scm_make_custom_binary_output_port (id, write!, 
get-position, set-position!, close)
+Return a new custom binary output port named @var{id} (a string) whose
+output is sunk by invoking @var{write!} and passing it a bytevector, an
+index where bytes should be read from this bytevector, and the number of
+bytes to be ``written''.  The @code{write!}  procedure must return an
+integer indicating the number of bytes actually written; when it is
+passed @code{0} as the number of bytes to write, it should behave as
+though an end-of-file was sent to the byte sink.
+
+The other arguments are as for @code{make-custom-binary-input-port}
+(@pxref{R6RS Binary Input, @code{make-custom-binary-input-port}}).
address@hidden deffn
+
address@hidden binary output
+Writing to a binary output port can be done using the following
+procedures:
+
address@hidden {Scheme Procedure} put-u8 port octet
address@hidden {C Function} scm_put_u8 (port, octet)
+Write @var{octet}, an integer in the 0--255 range, to @var{port}, a
+binary output port.
address@hidden deffn
+
address@hidden {Scheme Procedure} put-bytevector port bv [start [count]]
address@hidden {C Function} scm_put_bytevector (port, bv, start, count)
+Write the contents of @var{bv} to @var{port}, optionally starting at
+index @var{start} and limiting to @var{count} octets.
address@hidden deffn
+
+
 @node I/O Extensions
 @subsection Using and Extending Ports in C
 
diff --git a/doc/ref/compiler.texi b/doc/ref/compiler.texi
index 0d68abf..f8d0895 100644
--- a/doc/ref/compiler.texi
+++ b/doc/ref/compiler.texi
@@ -1,6 +1,6 @@
 @c -*-texinfo-*-
 @c This is part of the GNU Guile Reference Manual.
address@hidden Copyright (C)  2008
address@hidden Copyright (C)  2008, 2009
 @c   Free Software Foundation, Inc.
 @c See the file guile.texi for copying conditions.
 
@@ -26,6 +26,7 @@ know how to compile your .scm file.
 * GLIL::                
 * Assembly::                   
 * Bytecode and Objcode::                   
+* Writing New High-Level Languages::
 * Extending the Compiler::
 @end menu
 
@@ -712,6 +713,19 @@ module, and @var{externals} should be a list of external 
variables.
 @code{#f} is also a valid object code environment.
 @end deffn
 
address@hidden Writing New High-Level Languages
address@hidden Writing New High-Level Languages
+
+In order to integrate a new language @var{lang} into Guile's compiler
+system, one has to create the module @code{(language @var{lang} spec)}
+containing the language definition and referencing the parser,
+compiler and other routines processing it. The module hierarchy in
address@hidden(language brainfuck)} defines a very basic Brainfuck
+implementation meant to serve as easy-to-understand example on how to
+do this. See for instance @url{http://en.wikipedia.org/wiki/Brainfuck}
+for more information about the Brainfuck language itself.
+
+
 @node Extending the Compiler
 @subsection Extending the Compiler
 
diff --git a/doc/ref/intro.texi b/doc/ref/intro.texi
index a31fe30..b0c4c12 100644
--- a/doc/ref/intro.texi
+++ b/doc/ref/intro.texi
@@ -470,12 +470,12 @@ You can get the version number by invoking the command
 
 @example
 $ guile --version
-Guile 1.4.1
-Copyright (c) 1995, 1996, 1997, 2000, 2006 Free Software Foundation
-Guile may be distributed under the terms of the GNU General Public License;
-certain other uses are permitted as well.  For details, see the file
-`COPYING', which is included in the Guile distribution.
-There is no warranty, to the extent permitted by law.
+Guile 1.9.0
+Copyright (c) 1995, 1996, 1997, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 
2007, 2008, 2009 Free Software Foundation
+Guile may be distributed under the terms of the GNU Lesser General
+Public Licence.  For details, see the files `COPYING.LESSER' and
+`COPYING', which are included in the Guile distribution.  There is no
+warranty, to the extent permitted by law.
 @end example
 
 @item
diff --git a/doc/ref/preface.texi b/doc/ref/preface.texi
index d6de774..7fa8581 100644
--- a/doc/ref/preface.texi
+++ b/doc/ref/preface.texi
@@ -159,12 +159,12 @@ person would want to do.
 @itemize @bullet
 @item
 The Guile library (libguile) and supporting files are published under
-the terms of the GNU Lesser General Public License version 2.1.  See
-the file @file{COPYING.LIB}.
+the terms of the GNU Lesser General Public License version 3 or later.
+See the files @file{COPYING.LESSER} and @file{COPYING}.
 
 @item
 The Guile readline module is published under the terms of the GNU
-General Public License version 2.  See the file @file{COPYING}.
+General Public License version 3 or later.  See the file @file{COPYING}.
 
 @item
 The manual you're now reading is published under the terms of the GNU
diff --git a/doc/tutorial/Makefile.am b/doc/tutorial/Makefile.am
index f49220d..d359c4f 100644
--- a/doc/tutorial/Makefile.am
+++ b/doc/tutorial/Makefile.am
@@ -4,20 +4,20 @@
 ##
 ##   This file is part of GUILE.
 ##   
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
-##   
+##
 ##   GUILE 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 General Public License for more details.
-##   
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   GNU Lesser General Public License for more details.
+##
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 AUTOMAKE_OPTIONS = gnu
 
diff --git a/emacs/Makefile.am b/emacs/Makefile.am
index ad7a5c9..e18f30b 100644
--- a/emacs/Makefile.am
+++ b/emacs/Makefile.am
@@ -4,20 +4,20 @@
 ##
 ##   This file is part of GUILE.
 ##
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
 ##
 ##   GUILE 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 General Public License for more details.
+##   GNU Lesser General Public License for more details.
 ##
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 AUTOMAKE_OPTIONS = gnu
 
diff --git a/emacs/gds-scheme.el b/emacs/gds-scheme.el
index b8a161b..54c75a7 100755
--- a/emacs/gds-scheme.el
+++ b/emacs/gds-scheme.el
@@ -5,8 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later
-;;;; version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/emacs/gds-server.el b/emacs/gds-server.el
index 86defc0..d4fe997 100644
--- a/emacs/gds-server.el
+++ b/emacs/gds-server.el
@@ -5,8 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later
-;;;; version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/emacs/gds.el b/emacs/gds.el
index 7a1486d..a9450d0 100644
--- a/emacs/gds.el
+++ b/emacs/gds.el
@@ -5,8 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later
-;;;; version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/emacs/gud-guile.el b/emacs/gud-guile.el
index bd1b0ff..5d29526 100644
--- a/emacs/gud-guile.el
+++ b/emacs/gud-guile.el
@@ -2,20 +2,20 @@
 
 ;; Copyright (C) 2001, 2006 Free Software Foundation, Inc.
 
-;; GNU Emacs is free software; you can redistribute it and/or modify
-;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2, or (at your option)
-;; any later version.
-
-;; GNU Emacs 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 General Public License for more details.
-
-;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING.  If not, write to the
-;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;; Boston, MA 02110-1301, USA.
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free
+;;;; Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+;;;; 02111-1307 USA
 
 ;;; Author: Thien-Thi Nguyen <address@hidden>
 ;;; Version: 1
diff --git a/emacs/guile-c.el b/emacs/guile-c.el
index b23ddd3..1ccfd4d 100644
--- a/emacs/guile-c.el
+++ b/emacs/guile-c.el
@@ -2,20 +2,20 @@
 
 ;; Copyright (C) 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 General Public License as published by
-;; the Free Software Foundation; either version 2, 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 General Public License for more details.
-
-;; You should have received a copy of the GNU General Public License
-;; along with this program; see the file COPYING.  If not, write to the
-;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;; Boston, MA 02110-1301, USA.
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free
+;;;; Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+;;;; 02111-1307 USA
 
 ;;; Commentary:
 
diff --git a/emacs/guile-emacs.scm b/emacs/guile-emacs.scm
index 000d0cc..4d99002 100644
--- a/emacs/guile-emacs.scm
+++ b/emacs/guile-emacs.scm
@@ -2,20 +2,20 @@
 
 ;; Copyright (C) 2001 Keisuke Nishida <address@hidden>
 
-;; GNU Emacs is free software; you can redistribute it and/or modify
-;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2, or (at your option)
-;; any later version.
-
-;; GNU Emacs 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 General Public License for more details.
-
-;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING.  If not, write to the
-;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;; Boston, MA 02110-1301, USA.
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free
+;;;; Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+;;;; 02111-1307 USA
 
 ;;; Code:
 
diff --git a/emacs/guile-scheme.el b/emacs/guile-scheme.el
index a6d8b1f..5e112a0 100644
--- a/emacs/guile-scheme.el
+++ b/emacs/guile-scheme.el
@@ -2,20 +2,20 @@
 
 ;; Copyright (C) 2001, 2006 Free Software Foundation, Inc.
 
-;; GNU Emacs is free software; you can redistribute it and/or modify
-;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2, or (at your option)
-;; any later version.
-
-;; GNU Emacs 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 General Public License for more details.
-
-;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING.  If not, write to the
-;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;; Boston, MA 02110-1301, USA.
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free
+;;;; Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+;;;; 02111-1307 USA
 
 ;;; Commentary:
 
diff --git a/emacs/guile.el b/emacs/guile.el
index e85c81c..25a9b9b 100644
--- a/emacs/guile.el
+++ b/emacs/guile.el
@@ -2,20 +2,20 @@
 
 ;; Copyright (C) 2001 Keisuke Nishida <address@hidden>
 
-;; GNU Emacs is free software; you can redistribute it and/or modify
-;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2, or (at your option)
-;; any later version.
-
-;; GNU Emacs 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 General Public License for more details.
-
-;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING.  If not, write to the
-;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;; Boston, MA 02110-1301, USA.
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free
+;;;; Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+;;;; 02111-1307 USA
 
 ;;; Code:
 
diff --git a/emacs/multistring.el b/emacs/multistring.el
index ca17a84..df84195 100644
--- a/emacs/multistring.el
+++ b/emacs/multistring.el
@@ -2,22 +2,20 @@
 
 ;; Copyright (C) 2000, 2006 Free Software Foundation, Inc.
 
-;; This file is part of GNU Emacs.
-
-;; GNU Emacs is free software; you can redistribute it and/or modify
-;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2, or (at your option)
-;; any later version.
-
-;; GNU Emacs 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 General Public License for more details.
-
-;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING.  If not, write to the
-;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;; Boston, MA 02110-1301, USA.
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free
+;;;; Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+;;;; 02111-1307 USA
 
 ;;; Author: Mikael Djurfeldt <address@hidden>
 
diff --git a/emacs/patch.el b/emacs/patch.el
index 6bcb087..2fd20f5 100644
--- a/emacs/patch.el
+++ b/emacs/patch.el
@@ -2,20 +2,20 @@
 
 ;; Copyright (C) 2001, 2006 Free Software Foundation, Inc.
 
-;; GNU Emacs is free software; you can redistribute it and/or modify
-;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2, or (at your option)
-;; any later version.
-
-;; GNU Emacs 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 General Public License for more details.
-
-;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING.  If not, write to the
-;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;; Boston, MA 02110-1301, USA.
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free
+;;;; Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+;;;; 02111-1307 USA
 
 ;;; Author: Thien-Thi Nguyen <address@hidden>
 ;;; Version: 1
diff --git a/emacs/ppexpand.el b/emacs/ppexpand.el
index 7ec3b1c..f6c1876 100644
--- a/emacs/ppexpand.el
+++ b/emacs/ppexpand.el
@@ -2,22 +2,20 @@
 
 ;; Copyright (C) 2000, 2006 Free Software Foundation, Inc.
 
-;; This file is part of GNU Emacs.
-
-;; GNU Emacs is free software; you can redistribute it and/or modify
-;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2, or (at your option)
-;; any later version.
-
-;; GNU Emacs 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 General Public License for more details.
-
-;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING.  If not, write to the
-;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;; Boston, MA 02110-1301, USA.
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free
+;;;; Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+;;;; 02111-1307 USA
 
 ;;; Author: Mikael Djurfeldt <address@hidden>
 
diff --git a/emacs/update-changelog.el b/emacs/update-changelog.el
index e0c0a4b..c8dfa93 100644
--- a/emacs/update-changelog.el
+++ b/emacs/update-changelog.el
@@ -2,20 +2,20 @@
 
 ;;; Copyright (C) 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 General Public License as published by
-;; the Free Software Foundation; either version 2, 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 General Public License for more details.
-
-;; You should have received a copy of the GNU General Public License
-;; along with this program; see the file COPYING.  If not, write to the
-;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;; Boston, MA 02110-1301, USA.
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free
+;;;; Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+;;;; 02111-1307 USA
 
 ;;; Commentary:
 
diff --git a/examples/Makefile.am b/examples/Makefile.am
index 873f34c..5de528a 100644
--- a/examples/Makefile.am
+++ b/examples/Makefile.am
@@ -4,20 +4,20 @@
 ##
 ##   This file is part of GUILE.
 ##   
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
-##   
+##
 ##   GUILE 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 General Public License for more details.
-##   
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   GNU Lesser General Public License for more details.
+##
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 EXTRA_DIST = README ChangeLog-2008 check.test                          \
                                                                        \
@@ -38,8 +38,8 @@ EXTRA_DIST = README ChangeLog-2008 check.test                 
        \
                                                                        \
  safe/README safe/safe safe/untrusted.scm safe/evil.scm
 
-AM_CFLAGS = `PKG_CONFIG_PATH=$(libdir)/pkgconfig $(bindir)/guile-config 
compile`
-AM_LIBS   = `PKG_CONFIG_PATH=$(libdir)/pkgconfig $(bindir)/guile-config link`
+AM_CFLAGS = `PATH=$(bindir):$$PATH PKG_CONFIG_PATH=$(libdir)/pkgconfig 
$(bindir)/guile-config compile`
+AM_LIBS   = `PATH=$(bindir):$$PATH PKG_CONFIG_PATH=$(libdir)/pkgconfig 
$(bindir)/guile-config link`
 
 
 box/box: box/box.o
@@ -81,6 +81,7 @@ installcheck: box/box box-module/box libbox.la 
libbox-module.la
          LTDL_LIBRARY_PATH="$(builddir):$$LTDL_LIBRARY_PATH"   \
          GUILE_LOAD_PATH="$(abs_top_srcdir):$$GUILE_LOAD_PATH" \
          PATH="$(bindir):$$PATH"                               \
+         GUILE_AUTO_COMPILE=0                                  \
          srcdir="$(srcdir)"                                    \
          $(srcdir)/check.test
 
diff --git a/examples/box-dynamic-module/box.c 
b/examples/box-dynamic-module/box.c
index 7d6e2ce..e180565 100644
--- a/examples/box-dynamic-module/box.c
+++ b/examples/box-dynamic-module/box.c
@@ -2,20 +2,20 @@
  * 
  *     Copyright (C) 1998,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 General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * 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 General Public License for more details.
+ * 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 General Public License
- * along with this software; see the file COPYING.  If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- * Boston, MA 02110-1301 USA
+ * 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
  */
 
 /* Include all needed declarations.  */
diff --git a/examples/box-dynamic/box.c b/examples/box-dynamic/box.c
index bb95296..e96c011 100644
--- a/examples/box-dynamic/box.c
+++ b/examples/box-dynamic/box.c
@@ -2,20 +2,20 @@
  * 
  *     Copyright (C) 1998,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 General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * 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 General Public License for more details.
+ * 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 General Public License
- * along with this software; see the file COPYING.  If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- * Boston, MA 02110-1301 USA
+ * 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
  */
 
 /* Include all needed declarations.  */
diff --git a/examples/box-module/box.c b/examples/box-module/box.c
index b589b26..b69377e 100644
--- a/examples/box-module/box.c
+++ b/examples/box-module/box.c
@@ -2,20 +2,20 @@
  * 
  *     Copyright (C) 1998,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 General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * 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 General Public License for more details.
+ * 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 General Public License
- * along with this software; see the file COPYING.  If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- * Boston, MA 02110-1301 USA
+ * 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
  */
 
 /* Include all needed declarations.  */
diff --git a/examples/box/box.c b/examples/box/box.c
index e36d650..0662c3d 100644
--- a/examples/box/box.c
+++ b/examples/box/box.c
@@ -2,20 +2,20 @@
  * 
  *     Copyright (C) 1998,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 General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
+ * 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 General Public License for more details.
+ * 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 General Public License
- * along with this software; see the file COPYING.  If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- * Boston, MA 02110-1301 USA
+ * 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
  */
 
 /* Include all needed declarations.  */
diff --git a/examples/compat/compat.h b/examples/compat/compat.h
index 5ed11ef..67f1b9b 100644
--- a/examples/compat/compat.h
+++ b/examples/compat/compat.h
@@ -5,9 +5,9 @@
 /*     Copyright (C) 2001, 2002, 2006, 2008 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
  * This library is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -16,7 +16,8 @@
  *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/gc-benchmarks/gc-profile.scm b/gc-benchmarks/gc-profile.scm
index 002bfc5..3365832 100755
--- a/gc-benchmarks/gc-profile.scm
+++ b/gc-benchmarks/gc-profile.scm
@@ -5,20 +5,20 @@ exec ${GUILE-guile} --no-debug -q -l "$0" \
 !#
 ;;; Copyright (C) 2008 Free Software Foundation, Inc.
 ;;;
-;;; This program is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
+;;; 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 General Public License for more details.
+;;; GNU Lesser General Public License for more details.
 ;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with this software; see the file COPYING.  If not, write to
-;;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;;; Boston, MA 02110-1301 USA
+;;; 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
 
 (use-modules (ice-9 format)
              (ice-9 rdelim)
diff --git a/gc-benchmarks/run-benchmark.scm b/gc-benchmarks/run-benchmark.scm
index a50fb48..915143f 100755
--- a/gc-benchmarks/run-benchmark.scm
+++ b/gc-benchmarks/run-benchmark.scm
@@ -6,20 +6,20 @@ exec ${GUILE-guile} -q -l "$0"                                
  \
 !#
 ;;; Copyright (C) 2008 Free Software Foundation, Inc.
 ;;;
-;;; This program is free software; you can redistribute it and/or modify
-;;; it under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 2, or (at your option)
-;;; any later version.
+;;; 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 General Public License for more details.
+;;; GNU Lesser General Public License for more details.
 ;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with this software; see the file COPYING.  If not, write to
-;;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;;; Boston, MA 02110-1301 USA
+;;; 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
 
 (use-modules (ice-9 rdelim)
              (ice-9 popen)
diff --git a/guile-readline/Makefile.am b/guile-readline/Makefile.am
index 337bc53..28bfd9b 100644
--- a/guile-readline/Makefile.am
+++ b/guile-readline/Makefile.am
@@ -2,20 +2,20 @@
 ##
 ##     Copyright (C) 1998, 1999, 2000, 2001, 2004, 2006, 2007, 2008 Free 
Software Foundation, Inc.
 ##
-##   This file is part of GUILE.
+##   This file is part of guile-readline.
 ##
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   guile-readline is free software; you can redistribute it and/or
+##   modify it under the terms of the GNU General Public License as
+##   published by the Free Software Foundation; either version 3, or
 ##   (at your option) any later version.
 ##
-##   GUILE 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 General Public License for more details.
+##   guile-readline 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
+##   General Public License for more details.
 ##
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
+##   You should have received a copy of the GNU General Public License
+##   along with guile-readline; see the file COPYING.  If not, write
 ##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
 ##   Floor, Boston, MA 02110-1301 USA
 
diff --git a/guile-readline/configure.in b/guile-readline/configure.in
index 9098a31..d053566 100644
--- a/guile-readline/configure.in
+++ b/guile-readline/configure.in
@@ -7,7 +7,7 @@ AC_INIT(guile-readline,
 ]),
        address@hidden)
 
-AC_CONFIG_AUX_DIR([.])
+AC_CONFIG_AUX_DIR([../build-aux])
 AC_CONFIG_SRCDIR(readline.c)
 AM_CONFIG_HEADER([guile-readline-config.h])
 AM_INIT_AUTOMAKE([foreign no-define])
@@ -38,6 +38,7 @@ for termlib in ncurses curses termcap terminfo termlib ; do
                 [LIBS="-l${termlib} $LIBS"; break])
 done
 
+AC_LIB_LINKFLAGS(readline)
 AC_CHECK_LIB(readline, readline)
 if test $ac_cv_lib_readline_readline = no; then
   AC_MSG_WARN([libreadline was not found on your system.])
diff --git a/guile-readline/ice-9/Makefile.am b/guile-readline/ice-9/Makefile.am
index d1e7c82..ffa767e 100644
--- a/guile-readline/ice-9/Makefile.am
+++ b/guile-readline/ice-9/Makefile.am
@@ -2,20 +2,20 @@
 ##
 ##     Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2006, 2008 Free 
Software Foundation, Inc.
 ##
-##   This file is part of GUILE.
+##   This file is part of guile-readline.
 ##
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   guile-readline is free software; you can redistribute it and/or
+##   modify it under the terms of the GNU General Public License as
+##   published by the Free Software Foundation; either version 3, or
 ##   (at your option) any later version.
 ##
-##   GUILE 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 General Public License for more details.
+##   guile-readline 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
+##   General Public License for more details.
 ##
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
+##   You should have received a copy of the GNU General Public License
+##   along with guile-readline; see the file COPYING.  If not, write
 ##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
 ##   Floor, Boston, MA 02110-1301 USA
 
diff --git a/guile-readline/ice-9/readline.scm 
b/guile-readline/ice-9/readline.scm
index 19dda94..96af69e 100644
--- a/guile-readline/ice-9/readline.scm
+++ b/guile-readline/ice-9/readline.scm
@@ -4,7 +4,7 @@
 ;;;; 
 ;;;; This program is free software; you can redistribute it and/or modify
 ;;;; it under the terms of the GNU General Public License as published by
-;;;; the Free Software Foundation; either version 2, or (at your option)
+;;;; 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,
diff --git a/guile-readline/readline.c b/guile-readline/readline.c
index a884538..ac44e26 100644
--- a/guile-readline/readline.c
+++ b/guile-readline/readline.c
@@ -4,7 +4,7 @@
  * 
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
+ * 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,
diff --git a/guile-readline/readline.h b/guile-readline/readline.h
index 6242c56..2bf5f80 100644
--- a/guile-readline/readline.h
+++ b/guile-readline/readline.h
@@ -5,7 +5,7 @@
  * 
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2, or (at your option)
+ * 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,
diff --git a/lang/Makefile.am b/lang/Makefile.am
index 97c440d..adbe4d4 100644
--- a/lang/Makefile.am
+++ b/lang/Makefile.am
@@ -4,20 +4,20 @@
 ##
 ##   This file is part of GUILE.
 ##   
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
-##   
+##
 ##   GUILE 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 General Public License for more details.
-##   
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   GNU Lesser General Public License for more details.
+##
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 AUTOMAKE_OPTIONS = gnu
 
diff --git a/lib/Makefile.am b/lib/Makefile.am
index 6f2f5c5..f488fa1 100644
--- a/lib/Makefile.am
+++ b/lib/Makefile.am
@@ -9,7 +9,7 @@
 # the same distribution terms as the rest of that program.
 #
 # Generated by gnulib-tool.
-# Reproduce by: gnulib-tool --import --dir=. --lib=libgnu --source-base=lib 
--m4-base=m4 --doc-base=doc --tests-base=tests --aux-dir=build-aux --lgpl 
--libtool --macro-prefix=gl --no-vc-files alloca-opt autobuild byteswap 
count-one-bits environ extensions flock fpieee full-read full-write 
iconv_open-utf lib-symbol-visibility libunistring putenv stdlib strcase 
strftime striconveh string
+# Reproduce by: gnulib-tool --import --dir=. --lib=libgnu --source-base=lib 
--m4-base=m4 --doc-base=doc --tests-base=tests --aux-dir=build-aux --lgpl 
--libtool --macro-prefix=gl --no-vc-files alloca-opt autobuild byteswap 
canonicalize-lgpl count-one-bits environ extensions flock fpieee full-read 
full-write havelib iconv_open-utf lib-symbol-visibility libunistring putenv 
stdlib strcase strftime striconveh string
 
 AUTOMAKE_OPTIONS = 1.5 gnits subdir-objects
 
@@ -90,6 +90,15 @@ EXTRA_DIST += c-strcaseeq.h
 
 ## end   gnulib module c-strcaseeq
 
+## begin gnulib module canonicalize-lgpl
+
+
+EXTRA_DIST += canonicalize-lgpl.c canonicalize.h
+
+EXTRA_libgnu_la_SOURCES += canonicalize-lgpl.c
+
+## end   gnulib module canonicalize-lgpl
+
 ## begin gnulib module configmake
 
 # Retrieve values of the variables through 'configure' followed by
@@ -346,6 +355,14 @@ EXTRA_libgnu_la_SOURCES += malloc.c
 
 ## end   gnulib module malloc-posix
 
+## begin gnulib module malloca
+
+libgnu_la_SOURCES += malloca.c
+
+EXTRA_DIST += malloca.h malloca.valgrind
+
+## end   gnulib module malloca
+
 ## begin gnulib module mbrlen
 
 
@@ -373,6 +390,13 @@ EXTRA_libgnu_la_SOURCES += mbsinit.c
 
 ## end   gnulib module mbsinit
 
+## begin gnulib module pathmax
+
+
+EXTRA_DIST += pathmax.h
+
+## end   gnulib module pathmax
+
 ## begin gnulib module putenv
 
 
@@ -382,6 +406,15 @@ EXTRA_libgnu_la_SOURCES += putenv.c
 
 ## end   gnulib module putenv
 
+## begin gnulib module readlink
+
+
+EXTRA_DIST += readlink.c
+
+EXTRA_libgnu_la_SOURCES += readlink.c
+
+## end   gnulib module readlink
+
 ## begin gnulib module safe-read
 
 
@@ -581,6 +614,7 @@ string.h: string.in.h
              -e 's|@''GNULIB_MBSSPN''@|$(GNULIB_MBSSPN)|g' \
              -e 's|@''GNULIB_MBSSEP''@|$(GNULIB_MBSSEP)|g' \
              -e 's|@''GNULIB_MBSTOK_R''@|$(GNULIB_MBSTOK_R)|g' \
+             -e 's|@''GNULIB_MEMCHR''@|$(GNULIB_MEMCHR)|g' \
              -e 's|@''GNULIB_MEMMEM''@|$(GNULIB_MEMMEM)|g' \
              -e 's|@''GNULIB_MEMPCPY''@|$(GNULIB_MEMPCPY)|g' \
              -e 's|@''GNULIB_MEMRCHR''@|$(GNULIB_MEMRCHR)|g' \
@@ -617,6 +651,7 @@ string.h: string.in.h
              -e 's|@''HAVE_DECL_STRERROR''@|$(HAVE_DECL_STRERROR)|g' \
              -e 's|@''HAVE_DECL_STRSIGNAL''@|$(HAVE_DECL_STRSIGNAL)|g' \
              -e 's|@''HAVE_STRVERSCMP''@|$(HAVE_STRVERSCMP)|g' \
+             -e 's|@''REPLACE_MEMCHR''@|$(REPLACE_MEMCHR)|g' \
              -e 's|@''REPLACE_MEMMEM''@|$(REPLACE_MEMMEM)|g' \
              -e 's|@''REPLACE_STRCASESTR''@|$(REPLACE_STRCASESTR)|g' \
              -e 's|@''REPLACE_STRDUP''@|$(REPLACE_STRDUP)|g' \
diff --git a/lib/canonicalize-lgpl.c b/lib/canonicalize-lgpl.c
new file mode 100644
index 0000000..8bc2468
--- /dev/null
+++ b/lib/canonicalize-lgpl.c
@@ -0,0 +1,362 @@
+/* Return the canonical absolute name of a given file.
+   Copyright (C) 1996-2003, 2005-2008 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   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 of the License, 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 program.  If not, see <http://www.gnu.org/licenses/>.  */
+
+#include <config.h>
+
+/* Avoid a clash of our rpl_realpath() function with the prototype in
+   <stdlib.h> on Solaris 2.5.1.  */
+#undef realpath
+
+#if !HAVE_CANONICALIZE_FILE_NAME || defined _LIBC
+
+#include <alloca.h>
+
+/* Specification.  */
+#include "canonicalize.h"
+
+#include <stddef.h>
+#include <stdlib.h>
+#include <string.h>
+
+#if HAVE_UNISTD_H || defined _LIBC
+# include <unistd.h>
+#endif
+
+#include <limits.h>
+
+#if HAVE_SYS_PARAM_H || defined _LIBC
+# include <sys/param.h>
+#endif
+#ifndef MAXSYMLINKS
+# define MAXSYMLINKS 20
+#endif
+
+#include <sys/stat.h>
+
+#include <errno.h>
+#ifndef _LIBC
+# define __set_errno(e) errno = (e)
+# ifndef ENAMETOOLONG
+#  define ENAMETOOLONG EINVAL
+# endif
+#endif
+
+#ifdef _LIBC
+# include <shlib-compat.h>
+#else
+# define SHLIB_COMPAT(lib, introduced, obsoleted) 0
+# define versioned_symbol(lib, local, symbol, version)
+# define compat_symbol(lib, local, symbol, version)
+# define weak_alias(local, symbol)
+# define __canonicalize_file_name canonicalize_file_name
+# define __realpath rpl_realpath
+# include "pathmax.h"
+# include "malloca.h"
+# if HAVE_GETCWD
+#  ifdef VMS
+    /* We want the directory in Unix syntax, not in VMS syntax.  */
+#   define __getcwd(buf, max) getcwd (buf, max, 0)
+#  else
+#   define __getcwd getcwd
+#  endif
+# else
+#  define __getcwd(buf, max) getwd (buf)
+# endif
+# define __readlink readlink
+  /* On systems without symbolic links, call stat() instead of lstat().  */
+# if !defined S_ISLNK && !HAVE_READLINK
+#  define lstat stat
+# endif
+#endif
+
+/* Return the canonical absolute name of file NAME.  A canonical name
+   does not contain any `.', `..' components nor any repeated path
+   separators ('/') or symlinks.  All path components must exist.  If
+   RESOLVED is null, the result is malloc'd; otherwise, if the
+   canonical name is PATH_MAX chars or more, returns null with `errno'
+   set to ENAMETOOLONG; if the name fits in fewer than PATH_MAX chars,
+   returns the name in RESOLVED.  If the name cannot be resolved and
+   RESOLVED is non-NULL, it contains the path of the first component
+   that cannot be resolved.  If the path can be resolved, RESOLVED
+   holds the same value as the value returned.  */
+
+char *
+__realpath (const char *name, char *resolved)
+{
+  char *rpath, *dest, *extra_buf = NULL;
+  const char *start, *end, *rpath_limit;
+  long int path_max;
+#if HAVE_READLINK
+  int num_links = 0;
+#endif
+
+  if (name == NULL)
+    {
+      /* As per Single Unix Specification V2 we must return an error if
+        either parameter is a null pointer.  We extend this to allow
+        the RESOLVED parameter to be NULL in case the we are expected to
+        allocate the room for the return value.  */
+      __set_errno (EINVAL);
+      return NULL;
+    }
+
+  if (name[0] == '\0')
+    {
+      /* As per Single Unix Specification V2 we must return an error if
+        the name argument points to an empty string.  */
+      __set_errno (ENOENT);
+      return NULL;
+    }
+
+#ifdef PATH_MAX
+  path_max = PATH_MAX;
+#else
+  path_max = pathconf (name, _PC_PATH_MAX);
+  if (path_max <= 0)
+    path_max = 1024;
+#endif
+
+  if (resolved == NULL)
+    {
+      rpath = malloc (path_max);
+      if (rpath == NULL)
+       {
+         /* It's easier to set errno to ENOMEM than to rely on the
+            'malloc-posix' gnulib module.  */
+         errno = ENOMEM;
+         return NULL;
+       }
+    }
+  else
+    rpath = resolved;
+  rpath_limit = rpath + path_max;
+
+  if (name[0] != '/')
+    {
+      if (!__getcwd (rpath, path_max))
+       {
+         rpath[0] = '\0';
+         goto error;
+       }
+      dest = strchr (rpath, '\0');
+    }
+  else
+    {
+      rpath[0] = '/';
+      dest = rpath + 1;
+    }
+
+  for (start = end = name; *start; start = end)
+    {
+#ifdef _LIBC
+      struct stat64 st;
+#else
+      struct stat st;
+#endif
+
+      /* Skip sequence of multiple path-separators.  */
+      while (*start == '/')
+       ++start;
+
+      /* Find end of path component.  */
+      for (end = start; *end && *end != '/'; ++end)
+       /* Nothing.  */;
+
+      if (end - start == 0)
+       break;
+      else if (end - start == 1 && start[0] == '.')
+       /* nothing */;
+      else if (end - start == 2 && start[0] == '.' && start[1] == '.')
+       {
+         /* Back up to previous component, ignore if at root already.  */
+         if (dest > rpath + 1)
+           while ((--dest)[-1] != '/');
+       }
+      else
+       {
+         size_t new_size;
+
+         if (dest[-1] != '/')
+           *dest++ = '/';
+
+         if (dest + (end - start) >= rpath_limit)
+           {
+             ptrdiff_t dest_offset = dest - rpath;
+             char *new_rpath;
+
+             if (resolved)
+               {
+                 __set_errno (ENAMETOOLONG);
+                 if (dest > rpath + 1)
+                   dest--;
+                 *dest = '\0';
+                 goto error;
+               }
+             new_size = rpath_limit - rpath;
+             if (end - start + 1 > path_max)
+               new_size += end - start + 1;
+             else
+               new_size += path_max;
+             new_rpath = (char *) realloc (rpath, new_size);
+             if (new_rpath == NULL)
+               {
+                 /* It's easier to set errno to ENOMEM than to rely on the
+                    'realloc-posix' gnulib module.  */
+                 errno = ENOMEM;
+                 goto error;
+               }
+             rpath = new_rpath;
+             rpath_limit = rpath + new_size;
+
+             dest = rpath + dest_offset;
+           }
+
+#ifdef _LIBC
+         dest = __mempcpy (dest, start, end - start);
+#else
+         memcpy (dest, start, end - start);
+         dest += end - start;
+#endif
+         *dest = '\0';
+
+#ifdef _LIBC
+         if (__lxstat64 (_STAT_VER, rpath, &st) < 0)
+#else
+         if (lstat (rpath, &st) < 0)
+#endif
+           goto error;
+
+#if HAVE_READLINK
+         if (S_ISLNK (st.st_mode))
+           {
+             char *buf;
+             size_t len;
+             int n;
+
+             if (++num_links > MAXSYMLINKS)
+               {
+                 __set_errno (ELOOP);
+                 goto error;
+               }
+
+             buf = malloca (path_max);
+             if (!buf)
+               {
+                 errno = ENOMEM;
+                 goto error;
+               }
+
+             n = __readlink (rpath, buf, path_max - 1);
+             if (n < 0)
+               {
+                 int saved_errno = errno;
+                 freea (buf);
+                 errno = saved_errno;
+                 goto error;
+               }
+             buf[n] = '\0';
+
+             if (!extra_buf)
+               {
+                 extra_buf = malloca (path_max);
+                 if (!extra_buf)
+                   {
+                     freea (buf);
+                     errno = ENOMEM;
+                     goto error;
+                   }
+               }
+
+             len = strlen (end);
+             if ((long int) (n + len) >= path_max)
+               {
+                 freea (buf);
+                 __set_errno (ENAMETOOLONG);
+                 goto error;
+               }
+
+             /* Careful here, end may be a pointer into extra_buf... */
+             memmove (&extra_buf[n], end, len + 1);
+             name = end = memcpy (extra_buf, buf, n);
+
+             if (buf[0] == '/')
+               dest = rpath + 1;       /* It's an absolute symlink */
+             else
+               /* Back up to previous component, ignore if at root already: */
+               if (dest > rpath + 1)
+                 while ((--dest)[-1] != '/');
+           }
+#endif
+       }
+    }
+  if (dest > rpath + 1 && dest[-1] == '/')
+    --dest;
+  *dest = '\0';
+
+  if (extra_buf)
+    freea (extra_buf);
+
+  return resolved ? memcpy (resolved, rpath, dest - rpath + 1) : rpath;
+
+error:
+  {
+    int saved_errno = errno;
+    if (extra_buf)
+      freea (extra_buf);
+    if (resolved)
+      strcpy (resolved, rpath);
+    else
+      free (rpath);
+    errno = saved_errno;
+  }
+  return NULL;
+}
+#ifdef _LIBC
+versioned_symbol (libc, __realpath, realpath, GLIBC_2_3);
+#endif
+
+
+#if SHLIB_COMPAT(libc, GLIBC_2_0, GLIBC_2_3)
+char *
+__old_realpath (const char *name, char *resolved)
+{
+  if (resolved == NULL)
+    {
+      __set_errno (EINVAL);
+      return NULL;
+    }
+
+  return __realpath (name, resolved);
+}
+compat_symbol (libc, __old_realpath, realpath, GLIBC_2_0);
+#endif
+
+
+char *
+__canonicalize_file_name (const char *name)
+{
+  return __realpath (name, NULL);
+}
+weak_alias (__canonicalize_file_name, canonicalize_file_name)
+
+#else
+
+/* This declaration is solely to ensure that after preprocessing
+   this file is never empty.  */
+typedef int dummy;
+
+#endif
diff --git a/lib/canonicalize.h b/lib/canonicalize.h
new file mode 100644
index 0000000..184cf16
--- /dev/null
+++ b/lib/canonicalize.h
@@ -0,0 +1,52 @@
+/* Return the canonical absolute name of a given file.
+   Copyright (C) 1996-2007 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 of the License, 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 program.  If not, see <http://www.gnu.org/licenses/>.  */
+
+#ifndef CANONICALIZE_H_
+# define CANONICALIZE_H_
+
+# if GNULIB_CANONICALIZE
+enum canonicalize_mode_t
+  {
+    /* All components must exist.  */
+    CAN_EXISTING = 0,
+
+    /* All components excluding last one must exist.  */
+    CAN_ALL_BUT_LAST = 1,
+
+    /* No requirements on components existence.  */
+    CAN_MISSING = 2
+  };
+typedef enum canonicalize_mode_t canonicalize_mode_t;
+
+/* Return a malloc'd string containing the canonical absolute name of
+   the named file.  This acts like canonicalize_file_name, except that
+   whether components must exist depends on the canonicalize_mode_t
+   argument.  */
+char *canonicalize_filename_mode (const char *, canonicalize_mode_t);
+# endif
+
+# if HAVE_DECL_CANONICALIZE_FILE_NAME
+#  include <stdlib.h>
+# else
+/* Return a malloc'd string containing the canonical absolute name of
+   the named file.  If any file name component does not exist or is a
+   symlink to a nonexistent file, return NULL.  A canonical name does
+   not contain any `.', `..' components nor any repeated file name
+   separators ('/') or symlinks.  */
+char *canonicalize_file_name (const char *);
+# endif
+
+#endif /* !CANONICALIZE_H_ */
diff --git a/lib/malloca.c b/lib/malloca.c
new file mode 100644
index 0000000..7905e61
--- /dev/null
+++ b/lib/malloca.c
@@ -0,0 +1,137 @@
+/* Safe automatic memory allocation.
+   Copyright (C) 2003, 2006-2007 Free Software Foundation, Inc.
+   Written by Bruno Haible <address@hidden>, 2003.
+
+   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 2, 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 program; if not, write to the Free Software Foundation,
+   Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.  */
+
+#include <config.h>
+
+/* Specification.  */
+#include "malloca.h"
+
+/* The speed critical point in this file is freea() applied to an alloca()
+   result: it must be fast, to match the speed of alloca().  The speed of
+   mmalloca() and freea() in the other case are not critical, because they
+   are only invoked for big memory sizes.  */
+
+#if HAVE_ALLOCA
+
+/* Store the mmalloca() results in a hash table.  This is needed to reliably
+   distinguish a mmalloca() result and an alloca() result.
+
+   Although it is possible that the same pointer is returned by alloca() and
+   by mmalloca() at different times in the same application, it does not lead
+   to a bug in freea(), because:
+     - Before a pointer returned by alloca() can point into malloc()ed memory,
+       the function must return, and once this has happened the programmer must
+       not call freea() on it anyway.
+     - Before a pointer returned by mmalloca() can point into the stack, it
+       must be freed.  The only function that can free it is freea(), and
+       when freea() frees it, it also removes it from the hash table.  */
+
+#define MAGIC_NUMBER 0x1415fb4a
+#define MAGIC_SIZE sizeof (int)
+/* This is how the header info would look like without any alignment
+   considerations.  */
+struct preliminary_header { void *next; char room[MAGIC_SIZE]; };
+/* But the header's size must be a multiple of sa_alignment_max.  */
+#define HEADER_SIZE \
+  (((sizeof (struct preliminary_header) + sa_alignment_max - 1) / 
sa_alignment_max) * sa_alignment_max)
+struct header { void *next; char room[HEADER_SIZE - sizeof (struct 
preliminary_header) + MAGIC_SIZE]; };
+/* Verify that HEADER_SIZE == sizeof (struct header).  */
+typedef int verify1[2 * (HEADER_SIZE == sizeof (struct header)) - 1];
+/* We make the hash table quite big, so that during lookups the probability
+   of empty hash buckets is quite high.  There is no need to make the hash
+   table resizable, because when the hash table gets filled so much that the
+   lookup becomes slow, it means that the application has memory leaks.  */
+#define HASH_TABLE_SIZE 257
+static void * mmalloca_results[HASH_TABLE_SIZE];
+
+#endif
+
+void *
+mmalloca (size_t n)
+{
+#if HAVE_ALLOCA
+  /* Allocate one more word, that serves as an indicator for malloc()ed
+     memory, so that freea() of an alloca() result is fast.  */
+  size_t nplus = n + HEADER_SIZE;
+
+  if (nplus >= n)
+    {
+      char *p = (char *) malloc (nplus);
+
+      if (p != NULL)
+       {
+         size_t slot;
+
+         p += HEADER_SIZE;
+
+         /* Put a magic number into the indicator word.  */
+         ((int *) p)[-1] = MAGIC_NUMBER;
+
+         /* Enter p into the hash table.  */
+         slot = (unsigned long) p % HASH_TABLE_SIZE;
+         ((struct header *) (p - HEADER_SIZE))->next = mmalloca_results[slot];
+         mmalloca_results[slot] = p;
+
+         return p;
+       }
+    }
+  /* Out of memory.  */
+  return NULL;
+#else
+# if !MALLOC_0_IS_NONNULL
+  if (n == 0)
+    n = 1;
+# endif
+  return malloc (n);
+#endif
+}
+
+#if HAVE_ALLOCA
+void
+freea (void *p)
+{
+  /* mmalloca() may have returned NULL.  */
+  if (p != NULL)
+    {
+      /* Attempt to quickly distinguish the mmalloca() result - which has
+        a magic indicator word - and the alloca() result - which has an
+        uninitialized indicator word.  It is for this test that sa_increment
+        additional bytes are allocated in the alloca() case.  */
+      if (((int *) p)[-1] == MAGIC_NUMBER)
+       {
+         /* Looks like a mmalloca() result.  To see whether it really is one,
+            perform a lookup in the hash table.  */
+         size_t slot = (unsigned long) p % HASH_TABLE_SIZE;
+         void **chain = &mmalloca_results[slot];
+         for (; *chain != NULL;)
+           {
+             if (*chain == p)
+               {
+                 /* Found it.  Remove it from the hash table and free it.  */
+                 char *p_begin = (char *) p - HEADER_SIZE;
+                 *chain = ((struct header *) p_begin)->next;
+                 free (p_begin);
+                 return;
+               }
+             chain = &((struct header *) ((char *) *chain - 
HEADER_SIZE))->next;
+           }
+       }
+      /* At this point, we know it was not a mmalloca() result.  */
+    }
+}
+#endif
diff --git a/lib/malloca.h b/lib/malloca.h
new file mode 100644
index 0000000..7d92b0a
--- /dev/null
+++ b/lib/malloca.h
@@ -0,0 +1,134 @@
+/* Safe automatic memory allocation.
+   Copyright (C) 2003-2007 Free Software Foundation, Inc.
+   Written by Bruno Haible <address@hidden>, 2003.
+
+   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 2, 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 program; if not, write to the Free Software Foundation,
+   Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.  */
+
+#ifndef _MALLOCA_H
+#define _MALLOCA_H
+
+#include <alloca.h>
+#include <stddef.h>
+#include <stdlib.h>
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+
+/* safe_alloca(N) is equivalent to alloca(N) when it is safe to call
+   alloca(N); otherwise it returns NULL.  It either returns N bytes of
+   memory allocated on the stack, that lasts until the function returns,
+   or NULL.
+   Use of safe_alloca should be avoided:
+     - inside arguments of function calls - undefined behaviour,
+     - in inline functions - the allocation may actually last until the
+       calling function returns.
+*/
+#if HAVE_ALLOCA
+/* The OS usually guarantees only one guard page at the bottom of the stack,
+   and a page size can be as small as 4096 bytes.  So we cannot safely
+   allocate anything larger than 4096 bytes.  Also care for the possibility
+   of a few compiler-allocated temporary stack slots.
+   This must be a macro, not an inline function.  */
+# define safe_alloca(N) ((N) < 4032 ? alloca (N) : NULL)
+#else
+# define safe_alloca(N) ((void) (N), NULL)
+#endif
+
+/* malloca(N) is a safe variant of alloca(N).  It allocates N bytes of
+   memory allocated on the stack, that must be freed using freea() before
+   the function returns.  Upon failure, it returns NULL.  */
+#if HAVE_ALLOCA
+# define malloca(N) \
+  ((N) < 4032 - sa_increment                                       \
+   ? (void *) ((char *) alloca ((N) + sa_increment) + sa_increment) \
+   : mmalloca (N))
+#else
+# define malloca(N) \
+  mmalloca (N)
+#endif
+extern void * mmalloca (size_t n);
+
+/* Free a block of memory allocated through malloca().  */
+#if HAVE_ALLOCA
+extern void freea (void *p);
+#else
+# define freea free
+#endif
+
+/* nmalloca(N,S) is an overflow-safe variant of malloca (N * S).
+   It allocates an array of N objects, each with S bytes of memory,
+   on the stack.  S must be positive and N must be nonnegative.
+   The array must be freed using freea() before the function returns.  */
+#if 1
+/* Cf. the definition of xalloc_oversized.  */
+# define nmalloca(n, s) \
+    ((n) > (size_t) (sizeof (ptrdiff_t) <= sizeof (size_t) ? -1 : -2) / (s) \
+     ? NULL \
+     : malloca ((n) * (s)))
+#else
+extern void * nmalloca (size_t n, size_t s);
+#endif
+
+
+#ifdef __cplusplus
+}
+#endif
+
+
+/* ------------------- Auxiliary, non-public definitions ------------------- */
+
+/* Determine the alignment of a type at compile time.  */
+#if defined __GNUC__
+# define sa_alignof __alignof__
+#elif defined __cplusplus
+  template <class type> struct sa_alignof_helper { char __slot1; type __slot2; 
};
+# define sa_alignof(type) offsetof (sa_alignof_helper<type>, __slot2)
+#elif defined __hpux
+  /* Work around a HP-UX 10.20 cc bug with enums constants defined as offsetof
+     values.  */
+# define sa_alignof(type) (sizeof (type) <= 4 ? 4 : 8)
+#elif defined _AIX
+  /* Work around an AIX 3.2.5 xlc bug with enums constants defined as offsetof
+     values.  */
+# define sa_alignof(type) (sizeof (type) <= 4 ? 4 : 8)
+#else
+# define sa_alignof(type) offsetof (struct { char __slot1; type __slot2; }, 
__slot2)
+#endif
+
+enum
+{
+/* The desired alignment of memory allocations is the maximum alignment
+   among all elementary types.  */
+  sa_alignment_long = sa_alignof (long),
+  sa_alignment_double = sa_alignof (double),
+#if HAVE_LONG_LONG_INT
+  sa_alignment_longlong = sa_alignof (long long),
+#endif
+  sa_alignment_longdouble = sa_alignof (long double),
+  sa_alignment_max = ((sa_alignment_long - 1) | (sa_alignment_double - 1)
+#if HAVE_LONG_LONG_INT
+                     | (sa_alignment_longlong - 1)
+#endif
+                     | (sa_alignment_longdouble - 1)
+                    ) + 1,
+/* The increment that guarantees room for a magic word must be >= sizeof (int)
+   and a multiple of sa_alignment_max.  */
+  sa_increment = ((sizeof (int) + sa_alignment_max - 1) / sa_alignment_max) * 
sa_alignment_max
+};
+
+#endif /* _MALLOCA_H */
diff --git a/lib/malloca.valgrind b/lib/malloca.valgrind
new file mode 100644
index 0000000..52f0a50
--- /dev/null
+++ b/lib/malloca.valgrind
@@ -0,0 +1,7 @@
+# Suppress a valgrind message about use of uninitialized memory in freea().
+# This use is OK because it provides only a speedup.
+{
+    freea
+    Memcheck:Cond
+    fun:freea
+}
diff --git a/lib/pathmax.h b/lib/pathmax.h
new file mode 100644
index 0000000..a5d4335
--- /dev/null
+++ b/lib/pathmax.h
@@ -0,0 +1,47 @@
+/* Define PATH_MAX somehow.  Requires sys/types.h.
+   Copyright (C) 1992, 1999, 2001, 2003, 2005, 2009 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 2, 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 program; if not, write to the Free Software Foundation,
+   Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.  */
+
+#ifndef _PATHMAX_H
+# define _PATHMAX_H
+
+# include <unistd.h>
+
+# include <limits.h>
+
+# ifndef _POSIX_PATH_MAX
+#  define _POSIX_PATH_MAX 256
+# endif
+
+# if !defined PATH_MAX && defined _PC_PATH_MAX && defined HAVE_PATHCONF
+#  define PATH_MAX (pathconf ("/", _PC_PATH_MAX) < 1 ? 1024 \
+                   : pathconf ("/", _PC_PATH_MAX))
+# endif
+
+/* Don't include sys/param.h if it already has been.  */
+# if defined HAVE_SYS_PARAM_H && !defined PATH_MAX && !defined MAXPATHLEN
+#  include <sys/param.h>
+# endif
+
+# if !defined PATH_MAX && defined MAXPATHLEN
+#  define PATH_MAX MAXPATHLEN
+# endif
+
+# ifndef PATH_MAX
+#  define PATH_MAX _POSIX_PATH_MAX
+# endif
+
+#endif /* _PATHMAX_H */
diff --git a/lib/readlink.c b/lib/readlink.c
new file mode 100644
index 0000000..c9f49f8
--- /dev/null
+++ b/lib/readlink.c
@@ -0,0 +1,49 @@
+/* Stub for readlink().
+   Copyright (C) 2003-2007 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 of the License, 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 program.  If not, see <http://www.gnu.org/licenses/>.  */
+
+#include <config.h>
+
+/* Specification.  */
+#include <unistd.h>
+
+#include <errno.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <stddef.h>
+
+#if !HAVE_READLINK
+
+/* readlink() substitute for systems that don't have a readlink() function,
+   such as DJGPP 2.03 and mingw32.  */
+
+/* The official POSIX return type of readlink() is ssize_t, but since here
+   we have no declaration in a public header file, we use 'int' as return
+   type.  */
+
+int
+readlink (const char *path, char *buf, size_t bufsize)
+{
+  struct stat statbuf;
+
+  /* In general we should use lstat() here, not stat().  But on platforms
+     without symbolic links lstat() - if it exists - would be equivalent to
+     stat(), therefore we can use stat().  This saves us a configure check.  */
+  if (stat (path, &statbuf) >= 0)
+    errno = EINVAL;
+  return -1;
+}
+
+#endif
diff --git a/lib/string.in.h b/lib/string.in.h
index ca029d7..fe11425 100644
--- a/lib/string.in.h
+++ b/lib/string.in.h
@@ -1,6 +1,6 @@
 /* A GNU-like <string.h>.
 
-   Copyright (C) 1995-1996, 2001-2008 Free Software Foundation, Inc.
+   Copyright (C) 1995-1996, 2001-2009 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
@@ -49,6 +49,21 @@ extern "C" {
 #endif
 
 
+/* Return the first instance of C within N bytes of S, or NULL.  */
+#if @GNULIB_MEMCHR@
+# if @REPLACE_MEMCHR@
+#  define memchr rpl_memchr
+extern void *memchr (void const *__s, int __c, size_t __n)
+  __attribute__ ((__pure__));
+# endif
+#elif defined GNULIB_POSIXCHECK
+# undef memchr
+# define memchr(s,c,n) \
+    (GL_LINK_WARNING ("memchr has platform-specific bugs - " \
+                      "use gnulib module memchr for portability" ), \
+     memchr (s, c, n))
+#endif
+
 /* Return the first occurrence of NEEDLE in HAYSTACK.  */
 #if @GNULIB_MEMMEM@
 # if @REPLACE_MEMMEM@
diff --git a/libguile.h b/libguile.h
index 6a6d232..7b5649b 100644
--- a/libguile.h
+++ b/libguile.h
@@ -4,18 +4,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2002, 2003, 2004, 2006, 2008, 
2009 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/Makefile.am b/libguile/Makefile.am
index 75eb089..f5b0978 100644
--- a/libguile/Makefile.am
+++ b/libguile/Makefile.am
@@ -4,20 +4,20 @@
 ##
 ##   This file is part of GUILE.
 ##
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
 ##
 ##   GUILE 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 General Public License for more details.
+##   GNU Lesser General Public License for more details.
 ##
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 AUTOMAKE_OPTIONS = gnu
 
diff --git a/libguile/__scm.h b/libguile/__scm.h
index aabad00..b92eeae 100644
--- a/libguile/__scm.h
+++ b/libguile/__scm.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2001,2002,2003, 2006, 2007, 2008, 
2009 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -560,7 +561,7 @@ SCM_API SCM scm_call_generic_1 (SCM gf, SCM a1);
 #define SCM_WTA_DISPATCH_1_SUBR(subr, a1, pos)                         \
   return (SCM_UNPACK ((*SCM_SUBR_GENERIC (subr)))                      \
          ? scm_call_generic_1 ((*SCM_SUBR_GENERIC (subr)), (a1))       \
-         : (scm_i_wrong_type_arg_symbol (SCM_SNAME (subr), (pos), (a1)), 
SCM_UNSPECIFIED))
+         : (scm_i_wrong_type_arg_symbol (SCM_SUBR_NAME (subr), (pos), (a1)), 
SCM_UNSPECIFIED))
 
 #define SCM_GASSERT1(cond, gf, a1, pos, subr)          \
   if (SCM_UNLIKELY (!(cond)))                  \
diff --git a/libguile/_scm.h b/libguile/_scm.h
index e40f29b..1a0a986 100644
--- a/libguile/_scm.h
+++ b/libguile/_scm.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000,2001, 2002, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/alist.c b/libguile/alist.c
index ca55b08..919bd22 100644
--- a/libguile/alist.c
+++ b/libguile/alist.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995, 96, 97, 98, 99, 2000, 2001, 2004, 2006, 2008 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/alist.h b/libguile/alist.h
index 76cccba..77c5656 100644
--- a/libguile/alist.h
+++ b/libguile/alist.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/arbiters.c b/libguile/arbiters.c
index a341ed6..cc68c85 100644
--- a/libguile/arbiters.c
+++ b/libguile/arbiters.c
@@ -1,18 +1,19 @@
 /*     Copyright (C) 1995,1996, 1997, 2000, 2001, 2004, 2005, 2006, 2008 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/arbiters.h b/libguile/arbiters.h
index 7a7dfd3..214e92a 100644
--- a/libguile/arbiters.h
+++ b/libguile/arbiters.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/async.c b/libguile/async.c
index 4dc5ea4..d3fb012 100644
--- a/libguile/async.c
+++ b/libguile/async.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2002, 2004, 2006, 2008 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/async.h b/libguile/async.h
index c01bde0..427d9b4 100644
--- a/libguile/async.h
+++ b/libguile/async.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2002, 2004, 2005, 2006, 2008 
Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/backtrace.c b/libguile/backtrace.c
index a8afcdf..8357905 100644
--- a/libguile/backtrace.c
+++ b/libguile/backtrace.c
@@ -2,18 +2,19 @@
  * Copyright (C) 1996,1997,1998,1999,2000,2001, 2003, 2004, 2006 Free Software 
Foundation
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/backtrace.h b/libguile/backtrace.h
index e11cb85..c065166 100644
--- a/libguile/backtrace.h
+++ b/libguile/backtrace.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1996,1998,1999,2000,2001, 2004, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/boolean.c b/libguile/boolean.c
index 4b06e04..d79bf79 100644
--- a/libguile/boolean.c
+++ b/libguile/boolean.c
@@ -1,18 +1,19 @@
 /*     Copyright (C) 1995, 1996, 2000, 2001, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/boolean.h b/libguile/boolean.h
index 1388c2f..5a83797 100644
--- a/libguile/boolean.h
+++ b/libguile/boolean.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/bytevectors.c b/libguile/bytevectors.c
index 1de4db0..fd9043a 100644
--- a/libguile/bytevectors.c
+++ b/libguile/bytevectors.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2009 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -25,6 +26,7 @@
 #include <gmp.h>
 
 #include "libguile/_scm.h"
+#include "libguile/extensions.h"
 #include "libguile/bytevectors.h"
 #include "libguile/strings.h"
 #include "libguile/validate.h"
@@ -73,7 +75,7 @@
 
 
 #define INTEGER_ACCESSOR_PROLOGUE(_len, _sign)                 \
-  unsigned c_len, c_index;                                     \
+  size_t c_len, c_index;                                       \
   _sign char *c_bv;                                            \
                                                                \
   SCM_VALIDATE_BYTEVECTOR (1, bv);                             \
@@ -171,7 +173,7 @@
 
 /* Bytevector type.  */
 
-SCM_GLOBAL_SMOB (scm_tc16_bytevector, "r6rs-bytevector", 0);
+scm_t_bits scm_tc16_bytevector;
 
 #define SCM_BYTEVECTOR_SET_LENGTH(_bv, _len)   \
   SCM_SET_SMOB_DATA ((_bv), (scm_t_bits) (_len))
@@ -183,14 +185,14 @@ SCM scm_null_bytevector = SCM_UNSPECIFIED;
 
 
 static inline SCM
-make_bytevector_from_buffer (unsigned len, signed char *contents)
+make_bytevector_from_buffer (size_t len, signed char *contents)
 {
   /* Assuming LEN > SCM_BYTEVECTOR_INLINE_THRESHOLD.  */
   SCM_RETURN_NEWSMOB2 (scm_tc16_bytevector, len, contents);
 }
 
 static inline SCM
-make_bytevector (unsigned len)
+make_bytevector (size_t len)
 {
   SCM bv;
 
@@ -211,7 +213,7 @@ make_bytevector (unsigned len)
 
 /* Return a new bytevector of size LEN octets.  */
 SCM
-scm_c_make_bytevector (unsigned len)
+scm_c_make_bytevector (size_t len)
 {
   return (make_bytevector (len));
 }
@@ -219,7 +221,7 @@ scm_c_make_bytevector (unsigned len)
 /* Return a bytevector of size LEN made up of CONTENTS.  The area pointed to
    by CONTENTS must have been allocated using `scm_gc_malloc ()'.  */
 SCM
-scm_c_take_bytevector (signed char *contents, unsigned len)
+scm_c_take_bytevector (signed char *contents, size_t len)
 {
   SCM bv;
 
@@ -242,11 +244,11 @@ scm_c_take_bytevector (signed char *contents, unsigned 
len)
 /* Shrink BV to C_NEW_LEN (which is assumed to be smaller than its current
    size) and return BV.  */
 SCM
-scm_i_shrink_bytevector (SCM bv, unsigned c_new_len)
+scm_i_shrink_bytevector (SCM bv, size_t c_new_len)
 {
   if (!SCM_BYTEVECTOR_INLINE_P (bv))
     {
-      unsigned c_len;
+      size_t c_len;
       signed char *c_bv, *c_new_bv;
 
       c_len = SCM_BYTEVECTOR_LENGTH (bv);
@@ -273,8 +275,71 @@ scm_i_shrink_bytevector (SCM bv, unsigned c_new_len)
   return bv;
 }
 
-SCM_SMOB_PRINT (scm_tc16_bytevector, print_bytevector,
-               bv, port, pstate)
+int
+scm_is_bytevector (SCM obj)
+{
+  return SCM_SMOB_PREDICATE (scm_tc16_bytevector, obj);
+}
+
+size_t
+scm_c_bytevector_length (SCM bv)
+#define FUNC_NAME "scm_c_bytevector_length"
+{
+  SCM_VALIDATE_BYTEVECTOR (1, bv);
+
+  return SCM_BYTEVECTOR_LENGTH (bv);
+}
+#undef FUNC_NAME
+
+scm_t_uint8
+scm_c_bytevector_ref (SCM bv, size_t index)
+#define FUNC_NAME "scm_c_bytevector_ref"
+{
+  size_t c_len;
+  const scm_t_uint8 *c_bv;
+
+  SCM_VALIDATE_BYTEVECTOR (1, bv);
+
+  c_len = SCM_BYTEVECTOR_LENGTH (bv);
+  c_bv = (scm_t_uint8 *) SCM_BYTEVECTOR_CONTENTS (bv);
+
+  if (SCM_UNLIKELY (index >= c_len))
+    scm_out_of_range (FUNC_NAME, scm_from_size_t (index));
+
+  return c_bv[index];
+}
+#undef FUNC_NAME
+
+void
+scm_c_bytevector_set_x (SCM bv, size_t index, scm_t_uint8 value)
+#define FUNC_NAME "scm_c_bytevector_set_x"
+{
+  size_t c_len;
+  scm_t_uint8 *c_bv;
+
+  SCM_VALIDATE_BYTEVECTOR (1, bv);
+
+  c_len = SCM_BYTEVECTOR_LENGTH (bv);
+  c_bv = (scm_t_uint8 *) SCM_BYTEVECTOR_CONTENTS (bv);
+
+  if (SCM_UNLIKELY (index >= c_len))
+    scm_out_of_range (FUNC_NAME, scm_from_size_t (index));
+
+  c_bv[index] = value;
+}
+#undef FUNC_NAME
+
+/* This procedure is used by `scm_c_generalized_vector_set_x ()'.  */
+void
+scm_i_bytevector_generalized_set_x (SCM bv, size_t index, SCM value)
+#define FUNC_NAME "scm_i_bytevector_generalized_set_x"
+{
+  scm_c_bytevector_set_x (bv, index, scm_to_uint8 (value));
+}
+#undef FUNC_NAME
+
+static int
+print_bytevector (SCM bv, SCM port, scm_print_state *pstate)
 {
   unsigned c_len, i;
   unsigned char *c_bv;
@@ -299,7 +364,14 @@ SCM_SMOB_PRINT (scm_tc16_bytevector, print_bytevector,
   return 1;
 }
 
-SCM_SMOB_FREE (scm_tc16_bytevector, free_bytevector, bv)
+static SCM
+bytevector_equal_p (SCM bv1, SCM bv2)
+{
+  return scm_bytevector_eq_p (bv1, bv2);
+}
+
+static size_t
+free_bytevector (SCM bv)
 {
 
   if (!SCM_BYTEVECTOR_INLINE_P (bv))
@@ -351,8 +423,7 @@ SCM_DEFINE (scm_bytevector_p, "bytevector?", 1, 0, 0,
            "Return true if @var{obj} is a bytevector.")
 #define FUNC_NAME s_scm_bytevector_p
 {
-  return (scm_from_bool (SCM_SMOB_PREDICATE (scm_tc16_bytevector,
-                                            obj)));
+  return scm_from_bool (scm_is_bytevector (obj));
 }
 #undef FUNC_NAME
 
@@ -397,9 +468,7 @@ SCM_DEFINE (scm_bytevector_length, "bytevector-length", 1, 
0, 0,
            "Return the length (in bytes) of @var{bv}.")
 #define FUNC_NAME s_scm_bytevector_length
 {
-  SCM_VALIDATE_BYTEVECTOR (1, bv);
-
-  return (scm_from_uint (SCM_BYTEVECTOR_LENGTH (bv)));
+  return scm_from_uint (scm_c_bytevector_length (bv));
 }
 #undef FUNC_NAME
 
@@ -1993,6 +2062,25 @@ SCM_DEFINE (scm_utf32_to_string, "utf32->string",
 /* Initialization.  */
 
 void
+scm_bootstrap_bytevectors (void)
+{
+  /* The SMOB type must be instantiated here because the
+     generalized-vector API may want to access bytevectors even though
+     `(rnrs bytevector)' hasn't been loaded.  */
+  scm_tc16_bytevector = scm_make_smob_type ("bytevector", 0);
+  scm_set_smob_free (scm_tc16_bytevector, free_bytevector);
+  scm_set_smob_print (scm_tc16_bytevector, print_bytevector);
+  scm_set_smob_equalp (scm_tc16_bytevector, bytevector_equal_p);
+
+  scm_null_bytevector =
+    scm_gc_protect_object (make_bytevector_from_buffer (0, NULL));
+
+  scm_c_register_extension ("libguile", "scm_init_bytevectors",
+                           (scm_t_extension_init_func) scm_init_bytevectors,
+                           NULL);
+}
+
+void
 scm_init_bytevectors (void)
 {
 #include "libguile/bytevectors.x"
@@ -2005,7 +2093,4 @@ scm_init_bytevectors (void)
 
   scm_endianness_big = scm_sym_big;
   scm_endianness_little = scm_sym_little;
-
-  scm_null_bytevector =
-    scm_gc_protect_object (make_bytevector_from_buffer (0, NULL));
 }
diff --git a/libguile/bytevectors.h b/libguile/bytevectors.h
index b01116c..903ce7a 100644
--- a/libguile/bytevectors.h
+++ b/libguile/bytevectors.h
@@ -4,18 +4,19 @@
 /* Copyright (C) 2009 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -26,7 +27,7 @@
 /* R6RS bytevectors.  */
 
 #define SCM_BYTEVECTOR_LENGTH(_bv)             \
-  ((unsigned) SCM_SMOB_DATA (_bv))
+  ((size_t) SCM_SMOB_DATA (_bv))
 #define SCM_BYTEVECTOR_CONTENTS(_bv)           \
   (SCM_BYTEVECTOR_INLINE_P (_bv)                       \
    ? (signed char *) SCM_SMOB_OBJECT_2_LOC (_bv)       \
@@ -36,8 +37,13 @@
 SCM_API SCM scm_endianness_big;
 SCM_API SCM scm_endianness_little;
 
+SCM_API SCM scm_c_make_bytevector (size_t);
+SCM_API int scm_is_bytevector (SCM);
+SCM_API size_t scm_c_bytevector_length (SCM);
+SCM_API scm_t_uint8 scm_c_bytevector_ref (SCM, size_t);
+SCM_API void scm_c_bytevector_set_x (SCM, size_t, scm_t_uint8);
+
 SCM_API SCM scm_make_bytevector (SCM, SCM);
-SCM_API SCM scm_c_make_bytevector (unsigned);
 SCM_API SCM scm_native_endianness (void);
 SCM_API SCM scm_bytevector_p (SCM);
 SCM_API SCM scm_bytevector_length (SCM);
@@ -119,17 +125,19 @@ SCM_API SCM scm_utf32_to_string (SCM, SCM);
 /* Hint that is passed to `scm_gc_malloc ()' and friends.  */
 #define SCM_GC_BYTEVECTOR "bytevector"
 
-SCM_API void scm_init_bytevectors (void);
+SCM_INTERNAL void scm_bootstrap_bytevectors (void);
+SCM_INTERNAL void scm_init_bytevectors (void);
 
 SCM_INTERNAL scm_t_bits scm_tc16_bytevector;
-SCM_INTERNAL SCM scm_c_take_bytevector (signed char *, unsigned);
+SCM_INTERNAL SCM scm_c_take_bytevector (signed char *, size_t);
 
 #define scm_c_shrink_bytevector(_bv, _len)             \
   (SCM_BYTEVECTOR_INLINE_P (_bv)                       \
    ? (_bv)                                             \
    : scm_i_shrink_bytevector ((_bv), (_len)))
 
-SCM_INTERNAL SCM scm_i_shrink_bytevector (SCM, unsigned);
+SCM_INTERNAL SCM scm_i_shrink_bytevector (SCM, size_t);
+SCM_INTERNAL void scm_i_bytevector_generalized_set_x (SCM, size_t, SCM);
 SCM_INTERNAL SCM scm_null_bytevector;
 
 #endif /* SCM_BYTEVECTORS_H */
diff --git a/libguile/chars.c b/libguile/chars.c
index b59e586..94f2740 100644
--- a/libguile/chars.c
+++ b/libguile/chars.c
@@ -1,18 +1,19 @@
 /*     Copyright (C) 1995,1996,1998, 2000, 2001, 2004, 2006, 2008 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/chars.h b/libguile/chars.h
index 42e4f7b..ac1c294 100644
--- a/libguile/chars.h
+++ b/libguile/chars.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000,2001,2004, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -37,9 +38,10 @@ typedef scm_t_int32 scm_t_wchar;
 #define SCM_CHAR(x) ((scm_t_wchar)SCM_ITAG8_DATA(x))
 #define SCM_MAKE_CHAR(x) (scm_i_make_char(x))
 
-#define SCM_IS_UNICODE_CHAR(c)                                         \
-  ((scm_t_wchar)(c)<=0xd7ff ||                                 \
-   ((scm_t_wchar)(c)>=0xe000 && (scm_t_wchar)(c)<=0x10ffff))
+#define SCM_CODEPOINT_MAX (0x10ffff)
+#define SCM_IS_UNICODE_CHAR(c)                                          \
+  ((scm_t_wchar)(c)<=0xd7ff ||                                          \
+   ((scm_t_wchar)(c)>=0xe000 && (scm_t_wchar)(c)<=SCM_CODEPOINT_MAX))
 
 
 
diff --git a/libguile/continuations.c b/libguile/continuations.c
index dc14569..f856476 100644
--- a/libguile/continuations.c
+++ b/libguile/continuations.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1998,2000,2001,2004, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/continuations.h b/libguile/continuations.h
index e5fd91f..08eec8f 100644
--- a/libguile/continuations.h
+++ b/libguile/continuations.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/convert.c b/libguile/convert.c
index 700deaa..d87d724 100644
--- a/libguile/convert.c
+++ b/libguile/convert.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2002, 2006 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/convert.h b/libguile/convert.h
index f834a6b..6ce7c22 100644
--- a/libguile/convert.h
+++ b/libguile/convert.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2002, 2006 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/debug-malloc.c b/libguile/debug-malloc.c
index 4d04df5..fa3612d 100644
--- a/libguile/debug-malloc.c
+++ b/libguile/debug-malloc.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/debug-malloc.h b/libguile/debug-malloc.h
index 1aa5221..7830adb 100644
--- a/libguile/debug-malloc.h
+++ b/libguile/debug-malloc.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/debug.c b/libguile/debug.c
index 5042fbb..71278c5 100644
--- a/libguile/debug.c
+++ b/libguile/debug.c
@@ -2,18 +2,19 @@
  * Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2003, 2006, 2008, 
2009 Free Software Foundation
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -308,7 +309,7 @@ SCM_DEFINE (scm_procedure_name, "procedure-name", 1, 0, 0,
   SCM_VALIDATE_PROC (1, proc);
   switch (SCM_TYP7 (proc)) {
   case scm_tcs_subrs:
-    return SCM_SNAME (proc);
+    return SCM_SUBR_NAME (proc);
   default:
     {
       SCM name = scm_procedure_property (proc, scm_sym_name);
diff --git a/libguile/debug.h b/libguile/debug.h
index 4d16fd8..20febdb 100644
--- a/libguile/debug.h
+++ b/libguile/debug.h
@@ -7,18 +7,19 @@
  * Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/deprecated.c b/libguile/deprecated.c
index af30a7c..dd7f5fd 100644
--- a/libguile/deprecated.c
+++ b/libguile/deprecated.c
@@ -5,18 +5,19 @@
 /* Copyright (C) 2003, 2004, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/deprecated.h b/libguile/deprecated.h
index 6285916..77ba6bb 100644
--- a/libguile/deprecated.h
+++ b/libguile/deprecated.h
@@ -8,18 +8,19 @@
 /* Copyright (C) 2003,2004, 2005, 2006, 2007 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #include "libguile/__scm.h"
diff --git a/libguile/deprecation.c b/libguile/deprecation.c
index 780e246..af8b936 100644
--- a/libguile/deprecation.c
+++ b/libguile/deprecation.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001, 2006 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -171,4 +172,5 @@ scm_init_deprecation ()
 /*
   Local Variables:
   c-file-style: "gnu"
-  End: */
+  End:
+ */
diff --git a/libguile/deprecation.h b/libguile/deprecation.h
index 9752d9b..06027c6 100644
--- a/libguile/deprecation.h
+++ b/libguile/deprecation.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2001, 2006, 2008, 2009 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/discouraged.c b/libguile/discouraged.c
index 203a1c7..ff9ff90 100644
--- a/libguile/discouraged.c
+++ b/libguile/discouraged.c
@@ -5,18 +5,19 @@
 /* Copyright (C) 2003, 2004, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/discouraged.h b/libguile/discouraged.h
index 6e537bf..1be05f0 100644
--- a/libguile/discouraged.h
+++ b/libguile/discouraged.h
@@ -16,18 +16,19 @@
 /* Copyright (C) 2004, 2006 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #include "libguile/__scm.h"
diff --git a/libguile/dynl.c b/libguile/dynl.c
index b2f0fb9..9ac4d4f 100644
--- a/libguile/dynl.c
+++ b/libguile/dynl.c
@@ -4,18 +4,19 @@
  * 2003, 2008 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/dynl.h b/libguile/dynl.h
index 72dc92e..eb318ae 100644
--- a/libguile/dynl.h
+++ b/libguile/dynl.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1996,1998,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/dynwind.c b/libguile/dynwind.c
index 999ba23..a45c5b5 100644
--- a/libguile/dynwind.c
+++ b/libguile/dynwind.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2001, 2003, 2004, 2006, 2008 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/dynwind.h b/libguile/dynwind.h
index dd39dae..b178bc4 100644
--- a/libguile/dynwind.h
+++ b/libguile/dynwind.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2003,2004, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/environments.c b/libguile/environments.c
index b81527e..fae936a 100644
--- a/libguile/environments.c
+++ b/libguile/environments.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1999,2000,2001, 2003, 2006, 2008 Free Software Foundation, 
Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/environments.h b/libguile/environments.h
index 10d42a7..5680662 100644
--- a/libguile/environments.h
+++ b/libguile/environments.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1999,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/eq.c b/libguile/eq.c
index b54a704..255c381 100644
--- a/libguile/eq.c
+++ b/libguile/eq.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001,2003, 2004, 2006 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/eq.h b/libguile/eq.h
index af6959f..1aeb1c4 100644
--- a/libguile/eq.h
+++ b/libguile/eq.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/error.c b/libguile/error.c
index cfe2422..bcbcd9c 100644
--- a/libguile/error.c
+++ b/libguile/error.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2004, 2006 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/error.h b/libguile/error.h
index bdfbfc3..8cc68b7 100644
--- a/libguile/error.h
+++ b/libguile/error.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2002, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/eval.c b/libguile/eval.c
index 6477d05..58eb78b 100644
--- a/libguile/eval.c
+++ b/libguile/eval.c
@@ -2,18 +2,19 @@
  * Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/eval.h b/libguile/eval.h
index b017f2e..0d42238 100644
--- a/libguile/eval.h
+++ b/libguile/eval.h
@@ -7,18 +7,19 @@
  * Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/eval.i.c b/libguile/eval.i.c
index 463aa25..4aebe04 100644
--- a/libguile/eval.i.c
+++ b/libguile/eval.i.c
@@ -4,18 +4,19 @@
  * Copyright (C) 2002, 03, 04, 05, 06, 07, 09 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #undef RETURN
diff --git a/libguile/evalext.c b/libguile/evalext.c
index 5ca7806..56f74e2 100644
--- a/libguile/evalext.c
+++ b/libguile/evalext.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1998,1999,2000,2001,2002,2003, 2006, 2008, 2009 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/evalext.h b/libguile/evalext.h
index a6a4a9f..fc3f1e6 100644
--- a/libguile/evalext.h
+++ b/libguile/evalext.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1998,1999,2000, 2003, 2006, 2008 Free Software Foundation, 
Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/extensions.c b/libguile/extensions.c
index 29cb58c..54351dd 100644
--- a/libguile/extensions.c
+++ b/libguile/extensions.c
@@ -3,18 +3,19 @@
  * Copyright (C) 2001, 2006 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/extensions.h b/libguile/extensions.h
index 260567e..765f9be 100644
--- a/libguile/extensions.h
+++ b/libguile/extensions.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/feature.c b/libguile/feature.c
index 8283cd6..9ef4b65 100644
--- a/libguile/feature.c
+++ b/libguile/feature.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2001,2002, 2003, 2004, 2006, 2007 
Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/feature.h b/libguile/feature.h
index 8c6371e..d373bc7 100644
--- a/libguile/feature.h
+++ b/libguile/feature.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1999,2000,2001, 2006, 2007, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/filesys.c b/libguile/filesys.c
index ae79d62..76f65a2 100644
--- a/libguile/filesys.c
+++ b/libguile/filesys.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1996,1997,1998,1999,2000,2001, 2002, 2004, 2006 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -29,6 +30,7 @@
 #endif
 
 #include <alloca.h>
+#include <canonicalize.h>
 
 #include <stdio.h>
 #include <errno.h>
@@ -1673,6 +1675,27 @@ SCM_DEFINE (scm_basename, "basename", 1, 1, 0,
 }
 #undef FUNC_NAME
 
+SCM_DEFINE (scm_canonicalize_path, "canonicalize-path", 1, 0, 0, 
+            (SCM path),
+           "Return the canonical path of @var{path}. A canonical path has\n"
+            "no @code{.} or @code{..} components, nor any repeated path\n"
+            "separators (@code{/}) nor symlinks.\n\n"
+            "Raises an error if any component of @var{path} does not exist.")
+#define FUNC_NAME s_scm_canonicalize_path
+{ char *str, *canon;
+  
+  SCM_VALIDATE_STRING (1, path);
+
+  str = scm_to_locale_string (path);
+  canon = canonicalize_file_name (str);
+  free (str);
+  
+  if (canon)
+    return scm_take_locale_string (canon);
+  else
+    SCM_SYSERROR;
+}
+#undef FUNC_NAME
 
 
 
diff --git a/libguile/filesys.h b/libguile/filesys.h
index cf0a6ac..b9a6ca8 100644
--- a/libguile/filesys.h
+++ b/libguile/filesys.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1997,1998,1999,2000,2001, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -64,6 +65,7 @@ SCM_API SCM scm_lstat (SCM str);
 SCM_API SCM scm_copy_file (SCM oldfile, SCM newfile);
 SCM_API SCM scm_dirname (SCM filename);
 SCM_API SCM scm_basename (SCM filename, SCM suffix);
+SCM_API SCM scm_canonicalize_path (SCM path);
 
 SCM_INTERNAL void scm_init_filesys (void);
 
diff --git a/libguile/fluids.c b/libguile/fluids.c
index 4311a49..bcd04c4 100644
--- a/libguile/fluids.c
+++ b/libguile/fluids.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1996,1997,2000,2001, 2004, 2006, 2007, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/fluids.h b/libguile/fluids.h
index c48a8c3..cf424fa 100644
--- a/libguile/fluids.h
+++ b/libguile/fluids.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1996,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/fports.c b/libguile/fports.c
index bcbb570..c6d1f1a 100644
--- a/libguile/fports.c
+++ b/libguile/fports.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2003, 2004, 2006, 
2007, 2008 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/fports.h b/libguile/fports.h
index c737b1e..2687504 100644
--- a/libguile/fports.h
+++ b/libguile/fports.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/frames.c b/libguile/frames.c
index c08fd31..76552f5 100644
--- a/libguile/frames.c
+++ b/libguile/frames.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #if HAVE_CONFIG_H
diff --git a/libguile/frames.h b/libguile/frames.h
index d74476a..99623fb 100644
--- a/libguile/frames.h
+++ b/libguile/frames.h
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifndef _SCM_FRAMES_H_
diff --git a/libguile/futures.c b/libguile/futures.c
index 5b1a3fb..ad70f7f 100644
--- a/libguile/futures.c
+++ b/libguile/futures.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2002, 2003, 2006, 2008 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/futures.h b/libguile/futures.h
index 95916f3..5d7712e 100644
--- a/libguile/futures.h
+++ b/libguile/futures.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2002, 2003, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/gc-card.c b/libguile/gc-card.c
index 0629da0..85520f8 100644
--- a/libguile/gc-card.c
+++ b/libguile/gc-card.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2004, 2005, 2006, 
2007, 2008, 2009 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/gc-freelist.c b/libguile/gc-freelist.c
index 4dd77aa..54a10e7 100644
--- a/libguile/gc-freelist.c
+++ b/libguile/gc-freelist.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2006, 2008 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/gc-malloc.c b/libguile/gc-malloc.c
index cdc985e..d6973d3 100644
--- a/libguile/gc-malloc.c
+++ b/libguile/gc-malloc.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2003, 2004, 2006, 
2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/gc-mark.c b/libguile/gc-mark.c
index a876b4b..c70d461 100644
--- a/libguile/gc-mark.c
+++ b/libguile/gc-mark.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2003, 2004, 2005, 
2006, 2009 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/gc-segment-table.c b/libguile/gc-segment-table.c
index 3e92c8c..75d109c 100644
--- a/libguile/gc-segment-table.c
+++ b/libguile/gc-segment-table.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2006, 2008 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/gc-segment.c b/libguile/gc-segment.c
index 4f98cbc..7a937e6 100644
--- a/libguile/gc-segment.c
+++ b/libguile/gc-segment.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2006, 2008 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/gc.c b/libguile/gc.c
index ce8c8af..b7a3bf0 100644
--- a/libguile/gc.c
+++ b/libguile/gc.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2003, 2006, 2008 
Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 /* #define DEBUGINFO */
diff --git a/libguile/gc.h b/libguile/gc.h
index 58ac772..8db76e3 100644
--- a/libguile/gc.h
+++ b/libguile/gc.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2001, 2002, 2003, 2004, 2006, 2008 
Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/gdb_interface.h b/libguile/gdb_interface.h
index 5be4d07..2278fc2 100644
--- a/libguile/gdb_interface.h
+++ b/libguile/gdb_interface.h
@@ -5,19 +5,20 @@
 /* Simple interpreter interface for GDB, the GNU debugger.
    Copyright (C) 1996, 2000, 2001, 2006 Free Software Foundation
 
- This library 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 2.1 of the License, or (at your option) any later version.
-
- This library 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 library; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * This library 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 of
+ * the License, or (at your option) any later version.
+ *
+ * This library 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 library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
 
 The author can be reached at address@hidden
 Mikael Djurfeldt, SANS/NADA KTH, 10044 STOCKHOLM, SWEDEN  */
diff --git a/libguile/gdbint.c b/libguile/gdbint.c
index b9c25c9..0f74ce1 100644
--- a/libguile/gdbint.c
+++ b/libguile/gdbint.c
@@ -3,18 +3,19 @@
  * Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/gdbint.h b/libguile/gdbint.h
index 64b9559..d7c6cf3 100644
--- a/libguile/gdbint.h
+++ b/libguile/gdbint.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1996,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/gettext.c b/libguile/gettext.c
index e74f9f3..2ae3ae5 100644
--- a/libguile/gettext.c
+++ b/libguile/gettext.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2004, 2006 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/gettext.h b/libguile/gettext.h
index 8a13307..d4576bd 100644
--- a/libguile/gettext.h
+++ b/libguile/gettext.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2004, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #include "libguile/__scm.h"
diff --git a/libguile/goops.c b/libguile/goops.c
index 38c63d0..d9fcc91 100644
--- a/libguile/goops.c
+++ b/libguile/goops.c
@@ -2,18 +2,19 @@
  * Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -1863,7 +1864,7 @@ SCM_DEFINE (scm_enable_primitive_generic_x, 
"enable-primitive-generic!", 0, 0, 1
       *SCM_SUBR_GENERIC (subr)
        = scm_make (scm_list_3 (scm_class_generic,
                                k_name,
-                               SCM_SNAME (subr)));
+                               SCM_SUBR_NAME (subr)));
       subrs = SCM_CDR (subrs);
     }
   return SCM_UNSPECIFIED;
@@ -1906,7 +1907,7 @@ scm_c_extend_primitive_generic (SCM extended, SCM 
extension)
       gf = *SCM_SUBR_GENERIC (extended);
       gext = scm_call_2 (SCM_VARIABLE_REF (scm_var_make_extended_generic),
                         gf,
-                        SCM_SNAME (extension));
+                        SCM_SUBR_NAME (extension));
       SCM_SET_SUBR_GENERIC (extension, gext);
     }
   else
diff --git a/libguile/goops.h b/libguile/goops.h
index d43d736..8d13823 100644
--- a/libguile/goops.h
+++ b/libguile/goops.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1998,1999,2000,2001,2002,2003, 2006, 2008, 2009 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/gsubr.c b/libguile/gsubr.c
index 5e5b4c1..3b73155 100644
--- a/libguile/gsubr.c
+++ b/libguile/gsubr.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2006, 2008, 2009 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -93,7 +94,7 @@ create_gsubr (int define, const char *name,
     }
 
   if (define)
-    scm_define (SCM_SNAME (subr), subr);
+    scm_define (SCM_SUBR_NAME (subr), subr);
 
   return subr;
 }
@@ -148,7 +149,7 @@ create_gsubr_with_generic (int define,
       subr = scm_c_make_subr_with_generic (name, scm_tc7_lsubr_2, fcn, gf);
     create_subr:
       if (define)
-       scm_define (SCM_SNAME (subr), subr);
+       scm_define (SCM_SUBR_NAME (subr), subr);
       return subr;
     default:
       ;
@@ -195,7 +196,7 @@ gsubr_apply_raw (SCM proc, unsigned int argc, const SCM 
*argv)
 
   if (SCM_UNLIKELY (argc != argc_max))
     /* We expect the exact argument count.  */
-    scm_wrong_num_args (SCM_SNAME (proc));
+    scm_wrong_num_args (SCM_SUBR_NAME (proc));
 
   fcn = SCM_SUBRF (proc);
 
@@ -228,7 +229,7 @@ gsubr_apply_raw (SCM proc, unsigned int argc, const SCM 
*argv)
       return (*fcn) (argv[0], argv[1], argv[2], argv[3], argv[4], argv[5],
                     argv[6], argv[7], argv[8], argv[9]);
     default:
-      scm_misc_error ((char *) SCM_SNAME (proc),
+      scm_misc_error ((char *) SCM_SUBR_NAME (proc),
                      "gsubr invocation with more than 10 arguments not 
implemented",
                      SCM_EOL);
     }
@@ -257,7 +258,7 @@ scm_i_gsubr_apply (SCM proc, SCM arg, ...)
     argv[argc] = arg;
 
   if (SCM_UNLIKELY (argc < SCM_GSUBR_REQ (type)))
-    scm_wrong_num_args (SCM_SNAME (proc));
+    scm_wrong_num_args (SCM_SUBR_NAME (proc));
 
   /* Fill in optional arguments that were not passed.  */
   while (argc < argc_max)
@@ -295,7 +296,7 @@ scm_i_gsubr_apply_list (SCM self, SCM args)
 
   for (i = 0; i < SCM_GSUBR_REQ (typ); i++) {
     if (scm_is_null (args))
-      scm_wrong_num_args (SCM_SNAME (self));
+      scm_wrong_num_args (SCM_SUBR_NAME (self));
     v[i] = SCM_CAR(args);
     args = SCM_CDR(args);
   }
@@ -310,7 +311,7 @@ scm_i_gsubr_apply_list (SCM self, SCM args)
   if (SCM_GSUBR_REST(typ))
     v[i] = args;
   else if (!scm_is_null (args))
-    scm_wrong_num_args (SCM_SNAME (self));
+    scm_wrong_num_args (SCM_SUBR_NAME (self));
 
   return gsubr_apply_raw (self, n, v);
 }
diff --git a/libguile/gsubr.h b/libguile/gsubr.h
index 65680a0..298181b 100644
--- a/libguile/gsubr.h
+++ b/libguile/gsubr.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,2000,2001, 2006, 2008, 2009 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/guardians.c b/libguile/guardians.c
index e2af784..f7bbb4b 100644
--- a/libguile/guardians.c
+++ b/libguile/guardians.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1998,1999,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/guardians.h b/libguile/guardians.h
index 295092e..a23026d 100644
--- a/libguile/guardians.h
+++ b/libguile/guardians.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1998,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/guile-doc-snarf.in b/libguile/guile-doc-snarf.in
index 49be291..a787d5a 100755
--- a/libguile/guile-doc-snarf.in
+++ b/libguile/guile-doc-snarf.in
@@ -4,19 +4,19 @@
 #  Copyright (C) 1999, 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 General Public License as published by
-# the Free Software Foundation; either version 2, 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 General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this software; see the file COPYING.  If not, write to
-# the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-# Boston, MA 02110-1301 USA
+# 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
 
 fullfilename=$1
 
diff --git a/libguile/guile-func-name-check.in 
b/libguile/guile-func-name-check.in
index 7f0114e..8b4924e 100644
--- a/libguile/guile-func-name-check.in
+++ b/libguile/guile-func-name-check.in
@@ -3,19 +3,19 @@
 #  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 General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
+# 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 General Public License for more details.
+# 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 General Public License
-# along with this software; see the file COPYING.  If not, write to
-# the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-# Boston, MA 02110-1301 USA
+# 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, <address@hidden>
 # 11-Jan-2000
diff --git a/libguile/guile-snarf-docs.in b/libguile/guile-snarf-docs.in
index 9cba3dc..1e57f26 100755
--- a/libguile/guile-snarf-docs.in
+++ b/libguile/guile-snarf-docs.in
@@ -4,19 +4,19 @@
 #  Copyright (C) 1996, 1997, 1998, 1999, 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 General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
+# 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 General Public License for more details.
+# 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 General Public License
-# along with this software; see the file COPYING.  If not, write to
-# the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-# Boston, MA 02110-1301 USA
+# 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
 
 bindir=`dirname $0`
 
diff --git a/libguile/guile-snarf.awk.in b/libguile/guile-snarf.awk.in
index be3b123..8a720a0 100644
--- a/libguile/guile-snarf.awk.in
+++ b/libguile/guile-snarf.awk.in
@@ -1,19 +1,19 @@
 #  Copyright (C) 1999, 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 General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
+# 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 General Public License for more details.
+# 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 General Public License
-# along with this software; see the file COPYING.  If not, write to
-# the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-# Boston, MA 02110-1301 USA
+# 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, <address@hidden>
 # 12-Dec-1999
diff --git a/libguile/guile-snarf.in b/libguile/guile-snarf.in
index 617bad8..6a72dd5 100644
--- a/libguile/guile-snarf.in
+++ b/libguile/guile-snarf.in
@@ -4,19 +4,19 @@
 #  Copyright (C) 1996, 97, 98, 99, 2000, 2001, 2002, 2004, 2006, 2008 Free 
Software Foundation, Inc.
 #
 # This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, 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 General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this software; see the file COPYING.  If not, write to
-# the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-# Boston, MA 02110-1301 USA
+# 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
 
 # Commentary:
 
diff --git a/libguile/guile.c b/libguile/guile.c
index c8341c2..6da547b 100644
--- a/libguile/guile.c
+++ b/libguile/guile.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1996,1997,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 /* This is the 'main' function for the `guile' executable.  It is not
diff --git a/libguile/hash.c b/libguile/hash.c
index 1cf8819..3e976cc 100644
--- a/libguile/hash.c
+++ b/libguile/hash.c
@@ -1,18 +1,19 @@
 /*     Copyright (C) 1995,1996,1997, 2000, 2001, 2003, 2004, 2006, 2008 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/hash.h b/libguile/hash.h
index 879f510..2ebc053 100644
--- a/libguile/hash.h
+++ b/libguile/hash.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/hashtab.c b/libguile/hashtab.c
index 79e635f..e3a6c43 100644
--- a/libguile/hashtab.c
+++ b/libguile/hashtab.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2001, 2003, 2004, 2006, 2008 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/hashtab.h b/libguile/hashtab.h
index 4220b86..13100f0 100644
--- a/libguile/hashtab.h
+++ b/libguile/hashtab.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1999,2000,2001, 2003, 2004, 2006, 2008 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/hooks.c b/libguile/hooks.c
index 5ca8580..d6b8981 100644
--- a/libguile/hooks.c
+++ b/libguile/hooks.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2001, 2003, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/hooks.h b/libguile/hooks.h
index 49ea553..15b57fa 100644
--- a/libguile/hooks.h
+++ b/libguile/hooks.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1999,2000,2001, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/i18n.c b/libguile/i18n.c
index 1b40159..412187a 100644
--- a/libguile/i18n.c
+++ b/libguile/i18n.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2006, 2007, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/i18n.h b/libguile/i18n.h
index 57f1654..df2970b 100644
--- a/libguile/i18n.h
+++ b/libguile/i18n.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #include "libguile/__scm.h"
diff --git a/libguile/init.c b/libguile/init.c
index c72aeff..5ece01f 100644
--- a/libguile/init.c
+++ b/libguile/init.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2003, 2004, 2006, 
2009 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -37,6 +38,7 @@
 #include "libguile/async.h"
 #include "libguile/backtrace.h"
 #include "libguile/boolean.h"
+#include "libguile/bytevectors.h"
 #include "libguile/chars.h"
 #include "libguile/continuations.h"
 #include "libguile/debug.h"
@@ -572,6 +574,7 @@ scm_i_init_guile (SCM_STACKITEM *base)
   scm_init_rw ();
   scm_init_extensions ();
 
+  scm_bootstrap_bytevectors ();
   scm_bootstrap_vm ();
 
   atexit (cleanup_for_exit);
diff --git a/libguile/init.h b/libguile/init.h
index 3ae27d8..7cfae76 100644
--- a/libguile/init.h
+++ b/libguile/init.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/inline.c b/libguile/inline.c
index a0c2500..79728ff 100644
--- a/libguile/inline.c
+++ b/libguile/inline.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/inline.h b/libguile/inline.h
index 23598db..be41c5c 100644
--- a/libguile/inline.h
+++ b/libguile/inline.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2001, 2002, 2003, 2004, 2006, 2008 Free Software Foundation, 
Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 /* This file is for inline functions.  On platforms that don't support
diff --git a/libguile/instructions.c b/libguile/instructions.c
index f0f52e4..a67684e 100644
--- a/libguile/instructions.c
+++ b/libguile/instructions.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #if HAVE_CONFIG_H
diff --git a/libguile/instructions.h b/libguile/instructions.h
index f4f45b3..c9fe6e9 100644
--- a/libguile/instructions.h
+++ b/libguile/instructions.h
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifndef _SCM_INSTRUCTIONS_H_
diff --git a/libguile/ioext.c b/libguile/ioext.c
index b542664..6b0c9b8 100644
--- a/libguile/ioext.c
+++ b/libguile/ioext.c
@@ -1,18 +1,19 @@
 /*     Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2006 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/ioext.h b/libguile/ioext.h
index 18289ea..1b7b93a 100644
--- a/libguile/ioext.h
+++ b/libguile/ioext.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/iselect.h b/libguile/iselect.h
index 5a4b30d..760d959 100644
--- a/libguile/iselect.h
+++ b/libguile/iselect.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1997,1998,2000,2001, 2002, 2006 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/keywords.c b/libguile/keywords.c
index 0f9f13e..ee4c3ff 100644
--- a/libguile/keywords.c
+++ b/libguile/keywords.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2003, 2004, 2006, 2008 
Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/keywords.h b/libguile/keywords.h
index a80e31b..bfffe59 100644
--- a/libguile/keywords.h
+++ b/libguile/keywords.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1999,2000,2001, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/lang.c b/libguile/lang.c
index 7f3986c..85da680 100644
--- a/libguile/lang.c
+++ b/libguile/lang.c
@@ -1,18 +1,19 @@
 /*     Copyright (C) 1999, 2000, 2001, 2006, 2008 Free Software Foundation, 
Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/lang.h b/libguile/lang.h
index 991e9ca..47128de 100644
--- a/libguile/lang.h
+++ b/libguile/lang.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1998, 2004, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/list.c b/libguile/list.c
index 07b96f5..70f5277 100644
--- a/libguile/list.c
+++ b/libguile/list.c
@@ -2,18 +2,19 @@
  * Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/list.h b/libguile/list.h
index 733432d..427dcb8 100644
--- a/libguile/list.h
+++ b/libguile/list.h
@@ -7,18 +7,19 @@
  * Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/load.c b/libguile/load.c
index b68af3a..e81b584 100644
--- a/libguile/load.c
+++ b/libguile/load.c
@@ -1,18 +1,19 @@
-/* Copyright (C) 1995,1996,1998,1999,2000,2001, 2004, 2006 Free Software 
Foundation, Inc.
+/* Copyright (C) 1995,1996,1998,1999,2000,2001, 2004, 2006, 2009 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -252,24 +253,28 @@ scm_init_load_path ()
 #endif /* SCM_LIBRARY_DIR */
 
   {
-    char *home;
+    char cachedir[1024];
+    char *e;
+#ifdef HAVE_GETPWENT
+    struct passwd *pwd;
+#endif
 
-    home = getenv ("HOME");
+#define FALLBACK_DIR "guile/ccache/"SCM_EFFECTIVE_VERSION
+
+    if ((e = getenv ("XDG_CACHE_HOME")))
+      snprintf (cachedir, sizeof(cachedir), "%s" FALLBACK_DIR, e);
+    else if ((e = getenv ("HOME")))
+      snprintf (cachedir, sizeof(cachedir), "%s/.cache/" FALLBACK_DIR, e);
 #ifdef HAVE_GETPWENT
-    if (!home)
-      {
-        struct passwd *pwd;
-        pwd = getpwuid (getuid ());
-        if (pwd)
-          home = pwd->pw_dir;
-      }
+    else if ((pwd = getpwuid (getuid ())) && pwd->pw_dir)
+      snprintf (cachedir, sizeof(cachedir), "%s/.cache/" FALLBACK_DIR,
+                pwd->pw_dir);
 #endif /* HAVE_GETPWENT */
-    if (home)
-      { char buf[1024];
-        snprintf (buf, sizeof(buf),
-                  "%s/.guile-ccache/" SCM_EFFECTIVE_VERSION, home);
-        *scm_loc_compile_fallback_path = scm_from_locale_string (buf);
-      }
+    else
+      cachedir[0] = 0;
+
+    if (cachedir[0])
+      *scm_loc_compile_fallback_path = scm_from_locale_string (cachedir);
   }
 
   env = getenv ("GUILE_LOAD_PATH");
diff --git a/libguile/load.h b/libguile/load.h
index 0219873..d5bc1b0 100644
--- a/libguile/load.h
+++ b/libguile/load.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,2000,2001, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/locale-categories.h b/libguile/locale-categories.h
index cbe9684..26b030d 100644
--- a/libguile/locale-categories.h
+++ b/libguile/locale-categories.h
@@ -1,18 +1,19 @@
 /* Copyright (C) 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 /* A list of all available locale categories, not including `ALL'.  */
diff --git a/libguile/macros.c b/libguile/macros.c
index ca3e83e..a6a4c3e 100644
--- a/libguile/macros.c
+++ b/libguile/macros.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001,2002,2003, 2006, 2008 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/macros.h b/libguile/macros.h
index 5e3d64a..8ff41c4 100644
--- a/libguile/macros.h
+++ b/libguile/macros.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1998,2000,2001,2002,2003, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/mallocs.c b/libguile/mallocs.c
index c11a51f..296b312 100644
--- a/libguile/mallocs.c
+++ b/libguile/mallocs.c
@@ -2,18 +2,19 @@
  * Copyright (C) 1995,1997,1998,2000,2001, 2006 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/mallocs.h b/libguile/mallocs.h
index f711ddb..9c797e9 100644
--- a/libguile/mallocs.h
+++ b/libguile/mallocs.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/modules.c b/libguile/modules.c
index 689510c..ecd136d 100644
--- a/libguile/modules.c
+++ b/libguile/modules.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1998,2000,2001,2002,2003,2004,2006,2007,2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/modules.h b/libguile/modules.h
index 3cd0904..8108ac3 100644
--- a/libguile/modules.h
+++ b/libguile/modules.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1998, 2000, 2001, 2002, 2003, 2006, 2007, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/net_db.c b/libguile/net_db.c
index af6e3d5..4307091 100644
--- a/libguile/net_db.c
+++ b/libguile/net_db.c
@@ -2,18 +2,19 @@
  * Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2006, 2009 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/net_db.h b/libguile/net_db.h
index df1f030..4b6327f 100644
--- a/libguile/net_db.h
+++ b/libguile/net_db.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/null-threads.c b/libguile/null-threads.c
index 8140175..28eff2c 100644
--- a/libguile/null-threads.c
+++ b/libguile/null-threads.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2002, 2006, 2008 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/null-threads.h b/libguile/null-threads.h
index 5a61dbf..ec83ab7 100644
--- a/libguile/null-threads.h
+++ b/libguile/null-threads.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2005, 2006 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/numbers.c b/libguile/numbers.c
index 6edf826..4dd0e1f 100644
--- a/libguile/numbers.c
+++ b/libguile/numbers.c
@@ -5,18 +5,19 @@
  *
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/numbers.h b/libguile/numbers.h
index 330248d..39c5225 100644
--- a/libguile/numbers.h
+++ b/libguile/numbers.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,2000,2001,2002,2003,2004,2005, 2006, 2008 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/objcodes.c b/libguile/objcodes.c
index 6a0a11b..6b69fb7 100644
--- a/libguile/objcodes.c
+++ b/libguile/objcodes.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #if HAVE_CONFIG_H
@@ -65,7 +66,9 @@ make_objcode_by_mmap (int fd)
     SCM_SYSERROR;
 
   if (memcmp (addr, OBJCODE_COOKIE, strlen (OBJCODE_COOKIE)))
-    SCM_SYSERROR;
+    scm_misc_error (FUNC_NAME, "bad header on object file: ~s",
+                   scm_list_1 (scm_from_locale_stringn
+                                (addr, strlen (OBJCODE_COOKIE))));
 
   data = (struct scm_objcode*)(addr + strlen (OBJCODE_COOKIE));
 
diff --git a/libguile/objcodes.h b/libguile/objcodes.h
index acd43a6..21e4add 100644
--- a/libguile/objcodes.h
+++ b/libguile/objcodes.h
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
- * * 
+ *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifndef _SCM_OBJCODES_H_
diff --git a/libguile/objects.c b/libguile/objects.c
index e68ed37..e82fb9d 100644
--- a/libguile/objects.c
+++ b/libguile/objects.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1999,2000,2001, 2003, 2004, 2006, 2008 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/objects.h b/libguile/objects.h
index 9b2a0ed..914a7ea 100644
--- a/libguile/objects.h
+++ b/libguile/objects.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1996,1999,2000,2001, 2003, 2006, 2008, 2009 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/objprop.c b/libguile/objprop.c
index 8e9486f..6dd1da6 100644
--- a/libguile/objprop.c
+++ b/libguile/objprop.c
@@ -1,18 +1,19 @@
 /*     Copyright (C) 1995,1996, 2000, 2001, 2003, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/objprop.h b/libguile/objprop.h
index 7e5365a..f9a2e94 100644
--- a/libguile/objprop.h
+++ b/libguile/objprop.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/options.c b/libguile/options.c
index cc3d452..ee7001a 100644
--- a/libguile/options.c
+++ b/libguile/options.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1998,2000,2001, 2006, 2008 Free Software Foundation
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/options.h b/libguile/options.h
index 4facdce..8ea960b 100644
--- a/libguile/options.h
+++ b/libguile/options.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/pairs.c b/libguile/pairs.c
index cb2d642..aaaeb11 100644
--- a/libguile/pairs.c
+++ b/libguile/pairs.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,2000,2001, 2004, 2005, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/pairs.h b/libguile/pairs.h
index 61af24e..a6d44d2 100644
--- a/libguile/pairs.h
+++ b/libguile/pairs.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000,2001, 2004, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/ports.c b/libguile/ports.c
index 45e7c41..b2d80fd 100644
--- a/libguile/ports.c
+++ b/libguile/ports.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2003, 2004, 2006, 2007, 
2008, 2009 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/ports.h b/libguile/ports.h
index 0c0b0bc..e8a1a87 100644
--- a/libguile/ports.h
+++ b/libguile/ports.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2003, 2004, 2006, 2008, 
2009 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/posix.c b/libguile/posix.c
index c27f4b8..782178d 100644
--- a/libguile/posix.c
+++ b/libguile/posix.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2003, 2004, 2005, 
2006, 2007, 2008 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/posix.h b/libguile/posix.h
index b0873b6..2d93300 100644
--- a/libguile/posix.h
+++ b/libguile/posix.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2003, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/print.c b/libguile/print.c
index 3c9290f..1c20b85 100644
--- a/libguile/print.c
+++ b/libguile/print.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995-1999,2000,2001, 2002, 2003, 2004, 2006, 2008, 2009 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -671,7 +672,7 @@ iprin1 (SCM exp, SCM port, scm_print_state *pstate)
          break;
        case scm_tcs_subrs:
          {
-           SCM name = scm_symbol_to_string (SCM_SNAME (exp));
+           SCM name = scm_symbol_to_string (SCM_SUBR_NAME (exp));
            scm_puts (SCM_SUBR_GENERIC (exp)
                      ? "#<primitive-generic "
                      : "#<primitive-procedure ",
diff --git a/libguile/print.h b/libguile/print.h
index b6a18d7..d21cb72 100644
--- a/libguile/print.h
+++ b/libguile/print.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,2000,2001, 2003, 2004, 2006, 2008 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/private-gc.h b/libguile/private-gc.h
index 125ef3a..ac22de5 100644
--- a/libguile/private-gc.h
+++ b/libguile/private-gc.h
@@ -4,18 +4,19 @@
  * Copyright (C) 2002, 03, 04, 05, 06, 07, 08, 09 Free Software Foundation, 
Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifndef PRIVATE_GC
diff --git a/libguile/private-options.h b/libguile/private-options.h
index eeaf0c1..ffb699b 100644
--- a/libguile/private-options.h
+++ b/libguile/private-options.h
@@ -7,18 +7,19 @@
  * Copyright (C) 2007 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifndef PRIVATE_OPTIONS
diff --git a/libguile/procprop.c b/libguile/procprop.c
index db16834..df96eaa 100644
--- a/libguile/procprop.c
+++ b/libguile/procprop.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1998,2000,2001,2003,2004, 2006, 2008, 2009 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/procprop.h b/libguile/procprop.h
index bf27dba..04cd384 100644
--- a/libguile/procprop.h
+++ b/libguile/procprop.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/procs.c b/libguile/procs.c
index b3a0d32..93e35ab 100644
--- a/libguile/procs.c
+++ b/libguile/procs.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1999,2000,2001, 2006, 2008, 2009 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -65,7 +66,7 @@ SCM
 scm_c_define_subr (const char *name, long type, SCM (*fcn) ())
 {
   SCM subr = scm_c_make_subr (name, type, fcn);
-  scm_define (SCM_SNAME (subr), subr);
+  scm_define (SCM_SUBR_NAME (subr), subr);
   return subr;
 }
 
@@ -92,7 +93,7 @@ scm_c_define_subr_with_generic (const char *name,
                                long type, SCM (*fcn) (), SCM *gf)
 {
   SCM subr = scm_c_make_subr_with_generic (name, type, fcn, gf);
-  scm_define (SCM_SNAME (subr), subr);
+  scm_define (SCM_SUBR_NAME (subr), subr);
   return subr;
 }
 
@@ -236,7 +237,7 @@ SCM_DEFINE (scm_make_procedure_with_setter, 
"make-procedure-with-setter", 2, 0,
      lookup */
   switch (SCM_TYP7 (procedure)) {
   case scm_tcs_subrs:
-    name = SCM_SNAME (procedure);
+    name = SCM_SUBR_NAME (procedure);
     break;
   default:
     name = scm_procedure_property (procedure, scm_sym_name);
diff --git a/libguile/procs.h b/libguile/procs.h
index b7ab614..ed4ac20 100644
--- a/libguile/procs.h
+++ b/libguile/procs.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2001, 2006, 2008, 2009 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -31,7 +32,7 @@
  */
 
 #define SCM_SUBR_META_INFO(x)  ((SCM *) SCM_CELL_WORD_3 (x))
-#define SCM_SNAME(x) (SCM_SUBR_META_INFO (x) [0])
+#define SCM_SUBR_NAME(x) (SCM_SUBR_META_INFO (x) [0])
 #define SCM_SUBRF(x) ((SCM (*)()) SCM_CELL_WORD_1 (x))
 #define SCM_SET_SUBRF(x, v) (SCM_SET_CELL_WORD_1 ((x), (v)))
 #define SCM_DSUBRF(x) ((double (*)()) SCM_CELL_WORD_1 (x))
diff --git a/libguile/programs.c b/libguile/programs.c
index 68e0b85..892b677 100644
--- a/libguile/programs.c
+++ b/libguile/programs.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #if HAVE_CONFIG_H
diff --git a/libguile/programs.h b/libguile/programs.h
index ae819ef..16a1550 100644
--- a/libguile/programs.h
+++ b/libguile/programs.h
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifndef _SCM_PROGRAMS_H_
diff --git a/libguile/properties.c b/libguile/properties.c
index 321dc9e..60ff2ff 100644
--- a/libguile/properties.c
+++ b/libguile/properties.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,2000,2001, 2003, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/properties.h b/libguile/properties.h
index 54feb01..efeaf3a 100644
--- a/libguile/properties.h
+++ b/libguile/properties.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/pthread-threads.h b/libguile/pthread-threads.h
index 608a00b..d5d838b 100644
--- a/libguile/pthread-threads.h
+++ b/libguile/pthread-threads.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2002, 2005, 2006 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/putenv.c b/libguile/putenv.c
index 0ff3359..cdc05dd 100644
--- a/libguile/putenv.c
+++ b/libguile/putenv.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1991, 2000, 2001, 2004, 2005, 2006 Free Software Foundation, 
Inc.
 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/r6rs-ports.c b/libguile/r6rs-ports.c
index 9fc092f..d77c214 100644
--- a/libguile/r6rs-ports.c
+++ b/libguile/r6rs-ports.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2009 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
@@ -210,7 +211,7 @@ static SCM
 cbp_mark (SCM port)
 {
   /* Mark the underlying method and object vector.  */
-  if (SCM_PTAB_ENTRY (port) != NULL)
+  if (SCM_OPENP (port))
     return SCM_PACK (SCM_STREAM (port));
   else
     return SCM_BOOL_F;
@@ -1112,7 +1113,7 @@ initialize_custom_binary_output_ports (void)
 void
 scm_init_r6rs_ports (void)
 {
-#include "r6rs-ports.x"
+#include "libguile/r6rs-ports.x"
 
   initialize_bytevector_input_ports ();
   initialize_custom_binary_input_ports ();
diff --git a/libguile/r6rs-ports.h b/libguile/r6rs-ports.h
index e29d962..5e1707a 100644
--- a/libguile/r6rs-ports.h
+++ b/libguile/r6rs-ports.h
@@ -4,18 +4,19 @@
 /* Copyright (C) 2009 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/ramap.c b/libguile/ramap.c
index 1bc4fdd..e141c18 100644
--- a/libguile/ramap.c
+++ b/libguile/ramap.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1996,1998,2000,2001,2004,2005, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/ramap.h b/libguile/ramap.h
index 9d87038..d6cb191 100644
--- a/libguile/ramap.h
+++ b/libguile/ramap.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/random.c b/libguile/random.c
index 8097b0c..1761f25 100644
--- a/libguile/random.c
+++ b/libguile/random.c
@@ -1,17 +1,18 @@
 /* Copyright (C) 1999,2000,2001, 2003, 2005, 2006 Free Software Foundation, 
Inc.
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/random.h b/libguile/random.h
index ae44092..6cf404f 100644
--- a/libguile/random.h
+++ b/libguile/random.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1999,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/rdelim.c b/libguile/rdelim.c
index 0d8a12f..083c25b 100644
--- a/libguile/rdelim.c
+++ b/libguile/rdelim.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2006 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/rdelim.h b/libguile/rdelim.h
index 17efb4f..2e401e4 100644
--- a/libguile/rdelim.h
+++ b/libguile/rdelim.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/read.c b/libguile/read.c
index 39e698f..fe7d7f7 100644
--- a/libguile/read.c
+++ b/libguile/read.c
@@ -1,19 +1,20 @@
-/* Copyright (C) 1995,1996,1997,1999,2000,2001,2003, 2004, 2006, 2007, 2008 
Free Software
+/* Copyright (C) 1995,1996,1997,1999,2000,2001,2003, 2004, 2006, 2007, 2008, 
2009 Free Software
  * Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -30,6 +31,7 @@
 #include <unicase.h>
 
 #include "libguile/_scm.h"
+#include "libguile/bytevectors.h"
 #include "libguile/chars.h"
 #include "libguile/eval.h"
 #include "libguile/unif.h"
@@ -896,6 +898,30 @@ scm_read_srfi4_vector (int chr, SCM port)
 }
 
 static SCM
+scm_read_bytevector (scm_t_wchar chr, SCM port)
+{
+  chr = scm_getc (port);
+  if (chr != 'u')
+    goto syntax;
+
+  chr = scm_getc (port);
+  if (chr != '8')
+    goto syntax;
+
+  chr = scm_getc (port);
+  if (chr != '(')
+    goto syntax;
+
+  return scm_u8_list_to_bytevector (scm_read_sexp (chr, port));
+
+ syntax:
+  scm_i_input_error ("read_bytevector", port,
+                    "invalid bytevector prefix",
+                    SCM_MAKE_CHAR (chr));
+  return SCM_UNSPECIFIED;
+}
+
+static SCM
 scm_read_guile_bit_vector (scm_t_wchar chr, SCM port)
 {
   /* Read the `#*10101'-style read syntax for bit vectors in Guile.  This is
@@ -1065,6 +1091,8 @@ scm_read_sharp (scm_t_wchar chr, SCM port)
     case 'f':
       /* This one may return either a boolean or an SRFI-4 vector.  */
       return (scm_read_srfi4_vector (chr, port));
+    case 'v':
+      return (scm_read_bytevector (chr, port));
     case '*':
       return (scm_read_guile_bit_vector (chr, port));
     case 't':
diff --git a/libguile/read.h b/libguile/read.h
index f08872c..84c20a6 100644
--- a/libguile/read.h
+++ b/libguile/read.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/regex-posix.c b/libguile/regex-posix.c
index 008917a..a95cfb8 100644
--- a/libguile/regex-posix.c
+++ b/libguile/regex-posix.c
@@ -1,18 +1,19 @@
 /*     Copyright (C) 1997, 1998, 1999, 2000, 2001, 2004, 2006, 2007 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/regex-posix.h b/libguile/regex-posix.h
index 2863b05..8060fe3 100644
--- a/libguile/regex-posix.h
+++ b/libguile/regex-posix.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1997,1998,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/root.c b/libguile/root.c
index 0d4ab29..83960b5 100644
--- a/libguile/root.c
+++ b/libguile/root.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000, 2001, 2002, 2006, 2008 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/root.h b/libguile/root.h
index 11f6b4f..cbf710d 100644
--- a/libguile/root.h
+++ b/libguile/root.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1996,1998,2000,2001, 2002, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/rw.c b/libguile/rw.c
index f33dd8e..308f9eb 100644
--- a/libguile/rw.c
+++ b/libguile/rw.c
@@ -1,18 +1,19 @@
 /*     Copyright (C) 2001, 2006 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/rw.h b/libguile/rw.h
index b526051..d54f1b3 100644
--- a/libguile/rw.h
+++ b/libguile/rw.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/scmconfig.h.top b/libguile/scmconfig.h.top
index dfc7ba9..b84660b 100644
--- a/libguile/scmconfig.h.top
+++ b/libguile/scmconfig.h.top
@@ -1,16 +1,17 @@
 /* Copyright (C) 2003, 2006 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
diff --git a/libguile/scmsigs.c b/libguile/scmsigs.c
index eb7cec6..258710e 100644
--- a/libguile/scmsigs.c
+++ b/libguile/scmsigs.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2004, 2006, 2007, 
2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/scmsigs.h b/libguile/scmsigs.h
index bcbf825..fce3728 100644
--- a/libguile/scmsigs.h
+++ b/libguile/scmsigs.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000, 2002, 2006, 2007, 2008 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/script.c b/libguile/script.c
index c61e85a..8c4e8ef 100644
--- a/libguile/script.c
+++ b/libguile/script.c
@@ -1,17 +1,18 @@
 /* Copyright (C) 1994, 1995, 1996, 1997, 1998, 2000, 2001, 2002, 2003, 2004, 
2005, 2006, 2007, 2008 Free Software Foundation, Inc.
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 /* "script.c" argv tricks for `#!' scripts.
diff --git a/libguile/script.h b/libguile/script.h
index 6c02f8d..7e3828a 100644
--- a/libguile/script.h
+++ b/libguile/script.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1997,1998,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/simpos.c b/libguile/simpos.c
index 402e4dc..60a5922 100644
--- a/libguile/simpos.c
+++ b/libguile/simpos.c
@@ -2,18 +2,19 @@
  * Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/simpos.h b/libguile/simpos.h
index 6df8bb1..b391a28 100644
--- a/libguile/simpos.h
+++ b/libguile/simpos.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/smob.c b/libguile/smob.c
index 8991979..2d7a970 100644
--- a/libguile/smob.c
+++ b/libguile/smob.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2001, 2003, 2004, 2006, 2009 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/smob.h b/libguile/smob.h
index 7aab3e7..b712f86 100644
--- a/libguile/smob.h
+++ b/libguile/smob.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2001, 2004, 2006, 2009 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/snarf.h b/libguile/snarf.h
index 5c2f187..03a3edd 100644
--- a/libguile/snarf.h
+++ b/libguile/snarf.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2003, 2004, 2006 
Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/socket.c b/libguile/socket.c
index c07c124..18750a3 100644
--- a/libguile/socket.c
+++ b/libguile/socket.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1996,1997,1998,2000,2001, 2002, 2003, 2004, 2005, 2006, 2007 
Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/socket.h b/libguile/socket.h
index 133dbf7..fcddd78 100644
--- a/libguile/socket.h
+++ b/libguile/socket.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,2000,2001, 2004, 2005, 2006, 2008 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/sort.c b/libguile/sort.c
index 2a73176..644526e 100644
--- a/libguile/sort.c
+++ b/libguile/sort.c
@@ -1,17 +1,18 @@
 /* Copyright (C) 1999,2000,2001,2002, 2004, 2006, 2007, 2008 Free Software 
Foundation, Inc.
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/sort.h b/libguile/sort.h
index 51f292a..3ae86c2 100644
--- a/libguile/sort.h
+++ b/libguile/sort.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1999,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/srcprop.c b/libguile/srcprop.c
index 055ae32..efa0b7f 100644
--- a/libguile/srcprop.c
+++ b/libguile/srcprop.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002, 2006, 2008 Free 
Software Foundation
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/srcprop.h b/libguile/srcprop.h
index a467aa3..2a27e04 100644
--- a/libguile/srcprop.h
+++ b/libguile/srcprop.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/srfi-13.c b/libguile/srfi-13.c
index b5eecdb..9338b9d 100644
--- a/libguile/srfi-13.c
+++ b/libguile/srfi-13.c
@@ -3,18 +3,19 @@
  * Copyright (C) 2001, 2004, 2005, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/srfi-13.h b/libguile/srfi-13.h
index f8221dd..478a55d 100644
--- a/libguile/srfi-13.h
+++ b/libguile/srfi-13.h
@@ -6,18 +6,19 @@
  *     Copyright (C) 2001, 2004, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/srfi-14.c b/libguile/srfi-14.c
index 25c5d08..e2df1e2 100644
--- a/libguile/srfi-14.c
+++ b/libguile/srfi-14.c
@@ -3,18 +3,19 @@
  * Copyright (C) 2001, 2004, 2006, 2007 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
@@ -23,45 +24,473 @@
 
 
 #include <string.h>
-#include <ctype.h>
+#include <unictype.h>
 
 #include "libguile.h"
 #include "libguile/srfi-14.h"
 #include "libguile/strings.h"
 
-#define SCM_CHARSET_SET(cs, idx)                               \
-  (((long *) SCM_SMOB_DATA (cs))[(idx) / SCM_BITS_PER_LONG] |= \
-    (1L << ((idx) % SCM_BITS_PER_LONG)))
+#define SCM_CHARSET_DATA(charset) ((scm_t_char_set *)SCM_SMOB_DATA (charset))
 
-#define SCM_CHARSET_UNSET(cs, idx)                             \
-  (((long *) SCM_SMOB_DATA (cs))[(idx) / SCM_BITS_PER_LONG] &= \
-    (~(1L << ((idx) % SCM_BITS_PER_LONG))))
-
-#define BYTES_PER_CHARSET (SCM_CHARSET_SIZE / 8)
-#define LONGS_PER_CHARSET (SCM_CHARSET_SIZE / SCM_BITS_PER_LONG)
+#define SCM_CHARSET_SET(cs, idx)                \
+  scm_i_charset_set(SCM_CHARSET_DATA(cs),idx)
 
+#define SCM_CHARSET_UNSET(cs, idx)              \
+  scm_i_charset_unset(SCM_CHARSET_DATA(cs),idx)
 
 /* Smob type code for character sets.  */
 int scm_tc16_charset = 0;
+int scm_tc16_charset_cursor = 0;
+
+/* True if N exists in charset CS.  */
+int
+scm_i_charset_get (scm_t_char_set *cs, scm_t_wchar n)
+{
+  size_t i, idx;
+
+  i = 0;
+  idx = 0;
+  while (i < cs->len)
+    {
+      if (cs->ranges[i].lo <= n && n <= cs->ranges[i].hi)
+        return 1;
+      i ++;
+    }
+
+  return 0;
+}
+
+/* Put N into charset CS.  */
+void
+scm_i_charset_set (scm_t_char_set *cs, scm_t_wchar n)
+{
+  size_t i;
+  size_t len;
+
+  len = cs->len;
+
+  i = 0;
+  while (i < len)
+    {
+      /* Already in this range  */
+      if (cs->ranges[i].lo <= n && n <= cs->ranges[i].hi)
+        {
+          return;
+        }
+      
+      if (n == cs->ranges[i].lo - 1)
+        {
+          /* This char is one below the current range. */
+          if (i > 0 && cs->ranges[i-1].hi + 1 == n)
+            {
+              /* It is also one above the previous range, so combine them.  */
+              cs->ranges[i-1].hi = cs->ranges[i].hi;
+              if (i < len - 1)
+                memmove (cs->ranges + i, cs->ranges + (i+1), 
+                         sizeof (scm_t_char_range) * (len - i - 1));
+              cs->ranges = scm_gc_realloc (cs->ranges, 
+                                           sizeof (scm_t_char_range) * len,
+                                           sizeof (scm_t_char_range) * (len - 
1),
+                                           "character-set");
+              cs->len = len - 1;
+              return;
+            }
+          else
+            {
+              /* Expand the range down by one.  */
+              cs->ranges[i].lo = n;
+              return;
+            }
+        }
+      else if (n == cs->ranges[i].hi + 1)
+        {
+          /* This char is one above the current range.  */
+          if (i < len - 1 && cs->ranges[i+1].lo - 1 == n)
+            {
+              /* It is also one below the next range, so combine them.  */
+              cs->ranges[i].hi = cs->ranges[i+1].hi;
+              if (i < len - 2)
+                memmove (cs->ranges + (i+1), cs->ranges + (i+2), 
+                         sizeof (scm_t_char_range) * (len - i - 2));
+              cs->ranges = scm_gc_realloc (cs->ranges,
+                                           sizeof (scm_t_char_range) * len,
+                                           sizeof (scm_t_char_range) * (len - 
1),
+                                           "character-set");
+              cs->len = len - 1;
+              return;
+            }
+          else
+            {
+              /* Expand the range up by one.  */
+              cs->ranges[i].hi = n;
+              return;
+            }
+        }
+      else if (n < cs->ranges[i].lo - 1)
+        {
+          /* This is a new range below the current one.  */
+          cs->ranges = scm_gc_realloc (cs->ranges, 
+                                       sizeof (scm_t_char_range) * len,
+                                       sizeof (scm_t_char_range) * (len + 1),
+                                       "character-set");
+          memmove (cs->ranges + (i+1), cs->ranges + i, 
+                   sizeof (scm_t_char_range) * (len - i));
+          cs->ranges[i].lo = n;
+          cs->ranges[i].hi = n;
+          cs->len = len + 1;
+          return;
+        }
+      
+      i++;
+    }
+
+  /* This is a new range above all previous ranges.  */
+  if (len == 0)
+    {
+      cs->ranges = scm_gc_malloc (sizeof (scm_t_char_range),
+                                  "character-set");
+    }
+  else
+    {
+      cs->ranges = scm_gc_realloc (cs->ranges, 
+                                   sizeof (scm_t_char_range) * len,
+                                   sizeof (scm_t_char_range) * (len + 1),
+                                   "character-set");
+    }
+  cs->ranges[len].lo = n;
+  cs->ranges[len].hi = n;
+  cs->len = len + 1;
+
+  return;
+}
+
+/* If N is in charset CS, remove it.  */                   
+void
+scm_i_charset_unset (scm_t_char_set *cs, scm_t_wchar n)
+{
+  size_t i;
+  size_t len;
+
+  len = cs->len;
+
+  i = 0;
+  while (i < len)
+    {
+      if (n < cs->ranges[i].lo) 
+        {
+          /* Not in this set.  */
+          return;
+        }
+      
+      if (n == cs->ranges[i].lo && n == cs->ranges[i].hi)
+        {
+          /* Remove this one-character range.  */
+          if (len == 1)
+            {
+              scm_gc_free (cs->ranges, 
+                           sizeof (scm_t_char_range) * cs->len, 
+                           "character-set");
+              cs->ranges = NULL;
+              cs->len = 0;
+              return;
+            }
+          else if (i < len - 1)
+            {
+              memmove (cs->ranges + i, cs->ranges + (i+1),
+                       sizeof (scm_t_char_range) * (len - i - 1));
+              cs->ranges = scm_gc_realloc (cs->ranges,
+                                           sizeof (scm_t_char_range) * len,
+                                           sizeof (scm_t_char_range) * (len - 
1),
+                                           "character-set");
+              cs->len = len - 1;
+              return;
+            }
+          else if (i == len - 1)
+            {
+              cs->ranges = scm_gc_realloc (cs->ranges,
+                                           sizeof (scm_t_char_range) * len,
+                                           sizeof (scm_t_char_range) * (len - 
1),
+                                           "character-set");
+              cs->len = len - 1;
+              return;
+            }
+        }
+      else if (n == cs->ranges[i].lo)
+        {
+          /* Shrink this range from the left.  */
+          cs->ranges[i].lo = n + 1;
+          return;
+        }
+      else if (n == cs->ranges[i].hi)
+        {
+          /* Shrink this range from the right.  */
+          cs->ranges[i].hi = n - 1;
+          return;
+        }
+      else if (n > cs->ranges[i].lo && n < cs->ranges[i].hi)
+        {
+          /* Split this range into two pieces.  */
+          cs->ranges = scm_gc_realloc (cs->ranges,
+                                       sizeof (scm_t_char_range) * len,
+                                       sizeof (scm_t_char_range) * (len + 1),
+                                       "character-set");
+          if (i < len - 1)
+            memmove (cs->ranges + (i+2), cs->ranges + (i+1), 
+                     sizeof (scm_t_char_range) * (len - i));
+          cs->ranges[i+1].hi = cs->ranges[i].hi;
+          cs->ranges[i+1].lo = n + 1;
+          cs->ranges[i].hi = n - 1;
+          cs->len = len + 1;
+          return;
+        }
+
+      i++;
+    }
+
+  /* This value is above all ranges, so do nothing here.  */
+  return;
+}
+
+static int
+charsets_equal (scm_t_char_set *a, scm_t_char_set *b)
+{
+  if (a->len != b->len)
+    return 0;
+  
+  if (memcmp (a->ranges, b->ranges, sizeof (scm_t_char_range) * a->len) != 0)
+    return 0;
+
+  return 1;
+}  
+
+/* Return true if every character in A is also in B.  */
+static int
+charsets_leq (scm_t_char_set *a, scm_t_char_set *b)
+{
+  size_t i = 0, j = 0;
+  scm_t_wchar alo, ahi;
+  
+  if (a->len == 0)
+    {
+      return 1;
+    }
+  if (b->len == 0)
+    {
+      return 0;
+    }
+  while (i < a->len)
+    {
+      alo = a->ranges[i].lo;
+      ahi = a->ranges[i].hi;
+      while (b->ranges[j].hi < alo)
+        {
+          if (j < b->len - 1)
+            j ++;
+          else
+            {
+              return 0;
+            }
+        }
+      if (alo < b->ranges[j].lo || ahi > b->ranges[i].hi)
+        {
+          return 0;
+        }
+      i ++;
+    }
+
+  return 1;
+}
+
+/* Merge B into A. */
+static void
+charsets_union (scm_t_char_set *a, scm_t_char_set *b)
+{
+  size_t i = 0;
+  scm_t_wchar blo, bhi, n;
+
+  if (b->len == 0)
+    {
+      return;
+    }
+
+  if (a->len == 0)
+    {
+      a->len = b->len;
+      a->ranges = scm_gc_malloc (sizeof (scm_t_char_range) * b->len,
+                                 "character-set");
+      memcpy (a->ranges, b->ranges, sizeof (scm_t_char_range) * b->len);
+      return;
+    }
+
+  while (i < b->len)
+    {
+      blo = b->ranges[i].lo;
+      bhi = b->ranges[i].hi;
+      for (n = blo; n <= bhi; n++)
+        scm_i_charset_set (a, n);
+
+      i ++;
+    }
+
+  return;
+}
+
+/* Remove elements not both in A and B from A. */
+static void
+charsets_intersection (scm_t_char_set *a, scm_t_char_set *b)
+{
+  size_t i = 0;
+  scm_t_wchar blo, bhi, n;
+  scm_t_char_set *c;
+
+  c = (scm_t_char_set *) scm_malloc (sizeof (scm_t_char_set));
+  c->len = 0;
+  c->ranges = NULL;
+
+  if (a->len == 0)
+    return;
+  
+  if (b->len == 0)
+    {
+      scm_gc_free (a->ranges, sizeof (scm_t_char_range) * a->len, 
"character-set");
+      a->len = 0;
+      return;
+    }
+
+  while (i < b->len)
+    {
+      blo = b->ranges[i].lo;
+      bhi = b->ranges[i].hi;
+      for (n = blo; n <= bhi; n++)
+        if (scm_i_charset_get (a, n))
+          scm_i_charset_set (c, n);
+      i ++;
+    }
+  scm_gc_free (a->ranges, sizeof (scm_t_char_range) * a->len, "character-set");
+
+  a->len = c->len;
+  if (c->len != 0)
+    a->ranges = c->ranges;
+  else
+    a->ranges = NULL;
+
+  return;
+}
+
+/* Make P the compelement of Q. */
+static void
+charsets_complement (scm_t_char_set *p, scm_t_char_set *q)
+{
+  int k, idx;
 
+  if (q->len == 0)
+    {
+      /* Fill with all valid codepoints.  */
+      p->len = 2;
+      p->ranges = scm_gc_malloc (sizeof (scm_t_char_range) * 2, 
+                                 "character-set");
+      p->ranges[0].lo = 0;
+      p->ranges[0].hi = 0xd7ff;
+      p->ranges[1].lo = 0xe000;
+      p->ranges[1].hi = SCM_CODEPOINT_MAX;
+      return;
+    }
+  
+  if (p->len > 0)
+    scm_gc_free (p->ranges, sizeof (scm_t_char_set) * p->len, "character-set");
+  
+  p->len = 0;
+  if (q->ranges[0].lo > 0)
+    p->len ++;
+  if (q->ranges[q->len-1].hi < SCM_CODEPOINT_MAX)
+    p->len ++;
+  p->len += q->len - 1;
+  p->ranges = (scm_t_char_range *) scm_gc_malloc (sizeof (scm_t_char_range) * 
p->len,
+                                                  "character-set");
+  idx = 0;
+  if (q->ranges[0].lo > 0)
+    {
+      p->ranges[idx].lo = 0;
+      p->ranges[idx++].hi = q->ranges[0].lo - 1;
+    }
+  for (k = 1; k < q->len; k++)
+    {
+      p->ranges[idx].lo = q->ranges[k-1].hi + 1;
+      p->ranges[idx++].hi = q->ranges[k].lo - 1;
+    }
+  if (q->ranges[q->len-1].hi < SCM_CODEPOINT_MAX)
+    {
+      p->ranges[idx].lo = q->ranges[q->len-1].hi + 1;
+      p->ranges[idx].hi = SCM_CODEPOINT_MAX;
+    }
+  return;
+}
+
+/* Replace A with elements only found in one of A or B.  */
+static void
+charsets_xor (scm_t_char_set *a, scm_t_char_set *b)
+{
+  size_t i = 0;
+  scm_t_wchar blo, bhi, n;
+
+  if (b->len == 0)
+    {
+      return;
+    }
+
+  if (a->len == 0)
+    {
+      scm_gc_free (a->ranges, sizeof (scm_t_char_range) * a->len, 
"character-set");
+      a->ranges = scm_gc_realloc (a->ranges, 
+                                  sizeof (scm_t_char_range) * a->len,
+                                  sizeof (scm_t_char_range) * b->len,
+                                  "character-set");
+      a->len = b->len;
+      memcpy (a->ranges, b->ranges, sizeof (scm_t_char_range) * a->len);
+      return;
+    }
+
+  while (i < b->len)
+    {
+      blo = b->ranges[i].lo;
+      bhi = b->ranges[i].hi;
+      for (n = blo; n <= bhi; n++)
+        {
+          if (scm_i_charset_get (a, n))
+            scm_i_charset_unset (a, n);
+          else
+            scm_i_charset_set (a, n);
+        }
+      
+      i ++;
+    }
+  return;
+}
 
 /* Smob print hook for character sets.  */
 static int
 charset_print (SCM charset, SCM port, scm_print_state *pstate SCM_UNUSED)
 {
-  int i;
+  size_t i;
   int first = 1;
+  scm_t_char_set *p;
+
+  p = SCM_CHARSET_DATA (charset);
 
   scm_puts ("#<charset {", port);
-  for (i = 0; i < SCM_CHARSET_SIZE; i++)
-    if (SCM_CHARSET_GET (charset, i))
-      {
-       if (first)
-         first = 0;
-       else
-         scm_puts (" ", port);
-       scm_write (SCM_MAKE_CHAR (i), port);
-      }
+  for (i = 0; i < p->len; i++)
+    {
+      if (first)
+        first = 0;
+      else
+        scm_puts (" ", port);
+      scm_write (SCM_MAKE_CHAR (p->ranges[i].lo), port);
+      if (p->ranges[i].lo != p->ranges[i].hi)
+        {
+          scm_puts ("..", port);
+          scm_write (SCM_MAKE_CHAR (p->ranges[i].hi), port);
+        }
+    }
   scm_puts ("}>", port);
   return 1;
 }
@@ -71,7 +500,58 @@ charset_print (SCM charset, SCM port, scm_print_state 
*pstate SCM_UNUSED)
 static size_t
 charset_free (SCM charset)
 {
-  return scm_smob_free (charset);
+  scm_t_char_set *cs;
+  size_t len;
+
+  cs = SCM_CHARSET_DATA (charset);
+  if (cs != NULL)
+    len = cs->len;
+  if (len > 0)
+    scm_gc_free (cs->ranges, sizeof (scm_t_char_range) * len, "character-set");
+
+  cs->ranges = NULL;
+  cs->len = 0;
+
+  scm_gc_free (cs, sizeof (scm_t_char_set), "character-set");
+
+  scm_remember_upto_here_1 (charset);
+  
+  return 0;
+}
+
+
+/* Smob print hook for character sets cursors.  */
+static int
+charset_cursor_print (SCM cursor, SCM port, scm_print_state *pstate SCM_UNUSED)
+{
+  scm_t_char_set_cursor *cur;
+
+  cur = (scm_t_char_set_cursor *) SCM_SMOB_DATA (cursor);
+
+  scm_puts ("#<charset-cursor ", port);
+  if (cur->range == (size_t) (-1))
+    scm_puts ("(empty)", port);
+  else
+    {
+      scm_write (scm_from_size_t (cur->range), port);
+      scm_puts (":", port);
+      scm_write (scm_from_int32 (cur->n), port);
+    }
+  scm_puts (">", port);
+  return 1;
+}
+
+/* Smob free hook for character sets. */
+static size_t
+charset_cursor_free (SCM charset)
+{
+  scm_t_char_set_cursor *cur;
+
+  cur = (scm_t_char_set_cursor *) SCM_SMOB_DATA (charset);
+  scm_gc_free (cur, sizeof (scm_t_char_set_cursor), "charset-cursor");
+  scm_remember_upto_here_1 (charset);
+  
+  return 0;
 }
 
 
@@ -79,10 +559,10 @@ charset_free (SCM charset)
 static SCM
 make_char_set (const char * func_name)
 {
-  long * p;
+  scm_t_char_set *p;
 
-  p = scm_gc_malloc (BYTES_PER_CHARSET, "character-set");
-  memset (p, 0, BYTES_PER_CHARSET);
+  p = scm_gc_malloc (sizeof (scm_t_char_set), "character-set");
+  memset (p, 0, sizeof (scm_t_char_set));
   SCM_RETURN_NEWSMOB (scm_tc16_charset, p);
 }
 
@@ -104,22 +584,22 @@ SCM_DEFINE (scm_char_set_eq, "char-set=", 0, 0, 1,
 #define FUNC_NAME s_scm_char_set_eq
 {
   int argnum = 1;
-  long *cs1_data = NULL;
+  scm_t_char_set *cs1_data = NULL;
 
   SCM_VALIDATE_REST_ARGUMENT (char_sets);
 
   while (!scm_is_null (char_sets))
     {
       SCM csi = SCM_CAR (char_sets);
-      long *csi_data;
+      scm_t_char_set *csi_data;
 
       SCM_VALIDATE_SMOB (argnum, csi, charset);
       argnum++;
-      csi_data = (long *) SCM_SMOB_DATA (csi);
+      csi_data = SCM_CHARSET_DATA (csi);
       if (cs1_data == NULL)
        cs1_data = csi_data;
-      else if (memcmp (cs1_data, csi_data, BYTES_PER_CHARSET) != 0)
-       return SCM_BOOL_F;
+      else if (!charsets_equal (cs1_data, csi_data))
+        return SCM_BOOL_F;
       char_sets = SCM_CDR (char_sets);
     }
   return SCM_BOOL_T;
@@ -134,27 +614,22 @@ SCM_DEFINE (scm_char_set_leq, "char-set<=", 0, 0, 1,
 #define FUNC_NAME s_scm_char_set_leq
 {
   int argnum = 1;
-  long *prev_data = NULL;
+  scm_t_char_set *prev_data = NULL;
 
   SCM_VALIDATE_REST_ARGUMENT (char_sets);
 
   while (!scm_is_null (char_sets))
     {
       SCM csi = SCM_CAR (char_sets);
-      long *csi_data;
+      scm_t_char_set *csi_data;
 
       SCM_VALIDATE_SMOB (argnum, csi, charset);
       argnum++;
-      csi_data = (long *) SCM_SMOB_DATA (csi);
+      csi_data = SCM_CHARSET_DATA (csi);
       if (prev_data)
        {
-         int k;
-
-         for (k = 0; k < LONGS_PER_CHARSET; k++)
-           {
-             if ((prev_data[k] & csi_data[k]) != prev_data[k])
-               return SCM_BOOL_F;
-           }
+          if (!charsets_leq (prev_data, csi_data))
+            return SCM_BOOL_F;
        }
       prev_data = csi_data;
       char_sets = SCM_CDR (char_sets);
@@ -173,9 +648,10 @@ SCM_DEFINE (scm_char_set_hash, "char-set-hash", 1, 1, 0,
 {
   const unsigned long default_bnd = 871;
   unsigned long bnd;
-  long * p;
+  scm_t_char_set * p;
   unsigned long val = 0;
   int k;
+  scm_t_wchar c;
 
   SCM_VALIDATE_SMOB (1, cs, charset);
 
@@ -188,11 +664,11 @@ SCM_DEFINE (scm_char_set_hash, "char-set-hash", 1, 1, 0,
        bnd = default_bnd;
     }
 
-  p = (long *) SCM_SMOB_DATA (cs);
-  for (k = 0; k < LONGS_PER_CHARSET; k++)
+  p = SCM_CHARSET_DATA (cs);
+  for (k = 0; k < p->len; k++)
     {
-      if (p[k] != 0)
-        val = p[k] + (val << 1);
+      for (c = p->ranges[k].lo; c <= p->ranges[k].hi; c++)
+        val = c + (val << 1);
     }
   return scm_from_ulong (val % bnd);
 }
@@ -204,15 +680,25 @@ SCM_DEFINE (scm_char_set_cursor, "char-set-cursor", 1, 0, 
0,
            "Return a cursor into the character set @var{cs}.")
 #define FUNC_NAME s_scm_char_set_cursor
 {
-  int idx;
+  scm_t_char_set *cs_data;
+  scm_t_char_set_cursor *cur_data;
 
   SCM_VALIDATE_SMOB (1, cs, charset);
-  for (idx = 0; idx < SCM_CHARSET_SIZE; idx++)
+
+  cs_data = SCM_CHARSET_DATA (cs);
+  cur_data = (scm_t_char_set_cursor *) scm_gc_malloc (sizeof 
(scm_t_char_set_cursor),
+                                                      "charset-cursor");
+  if (cs_data->len == 0)
     {
-      if (SCM_CHARSET_GET (cs, idx))
-       break;
+      cur_data->range = (size_t) (-1);
+      cur_data->n = 0;
     }
-  return SCM_I_MAKINUM (idx);
+  else
+    {
+      cur_data->range = 0;
+      cur_data->n = cs_data->ranges[0].lo;
+    }
+  SCM_RETURN_NEWSMOB (scm_tc16_charset_cursor, cur_data);
 }
 #undef FUNC_NAME
 
@@ -224,12 +710,25 @@ SCM_DEFINE (scm_char_set_ref, "char-set-ref", 2, 0, 0,
            "pass a cursor for which @code{end-of-char-set?} returns true.")
 #define FUNC_NAME s_scm_char_set_ref
 {
-  size_t ccursor = scm_to_size_t (cursor);
+  scm_t_char_set *cs_data;
+  scm_t_char_set_cursor *cur_data;
+  size_t i;
+
   SCM_VALIDATE_SMOB (1, cs, charset);
+  SCM_VALIDATE_SMOB (2, cursor, charset_cursor);
 
-  if (ccursor >= SCM_CHARSET_SIZE || !SCM_CHARSET_GET (cs, ccursor))
+  cs_data = SCM_CHARSET_DATA (cs);
+  cur_data = (scm_t_char_set_cursor *) SCM_SMOB_DATA (cursor);
+
+  /* Validate that this cursor is still true.  */
+  i = cur_data->range;
+  if (i == (size_t)(-1)
+      || i >= cs_data->len
+      || cur_data->n < cs_data->ranges[i].lo
+      || cur_data->n > cs_data->ranges[i].hi)
     SCM_MISC_ERROR ("invalid character set cursor: ~A", scm_list_1 (cursor));
-  return SCM_MAKE_CHAR (ccursor);
+
+  return SCM_MAKE_CHAR (cur_data->n);
 }
 #undef FUNC_NAME
 
@@ -241,17 +740,45 @@ SCM_DEFINE (scm_char_set_cursor_next, 
"char-set-cursor-next", 2, 0, 0,
            "cursor given satisfies @code{end-of-char-set?}.")
 #define FUNC_NAME s_scm_char_set_cursor_next
 {
-  size_t ccursor = scm_to_size_t (cursor);
+  scm_t_char_set *cs_data;
+  scm_t_char_set_cursor *cur_data;
+  size_t i;
+
   SCM_VALIDATE_SMOB (1, cs, charset);
+  SCM_VALIDATE_SMOB (2, cursor, charset_cursor);
+
+  cs_data = SCM_CHARSET_DATA (cs);
+  cur_data = (scm_t_char_set_cursor *) SCM_SMOB_DATA (cursor);
 
-  if (ccursor >= SCM_CHARSET_SIZE || !SCM_CHARSET_GET (cs, ccursor))
+  /* Validate that this cursor is still true.  */
+  i = cur_data->range;
+  if (i == (size_t) (-1)
+      || i >= cs_data->len
+      || cur_data->n < cs_data->ranges[i].lo
+      || cur_data->n > cs_data->ranges[i].hi)
     SCM_MISC_ERROR ("invalid character set cursor: ~A", scm_list_1 (cursor));
-  for (ccursor++; ccursor < SCM_CHARSET_SIZE; ccursor++)
+
+  /* Increment the cursor.  */
+  if (cur_data->n == cs_data->ranges[i].hi)
+    {
+      if (i + 1 < cs_data->len)
+        {
+          cur_data->range = i + 1;
+          cur_data->n = cs_data->ranges[i+1].lo;
+        }
+      else
+        {
+          /* This is the end of the road.  */
+          cur_data->range = (size_t) (-1);
+          cur_data->n = 0;
+        }
+    }
+  else
     {
-      if (SCM_CHARSET_GET (cs, ccursor))
-       break;
+      cur_data->n = cur_data->n + 1;
     }
-  return SCM_I_MAKINUM (ccursor);
+
+  return cursor;
 }
 #undef FUNC_NAME
 
@@ -262,8 +789,14 @@ SCM_DEFINE (scm_end_of_char_set_p, "end-of-char-set?", 1, 
0, 0,
            "character set, @code{#f} otherwise.")
 #define FUNC_NAME s_scm_end_of_char_set_p
 {
-  size_t ccursor = scm_to_size_t (cursor);
-  return scm_from_bool (ccursor >= SCM_CHARSET_SIZE);
+  scm_t_char_set_cursor *cur_data;
+  SCM_VALIDATE_SMOB (1, cursor, charset_cursor);
+
+  cur_data = (scm_t_char_set_cursor *) SCM_SMOB_DATA (cursor);
+  if (cur_data->range == (size_t) (-1))
+    return SCM_BOOL_T;
+
+  return SCM_BOOL_F;
 }
 #undef FUNC_NAME
 
@@ -274,15 +807,22 @@ SCM_DEFINE (scm_char_set_fold, "char-set-fold", 3, 0, 0,
            "initializing it with @var{knil}.")
 #define FUNC_NAME s_scm_char_set_fold
 {
+  scm_t_char_set *cs_data;
   int k;
+  scm_t_wchar n;
 
   SCM_VALIDATE_PROC (1, kons);
   SCM_VALIDATE_SMOB (3, cs, charset);
 
-  for (k = 0; k < SCM_CHARSET_SIZE; k++)
-    if (SCM_CHARSET_GET (cs, k))
+  cs_data = SCM_CHARSET_DATA (cs);
+
+  if (cs_data->len == 0)
+    return knil;
+
+  for (k = 0; k < cs_data->len; k++)
+    for (n = cs_data->ranges[k].lo; n <= cs_data->ranges[k].hi; n++)
       {
-       knil = scm_call_2 (kons, SCM_MAKE_CHAR (k), knil);
+       knil = scm_call_2 (kons, SCM_MAKE_CHAR (n), knil);
       }
   return knil;
 }
@@ -377,14 +917,24 @@ SCM_DEFINE (scm_char_set_for_each, "char-set-for-each", 
2, 0, 0,
            "@var{cs}.  The return value is not specified.")
 #define FUNC_NAME s_scm_char_set_for_each
 {
+  scm_t_char_set *cs_data;
   int k;
+  scm_t_wchar n;
 
   SCM_VALIDATE_PROC (1, proc);
   SCM_VALIDATE_SMOB (2, cs, charset);
 
-  for (k = 0; k < SCM_CHARSET_SIZE; k++)
-    if (SCM_CHARSET_GET (cs, k))
-      scm_call_1 (proc, SCM_MAKE_CHAR (k));
+  cs_data = SCM_CHARSET_DATA (cs);
+
+  if (cs_data->len == 0)
+    return SCM_UNSPECIFIED;
+
+  for (k = 0; k < cs_data->len; k++)
+    for (n = cs_data->ranges[k].lo; n <= cs_data->ranges[k].hi; n++)
+      {
+        scm_call_1 (proc, SCM_MAKE_CHAR (n));
+      }
+
   return SCM_UNSPECIFIED;
 }
 #undef FUNC_NAME
@@ -398,19 +948,28 @@ SCM_DEFINE (scm_char_set_map, "char-set-map", 2, 0, 0,
 {
   SCM result;
   int k;
+  scm_t_char_set *cs_data;
+  scm_t_wchar n;
 
   SCM_VALIDATE_PROC (1, proc);
   SCM_VALIDATE_SMOB (2, cs, charset);
 
   result = make_char_set (FUNC_NAME);
-  for (k = 0; k < SCM_CHARSET_SIZE; k++)
-    if (SCM_CHARSET_GET (cs, k))
+
+  cs_data = SCM_CHARSET_DATA (cs);
+
+  if (cs_data->len == 0)
+    return result;
+
+  for (k = 0; k < cs_data->len; k++)
+    for (n = cs_data->ranges[k].lo; n <= cs_data->ranges[k].hi; n++)
       {
-       SCM ch = scm_call_1 (proc, SCM_MAKE_CHAR (k));
-       if (!SCM_CHARP (ch))
+        SCM ch = scm_call_1 (proc, SCM_MAKE_CHAR (n));
+        if (!SCM_CHARP (ch))
          SCM_MISC_ERROR ("procedure ~S returned non-char", scm_list_1 (proc));
        SCM_CHARSET_SET (result, SCM_CHAR (ch));
       }
+
   return result;
 }
 #undef FUNC_NAME
@@ -423,15 +982,23 @@ SCM_DEFINE (scm_char_set_copy, "char-set-copy", 1, 0, 0,
 #define FUNC_NAME s_scm_char_set_copy
 {
   SCM ret;
-  long * p1, * p2;
-  int k;
+  scm_t_char_set *p1, *p2;
 
   SCM_VALIDATE_SMOB (1, cs, charset);
   ret = make_char_set (FUNC_NAME);
-  p1 = (long *) SCM_SMOB_DATA (cs);
-  p2 = (long *) SCM_SMOB_DATA (ret);
-  for (k = 0; k < LONGS_PER_CHARSET; k++)
-    p2[k] = p1[k];
+  p1 = SCM_CHARSET_DATA (cs);
+  p2 = SCM_CHARSET_DATA (ret);
+  p2->len = p1->len;
+
+  if (p1->len == 0)
+    p2->ranges = NULL;
+  else
+    {
+      p2->ranges = scm_gc_malloc (sizeof (scm_t_char_range) * p1->len,
+                                  "character-set");
+      memcpy (p2->ranges, p1->ranges, sizeof (scm_t_char_range) * p1->len);
+    }
+
   return ret;
 }
 #undef FUNC_NAME
@@ -443,12 +1010,10 @@ SCM_DEFINE (scm_char_set, "char-set", 0, 0, 1,
 #define FUNC_NAME s_scm_char_set
 {
   SCM cs;
-  long * p;
   int argnum = 1;
 
   SCM_VALIDATE_REST_ARGUMENT (rest);
   cs = make_char_set (FUNC_NAME);
-  p = (long *) SCM_SMOB_DATA (cs);
   while (!scm_is_null (rest))
     {
       scm_t_wchar c;
@@ -456,7 +1021,7 @@ SCM_DEFINE (scm_char_set, "char-set", 0, 0, 1,
       SCM_VALIDATE_CHAR_COPY (argnum, SCM_CAR (rest), c);
       argnum++;
       rest = SCM_CDR (rest);
-      p[c / SCM_BITS_PER_LONG] |= 1L << (c % SCM_BITS_PER_LONG);
+      SCM_CHARSET_SET (cs, c);
     }
   return cs;
 }
@@ -471,7 +1036,6 @@ SCM_DEFINE (scm_list_to_char_set, "list->char-set", 1, 1, 
0,
 #define FUNC_NAME s_scm_list_to_char_set
 {
   SCM cs;
-  long * p;
 
   SCM_VALIDATE_LIST (1, list);
   if (SCM_UNBNDP (base_cs))
@@ -481,7 +1045,6 @@ SCM_DEFINE (scm_list_to_char_set, "list->char-set", 1, 1, 
0,
       SCM_VALIDATE_SMOB (2, base_cs, charset);
       cs = scm_char_set_copy (base_cs);
     }
-  p = (long *) SCM_SMOB_DATA (cs);
   while (!scm_is_null (list))
     {
       SCM chr = SCM_CAR (list);
@@ -489,8 +1052,8 @@ SCM_DEFINE (scm_list_to_char_set, "list->char-set", 1, 1, 
0,
 
       SCM_VALIDATE_CHAR_COPY (0, chr, c);
       list = SCM_CDR (list);
-
-      p[c / SCM_BITS_PER_LONG] |= 1L << (c % SCM_BITS_PER_LONG);
+      
+      SCM_CHARSET_SET (cs, c);
     }
   return cs;
 }
@@ -504,11 +1067,8 @@ SCM_DEFINE (scm_list_to_char_set_x, "list->char-set!", 2, 
0, 0,
            "returned.")
 #define FUNC_NAME s_scm_list_to_char_set_x
 {
-  long * p;
-
   SCM_VALIDATE_LIST (1, list);
   SCM_VALIDATE_SMOB (2, base_cs, charset);
-  p = (long *) SCM_SMOB_DATA (base_cs);
   while (!scm_is_null (list))
     {
       SCM chr = SCM_CAR (list);
@@ -517,7 +1077,7 @@ SCM_DEFINE (scm_list_to_char_set_x, "list->char-set!", 2, 
0, 0,
       SCM_VALIDATE_CHAR_COPY (0, chr, c);
       list = SCM_CDR (list);
 
-      p[c / SCM_BITS_PER_LONG] |= 1L << (c % SCM_BITS_PER_LONG);
+      SCM_CHARSET_SET (base_cs, c);
     }
   return base_cs;
 }
@@ -532,7 +1092,6 @@ SCM_DEFINE (scm_string_to_char_set, "string->char-set", 1, 
1, 0,
 #define FUNC_NAME s_scm_string_to_char_set
 {
   SCM cs;
-  long * p;
   size_t k = 0, len;
 
   SCM_VALIDATE_STRING (1, str);
@@ -543,16 +1102,11 @@ SCM_DEFINE (scm_string_to_char_set, "string->char-set", 
1, 1, 0,
       SCM_VALIDATE_SMOB (2, base_cs, charset);
       cs = scm_char_set_copy (base_cs);
     }
-  p = (long *) SCM_SMOB_DATA (cs);
   len = scm_i_string_length (str);
   while (k < len)
     {
       scm_t_wchar c = scm_i_string_ref_to_wchar (str, k++);
-      if (c >= 0 && c <= 0xFF)
-       p[c / SCM_BITS_PER_LONG] |= 1L << (c % SCM_BITS_PER_LONG);
-      else
-       SCM_MISC_ERROR ("FIXME: character sets cannot contain wide characters",
-                       SCM_EOL);
+      SCM_CHARSET_SET (cs, c);
     }
   scm_remember_upto_here_1 (str);
   return cs;
@@ -567,22 +1121,15 @@ SCM_DEFINE (scm_string_to_char_set_x, 
"string->char-set!", 2, 0, 0,
            "@var{base_cs} is returned.")
 #define FUNC_NAME s_scm_string_to_char_set_x
 {
-  long * p;
   size_t k = 0, len;
 
   SCM_VALIDATE_STRING (1, str);
   SCM_VALIDATE_SMOB (2, base_cs, charset);
-  p = (long *) SCM_SMOB_DATA (base_cs);
   len = scm_i_string_length (str);
   while (k < len)
     {
       scm_t_wchar c = scm_i_string_ref_to_wchar (str, k++);
-      if (c >= 0 && c < 0xff)
-       p[c / SCM_BITS_PER_LONG] |= 1L << (c % SCM_BITS_PER_LONG);
-      else
-       SCM_MISC_ERROR ("FIXME: character sets cannot contain wide characters",
-                       SCM_EOL);
-       
+      SCM_CHARSET_SET(base_cs, c);
     }
   scm_remember_upto_here_1 (str);
   return base_cs;
@@ -599,7 +1146,8 @@ SCM_DEFINE (scm_char_set_filter, "char-set-filter", 2, 1, 
0,
 {
   SCM ret;
   int k;
-  long * p;
+  scm_t_wchar n;
+  scm_t_char_set *p;
 
   SCM_VALIDATE_PROC (1, pred);
   SCM_VALIDATE_SMOB (2, cs, charset);
@@ -610,17 +1158,20 @@ SCM_DEFINE (scm_char_set_filter, "char-set-filter", 2, 
1, 0,
     }
   else
     ret = make_char_set (FUNC_NAME);
-  p = (long *) SCM_SMOB_DATA (ret);
-  for (k = 0; k < SCM_CHARSET_SIZE; k++)
-    {
-      if (SCM_CHARSET_GET (cs, k))
-       {
-         SCM res = scm_call_1 (pred, SCM_MAKE_CHAR (k));
 
-         if (scm_is_true (res))
-           p[k / SCM_BITS_PER_LONG] |= 1L << (k % SCM_BITS_PER_LONG);
-       }
-    }
+  p = SCM_CHARSET_DATA (cs);
+
+  if (p->len == 0)
+    return ret;
+
+  for (k = 0; k < p->len; k++)
+    for (n = p->ranges[k].lo; n <= p->ranges[k].hi; n++)
+      {
+        SCM res = scm_call_1 (pred, SCM_MAKE_CHAR (n));
+
+        if (scm_is_true (res))
+          SCM_CHARSET_SET (ret, n);
+      }
   return ret;
 }
 #undef FUNC_NAME
@@ -634,22 +1185,24 @@ SCM_DEFINE (scm_char_set_filter_x, "char-set-filter!", 
3, 0, 0,
 #define FUNC_NAME s_scm_char_set_filter_x
 {
   int k;
-  long * p;
+  scm_t_wchar n;
+  scm_t_char_set *p;
 
   SCM_VALIDATE_PROC (1, pred);
   SCM_VALIDATE_SMOB (2, cs, charset);
   SCM_VALIDATE_SMOB (3, base_cs, charset);
-  p = (long *) SCM_SMOB_DATA (base_cs);
-  for (k = 0; k < SCM_CHARSET_SIZE; k++)
-    {
-      if (SCM_CHARSET_GET (cs, k))
-       {
-         SCM res = scm_call_1 (pred, SCM_MAKE_CHAR (k));
+  p = SCM_CHARSET_DATA (cs);
+  if (p->len == 0)
+    return base_cs;
 
-         if (scm_is_true (res))
-           p[k / SCM_BITS_PER_LONG] |= 1L << (k % SCM_BITS_PER_LONG);
-       }
-    }
+  for (k = 0; k < p->len; k++)
+    for (n = p->ranges[k].lo; n <= p->ranges[k].hi; n++)
+      {
+        SCM res = scm_call_1 (pred, SCM_MAKE_CHAR (k));
+        
+        if (scm_is_true (res))
+          SCM_CHARSET_SET(base_cs, n);
+      }
   return base_cs;
 }
 #undef FUNC_NAME
@@ -673,7 +1226,6 @@ SCM_DEFINE (scm_ucs_range_to_char_set, 
"ucs-range->char-set", 2, 2, 0,
 {
   SCM cs;
   size_t clower, cupper;
-  long * p;
 
   clower = scm_to_size_t (lower);
   cupper = scm_to_size_t (upper);
@@ -682,14 +1234,14 @@ SCM_DEFINE (scm_ucs_range_to_char_set, 
"ucs-range->char-set", 2, 2, 0,
     {
       if (scm_is_true (error))
        {
-         SCM_ASSERT_RANGE (1, lower, clower <= SCM_CHARSET_SIZE);
-         SCM_ASSERT_RANGE (2, upper, cupper <= SCM_CHARSET_SIZE);
+         SCM_ASSERT_RANGE (1, lower, SCM_IS_UNICODE_CHAR (clower));
+         SCM_ASSERT_RANGE (2, upper, SCM_IS_UNICODE_CHAR (cupper));
        }
     }
-  if (clower > SCM_CHARSET_SIZE)
-    clower = SCM_CHARSET_SIZE;
-  if (cupper > SCM_CHARSET_SIZE)
-    cupper = SCM_CHARSET_SIZE;
+  if (clower > 0x10FFFF)
+    clower = 0x10FFFF;
+  if (cupper > 0x10FFFF)
+    cupper = 0x10FFFF;
   if (SCM_UNBNDP (base_cs))
     cs = make_char_set (FUNC_NAME);
   else
@@ -697,10 +1249,12 @@ SCM_DEFINE (scm_ucs_range_to_char_set, 
"ucs-range->char-set", 2, 2, 0,
       SCM_VALIDATE_SMOB (4, base_cs, charset);
       cs = scm_char_set_copy (base_cs);
     }
-  p = (long *) SCM_SMOB_DATA (cs);
+
+  /* It not be difficult to write a more optimized version of the
+     following.  */
   while (clower < cupper)
     {
-      p[clower / SCM_BITS_PER_LONG] |= 1L << (clower % SCM_BITS_PER_LONG);
+      SCM_CHARSET_SET (cs, clower);
       clower++;
     }
   return cs;
@@ -725,24 +1279,25 @@ SCM_DEFINE (scm_ucs_range_to_char_set_x, 
"ucs-range->char-set!", 4, 0, 0,
 #define FUNC_NAME s_scm_ucs_range_to_char_set_x
 {
   size_t clower, cupper;
-  long * p;
 
   clower = scm_to_size_t (lower);
   cupper = scm_to_size_t (upper);
   SCM_ASSERT_RANGE (2, upper, cupper >= clower);
+
   if (scm_is_true (error))
     {
-      SCM_ASSERT_RANGE (1, lower, clower <= SCM_CHARSET_SIZE);
-      SCM_ASSERT_RANGE (2, upper, cupper <= SCM_CHARSET_SIZE);
+      SCM_ASSERT_RANGE (1, lower, SCM_IS_UNICODE_CHAR (clower));
+      SCM_ASSERT_RANGE (2, upper, SCM_IS_UNICODE_CHAR (cupper));
     }
-  if (clower > SCM_CHARSET_SIZE)
-    clower = SCM_CHARSET_SIZE;
-  if (cupper > SCM_CHARSET_SIZE)
-    cupper = SCM_CHARSET_SIZE;
-  p = (long *) SCM_SMOB_DATA (base_cs);
+  if (clower > SCM_CODEPOINT_MAX)
+    clower = SCM_CODEPOINT_MAX;
+  if (cupper > SCM_CODEPOINT_MAX)
+    cupper = SCM_CODEPOINT_MAX;
+
   while (clower < cupper)
     {
-      p[clower / SCM_BITS_PER_LONG] |= 1L << (clower % SCM_BITS_PER_LONG);
+      if (SCM_IS_UNICODE_CHAR (clower))
+        SCM_CHARSET_SET (base_cs, clower);
       clower++;
     }
   return base_cs;
@@ -751,7 +1306,10 @@ SCM_DEFINE (scm_ucs_range_to_char_set_x, 
"ucs-range->char-set!", 4, 0, 0,
 
 SCM_DEFINE (scm_to_char_set, "->char-set", 1, 0, 0,
            (SCM x),
-           "Coerces x into a char-set. @var{x} may be a string, character or 
char-set. A string is converted to the set of its constituent characters; a 
character is converted to a singleton set; a char-set is returned as-is.")
+           "Coerces x into a char-set. @var{x} may be a string, character\n"
+            "or char-set. A string is converted to the set of its 
constituent\n"
+            "characters; a character is converted to a singleton set; a\n"
+            "char-set is returned as-is.")
 #define FUNC_NAME s_scm_to_char_set
 {
   if (scm_is_string (x))
@@ -771,12 +1329,18 @@ SCM_DEFINE (scm_char_set_size, "char-set-size", 1, 0, 0,
 #define FUNC_NAME s_scm_char_set_size
 {
   int k, count = 0;
+  scm_t_char_set *cs_data;
 
   SCM_VALIDATE_SMOB (1, cs, charset);
-  for (k = 0; k < SCM_CHARSET_SIZE; k++)
-    if (SCM_CHARSET_GET (cs, k))
-      count++;
-  return SCM_I_MAKINUM (count);
+  cs_data = SCM_CHARSET_DATA (cs);
+
+  if (cs_data->len == 0)
+    return scm_from_int (0);
+
+  for (k = 0; k < cs_data->len; k++)
+    count += cs_data->ranges[k].hi - cs_data->ranges[k].lo + 1;
+
+  return scm_from_int (count);
 }
 #undef FUNC_NAME
 
@@ -788,14 +1352,19 @@ SCM_DEFINE (scm_char_set_count, "char-set-count", 2, 0, 
0,
 #define FUNC_NAME s_scm_char_set_count
 {
   int k, count = 0;
+  scm_t_wchar n;
+  scm_t_char_set *cs_data;
 
   SCM_VALIDATE_PROC (1, pred);
   SCM_VALIDATE_SMOB (2, cs, charset);
+  cs_data = SCM_CHARSET_DATA (cs);
+  if (cs_data->len == 0)
+    return scm_from_int (0);
 
-  for (k = 0; k < SCM_CHARSET_SIZE; k++)
-    if (SCM_CHARSET_GET (cs, k))
+  for (k = 0; k < cs_data->len; k++)
+    for (n = cs_data->ranges[k].lo; n <= cs_data->ranges[k].hi; n++)
       {
-       SCM res = scm_call_1 (pred, SCM_MAKE_CHAR (k));
+       SCM res = scm_call_1 (pred, SCM_MAKE_CHAR (n));
        if (scm_is_true (res))
          count++;
       }
@@ -811,12 +1380,18 @@ SCM_DEFINE (scm_char_set_to_list, "char-set->list", 1, 
0, 0,
 #define FUNC_NAME s_scm_char_set_to_list
 {
   int k;
+  scm_t_wchar n;
   SCM result = SCM_EOL;
+  scm_t_char_set *p;
 
   SCM_VALIDATE_SMOB (1, cs, charset);
-  for (k = SCM_CHARSET_SIZE; k > 0; k--)
-    if (SCM_CHARSET_GET (cs, k - 1))
-      result = scm_cons (SCM_MAKE_CHAR (k - 1), result);
+  p = SCM_CHARSET_DATA (cs);
+  if (p->len == 0)
+    return SCM_EOL;
+
+  for (k = p->len - 1; k >= 0; k--)
+    for (n = p->ranges[k].hi; n >= p->ranges[k].lo; n --)
+      result = scm_cons (SCM_MAKE_CHAR (n), result);
   return result;
 }
 #undef FUNC_NAME
@@ -832,17 +1407,35 @@ SCM_DEFINE (scm_char_set_to_string, "char-set->string", 
1, 0, 0,
   int k;
   int count = 0;
   int idx = 0;
+  int wide = 0;
   SCM result;
-  char * p;
+  scm_t_wchar n;
+  scm_t_char_set *cs_data;
+  char *buf;
+  scm_t_wchar *wbuf;
 
   SCM_VALIDATE_SMOB (1, cs, charset);
-  for (k = 0; k < SCM_CHARSET_SIZE; k++)
-    if (SCM_CHARSET_GET (cs, k))
-      count++;
-  result = scm_i_make_string (count, &p);
-  for (k = 0; k < SCM_CHARSET_SIZE; k++)
-    if (SCM_CHARSET_GET (cs, k))
-      p[idx++] = k;
+  cs_data = SCM_CHARSET_DATA (cs);
+  if (cs_data->len == 0)
+    return scm_nullstr;
+
+  if (cs_data->ranges[cs_data->len-1].hi > 255)
+    wide = 1;
+
+  count = scm_to_int (scm_char_set_size (cs));
+  if (wide)
+    result = scm_i_make_wide_string (count, &wbuf);
+  else
+    result = scm_i_make_string (count, &buf);
+
+  for (k = 0; k < cs_data->len; k++)
+    for (n = cs_data->ranges[k].lo; n <= cs_data->ranges[k].hi; n++)
+      {
+        if (wide)
+          wbuf[idx++] = k;
+        else
+          buf[idx++] = k;
+      }
   return result;
 }
 #undef FUNC_NAME
@@ -868,19 +1461,25 @@ SCM_DEFINE (scm_char_set_every, "char-set-every", 2, 0, 
0,
 #define FUNC_NAME s_scm_char_set_every
 {
   int k;
+  scm_t_wchar n;
   SCM res = SCM_BOOL_T;
+  scm_t_char_set *cs_data;
 
   SCM_VALIDATE_PROC (1, pred);
   SCM_VALIDATE_SMOB (2, cs, charset);
 
-  for (k = 0; k < SCM_CHARSET_SIZE; k++)
-    if (SCM_CHARSET_GET (cs, k))
+  cs_data = SCM_CHARSET_DATA (cs);
+  if (cs_data->len == 0)
+    return SCM_BOOL_T;
+
+  for (k = 0; k < cs_data->len; k++)
+    for (n = cs_data->ranges[k].lo; n <= cs_data->ranges[k].hi; n++)
       {
-       res = scm_call_1 (pred, SCM_MAKE_CHAR (k));
-       if (scm_is_false (res))
-         return res;
+        res = scm_call_1 (pred, SCM_MAKE_CHAR (n));
+        if (scm_is_false (res))
+          return res;
       }
-  return res;
+  return SCM_BOOL_T;
 }
 #undef FUNC_NAME
 
@@ -892,14 +1491,17 @@ SCM_DEFINE (scm_char_set_any, "char-set-any", 2, 0, 0,
 #define FUNC_NAME s_scm_char_set_any
 {
   int k;
+  scm_t_wchar n;
+  scm_t_char_set *cs_data;
 
   SCM_VALIDATE_PROC (1, pred);
   SCM_VALIDATE_SMOB (2, cs, charset);
-
-  for (k = 0; k < SCM_CHARSET_SIZE; k++)
-    if (SCM_CHARSET_GET (cs, k))
+  cs_data = (scm_t_char_set *) cs;
+  
+  for (k = 0; k < cs_data->len; k++)
+    for (n = cs_data->ranges[k].lo; n <= cs_data->ranges[k].hi; n++)
       {
-       SCM res = scm_call_1 (pred, SCM_MAKE_CHAR (k));
+       SCM res = scm_call_1 (pred, SCM_MAKE_CHAR (n));
        if (scm_is_true (res))
          return res;
       }
@@ -914,13 +1516,10 @@ SCM_DEFINE (scm_char_set_adjoin, "char-set-adjoin", 1, 
0, 1,
            "be a character set.")
 #define FUNC_NAME s_scm_char_set_adjoin
 {
-  long * p;
-
   SCM_VALIDATE_SMOB (1, cs, charset);
   SCM_VALIDATE_REST_ARGUMENT (rest);
   cs = scm_char_set_copy (cs);
 
-  p = (long *) SCM_SMOB_DATA (cs);
   while (!scm_is_null (rest))
     {
       SCM chr = SCM_CAR (rest);
@@ -928,8 +1527,7 @@ SCM_DEFINE (scm_char_set_adjoin, "char-set-adjoin", 1, 0, 
1,
 
       SCM_VALIDATE_CHAR_COPY (1, chr, c);
       rest = SCM_CDR (rest);
-
-      p[c / SCM_BITS_PER_LONG] |= 1L << (c % SCM_BITS_PER_LONG);
+      SCM_CHARSET_SET(cs, c);
     }
   return cs;
 }
@@ -942,13 +1540,10 @@ SCM_DEFINE (scm_char_set_delete, "char-set-delete", 1, 
0, 1,
            "must be a character set.")
 #define FUNC_NAME s_scm_char_set_delete
 {
-  long * p;
-
   SCM_VALIDATE_SMOB (1, cs, charset);
   SCM_VALIDATE_REST_ARGUMENT (rest);
   cs = scm_char_set_copy (cs);
 
-  p = (long *) SCM_SMOB_DATA (cs);
   while (!scm_is_null (rest))
     {
       SCM chr = SCM_CAR (rest);
@@ -957,7 +1552,7 @@ SCM_DEFINE (scm_char_set_delete, "char-set-delete", 1, 0, 
1,
       SCM_VALIDATE_CHAR_COPY (1, chr, c);
       rest = SCM_CDR (rest);
 
-      p[c / SCM_BITS_PER_LONG] &= ~(1L << (c % SCM_BITS_PER_LONG));
+      SCM_CHARSET_UNSET (cs, c);
     }
   return cs;
 }
@@ -970,12 +1565,9 @@ SCM_DEFINE (scm_char_set_adjoin_x, "char-set-adjoin!", 1, 
0, 1,
            "be a character set.")
 #define FUNC_NAME s_scm_char_set_adjoin_x
 {
-  long * p;
-
   SCM_VALIDATE_SMOB (1, cs, charset);
   SCM_VALIDATE_REST_ARGUMENT (rest);
 
-  p = (long *) SCM_SMOB_DATA (cs);
   while (!scm_is_null (rest))
     {
       SCM chr = SCM_CAR (rest);
@@ -983,8 +1575,7 @@ SCM_DEFINE (scm_char_set_adjoin_x, "char-set-adjoin!", 1, 
0, 1,
 
       SCM_VALIDATE_CHAR_COPY (1, chr, c);
       rest = SCM_CDR (rest);
-
-      p[c / SCM_BITS_PER_LONG] |= 1L << (c % SCM_BITS_PER_LONG);
+      SCM_CHARSET_SET (cs, c);
     }
   return cs;
 }
@@ -997,12 +1588,9 @@ SCM_DEFINE (scm_char_set_delete_x, "char-set-delete!", 1, 
0, 1,
            "must be a character set.")
 #define FUNC_NAME s_scm_char_set_delete_x
 {
-  long * p;
-
   SCM_VALIDATE_SMOB (1, cs, charset);
   SCM_VALIDATE_REST_ARGUMENT (rest);
 
-  p = (long *) SCM_SMOB_DATA (cs);
   while (!scm_is_null (rest))
     {
       SCM chr = SCM_CAR (rest);
@@ -1011,7 +1599,7 @@ SCM_DEFINE (scm_char_set_delete_x, "char-set-delete!", 1, 
0, 1,
       SCM_VALIDATE_CHAR_COPY (1, chr, c);
       rest = SCM_CDR (rest);
 
-      p[c / SCM_BITS_PER_LONG] &= ~(1L << (c % SCM_BITS_PER_LONG));
+      SCM_CHARSET_UNSET (cs, c);
     }
   return cs;
 }
@@ -1023,17 +1611,16 @@ SCM_DEFINE (scm_char_set_complement, 
"char-set-complement", 1, 0, 0,
            "Return the complement of the character set @var{cs}.")
 #define FUNC_NAME s_scm_char_set_complement
 {
-  int k;
   SCM res;
-  long * p, * q;
+  scm_t_char_set *p, *q;
 
   SCM_VALIDATE_SMOB (1, cs, charset);
 
   res = make_char_set (FUNC_NAME);
-  p = (long *) SCM_SMOB_DATA (res);
-  q = (long *) SCM_SMOB_DATA (cs);
-  for (k = 0; k < LONGS_PER_CHARSET; k++)
-    p[k] = ~q[k];
+  p = SCM_CHARSET_DATA (res);
+  q = SCM_CHARSET_DATA (cs);
+
+  charsets_complement (p, q);
   return res;
 }
 #undef FUNC_NAME
@@ -1046,22 +1633,20 @@ SCM_DEFINE (scm_char_set_union, "char-set-union", 0, 0, 
1,
 {
   int c = 1;
   SCM res;
-  long * p;
+  scm_t_char_set *p;
 
   SCM_VALIDATE_REST_ARGUMENT (rest);
 
   res = make_char_set (FUNC_NAME);
-  p = (long *) SCM_SMOB_DATA (res);
+  p = SCM_CHARSET_DATA (res);
   while (!scm_is_null (rest))
     {
-      int k;
       SCM cs = SCM_CAR (rest);
       SCM_VALIDATE_SMOB (c, cs, charset);
       c++;
       rest = SCM_CDR (rest);
-
-      for (k = 0; k < LONGS_PER_CHARSET; k++)
-       p[k] |= ((long *) SCM_SMOB_DATA (cs))[k];
+      
+      charsets_union (p, (scm_t_char_set *)SCM_SMOB_DATA (cs));
     }
   return res;
 }
@@ -1081,25 +1666,23 @@ SCM_DEFINE (scm_char_set_intersection, 
"char-set-intersection", 0, 0, 1,
     res = make_char_set (FUNC_NAME);
   else
     {
-      long *p;
+      scm_t_char_set *p;
       int argnum = 2;
 
       res = scm_char_set_copy (SCM_CAR (rest));
-      p = (long *) SCM_SMOB_DATA (res);
+      p = SCM_CHARSET_DATA (res);
       rest = SCM_CDR (rest);
 
       while (scm_is_pair (rest))
        {
-         int k;
          SCM cs = SCM_CAR (rest);
-         long *cs_data;
+         scm_t_char_set *cs_data;
 
          SCM_VALIDATE_SMOB (argnum, cs, charset);
          argnum++;
-         cs_data = (long *) SCM_SMOB_DATA (cs);
+         cs_data = SCM_CHARSET_DATA (cs);
          rest = SCM_CDR (rest);
-         for (k = 0; k < LONGS_PER_CHARSET; k++)
-           p[k] &= cs_data[k];
+          charsets_intersection (p, cs_data);
        }
     }
 
@@ -1114,24 +1697,24 @@ SCM_DEFINE (scm_char_set_difference, 
"char-set-difference", 1, 0, 1,
 #define FUNC_NAME s_scm_char_set_difference
 {
   int c = 2;
-  SCM res;
-  long * p;
+  SCM res, compl;
+  scm_t_char_set *p, *q;
 
   SCM_VALIDATE_SMOB (1, cs1, charset);
   SCM_VALIDATE_REST_ARGUMENT (rest);
 
   res = scm_char_set_copy (cs1);
-  p = (long *) SCM_SMOB_DATA (res);
+  p = SCM_CHARSET_DATA (res);
+  compl = make_char_set (FUNC_NAME);
+  q = SCM_CHARSET_DATA (compl);
   while (!scm_is_null (rest))
     {
-      int k;
       SCM cs = SCM_CAR (rest);
       SCM_VALIDATE_SMOB (c, cs, charset);
       c++;
       rest = SCM_CDR (rest);
-
-      for (k = 0; k < LONGS_PER_CHARSET; k++)
-       p[k] &= ~((long *) SCM_SMOB_DATA (cs))[k];
+      charsets_complement (q, SCM_CHARSET_DATA (cs));
+      charsets_intersection (p, q);
     }
   return res;
 }
@@ -1152,25 +1735,23 @@ SCM_DEFINE (scm_char_set_xor, "char-set-xor", 0, 0, 1,
   else
     {
       int argnum = 2;
-      long * p;
+      scm_t_char_set *p;
 
       res = scm_char_set_copy (SCM_CAR (rest));
-      p = (long *) SCM_SMOB_DATA (res);
+      p = SCM_CHARSET_DATA (res);
       rest = SCM_CDR (rest);
 
       while (scm_is_pair (rest))
        {
          SCM cs = SCM_CAR (rest);
-         long *cs_data;
-         int k;
+         scm_t_char_set *cs_data;
 
          SCM_VALIDATE_SMOB (argnum, cs, charset);
          argnum++;
-         cs_data = (long *) SCM_SMOB_DATA (cs);
+         cs_data = SCM_CHARSET_DATA (cs);
          rest = SCM_CDR (rest);
 
-         for (k = 0; k < LONGS_PER_CHARSET; k++)
-           p[k] ^= cs_data[k];
+          charsets_xor (p, cs_data);
        }
     }
   return res;
@@ -1186,30 +1767,26 @@ SCM_DEFINE (scm_char_set_diff_plus_intersection, 
"char-set-diff+intersection", 1
 {
   int c = 2;
   SCM res1, res2;
-  long * p, * q;
+  scm_t_char_set *p, *q;
 
   SCM_VALIDATE_SMOB (1, cs1, charset);
   SCM_VALIDATE_REST_ARGUMENT (rest);
 
   res1 = scm_char_set_copy (cs1);
   res2 = make_char_set (FUNC_NAME);
-  p = (long *) SCM_SMOB_DATA (res1);
-  q = (long *) SCM_SMOB_DATA (res2);
+  p = SCM_CHARSET_DATA (res1);
+  q = SCM_CHARSET_DATA (res2);
   while (!scm_is_null (rest))
     {
-      int k;
       SCM cs = SCM_CAR (rest);
-      long *r;
+      scm_t_char_set *r;
 
       SCM_VALIDATE_SMOB (c, cs, charset);
       c++;
-      r = (long *) SCM_SMOB_DATA (cs);
+      r = SCM_CHARSET_DATA (cs);
 
-      for (k = 0; k < LONGS_PER_CHARSET; k++)
-       {
-         q[k] |= p[k] & r[k];
-         p[k] &= ~r[k];
-       }
+      charsets_union (q, r);
+      charsets_intersection (p, r);
       rest = SCM_CDR (rest);
     }
   return scm_values (scm_list_2 (res1, res2));
@@ -1222,13 +1799,8 @@ SCM_DEFINE (scm_char_set_complement_x, 
"char-set-complement!", 1, 0, 0,
            "Return the complement of the character set @var{cs}.")
 #define FUNC_NAME s_scm_char_set_complement_x
 {
-  int k;
-  long * p;
-
   SCM_VALIDATE_SMOB (1, cs, charset);
-  p = (long *) SCM_SMOB_DATA (cs);
-  for (k = 0; k < LONGS_PER_CHARSET; k++)
-    p[k] = ~p[k];
+  cs = scm_char_set_complement (cs);
   return cs;
 }
 #undef FUNC_NAME
@@ -1239,24 +1811,10 @@ SCM_DEFINE (scm_char_set_union_x, "char-set-union!", 1, 
0, 1,
            "Return the union of all argument character sets.")
 #define FUNC_NAME s_scm_char_set_union_x
 {
-  int c = 2;
-  long * p;
-
   SCM_VALIDATE_SMOB (1, cs1, charset);
   SCM_VALIDATE_REST_ARGUMENT (rest);
 
-  p = (long *) SCM_SMOB_DATA (cs1);
-  while (!scm_is_null (rest))
-    {
-      int k;
-      SCM cs = SCM_CAR (rest);
-      SCM_VALIDATE_SMOB (c, cs, charset);
-      c++;
-      rest = SCM_CDR (rest);
-
-      for (k = 0; k < LONGS_PER_CHARSET; k++)
-       p[k] |= ((long *) SCM_SMOB_DATA (cs))[k];
-    }
+  cs1 = scm_char_set_union (scm_cons (cs1, rest));
   return cs1;
 }
 #undef FUNC_NAME
@@ -1267,24 +1825,10 @@ SCM_DEFINE (scm_char_set_intersection_x, 
"char-set-intersection!", 1, 0, 1,
            "Return the intersection of all argument character sets.")
 #define FUNC_NAME s_scm_char_set_intersection_x
 {
-  int c = 2;
-  long * p;
-
   SCM_VALIDATE_SMOB (1, cs1, charset);
   SCM_VALIDATE_REST_ARGUMENT (rest);
 
-  p = (long *) SCM_SMOB_DATA (cs1);
-  while (!scm_is_null (rest))
-    {
-      int k;
-      SCM cs = SCM_CAR (rest);
-      SCM_VALIDATE_SMOB (c, cs, charset);
-      c++;
-      rest = SCM_CDR (rest);
-
-      for (k = 0; k < LONGS_PER_CHARSET; k++)
-       p[k] &= ((long *) SCM_SMOB_DATA (cs))[k];
-    }
+  cs1 = scm_char_set_intersection (scm_cons (cs1, rest));
   return cs1;
 }
 #undef FUNC_NAME
@@ -1295,24 +1839,10 @@ SCM_DEFINE (scm_char_set_difference_x, 
"char-set-difference!", 1, 0, 1,
            "Return the difference of all argument character sets.")
 #define FUNC_NAME s_scm_char_set_difference_x
 {
-  int c = 2;
-  long * p;
-
   SCM_VALIDATE_SMOB (1, cs1, charset);
   SCM_VALIDATE_REST_ARGUMENT (rest);
 
-  p = (long *) SCM_SMOB_DATA (cs1);
-  while (!scm_is_null (rest))
-    {
-      int k;
-      SCM cs = SCM_CAR (rest);
-      SCM_VALIDATE_SMOB (c, cs, charset);
-      c++;
-      rest = SCM_CDR (rest);
-
-      for (k = 0; k < LONGS_PER_CHARSET; k++)
-       p[k] &= ~((long *) SCM_SMOB_DATA (cs))[k];
-    }
+  cs1 = scm_char_set_difference (cs1, rest);
   return cs1;
 }
 #undef FUNC_NAME
@@ -1323,35 +1853,7 @@ SCM_DEFINE (scm_char_set_xor_x, "char-set-xor!", 1, 0, 1,
            "Return the exclusive-or of all argument character sets.")
 #define FUNC_NAME s_scm_char_set_xor_x
 {
-  /* a side-effecting variant should presumably give consistent results:
-     (define a (char-set #\a))
-     (char-set-xor a a a) -> char set #\a
-     (char-set-xor! a a a) -> char set #\a
-  */
   return scm_char_set_xor (scm_cons (cs1, rest));
-
-#if 0
-  /* this would give (char-set-xor! a a a) -> empty char set.  */
-  int c = 2;
-  long * p;
-
-  SCM_VALIDATE_SMOB (1, cs1, charset);
-  SCM_VALIDATE_REST_ARGUMENT (rest);
-
-  p = (long *) SCM_SMOB_DATA (cs1);
-  while (!scm_is_null (rest))
-    {
-      int k;
-      SCM cs = SCM_CAR (rest);
-      SCM_VALIDATE_SMOB (c, cs, charset);
-      c++;
-      rest = SCM_CDR (rest);
-
-      for (k = 0; k < LONGS_PER_CHARSET; k++)
-       p[k] ^= ((long *) SCM_SMOB_DATA (cs))[k];
-    }
-  return cs1;
-#endif
 }
 #undef FUNC_NAME
 
@@ -1362,50 +1864,29 @@ SCM_DEFINE (scm_char_set_diff_plus_intersection_x, 
"char-set-diff+intersection!"
            "character sets.")
 #define FUNC_NAME s_scm_char_set_diff_plus_intersection_x
 {
-  int c = 3;
-  long * p, * q;
-  int k;
+  SCM diff, intersect;
 
-  SCM_VALIDATE_SMOB (1, cs1, charset);
-  SCM_VALIDATE_SMOB (2, cs2, charset);
-  SCM_VALIDATE_REST_ARGUMENT (rest);
-
-  p = (long *) SCM_SMOB_DATA (cs1);
-  q = (long *) SCM_SMOB_DATA (cs2);
-  if (p == q)
-    {
-      /* (char-set-diff+intersection! a a ...): can't share storage,
-        but we know the answer without checking for further
-        arguments.  */
-      return scm_values (scm_list_2 (make_char_set (FUNC_NAME), cs1));
-    }
-  for (k = 0; k < LONGS_PER_CHARSET; k++)
-    {
-      long t = p[k];
+  diff = scm_char_set_difference (cs1, scm_cons (cs2, rest));
+  intersect = scm_char_set_intersection (scm_cons (cs1, scm_cons (cs2, rest)));
+  cs1 = diff;
+  cs2 = intersect;
+  return scm_values (scm_list_2 (cs1, cs2));
+}
+#undef FUNC_NAME
 
-      p[k] &= ~q[k];
-      q[k] = t & q[k];
-    }
-  while (!scm_is_null (rest))
-    {
-      SCM cs = SCM_CAR (rest);
-      long *r;
 
-      SCM_VALIDATE_SMOB (c, cs, charset);
-      c++;
-      r = (long *) SCM_SMOB_DATA (cs);
-
-      for (k = 0; k < LONGS_PER_CHARSET; k++)
-       {
-         q[k] |= p[k] & r[k];
-         p[k] &= ~r[k];
-       }
-      rest = SCM_CDR (rest);
-    }
-  return scm_values (scm_list_2 (cs1, cs2));
+SCM_DEFINE (scm_unicode_char_sets, "unicode-char-sets", 0, 0, 0,
+           (void),
+           "Populates the standard characters sets with codepoints from the 
full\n"
+            "Unicode range, instead of just from Latin-1 characters.\n")
+#define FUNC_NAME s_scm_unicode_char_sets
+{
+  scm_srfi_14_compute_char_sets (0x10FFFF);
+  return SCM_UNSPECIFIED;
 }
 #undef FUNC_NAME
 
+
 
 /* Standard character sets.  */
 
@@ -1437,39 +1918,42 @@ define_charset (const char *name)
   return scm_permanent_object (cs);
 }
 
-/* Membership predicates for the various char sets.
-
-   XXX: The `punctuation' and `symbol' char sets have no direct equivalent in
-   <ctype.h>.  Thus, the predicates below yield correct results for ASCII,
-   but they do not provide the result described by the SRFI for Latin-1.  The
-   correct Latin-1 result could only be obtained by hard-coding the
-   characters listed by the SRFI, but the problem would remain for other
-   8-bit charsets.
-
-   Similarly, character 0xA0 in Latin-1 (unbreakable space, `#\0240') should
-   be part of `char-set:blank'.  However, glibc's current (2006/09) Latin-1
-   locales (which use the ISO 14652 "i18n" FDCC-set) do not consider it
-   `blank' so it ends up in `char-set:punctuation'.  */
-#ifdef HAVE_ISBLANK
-# define CSET_BLANK_PRED(c)  (isblank (c))
-#else
-# define CSET_BLANK_PRED(c)                    \
-   (((c) == ' ') || ((c) == '\t'))
-#endif
-
-#define CSET_SYMBOL_PRED(c)                                    \
-  (((c) != '\0') && (strchr ("$+<=>^`|~", (c)) != NULL))
-#define CSET_PUNCT_PRED(c)                                     \
-  ((ispunct (c)) && (!CSET_SYMBOL_PRED (c)))
-
-#define CSET_LOWER_PRED(c)       (islower (c))
-#define CSET_UPPER_PRED(c)       (isupper (c))
-#define CSET_LETTER_PRED(c)      (isalpha (c))
-#define CSET_DIGIT_PRED(c)       (isdigit (c))
-#define CSET_WHITESPACE_PRED(c)  (isspace (c))
-#define CSET_CONTROL_PRED(c)     (iscntrl (c))
-#define CSET_HEX_DIGIT_PRED(c)   (isxdigit (c))
-#define CSET_ASCII_PRED(c)       (isascii (c))
+/* Membership predicates for the various char sets.  */
+#define CSET_SYMBOL_PRED(c)                                             \
+  (((c) != '\0') && ((c) < 128) && (strchr ("$+<=>^`|~", (c)) != NULL))
+
+#define CSET_PUNCT_PRED(c)       (uc_is_general_category_withtable (c, 
UC_CATEGORY_MASK_P) \
+                                  && (!CSET_SYMBOL_PRED (c)))
+#define CSET_BLANK_PRED(c)       (uc_is_general_category_withtable (c, 
UC_CATEGORY_MASK_Zs))
+#define CSET_LOWER_PRED(c)       (uc_is_general_category_withtable (c, 
UC_CATEGORY_MASK_Ll))
+#define CSET_UPPER_PRED(c)       (uc_is_general_category_withtable (c, 
UC_CATEGORY_MASK_Lu))
+#define CSET_TITLE_PRED(c)       (uc_is_general_category_withtable (c, 
UC_CATEGORY_MASK_Lt))
+#define CSET_LETTER_PRED(c)      (uc_is_general_category_withtable (c, 
UC_CATEGORY_MASK_L))
+#define CSET_DIGIT_PRED(c)       (uc_is_general_category_withtable (c, 
UC_CATEGORY_MASK_Nd))
+#define CSET_WHITESPACE_PRED(c)  (uc_is_general_category_withtable (c, 
UC_CATEGORY_MASK_Zs))
+#define CSET_CONTROL_PRED(c)     (uc_is_general_category_withtable (c, 
UC_CATEGORY_MASK_Cc))
+#define CSET_GRAPHIC_PRED(c)     (uc_is_general_category_withtable (c, 
UC_CATEGORY_MASK_L \
+                                                                    | 
UC_CATEGORY_MASK_M \
+                                                                    | 
UC_CATEGORY_MASK_N \
+                                                                    | 
UC_CATEGORY_MASK_P \
+                                                                    | 
UC_CATEGORY_MASK_S))
+#define CSET_PRINTING_PRED(c)    (uc_is_general_category_withtable (c, 
UC_CATEGORY_MASK_L \
+                                                                    | 
UC_CATEGORY_MASK_M \
+                                                                    | 
UC_CATEGORY_MASK_N \
+                                                                    | 
UC_CATEGORY_MASK_P \
+                                                                    | 
UC_CATEGORY_MASK_S \
+                                                                    | 
UC_CATEGORY_MASK_Z))
+#define CSET_FULL_PRED(c)       (uc_is_general_category_withtable (c, 
UC_CATEGORY_MASK_L \
+                                                                   | 
UC_CATEGORY_MASK_M \
+                                                                   | 
UC_CATEGORY_MASK_N \
+                                                                   | 
UC_CATEGORY_MASK_P \
+                                                                   | 
UC_CATEGORY_MASK_S \
+                                                                   | 
UC_CATEGORY_MASK_Z \
+                                                                   | 
UC_CATEGORY_MASK_Cc \
+                                                                   | 
UC_CATEGORY_MASK_Cf))
+
+#define CSET_HEX_DIGIT_PRED(c)   (uc_is_xdigit (c))
+#define CSET_ASCII_PRED(c)       (((c) >= '\0') && ((c) <= 127))
 
 /* Some char sets are explicitly defined by the SRFI as a union of other char
    sets so we try to follow this closely.  */
@@ -1477,13 +1961,6 @@ define_charset (const char *name)
 #define CSET_LETTER_AND_DIGIT_PRED(c)          \
   (CSET_LETTER_PRED (c) || CSET_DIGIT_PRED (c))
 
-#define CSET_GRAPHIC_PRED(c)                           \
-  (CSET_LETTER_PRED (c) || CSET_DIGIT_PRED (c)         \
-   || CSET_PUNCT_PRED (c) || CSET_SYMBOL_PRED (c))
-
-#define CSET_PRINTING_PRED(c)                          \
-  (CSET_GRAPHIC_PRED (c) || CSET_WHITESPACE_PRED (c))
-
 /* False and true predicates.  */
 #define CSET_TRUE_PRED(c)    (1)
 #define CSET_FALSE_PRED(c)   (0)
@@ -1504,7 +1981,7 @@ define_charset (const char *name)
    charset-dependent, though generally not language-dependent).  For details,
    please see the `guile-devel' mailing list archive of September 2006.  */
 void
-scm_srfi_14_compute_char_sets (void)
+scm_srfi_14_compute_char_sets (scm_t_wchar max)
 {
 #define UPDATE_CSET(c, cset, pred)             \
   do                                           \
@@ -1518,11 +1995,14 @@ scm_srfi_14_compute_char_sets (void)
 
   register int ch;
 
-  for (ch = 0; ch < 256; ch++)
+  /* This is wrong of course.  It only iterates over the Basic
+     Multilingual Plane of 64k codepoints.  But, rebuilding these over
+     all of Unicode for each locale change is very expensive.  */
+  for (ch = 0; ch < max; ch++)
     {
       UPDATE_CSET (ch, scm_char_set_upper_case, CSET_UPPER_PRED);
       UPDATE_CSET (ch, scm_char_set_lower_case, CSET_LOWER_PRED);
-      UPDATE_CSET (ch, scm_char_set_title_case, CSET_FALSE_PRED);
+      UPDATE_CSET (ch, scm_char_set_title_case, CSET_TITLE_PRED);
       UPDATE_CSET (ch, scm_char_set_letter, CSET_LETTER_PRED);
       UPDATE_CSET (ch, scm_char_set_digit, CSET_DIGIT_PRED);
       UPDATE_CSET (ch, scm_char_set_letter_and_digit,
@@ -1537,23 +2017,54 @@ scm_srfi_14_compute_char_sets (void)
       UPDATE_CSET (ch, scm_char_set_blank, CSET_BLANK_PRED);
       UPDATE_CSET (ch, scm_char_set_ascii, CSET_ASCII_PRED);
       UPDATE_CSET (ch, scm_char_set_empty, CSET_FALSE_PRED);
-      UPDATE_CSET (ch, scm_char_set_full, CSET_TRUE_PRED);
+      UPDATE_CSET (ch, scm_char_set_full, CSET_FULL_PRED);
     }
 
 #undef UPDATE_CSET
 }
 
+#ifdef SCM_CHARSET_DEBUG
+SCM_DEFINE (scm_debug_char_set, "debug-char-set", 1, 0, 0,
+           (SCM charset),
+           "Print out the internal C structure of @var{charset}.\n")
+#define FUNC_NAME s_debug_char_set
+{
+  int i;
+  scm_t_char_set *cs = SCM_CHARSET_DATA (charset);
+  fprintf (stderr, "cs %p\n", cs);
+  fprintf (stderr, "len %d\n", cs->len);
+  fprintf (stderr, "arr %p\n", cs->ranges);
+  for (i = 0; i < cs->len; i ++)
+    {
+      if (cs->ranges[i].lo == cs->ranges[i].hi)
+        fprintf (stderr, "%04x\n", cs->ranges[i].lo);
+      else
+        fprintf (stderr, "%04x..%04x\t[%d]\n" ,
+                 cs->ranges[i].lo, 
+                 cs->ranges[i].hi,
+                 cs->ranges[i].hi - cs->ranges[i].lo + 1);
+    }
+  printf ("\n");
+  return SCM_UNSPECIFIED;
+}
+#undef FUNC_NAME
+#endif
+
+
 
 void
 scm_init_srfi_14 (void)
 {
-  scm_tc16_charset = scm_make_smob_type ("character-set",
-                                        BYTES_PER_CHARSET);
+  scm_tc16_charset = scm_make_smob_type ("character-set", 0);
   scm_set_smob_free (scm_tc16_charset, charset_free);
   scm_set_smob_print (scm_tc16_charset, charset_print);
 
-  scm_char_set_upper_case = define_charset ("char-set:upper-case");
-  scm_char_set_lower_case = define_charset ("char-set:lower-case");
+  scm_tc16_charset_cursor = scm_make_smob_type ("char-set-cursor", 0);
+  scm_set_smob_free (scm_tc16_charset_cursor, charset_cursor_free);
+  scm_set_smob_print (scm_tc16_charset_cursor, charset_cursor_print);
+
+  scm_char_set_upper_case = define_charset ("char-set:upper-case"); 
+  scm_char_set_lower_case = define_charset ("char-set:lower-case"); 
   scm_char_set_title_case = define_charset ("char-set:title-case");
   scm_char_set_letter = define_charset ("char-set:letter");
   scm_char_set_digit = define_charset ("char-set:digit");
@@ -1570,8 +2081,7 @@ scm_init_srfi_14 (void)
   scm_char_set_empty = define_charset ("char-set:empty");
   scm_char_set_full = define_charset ("char-set:full");
 
-  scm_srfi_14_compute_char_sets ();
-
+  scm_srfi_14_compute_char_sets (255);
 #include "libguile/srfi-14.x"
 }
 
diff --git a/libguile/srfi-14.h b/libguile/srfi-14.h
index ea8027a..4b21404 100644
--- a/libguile/srfi-14.h
+++ b/libguile/srfi-14.h
@@ -6,40 +6,54 @@
  *     Copyright (C) 2001, 2004, 2006, 2008 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
 #include "libguile/__scm.h"
 
-#define SCM_CHARSET_SIZE 256
+typedef struct
+{
+  scm_t_wchar lo;
+  scm_t_wchar hi;
+} scm_t_char_range;
 
-/* We expect 8-bit bytes here.  Should be no problem in the year
-   2001.  */
-#ifndef SCM_BITS_PER_LONG
-# define SCM_BITS_PER_LONG (sizeof (long) * 8)
-#endif
+typedef struct 
+{
+  size_t len;
+  scm_t_char_range *ranges;
+} scm_t_char_set;
+
+typedef struct
+{
+  size_t range;
+  scm_t_wchar n;
+} scm_t_char_set_cursor;
 
-#define SCM_CHARSET_GET(cs, idx) (((long *) SCM_SMOB_DATA (cs))\
-                                  [((unsigned char) (idx)) / 
SCM_BITS_PER_LONG] &\
-                                  (1L << (((unsigned char) (idx)) % 
SCM_BITS_PER_LONG)))
+#define SCM_CHARSET_GET(cs,idx)                                 \
+  scm_i_charset_get((scm_t_char_set *)SCM_SMOB_DATA(cs),idx)
 
 #define SCM_CHARSETP(x) (!SCM_IMP (x) && (SCM_TYP16 (x) == scm_tc16_charset))
 
 /* Smob type code for character sets.  */
 SCM_API int scm_tc16_charset;
 
+SCM_INTERNAL int scm_i_charset_get (scm_t_char_set *cs, scm_t_wchar n);
+SCM_INTERNAL void scm_i_charset_set (scm_t_char_set *cs, scm_t_wchar n);
+SCM_INTERNAL void scm_i_charset_unset (scm_t_char_set *cs, scm_t_wchar n);
+
 SCM_API SCM scm_char_set_p (SCM obj);
 SCM_API SCM scm_char_set_eq (SCM char_sets);
 SCM_API SCM scm_char_set_leq (SCM char_sets);
@@ -87,6 +101,10 @@ SCM_API SCM scm_char_set_intersection_x (SCM cs1, SCM rest);
 SCM_API SCM scm_char_set_difference_x (SCM cs1, SCM rest);
 SCM_API SCM scm_char_set_xor_x (SCM cs1, SCM rest);
 SCM_API SCM scm_char_set_diff_plus_intersection_x (SCM cs1, SCM cs2, SCM rest);
+SCM_API SCM scm_unicode_char_sets (void);
+#if SCM_CHARSET_DEBUG
+SCM_API SCM scm_debug_char_set (SCM cs);
+#endif
 
 SCM_API SCM scm_char_set_lower_case;
 SCM_API SCM scm_char_set_upper_case;
@@ -106,7 +124,7 @@ SCM_API SCM scm_char_set_ascii;
 SCM_API SCM scm_char_set_empty;
 SCM_API SCM scm_char_set_full;
 
-SCM_INTERNAL void scm_srfi_14_compute_char_sets (void);
+SCM_INTERNAL void scm_srfi_14_compute_char_sets (scm_t_wchar max);
 SCM_INTERNAL void scm_init_srfi_14 (void);
 
 #endif /* SCM_SRFI_14_H */
diff --git a/libguile/srfi-4.c b/libguile/srfi-4.c
index b0e052a..da571b0 100644
--- a/libguile/srfi-4.c
+++ b/libguile/srfi-4.c
@@ -1,20 +1,21 @@
 /* srfi-4.c --- Uniform numeric vector datatypes.
  *
- *     Copyright (C) 2001, 2004, 2006 Free Software Foundation, Inc.
+ *     Copyright (C) 2001, 2004, 2006, 2009 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
@@ -28,6 +29,7 @@
 #include "libguile/_scm.h"
 #include "libguile/__scm.h"
 #include "libguile/srfi-4.h"
+#include "libguile/bytevectors.h"
 #include "libguile/error.h"
 #include "libguile/read.h"
 #include "libguile/ports.h"
@@ -608,6 +610,8 @@ scm_i_generalized_vector_type (SCM v)
     return scm_sym_b;
   else if (scm_is_uniform_vector (v))
     return scm_from_locale_symbol (uvec_tags[SCM_UVEC_TYPE(v)]);
+  else if (scm_is_bytevector (v))
+    return scm_from_locale_symbol ("vu8");
   else
     return SCM_BOOL_F;
 }
@@ -749,6 +753,8 @@ scm_array_handle_uniform_element_size (scm_t_array_handle 
*h)
     vec = SCM_I_ARRAY_V (vec);
   if (scm_is_uniform_vector (vec))
     return uvec_sizes[SCM_UVEC_TYPE(vec)];
+  if (scm_is_bytevector (vec))
+    return 1U;
   scm_wrong_type_arg_msg (NULL, 0, h->array, "uniform array");
 }
 
@@ -789,6 +795,8 @@ scm_array_handle_uniform_writable_elements 
(scm_t_array_handle *h)
       char *elts = SCM_UVEC_BASE (vec);
       return (void *) (elts + size*h->base);
     }
+  if (scm_is_bytevector (vec))
+    return SCM_BYTEVECTOR_CONTENTS (vec);
   scm_wrong_type_arg_msg (NULL, 0, h->array, "uniform array");
 }
 
diff --git a/libguile/srfi-4.h b/libguile/srfi-4.h
index 3c340d9..a1a9baf 100644
--- a/libguile/srfi-4.h
+++ b/libguile/srfi-4.h
@@ -5,18 +5,19 @@
  *     Copyright (C) 2001, 2004, 2006, 2008 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/stackchk.c b/libguile/stackchk.c
index a53e676..b14a712 100644
--- a/libguile/stackchk.c
+++ b/libguile/stackchk.c
@@ -1,18 +1,19 @@
 /*     Copyright (C) 1995,1996,1997, 2000, 2001, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/stackchk.h b/libguile/stackchk.h
index 8681f5d..6aa0fec 100644
--- a/libguile/stackchk.h
+++ b/libguile/stackchk.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,2000, 2003, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/stacks.c b/libguile/stacks.c
index 69fb340..45566ca 100644
--- a/libguile/stacks.c
+++ b/libguile/stacks.c
@@ -2,18 +2,19 @@
  * Copyright (C) 1996,1997,2000,2001, 2006, 2007, 2008, 2009 Free Software 
Foundation
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/stacks.h b/libguile/stacks.h
index 53633bc..20735ef 100644
--- a/libguile/stacks.h
+++ b/libguile/stacks.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000,2001, 2004, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/stime.c b/libguile/stime.c
index 92438a5..c1ab3e9 100644
--- a/libguile/stime.c
+++ b/libguile/stime.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2003, 2004, 2005, 2006, 
2007, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/stime.h b/libguile/stime.h
index c64c60e..8b70cee 100644
--- a/libguile/stime.h
+++ b/libguile/stime.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000, 2003, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/strerror.c b/libguile/strerror.c
index c2f20f0..0e0e94e 100644
--- a/libguile/strerror.c
+++ b/libguile/strerror.c
@@ -1,19 +1,20 @@
 /* Turning errno values into English error messages.
    Copyright (C) 1985, 86, 87, 88, 93, 94, 95, 2000, 2001, 2006 Free Software 
Foundation, Inc.
 
-  This library 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 2.1 of the License, or (at your option) any later version.
- 
-  This library 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 library; if not, write to the Free Software
-  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+   This library 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 of
+   the License, or (at your option) any later version.
+  
+   This library 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 library; if not, write to the Free Software
+   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+   02110-1301 USA
 */
 
 char *
diff --git a/libguile/strings.c b/libguile/strings.c
index 5b68b38..1958b20 100644
--- a/libguile/strings.c
+++ b/libguile/strings.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1998,2000,2001, 2004, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/strings.h b/libguile/strings.h
index 8d02643..29ac8de 100644
--- a/libguile/strings.h
+++ b/libguile/strings.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2004, 2005, 2006, 2008 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/strorder.c b/libguile/strorder.c
index d3ccfcb..e0a2183 100644
--- a/libguile/strorder.c
+++ b/libguile/strorder.c
@@ -1,18 +1,19 @@
 /*     Copyright (C) 1995, 1996, 1999, 2000, 2004, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/strorder.h b/libguile/strorder.h
index 1711863..2c004e4 100644
--- a/libguile/strorder.h
+++ b/libguile/strorder.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/strports.c b/libguile/strports.c
index 3fa41a6..d1d238a 100644
--- a/libguile/strports.c
+++ b/libguile/strports.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2001,2002, 2003, 2005, 2006 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/strports.h b/libguile/strports.h
index 080efdb..b2ded01 100644
--- a/libguile/strports.h
+++ b/libguile/strports.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000,2001,2002, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/struct.c b/libguile/struct.c
index 40e0b25..72e1457 100644
--- a/libguile/struct.c
+++ b/libguile/struct.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1996,1997,1998,1999,2000,2001, 2003, 2004, 2006, 2007 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/struct.h b/libguile/struct.h
index 10c0d65..d53e59d 100644
--- a/libguile/struct.h
+++ b/libguile/struct.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1997,1999,2000,2001, 2006, 2007, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/symbols.c b/libguile/symbols.c
index 131ff2d..e93666b 100644
--- a/libguile/symbols.c
+++ b/libguile/symbols.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2003, 2004, 2006, 2009 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/symbols.h b/libguile/symbols.h
index c2dc183..e4bc333 100644
--- a/libguile/symbols.h
+++ b/libguile/symbols.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2003, 2004, 2006, 2008 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/tags.h b/libguile/tags.h
index 2f30369..3294533 100644
--- a/libguile/tags.h
+++ b/libguile/tags.h
@@ -7,18 +7,19 @@
  * Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/threads.c b/libguile/threads.c
index d63c619..9589336 100644
--- a/libguile/threads.c
+++ b/libguile/threads.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2002, 2003, 2004, 2005, 2006, 
2007, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/threads.h b/libguile/threads.h
index 5542ac3..32b0ea6 100644
--- a/libguile/threads.h
+++ b/libguile/threads.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1996,1997,1998,2000,2001, 2002, 2003, 2004, 2006, 2007, 2008 
Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/throw.c b/libguile/throw.c
index b971b69..92ead38 100644
--- a/libguile/throw.c
+++ b/libguile/throw.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2003, 2004, 2006, 2008 Free 
Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/throw.h b/libguile/throw.h
index 3cd5572..1ed6ba6 100644
--- a/libguile/throw.h
+++ b/libguile/throw.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/unif.c b/libguile/unif.c
index 13649f0..3a6790e 100644
--- a/libguile/unif.c
+++ b/libguile/unif.c
@@ -1,18 +1,19 @@
-/* Copyright (C) 1995,1996,1997,1998,2000,2001,2002,2003,2004, 2005, 2006 Free 
Software Foundation, Inc.
+/* Copyright (C) 1995,1996,1997,1998,2000,2001,2002,2003,2004, 2005, 2006, 
2009 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -46,6 +47,7 @@
 #include "libguile/srfi-13.h"
 #include "libguile/srfi-4.h"
 #include "libguile/vectors.h"
+#include "libguile/bytevectors.h"
 #include "libguile/list.h"
 #include "libguile/deprecation.h"
 #include "libguile/dynwind.h"
@@ -108,6 +110,7 @@ struct {
   { "f64", SCM_UNSPECIFIED, scm_make_f64vector },
   { "c32", SCM_UNSPECIFIED, scm_make_c32vector },
   { "c64", SCM_UNSPECIFIED, scm_make_c64vector },
+  { "vu8", SCM_UNSPECIFIED, scm_make_bytevector },
   { NULL }
 };
 
@@ -313,6 +316,12 @@ bitvector_ref (scm_t_array_handle *h, ssize_t pos)
 }
 
 static SCM
+bytevector_ref (scm_t_array_handle *h, ssize_t pos)
+{
+  return scm_from_uint8 (((scm_t_uint8 *) h->elements)[pos]);
+}
+
+static SCM
 memoize_ref (scm_t_array_handle *h, ssize_t pos)
 {
   SCM v = h->array;
@@ -345,6 +354,11 @@ memoize_ref (scm_t_array_handle *h, ssize_t pos)
       h->elements = scm_array_handle_bit_elements (h);
       h->ref = bitvector_ref;
     }
+  else if (scm_is_bytevector (v))
+    {
+      h->elements = scm_array_handle_uniform_elements (h);
+      h->ref = bytevector_ref;
+    }
   else
     scm_misc_error (NULL, "unknown array type: ~a", scm_list_1 (h->array));
 
@@ -386,6 +400,17 @@ bitvector_set (scm_t_array_handle *h, ssize_t pos, SCM val)
 }
 
 static void
+bytevector_set (scm_t_array_handle *h, ssize_t pos, SCM val)
+{
+  scm_t_uint8 c_value;
+  scm_t_uint8 *elements;
+
+  c_value = scm_to_uint8 (val);
+  elements = (scm_t_uint8 *) h->elements;
+  elements[pos] = (scm_t_uint8) c_value;
+}
+
+static void
 memoize_set (scm_t_array_handle *h, ssize_t pos, SCM val)
 {
   SCM v = h->array;
@@ -419,6 +444,11 @@ memoize_set (scm_t_array_handle *h, ssize_t pos, SCM val)
       h->writable_elements = scm_array_handle_bit_writable_elements (h);
       h->set = bitvector_set;
     }
+  else if (scm_is_bytevector (v))
+    {
+      h->elements = scm_array_handle_uniform_writable_elements (h);
+      h->set = bytevector_set;
+    }
   else
     scm_misc_error (NULL, "unknown array type: ~a", scm_list_1 (h->array));
 
diff --git a/libguile/unif.h b/libguile/unif.h
index 1d01f80..91d26c8 100644
--- a/libguile/unif.h
+++ b/libguile/unif.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1997,1999,2000,2001, 2004, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/validate.h b/libguile/validate.h
index c362c02..b48bec7 100644
--- a/libguile/validate.h
+++ b/libguile/validate.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1999,2000,2001, 2002, 2004, 2006, 2007, 2009 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 /* Written by Greg J. Badros <address@hidden>, Dec-1999 */
diff --git a/libguile/values.c b/libguile/values.c
index e766edb..81fdcf8 100644
--- a/libguile/values.c
+++ b/libguile/values.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2000, 2001, 2006, 2008 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/values.h b/libguile/values.h
index f05ce9f..0750aec 100644
--- a/libguile/values.h
+++ b/libguile/values.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/variable.c b/libguile/variable.c
index 6c39b30..a97444c 100644
--- a/libguile/variable.c
+++ b/libguile/variable.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1997,1998,2000,2001, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/variable.h b/libguile/variable.h
index 3f6398b..8faced4 100644
--- a/libguile/variable.h
+++ b/libguile/variable.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000,2001, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/vectors.c b/libguile/vectors.c
index eeb8569..6dc994f 100644
--- a/libguile/vectors.c
+++ b/libguile/vectors.c
@@ -1,18 +1,19 @@
-/* Copyright (C) 1995,1996,1998,1999,2000,2001, 2006, 2008 Free Software 
Foundation, Inc.
+/* Copyright (C) 1995,1996,1998,1999,2000,2001, 2006, 2008, 2009 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
@@ -30,6 +31,7 @@
 #include "libguile/validate.h"
 #include "libguile/vectors.h"
 #include "libguile/unif.h"
+#include "libguile/bytevectors.h"
 #include "libguile/ramap.h"
 #include "libguile/srfi-4.h"
 #include "libguile/strings.h"
@@ -522,7 +524,7 @@ SCM_DEFINE (scm_vector_move_right_x, "vector-move-right!", 
5, 0, 0,
 }
 #undef FUNC_NAME
 
-
+
 /* Generalized vectors. */
 
 int
@@ -531,7 +533,8 @@ scm_is_generalized_vector (SCM obj)
   return (scm_is_vector (obj)
          || scm_is_string (obj)
          || scm_is_bitvector (obj)
-         || scm_is_uniform_vector (obj));
+         || scm_is_uniform_vector (obj)
+         || scm_is_bytevector (obj));
 }
 
 SCM_DEFINE (scm_generalized_vector_p, "generalized-vector?", 1, 0, 0,
@@ -563,6 +566,8 @@ scm_c_generalized_vector_length (SCM v)
     return scm_c_bitvector_length (v);
   else if (scm_is_uniform_vector (v))
     return scm_c_uniform_vector_length (v);
+  else if (scm_is_bytevector (v))
+    return scm_c_bytevector_length (v);
   else
     scm_wrong_type_arg_msg (NULL, 0, v, "generalized vector");
 }
@@ -587,6 +592,8 @@ scm_c_generalized_vector_ref (SCM v, size_t idx)
     return scm_c_bitvector_ref (v, idx);
   else if (scm_is_uniform_vector (v))
     return scm_c_uniform_vector_ref (v, idx);
+  else if (scm_is_bytevector (v))
+    return scm_from_uint8 (scm_c_bytevector_ref (v, idx));
   else
     scm_wrong_type_arg_msg (NULL, 0, v, "generalized vector");
 }
@@ -612,6 +619,8 @@ scm_c_generalized_vector_set_x (SCM v, size_t idx, SCM val)
     scm_c_bitvector_set_x (v, idx, val);
   else if (scm_is_uniform_vector (v))
     scm_c_uniform_vector_set_x (v, idx, val);
+  else if (scm_is_bytevector (v))
+    scm_i_bytevector_generalized_set_x (v, idx, val);
   else
     scm_wrong_type_arg_msg (NULL, 0, v, "generalized vector");
 }
diff --git a/libguile/vectors.h b/libguile/vectors.h
index 28a576c..902e15a 100644
--- a/libguile/vectors.h
+++ b/libguile/vectors.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,2000,2001,2002,2004,2005, 2006, 2008 Free 
Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/version.c b/libguile/version.c
index 99c649b..3d5dc19 100644
--- a/libguile/version.c
+++ b/libguile/version.c
@@ -1,18 +1,19 @@
 /*     Copyright (C) 1995,1996, 1999, 2000, 2001, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/version.h.in b/libguile/version.h.in
index b565efd..394bbdb 100644
--- a/libguile/version.h.in
+++ b/libguile/version.h.in
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2001, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/vm-bootstrap.h b/libguile/vm-bootstrap.h
index 587766a..7ba1a93 100644
--- a/libguile/vm-bootstrap.h
+++ b/libguile/vm-bootstrap.h
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifndef _SCM_VM_BOOTSTRAP_H_
diff --git a/libguile/vm-engine.c b/libguile/vm-engine.c
index 34764c6..978d407 100644
--- a/libguile/vm-engine.c
+++ b/libguile/vm-engine.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 /* This file is included in vm.c multiple times */
diff --git a/libguile/vm-engine.h b/libguile/vm-engine.h
index 8c919f6..c98dfdd 100644
--- a/libguile/vm-engine.h
+++ b/libguile/vm-engine.h
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 /* This file is included in vm_engine.c */
diff --git a/libguile/vm-expand.h b/libguile/vm-expand.h
index 02dfbc4..787223d 100644
--- a/libguile/vm-expand.h
+++ b/libguile/vm-expand.h
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifndef VM_LABEL
diff --git a/libguile/vm-i-loader.c b/libguile/vm-i-loader.c
index 9fd6ede..35fba9a 100644
--- a/libguile/vm-i-loader.c
+++ b/libguile/vm-i-loader.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001,2008,2009 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 /* FIXME! Need to check that the fetch is within the current program */
diff --git a/libguile/vm-i-scheme.c b/libguile/vm-i-scheme.c
index 3742135..02139c0 100644
--- a/libguile/vm-i-scheme.c
+++ b/libguile/vm-i-scheme.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 /* This file is included in vm_engine.c */
diff --git a/libguile/vm-i-system.c b/libguile/vm-i-system.c
index 6b130e7..d55d6e2 100644
--- a/libguile/vm-i-system.c
+++ b/libguile/vm-i-system.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001,2008,2009 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/vm.c b/libguile/vm.c
index f708b21..514ff8d 100644
--- a/libguile/vm.c
+++ b/libguile/vm.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #if HAVE_CONFIG_H
diff --git a/libguile/vm.h b/libguile/vm.h
index 2f2b617..b079c7a 100644
--- a/libguile/vm.h
+++ b/libguile/vm.h
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifndef _SCM_VM_H_
diff --git a/libguile/vports.c b/libguile/vports.c
index 564f0e7..cea11c6 100644
--- a/libguile/vports.c
+++ b/libguile/vports.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1998,1999,2000,2001, 2002, 2003, 2006 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/vports.h b/libguile/vports.h
index 365303b..ae64dd4 100644
--- a/libguile/vports.h
+++ b/libguile/vports.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000, 2006, 2008 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/weaks.c b/libguile/weaks.c
index 1d58b5d..64aa536 100644
--- a/libguile/weaks.c
+++ b/libguile/weaks.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 1995,1996,1998,2000,2001, 2003, 2006, 2008 Free Software 
Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/weaks.h b/libguile/weaks.h
index 34c44a9..46afd83 100644
--- a/libguile/weaks.h
+++ b/libguile/weaks.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 1995,1996,2000,2001, 2003, 2006, 2008 Free Software 
Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/win32-dirent.c b/libguile/win32-dirent.c
index cd7e8ba..de170c7 100644
--- a/libguile/win32-dirent.c
+++ b/libguile/win32-dirent.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001, 2006, 2008 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/win32-dirent.h b/libguile/win32-dirent.h
index 30bc118..578db49 100644
--- a/libguile/win32-dirent.h
+++ b/libguile/win32-dirent.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2001, 2006 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 /* Directory stream type.
diff --git a/libguile/win32-socket.c b/libguile/win32-socket.c
index 54f80a7..e845d88 100644
--- a/libguile/win32-socket.c
+++ b/libguile/win32-socket.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001, 2006 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 
diff --git a/libguile/win32-socket.h b/libguile/win32-socket.h
index 5185605..4ab9b94 100644
--- a/libguile/win32-socket.h
+++ b/libguile/win32-socket.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2001, 2006 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #include "libguile/__scm.h"
diff --git a/libguile/win32-uname.c b/libguile/win32-uname.c
index d4d737f..5349f14 100644
--- a/libguile/win32-uname.c
+++ b/libguile/win32-uname.c
@@ -1,18 +1,19 @@
 /* Copyright (C) 2001, 2006, 2008 Free Software Foundation, Inc.
  * 
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #ifdef HAVE_CONFIG_H
diff --git a/libguile/win32-uname.h b/libguile/win32-uname.h
index 8593dc7..4b74981 100644
--- a/libguile/win32-uname.h
+++ b/libguile/win32-uname.h
@@ -6,18 +6,19 @@
 /* Copyright (C) 2001, 2006 Free Software Foundation, Inc.
  *
  * This library 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 2.1 of the License, or (at your option) any later version.
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 3 of
+ * the License, or (at your option) any later version.
  *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * This library 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 library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA
  */
 
 #define _UTSNAME_LENGTH 65
diff --git a/m4/canonicalize-lgpl.m4 b/m4/canonicalize-lgpl.m4
new file mode 100644
index 0000000..3a8ee2f
--- /dev/null
+++ b/m4/canonicalize-lgpl.m4
@@ -0,0 +1,35 @@
+# canonicalize-lgpl.m4 serial 5
+dnl Copyright (C) 2003, 2006-2007, 2009 Free Software Foundation, Inc.
+dnl This file is free software; the Free Software Foundation
+dnl gives unlimited permission to copy and/or distribute it,
+dnl with or without modifications, as long as this notice is preserved.
+
+AC_DEFUN([gl_CANONICALIZE_LGPL],
+[
+  dnl Do this replacement check manually because the file name is shorter
+  dnl than the function name.
+  AC_CHECK_DECLS_ONCE([canonicalize_file_name])
+  AC_CHECK_FUNCS_ONCE([canonicalize_file_name])
+  if test $ac_cv_func_canonicalize_file_name = no; then
+    AC_LIBOBJ([canonicalize-lgpl])
+    AC_DEFINE([realpath], [rpl_realpath],
+      [Define to a replacement function name for realpath().])
+    gl_PREREQ_CANONICALIZE_LGPL
+  fi
+])
+
+# Like gl_CANONICALIZE_LGPL, except prepare for separate compilation
+# (no AC_LIBOBJ).
+AC_DEFUN([gl_CANONICALIZE_LGPL_SEPARATE],
+[
+  AC_CHECK_DECLS_ONCE([canonicalize_file_name])
+  AC_CHECK_FUNCS_ONCE([canonicalize_file_name])
+  gl_PREREQ_CANONICALIZE_LGPL
+])
+
+# Prerequisites of lib/canonicalize-lgpl.c.
+AC_DEFUN([gl_PREREQ_CANONICALIZE_LGPL],
+[
+  AC_CHECK_HEADERS_ONCE([sys/param.h unistd.h])
+  AC_CHECK_FUNCS_ONCE([getcwd readlink])
+])
diff --git a/m4/eealloc.m4 b/m4/eealloc.m4
new file mode 100644
index 0000000..3c9c0b5
--- /dev/null
+++ b/m4/eealloc.m4
@@ -0,0 +1,32 @@
+# eealloc.m4 serial 2
+dnl Copyright (C) 2003, 2009 Free Software Foundation, Inc.
+dnl This file is free software; the Free Software Foundation
+dnl gives unlimited permission to copy and/or distribute it,
+dnl with or without modifications, as long as this notice is preserved.
+
+AC_DEFUN([gl_EEALLOC],
+[
+  AC_REQUIRE([gl_EEMALLOC])
+  AC_REQUIRE([gl_EEREALLOC])
+  AC_REQUIRE([AC_C_INLINE])
+])
+
+AC_DEFUN([gl_EEMALLOC],
+[
+  _AC_FUNC_MALLOC_IF(
+    [gl_cv_func_malloc_0_nonnull=1],
+    [gl_cv_func_malloc_0_nonnull=0])
+  AC_DEFINE_UNQUOTED([MALLOC_0_IS_NONNULL], [$gl_cv_func_malloc_0_nonnull],
+    [If malloc(0) is != NULL, define this to 1.  Otherwise define this
+     to 0.])
+])
+
+AC_DEFUN([gl_EEREALLOC],
+[
+  _AC_FUNC_REALLOC_IF(
+    [gl_cv_func_realloc_0_nonnull=1],
+    [gl_cv_func_realloc_0_nonnull=0])
+  AC_DEFINE_UNQUOTED([REALLOC_0_IS_NONNULL], [$gl_cv_func_realloc_0_nonnull],
+    [If realloc(NULL,0) is != NULL, define this to 1.  Otherwise define this
+     to 0.])
+])
diff --git a/m4/gnulib-cache.m4 b/m4/gnulib-cache.m4
index 0fbe119..e70283f 100644
--- a/m4/gnulib-cache.m4
+++ b/m4/gnulib-cache.m4
@@ -15,7 +15,7 @@
 
 
 # Specification in the form of a command-line invocation:
-#   gnulib-tool --import --dir=. --lib=libgnu --source-base=lib --m4-base=m4 
--doc-base=doc --tests-base=tests --aux-dir=build-aux --lgpl --libtool 
--macro-prefix=gl --no-vc-files alloca-opt autobuild byteswap count-one-bits 
environ extensions flock fpieee full-read full-write iconv_open-utf 
lib-symbol-visibility libunistring putenv stdlib strcase strftime striconveh 
string
+#   gnulib-tool --import --dir=. --lib=libgnu --source-base=lib --m4-base=m4 
--doc-base=doc --tests-base=tests --aux-dir=build-aux --lgpl --libtool 
--macro-prefix=gl --no-vc-files alloca-opt autobuild byteswap canonicalize-lgpl 
count-one-bits environ extensions flock fpieee full-read full-write havelib 
iconv_open-utf lib-symbol-visibility libunistring putenv stdlib strcase 
strftime striconveh string
 
 # Specification in the form of a few gnulib-tool.m4 macro invocations:
 gl_LOCAL_DIR([])
@@ -23,6 +23,7 @@ gl_MODULES([
   alloca-opt
   autobuild
   byteswap
+  canonicalize-lgpl
   count-one-bits
   environ
   extensions
@@ -30,6 +31,7 @@ gl_MODULES([
   fpieee
   full-read
   full-write
+  havelib
   iconv_open-utf
   lib-symbol-visibility
   libunistring
diff --git a/m4/gnulib-comp.m4 b/m4/gnulib-comp.m4
index 8f77510..ef0534e 100644
--- a/m4/gnulib-comp.m4
+++ b/m4/gnulib-comp.m4
@@ -46,6 +46,8 @@ AC_DEFUN([gl_INIT],
   gl_source_base='lib'
   gl_FUNC_ALLOCA
   gl_BYTESWAP
+  gl_CANONICALIZE_LGPL
+  gl_MODULE_INDICATOR([canonicalize-lgpl])
   gl_COUNT_ONE_BITS
   gl_ENVIRON
   gl_UNISTD_MODULE_INDICATOR([environ])
@@ -63,6 +65,7 @@ AC_DEFUN([gl_INIT],
   AC_SUBST([LOCALCHARSET_TESTS_ENVIRONMENT])
   gl_FUNC_MALLOC_POSIX
   gl_STDLIB_MODULE_INDICATOR([malloc-posix])
+  gl_MALLOCA
   gl_FUNC_MBRLEN
   gl_WCHAR_MODULE_INDICATOR([mbrlen])
   gl_FUNC_MBRTOWC
@@ -70,8 +73,11 @@ AC_DEFUN([gl_INIT],
   gl_FUNC_MBSINIT
   gl_WCHAR_MODULE_INDICATOR([mbsinit])
   gl_MULTIARCH
+  gl_PATHMAX
   gl_FUNC_PUTENV
   gl_STDLIB_MODULE_INDICATOR([putenv])
+  gl_FUNC_READLINK
+  gl_UNISTD_MODULE_INDICATOR([readlink])
   gl_SAFE_READ
   gl_SAFE_WRITE
   gt_TYPE_SSIZE_T
@@ -236,6 +242,8 @@ AC_DEFUN([gl_FILE_LIST], [
   lib/c-strcasecmp.c
   lib/c-strcaseeq.h
   lib/c-strncasecmp.c
+  lib/canonicalize-lgpl.c
+  lib/canonicalize.h
   lib/config.charset
   lib/count-one-bits.h
   lib/flock.c
@@ -255,10 +263,15 @@ AC_DEFUN([gl_FILE_LIST], [
   lib/localcharset.c
   lib/localcharset.h
   lib/malloc.c
+  lib/malloca.c
+  lib/malloca.h
+  lib/malloca.valgrind
   lib/mbrlen.c
   lib/mbrtowc.c
   lib/mbsinit.c
+  lib/pathmax.h
   lib/putenv.c
+  lib/readlink.c
   lib/ref-add.sin
   lib/ref-del.sin
   lib/safe-read.c
@@ -298,8 +311,10 @@ AC_DEFUN([gl_FILE_LIST], [
   m4/alloca.m4
   m4/autobuild.m4
   m4/byteswap.m4
+  m4/canonicalize-lgpl.m4
   m4/codeset.m4
   m4/count-one-bits.m4
+  m4/eealloc.m4
   m4/environ.m4
   m4/extensions.m4
   m4/flock.m4
@@ -321,12 +336,15 @@ AC_DEFUN([gl_FILE_LIST], [
   m4/locale-zh.m4
   m4/longlong.m4
   m4/malloc.m4
+  m4/malloca.m4
   m4/mbrlen.m4
   m4/mbrtowc.m4
   m4/mbsinit.m4
   m4/mbstate_t.m4
   m4/multiarch.m4
+  m4/pathmax.m4
   m4/putenv.m4
+  m4/readlink.m4
   m4/safe-read.m4
   m4/safe-write.m4
   m4/ssize_t.m4
diff --git a/m4/malloca.m4 b/m4/malloca.m4
new file mode 100644
index 0000000..2841ae8
--- /dev/null
+++ b/m4/malloca.m4
@@ -0,0 +1,14 @@
+# malloca.m4 serial 1
+dnl Copyright (C) 2003-2004, 2006-2007 Free Software Foundation, Inc.
+dnl This file is free software; the Free Software Foundation
+dnl gives unlimited permission to copy and/or distribute it,
+dnl with or without modifications, as long as this notice is preserved.
+
+AC_DEFUN([gl_MALLOCA],
+[
+  dnl Use the autoconf tests for alloca(), but not the AC_SUBSTed variables
+  dnl @ALLOCA@ and @address@hidden
+  dnl gl_FUNC_ALLOCA   dnl Already brought in by the module dependencies.
+  AC_REQUIRE([gl_EEMALLOC])
+  AC_REQUIRE([AC_TYPE_LONG_LONG_INT])
+])
diff --git a/m4/pathmax.m4 b/m4/pathmax.m4
new file mode 100644
index 0000000..4651801
--- /dev/null
+++ b/m4/pathmax.m4
@@ -0,0 +1,12 @@
+# pathmax.m4 serial 8
+dnl Copyright (C) 2002, 2003, 2005, 2006, 2009 Free Software Foundation, Inc.
+dnl This file is free software; the Free Software Foundation
+dnl gives unlimited permission to copy and/or distribute it,
+dnl with or without modifications, as long as this notice is preserved.
+
+AC_DEFUN([gl_PATHMAX],
+[
+  dnl Prerequisites of lib/pathmax.h.
+  AC_CHECK_FUNCS_ONCE([pathconf])
+  AC_CHECK_HEADERS_ONCE([sys/param.h])
+])
diff --git a/m4/readlink.m4 b/m4/readlink.m4
new file mode 100644
index 0000000..ff3f1f5
--- /dev/null
+++ b/m4/readlink.m4
@@ -0,0 +1,29 @@
+# readlink.m4 serial 5
+dnl Copyright (C) 2003, 2007, 2009 Free Software Foundation, Inc.
+dnl This file is free software; the Free Software Foundation
+dnl gives unlimited permission to copy and/or distribute it,
+dnl with or without modifications, as long as this notice is preserved.
+
+AC_DEFUN([gl_FUNC_READLINK],
+[
+  AC_REQUIRE([gl_UNISTD_H_DEFAULTS])
+  AC_CHECK_FUNCS_ONCE([readlink])
+  if test $ac_cv_func_readlink = no; then
+    HAVE_READLINK=0
+    AC_LIBOBJ([readlink])
+    gl_PREREQ_READLINK
+  fi
+])
+
+# Like gl_FUNC_READLINK, except prepare for separate compilation (no 
AC_LIBOBJ).
+AC_DEFUN([gl_FUNC_READLINK_SEPARATE],
+[
+  AC_CHECK_FUNCS_ONCE([readlink])
+  gl_PREREQ_READLINK
+])
+
+# Prerequisites of lib/readlink.c.
+AC_DEFUN([gl_PREREQ_READLINK],
+[
+  :
+])
diff --git a/m4/string_h.m4 b/m4/string_h.m4
index 2d5553c..11f09c8 100644
--- a/m4/string_h.m4
+++ b/m4/string_h.m4
@@ -1,11 +1,11 @@
 # Configure a GNU-like replacement for <string.h>.
 
-# Copyright (C) 2007, 2008 Free Software Foundation, Inc.
+# Copyright (C) 2007, 2008, 2009 Free Software Foundation, Inc.
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
 # with or without modifications, as long as this notice is preserved.
 
-# serial 6
+# serial 7
 
 # Written by Paul Eggert.
 
@@ -32,6 +32,7 @@ AC_DEFUN([gl_STRING_MODULE_INDICATOR],
 
 AC_DEFUN([gl_HEADER_STRING_H_DEFAULTS],
 [
+  GNULIB_MEMCHR=0;      AC_SUBST([GNULIB_MEMCHR])
   GNULIB_MEMMEM=0;      AC_SUBST([GNULIB_MEMMEM])
   GNULIB_MEMPCPY=0;     AC_SUBST([GNULIB_MEMPCPY])
   GNULIB_MEMRCHR=0;     AC_SUBST([GNULIB_MEMRCHR])
@@ -83,6 +84,7 @@ AC_DEFUN([gl_HEADER_STRING_H_DEFAULTS],
   HAVE_DECL_STRERROR=1;                AC_SUBST([HAVE_DECL_STRERROR])
   HAVE_DECL_STRSIGNAL=1;       AC_SUBST([HAVE_DECL_STRSIGNAL])
   HAVE_STRVERSCMP=1;           AC_SUBST([HAVE_STRVERSCMP])
+  REPLACE_MEMCHR=0;            AC_SUBST([REPLACE_MEMCHR])
   REPLACE_MEMMEM=0;            AC_SUBST([REPLACE_MEMMEM])
   REPLACE_STRDUP=0;            AC_SUBST([REPLACE_STRDUP])
   REPLACE_STRSTR=0;            AC_SUBST([REPLACE_STRSTR])
diff --git a/meta/Makefile.am b/meta/Makefile.am
index 7f655e5..e047038 100644
--- a/meta/Makefile.am
+++ b/meta/Makefile.am
@@ -5,20 +5,20 @@
 ##
 ##   This file is part of GUILE.
 ##   
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
 ##   
 ##   GUILE 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 General Public License for more details.
+##   GNU Lesser General Public License for more details.
 ##   
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 bin_SCRIPTS=guile-config guile-tools
 EXTRA_DIST= $(bin_SCRIPTS) \
diff --git a/meta/gdb-uninstalled-guile.in b/meta/gdb-uninstalled-guile.in
index aa33e07..1151dbc 100644
--- a/meta/gdb-uninstalled-guile.in
+++ b/meta/gdb-uninstalled-guile.in
@@ -4,20 +4,20 @@
 #
 #   This file is part of GUILE.
 #
-#   GUILE is free software; you can redistribute it and/or modify
-#   it under the terms of the GNU General Public License as
-#   published by the Free Software Foundation; either version 2, or
+#   GUILE 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.
 #
 #   GUILE 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 General Public License for more details.
+#   GNU Lesser General Public License for more details.
 #
-#   You should have received a copy of the GNU General Public
-#   License along with GUILE; see the file COPYING.  If not, write
-#   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-#   Floor, Boston, MA 02110-1301 USA
+#   You should have received a copy of the GNU Lesser General Public
+#   License along with GUILE; see the file COPYING.LESSER.  If not,
+#   write to the Free Software Foundation, Inc., 51 Franklin Street,
+#   Fifth Floor, Boston, MA 02110-1301 USA
 
 # Commentary:
 
diff --git a/meta/guile-config b/meta/guile-config
index 815414a..7304ae2 100755
--- a/meta/guile-config
+++ b/meta/guile-config
@@ -9,7 +9,7 @@ exec guile -e main -s $0 "$@"
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -17,8 +17,9 @@ exec guile -e main -s $0 "$@"
 ;;;; Lesser General Public License for more details.
 ;;;; 
 ;;;; You should have received a copy of the GNU Lesser General Public
-;;;; License along with this library; if not, write to the Free Software
-;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
+;;;; License along with this library; if not, write to the Free
+;;;; Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+;;;; Boston, MA 02110-1301 USA
 
 ;;; This script has been deprecated. Just use pkg-config.
 
diff --git a/meta/guile-tools b/meta/guile-tools
index 6fb93c1..0c66c72 100755
--- a/meta/guile-tools
+++ b/meta/guile-tools
@@ -4,14 +4,14 @@ exec guile $GUILE_FLAGS -e '(@@ (guile-tools) main)' -s "$0" 
"$@"
 !#
 
 ;;;; guile-tools --- running scripts bundled with Guile
-;;;; Jim Blandy <address@hidden> --- September 1997
+;;;; Andy Wingo <address@hidden> --- April 2009
 ;;;; 
-;;;;   Copyright (C) 1998, 2001, 2004, 2005, 2006, 2008, 2009 Free Software 
Foundation, Inc.
+;;;;   Copyright (C) 2009 Free Software Foundation, Inc.
 ;;;; 
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -19,8 +19,9 @@ exec guile $GUILE_FLAGS -e '(@@ (guile-tools) main)' -s "$0" 
"$@"
 ;;;; Lesser General Public License for more details.
 ;;;; 
 ;;;; You should have received a copy of the GNU Lesser General Public
-;;;; License along with this library; if not, write to the Free Software
-;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
+;;;; License along with this library; if not, write to the Free
+;;;; Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+;;;; Boston, MA 02110-1301 USA
 
 (define-module (guile-tools))
 
diff --git a/meta/guile.in b/meta/guile.in
index d7bc893..ab1fe37 100644
--- a/meta/guile.in
+++ b/meta/guile.in
@@ -4,20 +4,20 @@
 #
 #   This file is part of GUILE.
 #
-#   GUILE is free software; you can redistribute it and/or modify
-#   it under the terms of the GNU General Public License as
-#   published by the Free Software Foundation; either version 2, or
+#   GUILE 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.
 #
 #   GUILE 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 General Public License for more details.
+#   GNU Lesser General Public License for more details.
 #
-#   You should have received a copy of the GNU General Public
-#   License along with GUILE; see the file COPYING.  If not, write
-#   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-#   Floor, Boston, MA 02110-1301 USA
+#   You should have received a copy of the GNU Lesser General Public
+#   License along with GUILE; see the file COPYING.LESSER.  If not,
+#   write to the Free Software Foundation, Inc., 51 Franklin Street,
+#   Fifth Floor, Boston, MA 02110-1301 USA
 
 # Commentary:
 
diff --git a/meta/guile.m4 b/meta/guile.m4
index 1e30d50..5ba725f 100644
--- a/meta/guile.m4
+++ b/meta/guile.m4
@@ -3,9 +3,9 @@
 ##   Copyright (C) 1998,2001, 2006 Free Software Foundation, Inc.
 ##
 ## This library 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 2.1 of the License, or (at your option) any later version.
+## modify it under the terms of the GNU Lesser General Public License
+## as published by the Free Software Foundation; either version 3 of
+## the License, or (at your option) any later version.
 ## 
 ## This library is distributed in the hope that it will be useful,
 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -14,7 +14,8 @@
 ## 
 ## You should have received a copy of the GNU Lesser General Public
 ## License along with this library; if not, write to the Free Software
-## Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+## Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+## 02110-1301 USA
 
 # serial 9
 
diff --git a/meta/uninstalled-env.in b/meta/uninstalled-env.in
index b15237c..8ee690c 100644
--- a/meta/uninstalled-env.in
+++ b/meta/uninstalled-env.in
@@ -4,10 +4,10 @@
 #
 #   This file is part of GUILE.
 #
-# This script 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 2.1 of the License, or (at your option) any later version.
+# This script 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 of the
+# License, or (at your option) any later version.
 #
 # This library is distributed in the hope that it will be useful,
 # but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -16,7 +16,8 @@
 #
 # You should have received a copy of the GNU Lesser General Public
 # License along with this library; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+# 02110-1301 USA
 
 # NOTE: If you update this file, please update uninstalled.in as
 # well, if appropriate.
diff --git a/module/Makefile.am b/module/Makefile.am
index 3358441..a904a8f 100644
--- a/module/Makefile.am
+++ b/module/Makefile.am
@@ -4,20 +4,20 @@
 ##
 ##   This file is part of GUILE.
 ##
-##   GUILE is free software; you can redistribute it and/or modify
-##   it under the terms of the GNU General Public License as
-##   published by the Free Software Foundation; either version 2, or
+##   GUILE 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.
 ##
 ##   GUILE 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 General Public License for more details.
+##   GNU Lesser General Public License for more details.
 ##
-##   You should have received a copy of the GNU General Public
-##   License along with GUILE; see the file COPYING.  If not, write
-##   to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
-##   Floor, Boston, MA 02110-1301 USA
+##   You should have received a copy of the GNU Lesser General Public
+##   License along with GUILE; see the file COPYING.LESSER.  If not,
+##   write to the Free Software Foundation, Inc., 51 Franklin Street,
+##   Fifth Floor, Boston, MA 02110-1301 USA
 
 include $(top_srcdir)/am/guilec
 
@@ -50,6 +50,7 @@ SOURCES =                                                     
        \
   $(OOP_SOURCES)                                                       \
   $(SYSTEM_SOURCES)                                                     \
   $(ECMASCRIPT_LANG_SOURCES)                                           \
+  $(BRAINFUCK_LANG_SOURCES)                                            \
   $(SCRIPTS_SOURCES)
 
 ## test.scm is not currently installed.
@@ -112,6 +113,12 @@ ECMASCRIPT_LANG_SOURCES =                  \
   language/ecmascript/compile-ghil.scm         \
   language/ecmascript/spec.scm
 
+BRAINFUCK_LANG_SOURCES =                       \
+  language/brainfuck/parse.scm                 \
+  language/brainfuck/compile-scheme.scm                \
+  language/brainfuck/compile-tree-il.scm       \
+  language/brainfuck/spec.scm
+
 SCRIPTS_SOURCES =                              \
   scripts/PROGRAM.scm                          \
   scripts/autofrisk.scm                                \
diff --git a/module/ice-9/and-let-star.scm b/module/ice-9/and-let-star.scm
index b8cb2a6..bfd597b 100644
--- a/module/ice-9/and-let-star.scm
+++ b/module/ice-9/and-let-star.scm
@@ -6,7 +6,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/arrays.scm b/module/ice-9/arrays.scm
index 7ddcc8a..f7f9e5e 100644
--- a/module/ice-9/arrays.scm
+++ b/module/ice-9/arrays.scm
@@ -2,20 +2,19 @@
 
 ;;;; Copyright (C) 1999, 2001, 2004, 2006 Free Software Foundation, Inc.
 ;;;; 
-;;;; This program is free software; you can redistribute it and/or modify
-;;;; it under the terms of the GNU General Public License as published by
-;;;; the Free Software Foundation; either version 2, or (at your option)
-;;;; any later version.
+;;;; This library 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 of the License, or (at your option) any later version.
 ;;;; 
-;;;; This program is distributed in the hope that it will be useful,
+;;;; This library 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 General Public License for more details.
+;;;; 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 General Public License
-;;;; along with this software; see the file COPYING.  If not, write to
-;;;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;;;; Boston, MA 02110-1301 USA
+;;;; You should have received a copy of the GNU Lesser General Public
+;;;; License along with this library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 ;;;; 
 
 (define (array-shape a)
diff --git a/module/ice-9/boot-9.scm b/module/ice-9/boot-9.scm
index 3d77093..36a463a 100644
--- a/module/ice-9/boot-9.scm
+++ b/module/ice-9/boot-9.scm
@@ -6,7 +6,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -3192,69 +3192,66 @@ module '(ice-9 q) '(make-q q-length))}."
                     (append (hashq-ref %cond-expand-table mod '())
                             features)))))
 
-(define cond-expand
-  (procedure->memoizing-macro
-   (lambda (exp env)
-     (let ((clauses (cdr exp))
-          (syntax-error (lambda (cl)
-                          (error "invalid clause in `cond-expand'" cl))))
-       (letrec
-          ((test-clause
-            (lambda (clause)
-              (cond
-               ((symbol? clause)
-                (or (memq clause %cond-expand-features)
-                    (let lp ((uses (module-uses (env-module env))))
-                      (if (pair? uses)
-                          (or (memq clause
-                                    (hashq-ref %cond-expand-table
-                                               (car uses) '()))
-                              (lp (cdr uses)))
-                          #f))))
-               ((pair? clause)
-                (cond
-                 ((eq? 'and (car clause))
-                  (let lp ((l (cdr clause)))
-                    (cond ((null? l)
-                           #t)
-                          ((pair? l)
-                           (and (test-clause (car l)) (lp (cdr l))))
-                          (else
-                           (syntax-error clause)))))
-                 ((eq? 'or (car clause))
-                  (let lp ((l (cdr clause)))
-                    (cond ((null? l)
-                           #f)
-                          ((pair? l)
-                           (or (test-clause (car l)) (lp (cdr l))))
-                          (else
-                           (syntax-error clause)))))
-                 ((eq? 'not (car clause))
-                  (cond ((not (pair? (cdr clause)))
-                         (syntax-error clause))
-                        ((pair? (cddr clause))
-                         ((syntax-error clause))))
-                  (not (test-clause (cadr clause))))
-                 (else
-                  (syntax-error clause))))
-               (else
-                (syntax-error clause))))))
-        (let lp ((c clauses))
-          (cond
-           ((null? c)
-            (error "Unfulfilled `cond-expand'"))
-           ((not (pair? c))
-            (syntax-error c))
-           ((not (pair? (car c)))
-            (syntax-error (car c)))
-           ((test-clause (caar c))
-            `(begin ,@(cdar c)))
-           ((eq? (caar c) 'else)
-            (if (pair? (cdr c))
-                (syntax-error c))
-            `(begin ,@(cdar c)))
-           (else
-            (lp (cdr c))))))))))
+(define-macro (cond-expand . clauses)
+  (let ((syntax-error (lambda (cl)
+                        (error "invalid clause in `cond-expand'" cl))))
+    (letrec
+        ((test-clause
+          (lambda (clause)
+            (cond
+             ((symbol? clause)
+              (or (memq clause %cond-expand-features)
+                  (let lp ((uses (module-uses (current-module))))
+                    (if (pair? uses)
+                        (or (memq clause
+                                  (hashq-ref %cond-expand-table
+                                             (car uses) '()))
+                            (lp (cdr uses)))
+                        #f))))
+             ((pair? clause)
+              (cond
+               ((eq? 'and (car clause))
+                (let lp ((l (cdr clause)))
+                  (cond ((null? l)
+                         #t)
+                        ((pair? l)
+                         (and (test-clause (car l)) (lp (cdr l))))
+                        (else
+                         (syntax-error clause)))))
+               ((eq? 'or (car clause))
+                (let lp ((l (cdr clause)))
+                  (cond ((null? l)
+                         #f)
+                        ((pair? l)
+                         (or (test-clause (car l)) (lp (cdr l))))
+                        (else
+                         (syntax-error clause)))))
+               ((eq? 'not (car clause))
+                (cond ((not (pair? (cdr clause)))
+                       (syntax-error clause))
+                      ((pair? (cddr clause))
+                       ((syntax-error clause))))
+                (not (test-clause (cadr clause))))
+               (else
+                (syntax-error clause))))
+             (else
+              (syntax-error clause))))))
+      (let lp ((c clauses))
+        (cond
+         ((null? c)
+          (error "Unfulfilled `cond-expand'"))
+         ((not (pair? c))
+          (syntax-error c))
+         ((not (pair? (car c)))
+          (syntax-error (car c)))
+         ((test-clause (caar c))
+          `(begin ,@(cdar c)))
+         ((eq? (caar c) 'else)
+          (if (pair? (cdr c))
+              (syntax-error c))
+          `(begin ,@(cdar c)))
+         (else
+          (lp (cdr c))))))))
 
 ;; This procedure gets called from the startup code with a list of
 ;; numbers, which are the numbers of the SRFIs to be loaded on startup.
diff --git a/module/ice-9/buffered-input.scm b/module/ice-9/buffered-input.scm
index 11530e8..05e9255 100644
--- a/module/ice-9/buffered-input.scm
+++ b/module/ice-9/buffered-input.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/calling.scm b/module/ice-9/calling.scm
index 07f7a78..f66bba2 100644
--- a/module/ice-9/calling.scm
+++ b/module/ice-9/calling.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/channel.scm b/module/ice-9/channel.scm
index 8cbb001..b9d4700 100644
--- a/module/ice-9/channel.scm
+++ b/module/ice-9/channel.scm
@@ -2,19 +2,19 @@
 
 ;; Copyright (C) 2001, 2006 Free Software Foundation, Inc.
 
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 ;;; Commentary:
 
diff --git a/module/ice-9/common-list.scm b/module/ice-9/common-list.scm
index 7d62bc3..ea1b0f3 100644
--- a/module/ice-9/common-list.scm
+++ b/module/ice-9/common-list.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/debug.scm b/module/ice-9/debug.scm
index 0e75159..1fd5b66 100644
--- a/module/ice-9/debug.scm
+++ b/module/ice-9/debug.scm
@@ -3,7 +3,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/debugger.scm b/module/ice-9/debugger.scm
index 3dddd90..06f7ed2 100644
--- a/module/ice-9/debugger.scm
+++ b/module/ice-9/debugger.scm
@@ -2,19 +2,19 @@
 
 ;;; Copyright (C) 1999, 2001, 2002, 2006 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 (define-module (ice-9 debugger)
   #:use-module (ice-9 debugger command-loop)
diff --git a/module/ice-9/debugger/command-loop.scm 
b/module/ice-9/debugger/command-loop.scm
index 62a08ea..c662827 100644
--- a/module/ice-9/debugger/command-loop.scm
+++ b/module/ice-9/debugger/command-loop.scm
@@ -2,19 +2,19 @@
 
 ;;; Copyright (C) 1999, 2001, 2002, 2003, 2006 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 (define-module (ice-9 debugger command-loop)
   #:use-module ((ice-9 debugger commands) :prefix debugger:)
diff --git a/module/ice-9/debugger/commands.scm 
b/module/ice-9/debugger/commands.scm
index ef6f790..c254ce9 100644
--- a/module/ice-9/debugger/commands.scm
+++ b/module/ice-9/debugger/commands.scm
@@ -2,19 +2,19 @@
 
 ;;; Copyright (C) 2002, 2006 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 (define-module (ice-9 debugger commands)
   #:use-module (ice-9 debug)
diff --git a/module/ice-9/debugger/state.scm b/module/ice-9/debugger/state.scm
index 11b8ebb..0bda0fa 100644
--- a/module/ice-9/debugger/state.scm
+++ b/module/ice-9/debugger/state.scm
@@ -2,19 +2,19 @@
 
 ;;; Copyright (C) 2002, 2006 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 (define-module (ice-9 debugger state)
   #:export (make-state
diff --git a/module/ice-9/debugger/trc.scm b/module/ice-9/debugger/trc.scm
index 49af274..3e7e2f3 100644
--- a/module/ice-9/debugger/trc.scm
+++ b/module/ice-9/debugger/trc.scm
@@ -2,19 +2,19 @@
 
 ;;; Copyright (C) 2002, 2006 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 (define-module (ice-9 debugger trc)
   #:export (trc trc-syms trc-all trc-none trc-add trc-remove trc-port))
diff --git a/module/ice-9/debugging/breakpoints.scm 
b/module/ice-9/debugging/breakpoints.scm
index 132746f..c839409 100644
--- a/module/ice-9/debugging/breakpoints.scm
+++ b/module/ice-9/debugging/breakpoints.scm
@@ -2,19 +2,19 @@
 
 ;;; Copyright (C) 2005 Neil Jerram
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 ;;; This module provides a practical interface for setting and
 ;;; manipulating breakpoints.
diff --git a/module/ice-9/debugging/steps.scm b/module/ice-9/debugging/steps.scm
index fedbc6a..cd328bd 100644
--- a/module/ice-9/debugging/steps.scm
+++ b/module/ice-9/debugging/steps.scm
@@ -2,19 +2,19 @@
 
 ;;; Copyright (C) 2002, 2004 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 (define-module (ice-9 debugging steps)
   #:use-module (ice-9 debugging traps)
diff --git a/module/ice-9/debugging/trace.scm b/module/ice-9/debugging/trace.scm
index ad3015d..55b1f39 100644
--- a/module/ice-9/debugging/trace.scm
+++ b/module/ice-9/debugging/trace.scm
@@ -2,19 +2,19 @@
 
 ;;; Copyright (C) 2002 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 (define-module (ice-9 debugging trace)
   #:use-module (ice-9 debug)
diff --git a/module/ice-9/debugging/traps.scm b/module/ice-9/debugging/traps.scm
index ae16736..e13011e 100755
--- a/module/ice-9/debugging/traps.scm
+++ b/module/ice-9/debugging/traps.scm
@@ -3,19 +3,19 @@
 ;;; Copyright (C) 2002, 2004 Free Software Foundation, Inc.
 ;;; Copyright (C) 2005 Neil Jerram
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 ;;; This module provides an abstraction around Guile's low level trap
 ;;; handler interface; its aim is to make the low level trap mechanism
diff --git a/module/ice-9/debugging/trc.scm b/module/ice-9/debugging/trc.scm
index 9e95d7e..face227 100644
--- a/module/ice-9/debugging/trc.scm
+++ b/module/ice-9/debugging/trc.scm
@@ -2,19 +2,19 @@
 
 ;;; Copyright (C) 2002, 2004 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 (define-module (ice-9 debugging trc)
   #:export (trc trc-syms trc-all trc-none trc-add trc-remove trc-port))
diff --git a/module/ice-9/deprecated.scm b/module/ice-9/deprecated.scm
index 6f2c225..53fc741 100644
--- a/module/ice-9/deprecated.scm
+++ b/module/ice-9/deprecated.scm
@@ -3,7 +3,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/documentation.scm b/module/ice-9/documentation.scm
index 92d31ca..bbd6713 100644
--- a/module/ice-9/documentation.scm
+++ b/module/ice-9/documentation.scm
@@ -3,7 +3,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/emacs.scm b/module/ice-9/emacs.scm
index 12d8228..8803586 100644
--- a/module/ice-9/emacs.scm
+++ b/module/ice-9/emacs.scm
@@ -3,7 +3,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/expect.scm b/module/ice-9/expect.scm
index a024e91..ffc2e17 100644
--- a/module/ice-9/expect.scm
+++ b/module/ice-9/expect.scm
@@ -3,7 +3,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/ftw.scm b/module/ice-9/ftw.scm
index 23f3415..ce2fb16 100644
--- a/module/ice-9/ftw.scm
+++ b/module/ice-9/ftw.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/gap-buffer.scm b/module/ice-9/gap-buffer.scm
index b6162e8..4533bb5 100644
--- a/module/ice-9/gap-buffer.scm
+++ b/module/ice-9/gap-buffer.scm
@@ -2,19 +2,19 @@
 
 ;;;    Copyright (C) 2002, 2003, 2006 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 ;;;
 
 ;;; Author: Thien-Thi Nguyen <address@hidden>
diff --git a/module/ice-9/gds-server.scm b/module/ice-9/gds-server.scm
index f597587..b64e411 100644
--- a/module/ice-9/gds-server.scm
+++ b/module/ice-9/gds-server.scm
@@ -2,19 +2,19 @@
 
 ;;; Copyright (C) 2003 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 (define-module (ice-9 gds-server)
   #:export (run-server))
diff --git a/module/ice-9/getopt-long.scm b/module/ice-9/getopt-long.scm
index b16328b..891a2e3 100644
--- a/module/ice-9/getopt-long.scm
+++ b/module/ice-9/getopt-long.scm
@@ -1,18 +1,18 @@
 ;;; Copyright (C) 1998, 2001, 2006, 2009 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 ;;; Author: Russ McManus (rewritten by Thien-Thi Nguyen)
 
diff --git a/module/ice-9/hcons.scm b/module/ice-9/hcons.scm
index 6323506..7275cf4 100644
--- a/module/ice-9/hcons.scm
+++ b/module/ice-9/hcons.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/history.scm b/module/ice-9/history.scm
index 921a257..e9097c2 100644
--- a/module/ice-9/history.scm
+++ b/module/ice-9/history.scm
@@ -3,7 +3,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/i18n.scm b/module/ice-9/i18n.scm
index f33a9f2..dd14e67 100644
--- a/module/ice-9/i18n.scm
+++ b/module/ice-9/i18n.scm
@@ -5,13 +5,13 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
-;;;;
+;;;; version 3 of the License, or (at your option) any later version.
+;;;; 
 ;;;; This library 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 library; if not, write to the Free Software
 ;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
diff --git a/module/ice-9/lineio.scm b/module/ice-9/lineio.scm
index f122268..055eb6e 100644
--- a/module/ice-9/lineio.scm
+++ b/module/ice-9/lineio.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/list.scm b/module/ice-9/list.scm
index af83d17..1b898a3 100644
--- a/module/ice-9/list.scm
+++ b/module/ice-9/list.scm
@@ -2,19 +2,19 @@
 
 ;;; Copyright (C) 2003, 2006 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 (define-module (ice-9 list)
   :export (rassoc rassv rassq))
diff --git a/module/ice-9/ls.scm b/module/ice-9/ls.scm
index e848be3..f729d58 100644
--- a/module/ice-9/ls.scm
+++ b/module/ice-9/ls.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/mapping.scm b/module/ice-9/mapping.scm
index c4ef4fe..2907a8d 100644
--- a/module/ice-9/mapping.scm
+++ b/module/ice-9/mapping.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/match.scm b/module/ice-9/match.scm
index baa4d5a..d758923 100644
--- a/module/ice-9/match.scm
+++ b/module/ice-9/match.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/networking.scm b/module/ice-9/networking.scm
index 9a30fc5..7e84f09 100644
--- a/module/ice-9/networking.scm
+++ b/module/ice-9/networking.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/null.scm b/module/ice-9/null.scm
index 3f9f5b0..58b271e 100644
--- a/module/ice-9/null.scm
+++ b/module/ice-9/null.scm
@@ -3,7 +3,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/occam-channel.scm b/module/ice-9/occam-channel.scm
index e04ecac..ea1154b 100644
--- a/module/ice-9/occam-channel.scm
+++ b/module/ice-9/occam-channel.scm
@@ -2,19 +2,19 @@
 
 ;;; Copyright (C) 2003, 2006 Free Software Foundation, Inc.
 ;;;
-;; This library 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 2.1 of the License, or (at your option) any later version.
-;; 
-;; This library 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 library; if not, write to the Free Software
-;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+;;;; This library 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 of the License, or (at your option) any later version.
+;;;; 
+;;;; This library 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 library; if not, write to the Free Software
+;;;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 
USA
 
 (define-module (ice-9 occam-channel)
   #:use-module (oop goops)
diff --git a/module/ice-9/optargs.scm b/module/ice-9/optargs.scm
index 975703c..3093e15 100644
--- a/module/ice-9/optargs.scm
+++ b/module/ice-9/optargs.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/poe.scm b/module/ice-9/poe.scm
index fe963db..e7b6e3a 100644
--- a/module/ice-9/poe.scm
+++ b/module/ice-9/poe.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/popen.scm b/module/ice-9/popen.scm
index 275faaa..1a18928 100644
--- a/module/ice-9/popen.scm
+++ b/module/ice-9/popen.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/posix.scm b/module/ice-9/posix.scm
index dd1a126..a1be33c 100644
--- a/module/ice-9/posix.scm
+++ b/module/ice-9/posix.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/pretty-print.scm b/module/ice-9/pretty-print.scm
index bef76dd..0ce6a80 100644
--- a/module/ice-9/pretty-print.scm
+++ b/module/ice-9/pretty-print.scm
@@ -5,7 +5,7 @@
 ;;;; This library 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 2.1 of the License, or (at your option) any later version.
+;;;; version 3 of the License, or (at your option) any later version.
 ;;;; 
 ;;;; This library is distributed in the hope that it will be useful,
 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
diff --git a/module/ice-9/psyntax-pp.scm b/module/ice-9/psyntax-pp.scm
index a6e35b0..113269b 100644
--- a/module/ice-9/psyntax-pp.scm
+++ b/module/ice-9/psyntax-pp.scm
@@ -27,64 +27,64 @@
                                       (andmap63 first68 rest69)
                                       #f))))))
                      (andmap63 first56 rest55))))))))
-  (letrec ((lambda-var-list162
-             (lambda (vars286)
-               (letrec ((lvl287
-                          (lambda (vars288 ls289 w290)
-                            (if (pair? vars288)
-                              (lvl287
-                                (cdr vars288)
-                                (cons (wrap142 (car vars288) w290 #f) ls289)
-                                w290)
-                              (if (id?114 vars288)
-                                (cons (wrap142 vars288 w290 #f) ls289)
-                                (if (null? vars288)
-                                  ls289
-                                  (if (syntax-object?98 vars288)
-                                    (lvl287
-                                      (syntax-object-expression99 vars288)
-                                      ls289
-                                      (join-wraps133
-                                        w290
-                                        (syntax-object-wrap100 vars288)))
-                                    (cons vars288 ls289))))))))
-                 (lvl287 vars286 (quote ()) (quote (()))))))
-           (gen-var161
-             (lambda (id291)
-               (let ((id292 (if (syntax-object?98 id291)
-                              (syntax-object-expression99 id291)
-                              id291)))
-                 (gensym (symbol->string id292)))))
-           (strip160
-             (lambda (x293 w294)
-               (if (memq (quote top) (wrap-marks117 w294))
-                 x293
-                 (letrec ((f295 (lambda (x296)
-                                  (if (syntax-object?98 x296)
-                                    (strip160
-                                      (syntax-object-expression99 x296)
-                                      (syntax-object-wrap100 x296))
-                                    (if (pair? x296)
-                                      (let ((a297 (f295 (car x296)))
-                                            (d298 (f295 (cdr x296))))
-                                        (if (if (eq? a297 (car x296))
-                                              (eq? d298 (cdr x296))
+  (letrec ((lambda-var-list163
+             (lambda (vars287)
+               (letrec ((lvl288
+                          (lambda (vars289 ls290 w291)
+                            (if (pair? vars289)
+                              (lvl288
+                                (cdr vars289)
+                                (cons (wrap143 (car vars289) w291 #f) ls290)
+                                w291)
+                              (if (id?115 vars289)
+                                (cons (wrap143 vars289 w291 #f) ls290)
+                                (if (null? vars289)
+                                  ls290
+                                  (if (syntax-object?99 vars289)
+                                    (lvl288
+                                      (syntax-object-expression100 vars289)
+                                      ls290
+                                      (join-wraps134
+                                        w291
+                                        (syntax-object-wrap101 vars289)))
+                                    (cons vars289 ls290))))))))
+                 (lvl288 vars287 (quote ()) (quote (()))))))
+           (gen-var162
+             (lambda (id292)
+               (let ((id293 (if (syntax-object?99 id292)
+                              (syntax-object-expression100 id292)
+                              id292)))
+                 (gensym (symbol->string id293)))))
+           (strip161
+             (lambda (x294 w295)
+               (if (memq (quote top) (wrap-marks118 w295))
+                 x294
+                 (letrec ((f296 (lambda (x297)
+                                  (if (syntax-object?99 x297)
+                                    (strip161
+                                      (syntax-object-expression100 x297)
+                                      (syntax-object-wrap101 x297))
+                                    (if (pair? x297)
+                                      (let ((a298 (f296 (car x297)))
+                                            (d299 (f296 (cdr x297))))
+                                        (if (if (eq? a298 (car x297))
+                                              (eq? d299 (cdr x297))
                                               #f)
-                                          x296
-                                          (cons a297 d298)))
-                                      (if (vector? x296)
-                                        (let ((old299 (vector->list x296)))
-                                          (let ((new300 (map f295 old299)))
-                                            (if (and-map*17 eq? old299 new300)
-                                              x296
-                                              (list->vector new300))))
-                                        x296))))))
-                   (f295 x293)))))
-           (ellipsis?159
-             (lambda (x301)
-               (if (nonsymbol-id?113 x301)
-                 (free-id=?137
-                   x301
+                                          x297
+                                          (cons a298 d299)))
+                                      (if (vector? x297)
+                                        (let ((old300 (vector->list x297)))
+                                          (let ((new301 (map f296 old300)))
+                                            (if (and-map*17 eq? old300 new301)
+                                              x297
+                                              (list->vector new301))))
+                                        x297))))))
+                   (f296 x294)))))
+           (ellipsis?160
+             (lambda (x302)
+               (if (nonsymbol-id?114 x302)
+                 (free-id=?138
+                   x302
                    '#(syntax-object
                       ...
                       ((top)
@@ -192,6 +192,7 @@
                            build-conditional
                            build-application
                            build-void
+                           decorate-source
                            get-global-definition-hook
                            put-global-definition-hook
                            gensym-hook
@@ -313,6 +314,7 @@
                           (top)
                           (top)
                           (top)
+                          (top)
                           (top))
                          ("i"
                           "i"
@@ -424,6 +426,7 @@
                           "i"
                           "i"
                           "i"
+                          "i"
                           "i"))
                        #(ribcage
                          (define-structure and-map*)
@@ -431,1585 +434,1590 @@
                          ("i" "i")))
                       (hygiene guile)))
                  #f)))
-           (chi-void158 (lambda () (build-void80 #f)))
-           (eval-local-transformer157
-             (lambda (expanded302 mod303)
-               (let ((p304 (local-eval-hook77 expanded302 mod303)))
-                 (if (procedure? p304)
-                   p304
+           (chi-void159 (lambda () (build-void81 #f)))
+           (eval-local-transformer158
+             (lambda (expanded303 mod304)
+               (let ((p305 (local-eval-hook77 expanded303 mod304)))
+                 (if (procedure? p305)
+                   p305
                    (syntax-violation
                      #f
                      "nonprocedure transformer"
-                     p304)))))
-           (chi-local-syntax156
-             (lambda (rec?305 e306 r307 w308 s309 mod310 k311)
-               ((lambda (tmp312)
-                  ((lambda (tmp313)
-                     (if tmp313
-                       (apply (lambda (_314 id315 val316 e1317 e2318)
-                                (let ((ids319 id315))
-                                  (if (not (valid-bound-ids?139 ids319))
+                     p305)))))
+           (chi-local-syntax157
+             (lambda (rec?306 e307 r308 w309 s310 mod311 k312)
+               ((lambda (tmp313)
+                  ((lambda (tmp314)
+                     (if tmp314
+                       (apply (lambda (_315 id316 val317 e1318 e2319)
+                                (let ((ids320 id316))
+                                  (if (not (valid-bound-ids?140 ids320))
                                     (syntax-violation
                                       #f
                                       "duplicate bound keyword"
-                                      e306)
-                                    (let ((labels321 (gen-labels120 ids319)))
-                                      (let ((new-w322
-                                              (make-binding-wrap131
-                                                ids319
-                                                labels321
-                                                w308)))
-                                        (k311 (cons e1317 e2318)
-                                              (extend-env108
-                                                labels321
-                                                (let ((w324 (if rec?305
-                                                              new-w322
-                                                              w308))
-                                                      (trans-r325
-                                                        (macros-only-env110
-                                                          r307)))
-                                                  (map (lambda (x326)
+                                      e307)
+                                    (let ((labels322 (gen-labels121 ids320)))
+                                      (let ((new-w323
+                                              (make-binding-wrap132
+                                                ids320
+                                                labels322
+                                                w309)))
+                                        (k312 (cons e1318 e2319)
+                                              (extend-env109
+                                                labels322
+                                                (let ((w325 (if rec?306
+                                                              new-w323
+                                                              w309))
+                                                      (trans-r326
+                                                        (macros-only-env111
+                                                          r308)))
+                                                  (map (lambda (x327)
                                                          (cons 'macro
-                                                               
(eval-local-transformer157
-                                                                 (chi150
-                                                                   x326
-                                                                   trans-r325
-                                                                   w324
-                                                                   mod310)
-                                                                 mod310)))
-                                                       val316))
-                                                r307)
-                                              new-w322
-                                              s309
-                                              mod310))))))
-                              tmp313)
-                       ((lambda (_328)
+                                                               
(eval-local-transformer158
+                                                                 (chi151
+                                                                   x327
+                                                                   trans-r326
+                                                                   w325
+                                                                   mod311)
+                                                                 mod311)))
+                                                       val317))
+                                                r308)
+                                              new-w323
+                                              s310
+                                              mod311))))))
+                              tmp314)
+                       ((lambda (_329)
                           (syntax-violation
                             #f
                             "bad local syntax definition"
-                            (source-wrap143 e306 w308 s309 mod310)))
-                        tmp312)))
+                            (source-wrap144 e307 w309 s310 mod311)))
+                        tmp313)))
                    ($sc-dispatch
-                     tmp312
+                     tmp313
                      '(any #(each (any any)) any . each-any))))
-                e306)))
-           (chi-lambda-clause155
-             (lambda (e329 docstring330 c331 r332 w333 mod334 k335)
-               ((lambda (tmp336)
-                  ((lambda (tmp337)
-                     (if (if tmp337
-                           (apply (lambda (args338 doc339 e1340 e2341)
-                                    (if (string? (syntax->datum doc339))
-                                      (not docstring330)
+                e307)))
+           (chi-lambda-clause156
+             (lambda (e330 docstring331 c332 r333 w334 mod335 k336)
+               ((lambda (tmp337)
+                  ((lambda (tmp338)
+                     (if (if tmp338
+                           (apply (lambda (args339 doc340 e1341 e2342)
+                                    (if (string? (syntax->datum doc340))
+                                      (not docstring331)
                                       #f))
-                                  tmp337)
+                                  tmp338)
                            #f)
-                       (apply (lambda (args342 doc343 e1344 e2345)
-                                (chi-lambda-clause155
-                                  e329
-                                  doc343
-                                  (cons args342 (cons e1344 e2345))
-                                  r332
-                                  w333
-                                  mod334
-                                  k335))
-                              tmp337)
-                       ((lambda (tmp347)
-                          (if tmp347
-                            (apply (lambda (id348 e1349 e2350)
-                                     (let ((ids351 id348))
-                                       (if (not (valid-bound-ids?139 ids351))
+                       (apply (lambda (args343 doc344 e1345 e2346)
+                                (chi-lambda-clause156
+                                  e330
+                                  doc344
+                                  (cons args343 (cons e1345 e2346))
+                                  r333
+                                  w334
+                                  mod335
+                                  k336))
+                              tmp338)
+                       ((lambda (tmp348)
+                          (if tmp348
+                            (apply (lambda (id349 e1350 e2351)
+                                     (let ((ids352 id349))
+                                       (if (not (valid-bound-ids?140 ids352))
                                          (syntax-violation
                                            'lambda
                                            "invalid parameter list"
-                                           e329)
-                                         (let ((labels353
-                                                 (gen-labels120 ids351))
-                                               (new-vars354
-                                                 (map gen-var161 ids351)))
-                                           (k335 (map syntax->datum ids351)
-                                                 new-vars354
-                                                 (if docstring330
-                                                   (syntax->datum docstring330)
+                                           e330)
+                                         (let ((labels354
+                                                 (gen-labels121 ids352))
+                                               (new-vars355
+                                                 (map gen-var162 ids352)))
+                                           (k336 (map syntax->datum ids352)
+                                                 new-vars355
+                                                 (if docstring331
+                                                   (syntax->datum docstring331)
                                                    #f)
-                                                 (chi-body154
-                                                   (cons e1349 e2350)
-                                                   e329
-                                                   (extend-var-env109
-                                                     labels353
-                                                     new-vars354
-                                                     r332)
-                                                   (make-binding-wrap131
-                                                     ids351
-                                                     labels353
-                                                     w333)
-                                                   mod334))))))
-                                   tmp347)
-                            ((lambda (tmp356)
-                               (if tmp356
-                                 (apply (lambda (ids357 e1358 e2359)
-                                          (let ((old-ids360
-                                                  (lambda-var-list162 ids357)))
-                                            (if (not (valid-bound-ids?139
-                                                       old-ids360))
+                                                 (chi-body155
+                                                   (cons e1350 e2351)
+                                                   e330
+                                                   (extend-var-env110
+                                                     labels354
+                                                     new-vars355
+                                                     r333)
+                                                   (make-binding-wrap132
+                                                     ids352
+                                                     labels354
+                                                     w334)
+                                                   mod335))))))
+                                   tmp348)
+                            ((lambda (tmp357)
+                               (if tmp357
+                                 (apply (lambda (ids358 e1359 e2360)
+                                          (let ((old-ids361
+                                                  (lambda-var-list163 ids358)))
+                                            (if (not (valid-bound-ids?140
+                                                       old-ids361))
                                               (syntax-violation
                                                 'lambda
                                                 "invalid parameter list"
-                                                e329)
-                                              (let ((labels361
-                                                      (gen-labels120
-                                                        old-ids360))
-                                                    (new-vars362
-                                                      (map gen-var161
-                                                           old-ids360)))
-                                                (k335 (letrec ((f363 (lambda 
(ls1364
-                                                                              
ls2365)
-                                                                       (if 
(null? ls1364)
+                                                e330)
+                                              (let ((labels362
+                                                      (gen-labels121
+                                                        old-ids361))
+                                                    (new-vars363
+                                                      (map gen-var162
+                                                           old-ids361)))
+                                                (k336 (letrec ((f364 (lambda 
(ls1365
+                                                                              
ls2366)
+                                                                       (if 
(null? ls1365)
                                                                          
(syntax->datum
-                                                                           
ls2365)
-                                                                         (f363 
(cdr ls1364)
+                                                                           
ls2366)
+                                                                         (f364 
(cdr ls1365)
                                                                                
(cons (syntax->datum
-                                                                               
        (car ls1364))
-                                                                               
      ls2365))))))
-                                                        (f363 (cdr old-ids360)
-                                                              (car 
old-ids360)))
-                                                      (letrec ((f366 (lambda 
(ls1367
-                                                                              
ls2368)
-                                                                       (if 
(null? ls1367)
-                                                                         ls2368
-                                                                         (f366 
(cdr ls1367)
-                                                                               
(cons (car ls1367)
-                                                                               
      ls2368))))))
-                                                        (f366 (cdr new-vars362)
-                                                              (car 
new-vars362)))
-                                                      (if docstring330
+                                                                               
        (car ls1365))
+                                                                               
      ls2366))))))
+                                                        (f364 (cdr old-ids361)
+                                                              (car 
old-ids361)))
+                                                      (letrec ((f367 (lambda 
(ls1368
+                                                                              
ls2369)
+                                                                       (if 
(null? ls1368)
+                                                                         ls2369
+                                                                         (f367 
(cdr ls1368)
+                                                                               
(cons (car ls1368)
+                                                                               
      ls2369))))))
+                                                        (f367 (cdr new-vars363)
+                                                              (car 
new-vars363)))
+                                                      (if docstring331
                                                         (syntax->datum
-                                                          docstring330)
+                                                          docstring331)
                                                         #f)
-                                                      (chi-body154
-                                                        (cons e1358 e2359)
-                                                        e329
-                                                        (extend-var-env109
-                                                          labels361
-                                                          new-vars362
-                                                          r332)
-                                                        (make-binding-wrap131
-                                                          old-ids360
-                                                          labels361
-                                                          w333)
-                                                        mod334))))))
-                                        tmp356)
-                                 ((lambda (_370)
+                                                      (chi-body155
+                                                        (cons e1359 e2360)
+                                                        e330
+                                                        (extend-var-env110
+                                                          labels362
+                                                          new-vars363
+                                                          r333)
+                                                        (make-binding-wrap132
+                                                          old-ids361
+                                                          labels362
+                                                          w334)
+                                                        mod335))))))
+                                        tmp357)
+                                 ((lambda (_371)
                                     (syntax-violation
                                       'lambda
                                       "bad lambda"
-                                      e329))
-                                  tmp336)))
+                                      e330))
+                                  tmp337)))
                              ($sc-dispatch
-                               tmp336
+                               tmp337
                                '(any any . each-any)))))
                         ($sc-dispatch
-                          tmp336
+                          tmp337
                           '(each-any any . each-any)))))
                    ($sc-dispatch
-                     tmp336
+                     tmp337
                      '(any any any . each-any))))
-                c331)))
-           (chi-body154
-             (lambda (body371 outer-form372 r373 w374 mod375)
-               (let ((r376 (cons (quote ("placeholder" placeholder)) r373)))
-                 (let ((ribcage377
-                         (make-ribcage121
+                c332)))
+           (chi-body155
+             (lambda (body372 outer-form373 r374 w375 mod376)
+               (let ((r377 (cons (quote ("placeholder" placeholder)) r374)))
+                 (let ((ribcage378
+                         (make-ribcage122
                            '()
                            '()
                            '())))
-                   (let ((w378 (make-wrap116
-                                 (wrap-marks117 w374)
-                                 (cons ribcage377 (wrap-subst118 w374)))))
-                     (letrec ((parse379
-                                (lambda (body380
-                                         ids381
-                                         labels382
-                                         var-ids383
-                                         vars384
-                                         vals385
-                                         bindings386)
-                                  (if (null? body380)
+                   (let ((w379 (make-wrap117
+                                 (wrap-marks118 w375)
+                                 (cons ribcage378 (wrap-subst119 w375)))))
+                     (letrec ((parse380
+                                (lambda (body381
+                                         ids382
+                                         labels383
+                                         var-ids384
+                                         vars385
+                                         vals386
+                                         bindings387)
+                                  (if (null? body381)
                                     (syntax-violation
                                       #f
                                       "no expressions in body"
-                                      outer-form372)
-                                    (let ((e388 (cdar body380))
-                                          (er389 (caar body380)))
+                                      outer-form373)
+                                    (let ((e389 (cdar body381))
+                                          (er390 (caar body381)))
                                       (call-with-values
                                         (lambda ()
-                                          (syntax-type148
-                                            e388
-                                            er389
+                                          (syntax-type149
+                                            e389
+                                            er390
                                             '(())
-                                            (source-annotation105 er389)
-                                            ribcage377
-                                            mod375
+                                            (source-annotation106 er390)
+                                            ribcage378
+                                            mod376
                                             #f))
-                                        (lambda (type390
-                                                 value391
-                                                 e392
-                                                 w393
-                                                 s394
-                                                 mod395)
-                                          (if (memv type390
+                                        (lambda (type391
+                                                 value392
+                                                 e393
+                                                 w394
+                                                 s395
+                                                 mod396)
+                                          (if (memv type391
                                                     '(define-form))
-                                            (let ((id396 (wrap142
-                                                           value391
-                                                           w393
-                                                           mod395))
-                                                  (label397 (gen-label119)))
-                                              (let ((var398
-                                                      (gen-var161 id396)))
+                                            (let ((id397 (wrap143
+                                                           value392
+                                                           w394
+                                                           mod396))
+                                                  (label398 (gen-label120)))
+                                              (let ((var399
+                                                      (gen-var162 id397)))
                                                 (begin
-                                                  (extend-ribcage!130
-                                                    ribcage377
-                                                    id396
-                                                    label397)
-                                                  (parse379
-                                                    (cdr body380)
-                                                    (cons id396 ids381)
-                                                    (cons label397 labels382)
-                                                    (cons id396 var-ids383)
-                                                    (cons var398 vars384)
-                                                    (cons (cons er389
-                                                                (wrap142
-                                                                  e392
-                                                                  w393
-                                                                  mod395))
-                                                          vals385)
+                                                  (extend-ribcage!131
+                                                    ribcage378
+                                                    id397
+                                                    label398)
+                                                  (parse380
+                                                    (cdr body381)
+                                                    (cons id397 ids382)
+                                                    (cons label398 labels383)
+                                                    (cons id397 var-ids384)
+                                                    (cons var399 vars385)
+                                                    (cons (cons er390
+                                                                (wrap143
+                                                                  e393
+                                                                  w394
+                                                                  mod396))
+                                                          vals386)
                                                     (cons (cons 'lexical
-                                                                var398)
-                                                          bindings386)))))
-                                            (if (memv type390
+                                                                var399)
+                                                          bindings387)))))
+                                            (if (memv type391
                                                       '(define-syntax-form))
-                                              (let ((id399 (wrap142
-                                                             value391
-                                                             w393
-                                                             mod395))
-                                                    (label400 (gen-label119)))
+                                              (let ((id400 (wrap143
+                                                             value392
+                                                             w394
+                                                             mod396))
+                                                    (label401 (gen-label120)))
                                                 (begin
-                                                  (extend-ribcage!130
-                                                    ribcage377
-                                                    id399
-                                                    label400)
-                                                  (parse379
-                                                    (cdr body380)
-                                                    (cons id399 ids381)
-                                                    (cons label400 labels382)
-                                                    var-ids383
-                                                    vars384
-                                                    vals385
+                                                  (extend-ribcage!131
+                                                    ribcage378
+                                                    id400
+                                                    label401)
+                                                  (parse380
+                                                    (cdr body381)
+                                                    (cons id400 ids382)
+                                                    (cons label401 labels383)
+                                                    var-ids384
+                                                    vars385
+                                                    vals386
                                                     (cons (cons 'macro
-                                                                (cons er389
-                                                                      (wrap142
-                                                                        e392
-                                                                        w393
-                                                                        
mod395)))
-                                                          bindings386))))
-                                              (if (memv type390
+                                                                (cons er390
+                                                                      (wrap143
+                                                                        e393
+                                                                        w394
+                                                                        
mod396)))
+                                                          bindings387))))
+                                              (if (memv type391
                                                         '(begin-form))
-                                                ((lambda (tmp401)
-                                                   ((lambda (tmp402)
-                                                      (if tmp402
-                                                        (apply (lambda (_403
-                                                                        e1404)
-                                                                 (parse379
-                                                                   (letrec 
((f405 (lambda (forms406)
-                                                                               
     (if (null? forms406)
-                                                                               
       (cdr body380)
-                                                                               
       (cons (cons er389
-                                                                               
                   (wrap142
-                                                                               
                     (car forms406)
-                                                                               
                     w393
-                                                                               
                     mod395))
-                                                                               
             (f405 (cdr forms406)))))))
-                                                                     (f405 
e1404))
-                                                                   ids381
-                                                                   labels382
-                                                                   var-ids383
-                                                                   vars384
-                                                                   vals385
-                                                                   
bindings386))
-                                                               tmp402)
+                                                ((lambda (tmp402)
+                                                   ((lambda (tmp403)
+                                                      (if tmp403
+                                                        (apply (lambda (_404
+                                                                        e1405)
+                                                                 (parse380
+                                                                   (letrec 
((f406 (lambda (forms407)
+                                                                               
     (if (null? forms407)
+                                                                               
       (cdr body381)
+                                                                               
       (cons (cons er390
+                                                                               
                   (wrap143
+                                                                               
                     (car forms407)
+                                                                               
                     w394
+                                                                               
                     mod396))
+                                                                               
             (f406 (cdr forms407)))))))
+                                                                     (f406 
e1405))
+                                                                   ids382
+                                                                   labels383
+                                                                   var-ids384
+                                                                   vars385
+                                                                   vals386
+                                                                   
bindings387))
+                                                               tmp403)
                                                         (syntax-violation
                                                           #f
                                                           "source expression 
failed to match any pattern"
-                                                          tmp401)))
+                                                          tmp402)))
                                                     ($sc-dispatch
-                                                      tmp401
+                                                      tmp402
                                                       '(any . each-any))))
-                                                 e392)
-                                                (if (memv type390
+                                                 e393)
+                                                (if (memv type391
                                                           '(local-syntax-form))
-                                                  (chi-local-syntax156
-                                                    value391
-                                                    e392
-                                                    er389
-                                                    w393
-                                                    s394
-                                                    mod395
-                                                    (lambda (forms408
-                                                             er409
-                                                             w410
-                                                             s411
-                                                             mod412)
-                                                      (parse379
-                                                        (letrec ((f413 (lambda 
(forms414)
-                                                                         (if 
(null? forms414)
-                                                                           
(cdr body380)
-                                                                           
(cons (cons er409
-                                                                               
        (wrap142
-                                                                               
          (car forms414)
-                                                                               
          w410
-                                                                               
          mod412))
-                                                                               
  (f413 (cdr forms414)))))))
-                                                          (f413 forms408))
-                                                        ids381
-                                                        labels382
-                                                        var-ids383
-                                                        vars384
-                                                        vals385
-                                                        bindings386)))
-                                                  (if (null? ids381)
-                                                    (build-sequence93
+                                                  (chi-local-syntax157
+                                                    value392
+                                                    e393
+                                                    er390
+                                                    w394
+                                                    s395
+                                                    mod396
+                                                    (lambda (forms409
+                                                             er410
+                                                             w411
+                                                             s412
+                                                             mod413)
+                                                      (parse380
+                                                        (letrec ((f414 (lambda 
(forms415)
+                                                                         (if 
(null? forms415)
+                                                                           
(cdr body381)
+                                                                           
(cons (cons er410
+                                                                               
        (wrap143
+                                                                               
          (car forms415)
+                                                                               
          w411
+                                                                               
          mod413))
+                                                                               
  (f414 (cdr forms415)))))))
+                                                          (f414 forms409))
+                                                        ids382
+                                                        labels383
+                                                        var-ids384
+                                                        vars385
+                                                        vals386
+                                                        bindings387)))
+                                                  (if (null? ids382)
+                                                    (build-sequence94
                                                       #f
-                                                      (map (lambda (x415)
-                                                             (chi150
-                                                               (cdr x415)
-                                                               (car x415)
+                                                      (map (lambda (x416)
+                                                             (chi151
+                                                               (cdr x416)
+                                                               (car x416)
                                                                '(())
-                                                               mod395))
-                                                           (cons (cons er389
-                                                                       
(source-wrap143
-                                                                         e392
-                                                                         w393
-                                                                         s394
-                                                                         
mod395))
-                                                                 (cdr 
body380))))
+                                                               mod396))
+                                                           (cons (cons er390
+                                                                       
(source-wrap144
+                                                                         e393
+                                                                         w394
+                                                                         s395
+                                                                         
mod396))
+                                                                 (cdr 
body381))))
                                                     (begin
-                                                      (if (not 
(valid-bound-ids?139
-                                                                 ids381))
+                                                      (if (not 
(valid-bound-ids?140
+                                                                 ids382))
                                                         (syntax-violation
                                                           #f
                                                           "invalid or 
duplicate identifier in definition"
-                                                          outer-form372))
-                                                      (letrec ((loop416
-                                                                 (lambda (bs417
-                                                                          
er-cache418
-                                                                          
r-cache419)
-                                                                   (if (not 
(null? bs417))
-                                                                     (let 
((b420 (car bs417)))
-                                                                       (if 
(eq? (car b420)
+                                                          outer-form373))
+                                                      (letrec ((loop417
+                                                                 (lambda (bs418
+                                                                          
er-cache419
+                                                                          
r-cache420)
+                                                                   (if (not 
(null? bs418))
+                                                                     (let 
((b421 (car bs418)))
+                                                                       (if 
(eq? (car b421)
                                                                                
 'macro)
-                                                                         (let 
((er421 (cadr b420)))
-                                                                           
(let ((r-cache422
-                                                                               
    (if (eq? er421
-                                                                               
             er-cache418)
-                                                                               
      r-cache419
-                                                                               
      (macros-only-env110
-                                                                               
        er421))))
+                                                                         (let 
((er422 (cadr b421)))
+                                                                           
(let ((r-cache423
+                                                                               
    (if (eq? er422
+                                                                               
             er-cache419)
+                                                                               
      r-cache420
+                                                                               
      (macros-only-env111
+                                                                               
        er422))))
                                                                              
(begin
                                                                                
(set-cdr!
-                                                                               
  b420
-                                                                               
  (eval-local-transformer157
-                                                                               
    (chi150
-                                                                               
      (cddr b420)
-                                                                               
      r-cache422
+                                                                               
  b421
+                                                                               
  (eval-local-transformer158
+                                                                               
    (chi151
+                                                                               
      (cddr b421)
+                                                                               
      r-cache423
                                                                                
      '(())
-                                                                               
      mod395)
-                                                                               
    mod395))
-                                                                               
(loop416
-                                                                               
  (cdr bs417)
-                                                                               
  er421
-                                                                               
  r-cache422))))
-                                                                         
(loop416
-                                                                           
(cdr bs417)
-                                                                           
er-cache418
-                                                                           
r-cache419)))))))
-                                                        (loop416
-                                                          bindings386
+                                                                               
      mod396)
+                                                                               
    mod396))
+                                                                               
(loop417
+                                                                               
  (cdr bs418)
+                                                                               
  er422
+                                                                               
  r-cache423))))
+                                                                         
(loop417
+                                                                           
(cdr bs418)
+                                                                           
er-cache419
+                                                                           
r-cache420)))))))
+                                                        (loop417
+                                                          bindings387
                                                           #f
                                                           #f))
                                                       (set-cdr!
-                                                        r376
-                                                        (extend-env108
-                                                          labels382
-                                                          bindings386
-                                                          (cdr r376)))
-                                                      (build-letrec96
+                                                        r377
+                                                        (extend-env109
+                                                          labels383
+                                                          bindings387
+                                                          (cdr r377)))
+                                                      (build-letrec97
                                                         #f
                                                         (map syntax->datum
-                                                             var-ids383)
-                                                        vars384
-                                                        (map (lambda (x423)
-                                                               (chi150
-                                                                 (cdr x423)
-                                                                 (car x423)
+                                                             var-ids384)
+                                                        vars385
+                                                        (map (lambda (x424)
+                                                               (chi151
+                                                                 (cdr x424)
+                                                                 (car x424)
                                                                  '(())
-                                                                 mod395))
-                                                             vals385)
-                                                        (build-sequence93
+                                                                 mod396))
+                                                             vals386)
+                                                        (build-sequence94
                                                           #f
-                                                          (map (lambda (x424)
-                                                                 (chi150
-                                                                   (cdr x424)
-                                                                   (car x424)
+                                                          (map (lambda (x425)
+                                                                 (chi151
+                                                                   (cdr x425)
+                                                                   (car x425)
                                                                    '(())
-                                                                   mod395))
-                                                               (cons (cons 
er389
-                                                                           
(source-wrap143
-                                                                             
e392
-                                                                             
w393
-                                                                             
s394
-                                                                             
mod395))
-                                                                     (cdr 
body380))))))))))))))))))
-                       (parse379
-                         (map (lambda (x387)
-                                (cons r376 (wrap142 x387 w378 mod375)))
-                              body371)
+                                                                   mod396))
+                                                               (cons (cons 
er390
+                                                                           
(source-wrap144
+                                                                             
e393
+                                                                             
w394
+                                                                             
s395
+                                                                             
mod396))
+                                                                     (cdr 
body381))))))))))))))))))
+                       (parse380
+                         (map (lambda (x388)
+                                (cons r377 (wrap143 x388 w379 mod376)))
+                              body372)
                          '()
                          '()
                          '()
                          '()
                          '()
                          '())))))))
-           (chi-macro153
-             (lambda (p425 e426 r427 w428 rib429 mod430)
-               (letrec ((rebuild-macro-output431
-                          (lambda (x432 m433)
-                            (if (pair? x432)
-                              (cons (rebuild-macro-output431 (car x432) m433)
-                                    (rebuild-macro-output431 (cdr x432) m433))
-                              (if (syntax-object?98 x432)
-                                (let ((w434 (syntax-object-wrap100 x432)))
-                                  (let ((ms435 (wrap-marks117 w434))
-                                        (s436 (wrap-subst118 w434)))
-                                    (if (if (pair? ms435)
-                                          (eq? (car ms435) #f)
+           (chi-macro154
+             (lambda (p426 e427 r428 w429 rib430 mod431)
+               (letrec ((rebuild-macro-output432
+                          (lambda (x433 m434)
+                            (if (pair? x433)
+                              (cons (rebuild-macro-output432 (car x433) m434)
+                                    (rebuild-macro-output432 (cdr x433) m434))
+                              (if (syntax-object?99 x433)
+                                (let ((w435 (syntax-object-wrap101 x433)))
+                                  (let ((ms436 (wrap-marks118 w435))
+                                        (s437 (wrap-subst119 w435)))
+                                    (if (if (pair? ms436)
+                                          (eq? (car ms436) #f)
                                           #f)
-                                      (make-syntax-object97
-                                        (syntax-object-expression99 x432)
-                                        (make-wrap116
-                                          (cdr ms435)
-                                          (if rib429
-                                            (cons rib429 (cdr s436))
-                                            (cdr s436)))
-                                        (syntax-object-module101 x432))
-                                      (make-syntax-object97
-                                        (syntax-object-expression99 x432)
-                                        (make-wrap116
-                                          (cons m433 ms435)
-                                          (if rib429
-                                            (cons rib429
-                                                  (cons (quote shift) s436))
-                                            (cons (quote shift) s436)))
-                                        (let ((pmod437
-                                                (procedure-module p425)))
-                                          (if pmod437
+                                      (make-syntax-object98
+                                        (syntax-object-expression100 x433)
+                                        (make-wrap117
+                                          (cdr ms436)
+                                          (if rib430
+                                            (cons rib430 (cdr s437))
+                                            (cdr s437)))
+                                        (syntax-object-module102 x433))
+                                      (make-syntax-object98
+                                        (syntax-object-expression100 x433)
+                                        (make-wrap117
+                                          (cons m434 ms436)
+                                          (if rib430
+                                            (cons rib430
+                                                  (cons (quote shift) s437))
+                                            (cons (quote shift) s437)))
+                                        (let ((pmod438
+                                                (procedure-module p426)))
+                                          (if pmod438
                                             (cons 'hygiene
-                                                  (module-name pmod437))
+                                                  (module-name pmod438))
                                             '(hygiene guile)))))))
-                                (if (vector? x432)
-                                  (let ((n438 (vector-length x432)))
-                                    (let ((v439 (make-vector n438)))
-                                      (letrec ((loop440
-                                                 (lambda (i441)
-                                                   (if (fx=74 i441 n438)
-                                                     (begin (if #f #f) v439)
+                                (if (vector? x433)
+                                  (let ((n439 (vector-length x433)))
+                                    (let ((v440 (make-vector n439)))
+                                      (letrec ((loop441
+                                                 (lambda (i442)
+                                                   (if (fx=74 i442 n439)
+                                                     (begin (if #f #f) v440)
                                                      (begin
                                                        (vector-set!
-                                                         v439
-                                                         i441
-                                                         
(rebuild-macro-output431
+                                                         v440
+                                                         i442
+                                                         
(rebuild-macro-output432
                                                            (vector-ref
-                                                             x432
-                                                             i441)
-                                                           m433))
-                                                       (loop440
-                                                         (fx+72 i441 1)))))))
-                                        (loop440 0))))
-                                  (if (symbol? x432)
+                                                             x433
+                                                             i442)
+                                                           m434))
+                                                       (loop441
+                                                         (fx+72 i442 1)))))))
+                                        (loop441 0))))
+                                  (if (symbol? x433)
                                     (syntax-violation
                                       #f
                                       "encountered raw symbol in macro output"
-                                      (source-wrap143 e426 w428 s mod430)
-                                      x432)
-                                    x432)))))))
-                 (rebuild-macro-output431
-                   (p425 (wrap142 e426 (anti-mark129 w428) mod430))
+                                      (source-wrap144 e427 w429 s mod431)
+                                      x433)
+                                    x433)))))))
+                 (rebuild-macro-output432
+                   (p426 (wrap143 e427 (anti-mark130 w429) mod431))
                    (string #\m)))))
-           (chi-application152
-             (lambda (x442 e443 r444 w445 s446 mod447)
-               ((lambda (tmp448)
-                  ((lambda (tmp449)
-                     (if tmp449
-                       (apply (lambda (e0450 e1451)
-                                (build-application81
-                                  s446
-                                  x442
-                                  (map (lambda (e452)
-                                         (chi150 e452 r444 w445 mod447))
-                                       e1451)))
-                              tmp449)
+           (chi-application153
+             (lambda (x443 e444 r445 w446 s447 mod448)
+               ((lambda (tmp449)
+                  ((lambda (tmp450)
+                     (if tmp450
+                       (apply (lambda (e0451 e1452)
+                                (build-application82
+                                  s447
+                                  x443
+                                  (map (lambda (e453)
+                                         (chi151 e453 r445 w446 mod448))
+                                       e1452)))
+                              tmp450)
                        (syntax-violation
                          #f
                          "source expression failed to match any pattern"
-                         tmp448)))
-                   ($sc-dispatch tmp448 (quote (any . each-any)))))
-                e443)))
-           (chi-expr151
-             (lambda (type454 value455 e456 r457 w458 s459 mod460)
-               (if (memv type454 (quote (lexical)))
-                 (build-lexical-reference83
+                         tmp449)))
+                   ($sc-dispatch tmp449 (quote (any . each-any)))))
+                e444)))
+           (chi-expr152
+             (lambda (type455 value456 e457 r458 w459 s460 mod461)
+               (if (memv type455 (quote (lexical)))
+                 (build-lexical-reference84
                    'value
-                   s459
-                   e456
-                   value455)
-                 (if (memv type454 (quote (core core-form)))
-                   (value455 e456 r457 w458 s459 mod460)
-                   (if (memv type454 (quote (module-ref)))
+                   s460
+                   e457
+                   value456)
+                 (if (memv type455 (quote (core core-form)))
+                   (value456 e457 r458 w459 s460 mod461)
+                   (if (memv type455 (quote (module-ref)))
                      (call-with-values
-                       (lambda () (value455 e456))
-                       (lambda (id461 mod462)
-                         (build-global-reference86 s459 id461 mod462)))
-                     (if (memv type454 (quote (lexical-call)))
-                       (chi-application152
-                         (build-lexical-reference83
+                       (lambda () (value456 e457))
+                       (lambda (id462 mod463)
+                         (build-global-reference87 s460 id462 mod463)))
+                     (if (memv type455 (quote (lexical-call)))
+                       (chi-application153
+                         (build-lexical-reference84
                            'fun
-                           (source-annotation105 (car e456))
-                           (car e456)
-                           value455)
-                         e456
-                         r457
-                         w458
-                         s459
-                         mod460)
-                       (if (memv type454 (quote (global-call)))
-                         (chi-application152
-                           (build-global-reference86
-                             (source-annotation105 (car e456))
-                             (if (syntax-object?98 value455)
-                               (syntax-object-expression99 value455)
-                               value455)
-                             (if (syntax-object?98 value455)
-                               (syntax-object-module101 value455)
-                               mod460))
-                           e456
-                           r457
-                           w458
-                           s459
-                           mod460)
-                         (if (memv type454 (quote (constant)))
-                           (build-data92
-                             s459
-                             (strip160
-                               (source-wrap143 e456 w458 s459 mod460)
+                           (source-annotation106 (car e457))
+                           (car e457)
+                           value456)
+                         e457
+                         r458
+                         w459
+                         s460
+                         mod461)
+                       (if (memv type455 (quote (global-call)))
+                         (chi-application153
+                           (build-global-reference87
+                             (source-annotation106 (car e457))
+                             (if (syntax-object?99 value456)
+                               (syntax-object-expression100 value456)
+                               value456)
+                             (if (syntax-object?99 value456)
+                               (syntax-object-module102 value456)
+                               mod461))
+                           e457
+                           r458
+                           w459
+                           s460
+                           mod461)
+                         (if (memv type455 (quote (constant)))
+                           (build-data93
+                             s460
+                             (strip161
+                               (source-wrap144 e457 w459 s460 mod461)
                                '(())))
-                           (if (memv type454 (quote (global)))
-                             (build-global-reference86 s459 value455 mod460)
-                             (if (memv type454 (quote (call)))
-                               (chi-application152
-                                 (chi150 (car e456) r457 w458 mod460)
-                                 e456
-                                 r457
-                                 w458
-                                 s459
-                                 mod460)
-                               (if (memv type454 (quote (begin-form)))
-                                 ((lambda (tmp463)
-                                    ((lambda (tmp464)
-                                       (if tmp464
-                                         (apply (lambda (_465 e1466 e2467)
-                                                  (chi-sequence144
-                                                    (cons e1466 e2467)
-                                                    r457
-                                                    w458
-                                                    s459
-                                                    mod460))
-                                                tmp464)
+                           (if (memv type455 (quote (global)))
+                             (build-global-reference87 s460 value456 mod461)
+                             (if (memv type455 (quote (call)))
+                               (chi-application153
+                                 (chi151 (car e457) r458 w459 mod461)
+                                 e457
+                                 r458
+                                 w459
+                                 s460
+                                 mod461)
+                               (if (memv type455 (quote (begin-form)))
+                                 ((lambda (tmp464)
+                                    ((lambda (tmp465)
+                                       (if tmp465
+                                         (apply (lambda (_466 e1467 e2468)
+                                                  (chi-sequence145
+                                                    (cons e1467 e2468)
+                                                    r458
+                                                    w459
+                                                    s460
+                                                    mod461))
+                                                tmp465)
                                          (syntax-violation
                                            #f
                                            "source expression failed to match 
any pattern"
-                                           tmp463)))
+                                           tmp464)))
                                      ($sc-dispatch
-                                       tmp463
+                                       tmp464
                                        '(any any . each-any))))
-                                  e456)
-                                 (if (memv type454 (quote (local-syntax-form)))
-                                   (chi-local-syntax156
-                                     value455
-                                     e456
-                                     r457
-                                     w458
-                                     s459
-                                     mod460
-                                     chi-sequence144)
-                                   (if (memv type454 (quote (eval-when-form)))
-                                     ((lambda (tmp469)
-                                        ((lambda (tmp470)
-                                           (if tmp470
-                                             (apply (lambda (_471
-                                                             x472
-                                                             e1473
-                                                             e2474)
-                                                      (let ((when-list475
-                                                              (chi-when-list147
-                                                                e456
-                                                                x472
-                                                                w458)))
+                                  e457)
+                                 (if (memv type455 (quote (local-syntax-form)))
+                                   (chi-local-syntax157
+                                     value456
+                                     e457
+                                     r458
+                                     w459
+                                     s460
+                                     mod461
+                                     chi-sequence145)
+                                   (if (memv type455 (quote (eval-when-form)))
+                                     ((lambda (tmp470)
+                                        ((lambda (tmp471)
+                                           (if tmp471
+                                             (apply (lambda (_472
+                                                             x473
+                                                             e1474
+                                                             e2475)
+                                                      (let ((when-list476
+                                                              (chi-when-list148
+                                                                e457
+                                                                x473
+                                                                w459)))
                                                         (if (memq 'eval
-                                                                  when-list475)
-                                                          (chi-sequence144
-                                                            (cons e1473 e2474)
-                                                            r457
-                                                            w458
-                                                            s459
-                                                            mod460)
-                                                          (chi-void158))))
-                                                    tmp470)
+                                                                  when-list476)
+                                                          (chi-sequence145
+                                                            (cons e1474 e2475)
+                                                            r458
+                                                            w459
+                                                            s460
+                                                            mod461)
+                                                          (chi-void159))))
+                                                    tmp471)
                                              (syntax-violation
                                                #f
                                                "source expression failed to 
match any pattern"
-                                               tmp469)))
+                                               tmp470)))
                                          ($sc-dispatch
-                                           tmp469
+                                           tmp470
                                            '(any each-any any . each-any))))
-                                      e456)
-                                     (if (memv type454
+                                      e457)
+                                     (if (memv type455
                                                '(define-form
                                                   define-syntax-form))
                                        (syntax-violation
                                          #f
                                          "definition in expression context"
-                                         e456
-                                         (wrap142 value455 w458 mod460))
-                                       (if (memv type454 (quote (syntax)))
+                                         e457
+                                         (wrap143 value456 w459 mod461))
+                                       (if (memv type455 (quote (syntax)))
                                          (syntax-violation
                                            #f
                                            "reference to pattern variable 
outside syntax form"
-                                           (source-wrap143
-                                             e456
-                                             w458
-                                             s459
-                                             mod460))
-                                         (if (memv type454
+                                           (source-wrap144
+                                             e457
+                                             w459
+                                             s460
+                                             mod461))
+                                         (if (memv type455
                                                    '(displaced-lexical))
                                            (syntax-violation
                                              #f
                                              "reference to identifier outside 
its scope"
-                                             (source-wrap143
-                                               e456
-                                               w458
-                                               s459
-                                               mod460))
+                                             (source-wrap144
+                                               e457
+                                               w459
+                                               s460
+                                               mod461))
                                            (syntax-violation
                                              #f
                                              "unexpected syntax"
-                                             (source-wrap143
-                                               e456
-                                               w458
-                                               s459
-                                               mod460))))))))))))))))))
-           (chi150
-             (lambda (e478 r479 w480 mod481)
+                                             (source-wrap144
+                                               e457
+                                               w459
+                                               s460
+                                               mod461))))))))))))))))))
+           (chi151
+             (lambda (e479 r480 w481 mod482)
                (call-with-values
                  (lambda ()
-                   (syntax-type148
-                     e478
-                     r479
-                     w480
-                     (source-annotation105 e478)
+                   (syntax-type149
+                     e479
+                     r480
+                     w481
+                     (source-annotation106 e479)
                      #f
-                     mod481
+                     mod482
                      #f))
-                 (lambda (type482 value483 e484 w485 s486 mod487)
-                   (chi-expr151
-                     type482
-                     value483
-                     e484
-                     r479
-                     w485
-                     s486
-                     mod487)))))
-           (chi-top149
-             (lambda (e488 r489 w490 m491 esew492 mod493)
+                 (lambda (type483 value484 e485 w486 s487 mod488)
+                   (chi-expr152
+                     type483
+                     value484
+                     e485
+                     r480
+                     w486
+                     s487
+                     mod488)))))
+           (chi-top150
+             (lambda (e489 r490 w491 m492 esew493 mod494)
                (call-with-values
                  (lambda ()
-                   (syntax-type148
-                     e488
-                     r489
-                     w490
-                     (source-annotation105 e488)
+                   (syntax-type149
+                     e489
+                     r490
+                     w491
+                     (source-annotation106 e489)
                      #f
-                     mod493
+                     mod494
                      #f))
-                 (lambda (type501 value502 e503 w504 s505 mod506)
-                   (if (memv type501 (quote (begin-form)))
-                     ((lambda (tmp507)
-                        ((lambda (tmp508)
-                           (if tmp508
-                             (apply (lambda (_509) (chi-void158)) tmp508)
-                             ((lambda (tmp510)
-                                (if tmp510
-                                  (apply (lambda (_511 e1512 e2513)
-                                           (chi-top-sequence145
-                                             (cons e1512 e2513)
-                                             r489
-                                             w504
-                                             s505
-                                             m491
-                                             esew492
-                                             mod506))
-                                         tmp510)
+                 (lambda (type502 value503 e504 w505 s506 mod507)
+                   (if (memv type502 (quote (begin-form)))
+                     ((lambda (tmp508)
+                        ((lambda (tmp509)
+                           (if tmp509
+                             (apply (lambda (_510) (chi-void159)) tmp509)
+                             ((lambda (tmp511)
+                                (if tmp511
+                                  (apply (lambda (_512 e1513 e2514)
+                                           (chi-top-sequence146
+                                             (cons e1513 e2514)
+                                             r490
+                                             w505
+                                             s506
+                                             m492
+                                             esew493
+                                             mod507))
+                                         tmp511)
                                   (syntax-violation
                                     #f
                                     "source expression failed to match any 
pattern"
-                                    tmp507)))
+                                    tmp508)))
                               ($sc-dispatch
-                                tmp507
+                                tmp508
                                 '(any any . each-any)))))
-                         ($sc-dispatch tmp507 (quote (any)))))
-                      e503)
-                     (if (memv type501 (quote (local-syntax-form)))
-                       (chi-local-syntax156
-                         value502
-                         e503
-                         r489
-                         w504
-                         s505
-                         mod506
-                         (lambda (body515 r516 w517 s518 mod519)
-                           (chi-top-sequence145
-                             body515
-                             r516
-                             w517
-                             s518
-                             m491
-                             esew492
-                             mod519)))
-                       (if (memv type501 (quote (eval-when-form)))
-                         ((lambda (tmp520)
-                            ((lambda (tmp521)
-                               (if tmp521
-                                 (apply (lambda (_522 x523 e1524 e2525)
-                                          (let ((when-list526
-                                                  (chi-when-list147
-                                                    e503
-                                                    x523
-                                                    w504))
-                                                (body527 (cons e1524 e2525)))
-                                            (if (eq? m491 (quote e))
+                         ($sc-dispatch tmp508 (quote (any)))))
+                      e504)
+                     (if (memv type502 (quote (local-syntax-form)))
+                       (chi-local-syntax157
+                         value503
+                         e504
+                         r490
+                         w505
+                         s506
+                         mod507
+                         (lambda (body516 r517 w518 s519 mod520)
+                           (chi-top-sequence146
+                             body516
+                             r517
+                             w518
+                             s519
+                             m492
+                             esew493
+                             mod520)))
+                       (if (memv type502 (quote (eval-when-form)))
+                         ((lambda (tmp521)
+                            ((lambda (tmp522)
+                               (if tmp522
+                                 (apply (lambda (_523 x524 e1525 e2526)
+                                          (let ((when-list527
+                                                  (chi-when-list148
+                                                    e504
+                                                    x524
+                                                    w505))
+                                                (body528 (cons e1525 e2526)))
+                                            (if (eq? m492 (quote e))
                                               (if (memq 'eval
-                                                        when-list526)
-                                                (chi-top-sequence145
-                                                  body527
-                                                  r489
-                                                  w504
-                                                  s505
+                                                        when-list527)
+                                                (chi-top-sequence146
+                                                  body528
+                                                  r490
+                                                  w505
+                                                  s506
                                                   'e
                                                   '(eval)
-                                                  mod506)
-                                                (chi-void158))
+                                                  mod507)
+                                                (chi-void159))
                                               (if (memq 'load
-                                                        when-list526)
-                                                (if (let ((t530 (memq 'compile
-                                                                      
when-list526)))
-                                                      (if t530
-                                                        t530
-                                                        (if (eq? m491
+                                                        when-list527)
+                                                (if (let ((t531 (memq 'compile
+                                                                      
when-list527)))
+                                                      (if t531
+                                                        t531
+                                                        (if (eq? m492
                                                                  'c&e)
                                                           (memq 'eval
-                                                                when-list526)
+                                                                when-list527)
                                                           #f)))
-                                                  (chi-top-sequence145
-                                                    body527
-                                                    r489
-                                                    w504
-                                                    s505
+                                                  (chi-top-sequence146
+                                                    body528
+                                                    r490
+                                                    w505
+                                                    s506
                                                     'c&e
                                                     '(compile load)
-                                                    mod506)
-                                                  (if (memq m491
+                                                    mod507)
+                                                  (if (memq m492
                                                             '(c c&e))
-                                                    (chi-top-sequence145
-                                                      body527
-                                                      r489
-                                                      w504
-                                                      s505
+                                                    (chi-top-sequence146
+                                                      body528
+                                                      r490
+                                                      w505
+                                                      s506
                                                       'c
                                                       '(load)
-                                                      mod506)
-                                                    (chi-void158)))
-                                                (if (let ((t531 (memq 'compile
-                                                                      
when-list526)))
-                                                      (if t531
-                                                        t531
-                                                        (if (eq? m491
+                                                      mod507)
+                                                    (chi-void159)))
+                                                (if (let ((t532 (memq 'compile
+                                                                      
when-list527)))
+                                                      (if t532
+                                                        t532
+                                                        (if (eq? m492
                                                                  'c&e)
                                                           (memq 'eval
-                                                                when-list526)
+                                                                when-list527)
                                                           #f)))
                                                   (begin
                                                     (top-level-eval-hook76
-                                                      (chi-top-sequence145
-                                                        body527
-                                                        r489
-                                                        w504
-                                                        s505
+                                                      (chi-top-sequence146
+                                                        body528
+                                                        r490
+                                                        w505
+                                                        s506
                                                         'e
                                                         '(eval)
-                                                        mod506)
-                                                      mod506)
-                                                    (chi-void158))
-                                                  (chi-void158))))))
-                                        tmp521)
+                                                        mod507)
+                                                      mod507)
+                                                    (chi-void159))
+                                                  (chi-void159))))))
+                                        tmp522)
                                  (syntax-violation
                                    #f
                                    "source expression failed to match any 
pattern"
-                                   tmp520)))
+                                   tmp521)))
                              ($sc-dispatch
-                               tmp520
+                               tmp521
                                '(any each-any any . each-any))))
-                          e503)
-                         (if (memv type501 (quote (define-syntax-form)))
-                           (let ((n532 (id-var-name136 value502 w504))
-                                 (r533 (macros-only-env110 r489)))
-                             (if (memv m491 (quote (c)))
-                               (if (memq (quote compile) esew492)
-                                 (let ((e534 (chi-install-global146
-                                               n532
-                                               (chi150
-                                                 e503
-                                                 r533
-                                                 w504
-                                                 mod506))))
+                          e504)
+                         (if (memv type502 (quote (define-syntax-form)))
+                           (let ((n533 (id-var-name137 value503 w505))
+                                 (r534 (macros-only-env111 r490)))
+                             (if (memv m492 (quote (c)))
+                               (if (memq (quote compile) esew493)
+                                 (let ((e535 (chi-install-global147
+                                               n533
+                                               (chi151
+                                                 e504
+                                                 r534
+                                                 w505
+                                                 mod507))))
                                    (begin
-                                     (top-level-eval-hook76 e534 mod506)
-                                     (if (memq (quote load) esew492)
-                                       e534
-                                       (chi-void158))))
-                                 (if (memq (quote load) esew492)
-                                   (chi-install-global146
-                                     n532
-                                     (chi150 e503 r533 w504 mod506))
-                                   (chi-void158)))
-                               (if (memv m491 (quote (c&e)))
-                                 (let ((e535 (chi-install-global146
-                                               n532
-                                               (chi150
-                                                 e503
-                                                 r533
-                                                 w504
-                                                 mod506))))
+                                     (top-level-eval-hook76 e535 mod507)
+                                     (if (memq (quote load) esew493)
+                                       e535
+                                       (chi-void159))))
+                                 (if (memq (quote load) esew493)
+                                   (chi-install-global147
+                                     n533
+                                     (chi151 e504 r534 w505 mod507))
+                                   (chi-void159)))
+                               (if (memv m492 (quote (c&e)))
+                                 (let ((e536 (chi-install-global147
+                                               n533
+                                               (chi151
+                                                 e504
+                                                 r534
+                                                 w505
+                                                 mod507))))
                                    (begin
-                                     (top-level-eval-hook76 e535 mod506)
-                                     e535))
+                                     (top-level-eval-hook76 e536 mod507)
+                                     e536))
                                  (begin
-                                   (if (memq (quote eval) esew492)
+                                   (if (memq (quote eval) esew493)
                                      (top-level-eval-hook76
-                                       (chi-install-global146
-                                         n532
-                                         (chi150 e503 r533 w504 mod506))
-                                       mod506))
-                                   (chi-void158)))))
-                           (if (memv type501 (quote (define-form)))
-                             (let ((n536 (id-var-name136 value502 w504)))
-                               (let ((type537
-                                       (binding-type106
-                                         (lookup111 n536 r489 mod506))))
-                                 (if (memv type537
+                                       (chi-install-global147
+                                         n533
+                                         (chi151 e504 r534 w505 mod507))
+                                       mod507))
+                                   (chi-void159)))))
+                           (if (memv type502 (quote (define-form)))
+                             (let ((n537 (id-var-name137 value503 w505)))
+                               (let ((type538
+                                       (binding-type107
+                                         (lookup112 n537 r490 mod507))))
+                                 (if (memv type538
                                            '(global core macro module-ref))
                                    (begin
                                      (if (if (not (module-local-variable
                                                     (current-module)
-                                                    n536))
+                                                    n537))
                                            (current-module)
                                            #f)
                                        (module-define!
                                          (current-module)
-                                         n536
+                                         n537
                                          #f))
-                                     (let ((x538 (build-global-definition89
-                                                   s505
-                                                   n536
-                                                   (chi150
-                                                     e503
-                                                     r489
-                                                     w504
-                                                     mod506))))
+                                     (let ((x539 (build-global-definition90
+                                                   s506
+                                                   n537
+                                                   (chi151
+                                                     e504
+                                                     r490
+                                                     w505
+                                                     mod507))))
                                        (begin
-                                         (if (eq? m491 (quote c&e))
-                                           (top-level-eval-hook76 x538 mod506))
-                                         x538)))
-                                   (if (memv type537
+                                         (if (eq? m492 (quote c&e))
+                                           (top-level-eval-hook76 x539 mod507))
+                                         x539)))
+                                   (if (memv type538
                                              '(displaced-lexical))
                                      (syntax-violation
                                        #f
                                        "identifier out of context"
-                                       e503
-                                       (wrap142 value502 w504 mod506))
+                                       e504
+                                       (wrap143 value503 w505 mod507))
                                      (syntax-violation
                                        #f
                                        "cannot define keyword at top level"
-                                       e503
-                                       (wrap142 value502 w504 mod506))))))
-                             (let ((x539 (chi-expr151
-                                           type501
-                                           value502
-                                           e503
-                                           r489
-                                           w504
-                                           s505
-                                           mod506)))
+                                       e504
+                                       (wrap143 value503 w505 mod507))))))
+                             (let ((x540 (chi-expr152
+                                           type502
+                                           value503
+                                           e504
+                                           r490
+                                           w505
+                                           s506
+                                           mod507)))
                                (begin
-                                 (if (eq? m491 (quote c&e))
-                                   (top-level-eval-hook76 x539 mod506))
-                                 x539)))))))))))
-           (syntax-type148
-             (lambda (e540 r541 w542 s543 rib544 mod545 for-car?546)
-               (if (symbol? e540)
-                 (let ((n547 (id-var-name136 e540 w542)))
-                   (let ((b548 (lookup111 n547 r541 mod545)))
-                     (let ((type549 (binding-type106 b548)))
-                       (if (memv type549 (quote (lexical)))
+                                 (if (eq? m492 (quote c&e))
+                                   (top-level-eval-hook76 x540 mod507))
+                                 x540)))))))))))
+           (syntax-type149
+             (lambda (e541 r542 w543 s544 rib545 mod546 for-car?547)
+               (if (symbol? e541)
+                 (let ((n548 (id-var-name137 e541 w543)))
+                   (let ((b549 (lookup112 n548 r542 mod546)))
+                     (let ((type550 (binding-type107 b549)))
+                       (if (memv type550 (quote (lexical)))
                          (values
-                           type549
-                           (binding-value107 b548)
-                           e540
-                           w542
-                           s543
-                           mod545)
-                         (if (memv type549 (quote (global)))
-                           (values type549 n547 e540 w542 s543 mod545)
-                           (if (memv type549 (quote (macro)))
-                             (if for-car?546
+                           type550
+                           (binding-value108 b549)
+                           e541
+                           w543
+                           s544
+                           mod546)
+                         (if (memv type550 (quote (global)))
+                           (values type550 n548 e541 w543 s544 mod546)
+                           (if (memv type550 (quote (macro)))
+                             (if for-car?547
                                (values
-                                 type549
-                                 (binding-value107 b548)
-                                 e540
-                                 w542
-                                 s543
-                                 mod545)
-                               (syntax-type148
-                                 (chi-macro153
-                                   (binding-value107 b548)
-                                   e540
-                                   r541
-                                   w542
-                                   rib544
-                                   mod545)
-                                 r541
+                                 type550
+                                 (binding-value108 b549)
+                                 e541
+                                 w543
+                                 s544
+                                 mod546)
+                               (syntax-type149
+                                 (chi-macro154
+                                   (binding-value108 b549)
+                                   e541
+                                   r542
+                                   w543
+                                   rib545
+                                   mod546)
+                                 r542
                                  '(())
-                                 s543
-                                 rib544
-                                 mod545
+                                 s544
+                                 rib545
+                                 mod546
                                  #f))
                              (values
-                               type549
-                               (binding-value107 b548)
-                               e540
-                               w542
-                               s543
-                               mod545)))))))
-                 (if (pair? e540)
-                   (let ((first550 (car e540)))
+                               type550
+                               (binding-value108 b549)
+                               e541
+                               w543
+                               s544
+                               mod546)))))))
+                 (if (pair? e541)
+                   (let ((first551 (car e541)))
                      (call-with-values
                        (lambda ()
-                         (syntax-type148
-                           first550
-                           r541
-                           w542
-                           s543
-                           rib544
-                           mod545
+                         (syntax-type149
+                           first551
+                           r542
+                           w543
+                           s544
+                           rib545
+                           mod546
                            #t))
-                       (lambda (ftype551 fval552 fe553 fw554 fs555 fmod556)
-                         (if (memv ftype551 (quote (lexical)))
+                       (lambda (ftype552 fval553 fe554 fw555 fs556 fmod557)
+                         (if (memv ftype552 (quote (lexical)))
                            (values
                              'lexical-call
-                             fval552
-                             e540
-                             w542
-                             s543
-                             mod545)
-                           (if (memv ftype551 (quote (global)))
+                             fval553
+                             e541
+                             w543
+                             s544
+                             mod546)
+                           (if (memv ftype552 (quote (global)))
                              (values
                                'global-call
-                               (make-syntax-object97 fval552 w542 fmod556)
-                               e540
-                               w542
-                               s543
-                               mod545)
-                             (if (memv ftype551 (quote (macro)))
-                               (syntax-type148
-                                 (chi-macro153
-                                   fval552
-                                   e540
-                                   r541
-                                   w542
-                                   rib544
-                                   mod545)
-                                 r541
+                               (make-syntax-object98 fval553 w543 fmod557)
+                               e541
+                               w543
+                               s544
+                               mod546)
+                             (if (memv ftype552 (quote (macro)))
+                               (syntax-type149
+                                 (chi-macro154
+                                   fval553
+                                   e541
+                                   r542
+                                   w543
+                                   rib545
+                                   mod546)
+                                 r542
                                  '(())
-                                 s543
-                                 rib544
-                                 mod545
-                                 for-car?546)
-                               (if (memv ftype551 (quote (module-ref)))
+                                 s544
+                                 rib545
+                                 mod546
+                                 for-car?547)
+                               (if (memv ftype552 (quote (module-ref)))
                                  (call-with-values
-                                   (lambda () (fval552 e540))
-                                   (lambda (sym557 mod558)
-                                     (syntax-type148
-                                       sym557
-                                       r541
-                                       w542
-                                       s543
-                                       rib544
-                                       mod558
-                                       for-car?546)))
-                                 (if (memv ftype551 (quote (core)))
+                                   (lambda () (fval553 e541))
+                                   (lambda (sym558 mod559)
+                                     (syntax-type149
+                                       sym558
+                                       r542
+                                       w543
+                                       s544
+                                       rib545
+                                       mod559
+                                       for-car?547)))
+                                 (if (memv ftype552 (quote (core)))
                                    (values
                                      'core-form
-                                     fval552
-                                     e540
-                                     w542
-                                     s543
-                                     mod545)
-                                   (if (memv ftype551 (quote (local-syntax)))
+                                     fval553
+                                     e541
+                                     w543
+                                     s544
+                                     mod546)
+                                   (if (memv ftype552 (quote (local-syntax)))
                                      (values
                                        'local-syntax-form
-                                       fval552
-                                       e540
-                                       w542
-                                       s543
-                                       mod545)
-                                     (if (memv ftype551 (quote (begin)))
+                                       fval553
+                                       e541
+                                       w543
+                                       s544
+                                       mod546)
+                                     (if (memv ftype552 (quote (begin)))
                                        (values
                                          'begin-form
                                          #f
-                                         e540
-                                         w542
-                                         s543
-                                         mod545)
-                                       (if (memv ftype551 (quote (eval-when)))
+                                         e541
+                                         w543
+                                         s544
+                                         mod546)
+                                       (if (memv ftype552 (quote (eval-when)))
                                          (values
                                            'eval-when-form
                                            #f
-                                           e540
-                                           w542
-                                           s543
-                                           mod545)
-                                         (if (memv ftype551 (quote (define)))
-                                           ((lambda (tmp559)
-                                              ((lambda (tmp560)
-                                                 (if (if tmp560
-                                                       (apply (lambda (_561
-                                                                       name562
-                                                                       val563)
-                                                                (id?114
-                                                                  name562))
-                                                              tmp560)
+                                           e541
+                                           w543
+                                           s544
+                                           mod546)
+                                         (if (memv ftype552 (quote (define)))
+                                           ((lambda (tmp560)
+                                              ((lambda (tmp561)
+                                                 (if (if tmp561
+                                                       (apply (lambda (_562
+                                                                       name563
+                                                                       val564)
+                                                                (id?115
+                                                                  name563))
+                                                              tmp561)
                                                        #f)
-                                                   (apply (lambda (_564
-                                                                   name565
-                                                                   val566)
+                                                   (apply (lambda (_565
+                                                                   name566
+                                                                   val567)
                                                             (values
                                                               'define-form
-                                                              name565
-                                                              val566
-                                                              w542
-                                                              s543
-                                                              mod545))
-                                                          tmp560)
-                                                   ((lambda (tmp567)
-                                                      (if (if tmp567
-                                                            (apply (lambda 
(_568
-                                                                            
name569
-                                                                            
args570
-                                                                            
e1571
-                                                                            
e2572)
-                                                                     (if 
(id?114
-                                                                           
name569)
-                                                                       
(valid-bound-ids?139
-                                                                         
(lambda-var-list162
-                                                                           
args570))
+                                                              name566
+                                                              val567
+                                                              w543
+                                                              s544
+                                                              mod546))
+                                                          tmp561)
+                                                   ((lambda (tmp568)
+                                                      (if (if tmp568
+                                                            (apply (lambda 
(_569
+                                                                            
name570
+                                                                            
args571
+                                                                            
e1572
+                                                                            
e2573)
+                                                                     (if 
(id?115
+                                                                           
name570)
+                                                                       
(valid-bound-ids?140
+                                                                         
(lambda-var-list163
+                                                                           
args571))
                                                                        #f))
-                                                                   tmp567)
+                                                                   tmp568)
                                                             #f)
-                                                        (apply (lambda (_573
-                                                                        name574
-                                                                        args575
-                                                                        e1576
-                                                                        e2577)
+                                                        (apply (lambda (_574
+                                                                        name575
+                                                                        args576
+                                                                        e1577
+                                                                        e2578)
                                                                  (values
                                                                    'define-form
-                                                                   (wrap142
-                                                                     name574
-                                                                     w542
-                                                                     mod545)
-                                                                   (cons 
'#(syntax-object
-                                                                            
lambda
-                                                                            
((top)
-                                                                             
#(ribcage
-                                                                               
#(_
-                                                                               
  name
-                                                                               
  args
-                                                                               
  e1
-                                                                               
  e2)
-                                                                               
#((top)
-                                                                               
  (top)
-                                                                               
  (top)
-                                                                               
  (top)
-                                                                               
  (top))
-                                                                               
#("i"
-                                                                               
  "i"
-                                                                               
  "i"
-                                                                               
  "i"
-                                                                               
  "i"))
-                                                                             
#(ribcage
-                                                                               
()
-                                                                               
()
-                                                                               
())
-                                                                             
#(ribcage
-                                                                               
()
-                                                                               
()
-                                                                               
())
-                                                                             
#(ribcage
-                                                                               
#(ftype
-                                                                               
  fval
-                                                                               
  fe
-                                                                               
  fw
-                                                                               
  fs
-                                                                               
  fmod)
-                                                                               
#((top)
-                                                                               
  (top)
-                                                                               
  (top)
-                                                                               
  (top)
-                                                                               
  (top)
-                                                                               
  (top))
-                                                                               
#("i"
-                                                                               
  "i"
-                                                                               
  "i"
-                                                                               
  "i"
-                                                                               
  "i"
-                                                                               
  "i"))
-                                                                             
#(ribcage
-                                                                               
()
-                                                                               
()
-                                                                               
())
-                                                                             
#(ribcage
-                                                                               
#(first)
-                                                                               
#((top))
-                                                                               
#("i"))
-                                                                             
#(ribcage
-                                                                               
()
-                                                                               
()
-                                                                               
())
-                                                                             
#(ribcage
-                                                                               
()
-                                                                               
()
-                                                                               
())
-                                                                             
#(ribcage
-                                                                               
()
-                                                                               
()
-                                                                               
())
-                                                                             
#(ribcage
-                                                                               
#(e
-                                                                               
  r
-                                                                               
  w
-                                                                               
  s
-                                                                               
  rib
-                                                                               
  mod
-                                                                               
  for-car?)
-                                                                               
#((top)
-                                                                               
  (top)
-                                                                               
  (top)
-                                                                               
  (top)
-                                                                               
  (top)
-                                                                               
  (top)
-                                                                               
  (top))
-                                                                               
#("i"
-                                                                               
  "i"
-                                                                               
  "i"
-                                                                               
  "i"
-                                                                               
  "i"
-                                                                               
  "i"
-                                                                               
  "i"))
-                                                                             
#(ribcage
-                                                                               
(lambda-var-list
-                                                                               
  gen-var
-                                                                               
  strip
-                                                                               
  ellipsis?
-                                                                               
  chi-void
-                                                                               
  eval-local-transformer
-                                                                               
  chi-local-syntax
-                                                                               
  chi-lambda-clause
-                                                                               
  chi-body
-                                                                               
  chi-macro
-                                                                               
  chi-application
-                                                                               
  chi-expr
-                                                                               
  chi
-                                                                               
  chi-top
-                                                                               
  syntax-type
-                                                                               
  chi-when-list
-                                                                               
  chi-install-global
-                                                                               
  chi-top-sequence
-                                                                               
  chi-sequence
-                                                                               
  source-wrap
-                                                                               
  wrap
-                                                                               
  bound-id-member?
-                                                                               
  distinct-bound-ids?
-                                                                               
  valid-bound-ids?
-                                                                               
  bound-id=?
-                                                                               
  free-id=?
-                                                                               
  id-var-name
-                                                                               
  same-marks?
-                                                                               
  join-marks
-                                                                               
  join-wraps
-                                                                               
  smart-append
-                                                                               
  make-binding-wrap
-                                                                               
  extend-ribcage!
-                                                                               
  make-empty-ribcage
-                                                                               
  new-mark
-                                                                               
  anti-mark
-                                                                               
  the-anti-mark
-                                                                               
  top-marked?
-                                                                               
  top-wrap
-                                                                               
  empty-wrap
-                                                                               
  set-ribcage-labels!
-                                                                               
  set-ribcage-marks!
-                                                                               
  set-ribcage-symnames!
-                                                                               
  ribcage-labels
-                                                                               
  ribcage-marks
-                                                                               
  ribcage-symnames
-                                                                               
  ribcage?
-                                                                               
  make-ribcage
-                                                                               
  gen-labels
-                                                                               
  gen-label
-                                                                               
  make-rename
-                                                                               
  rename-marks
-                                                                               
  rename-new
-                                                                               
  rename-old
-                                                                               
  subst-rename?
-                                                                               
  wrap-subst
-                                                                               
  wrap-marks
-                                                                               
  make-wrap
-                                                                               
  id-sym-name&marks
-                                                                               
  id-sym-name
-                                                                               
  id?
-                                                                               
  nonsymbol-id?
-                                                                               
  global-extend
-                                                                               
  lookup
-                                                                               
  macros-only-env
-                                                                               
  extend-var-env
-                                                                               
  extend-env
-                                                                               
  null-env
-                                                                               
  binding-value
-                                                                               
  binding-type
-                                                                               
  make-binding
-                                                                               
  arg-check
-                                                                               
  source-annotation
-                                                                               
  no-source
-                                                                               
  set-syntax-object-module!
-                                                                               
  set-syntax-object-wrap!
-                                                                               
  set-syntax-object-expression!
-                                                                               
  syntax-object-module
-                                                                               
  syntax-object-wrap
-                                                                               
  syntax-object-expression
-                                                                               
  syntax-object?
-                                                                               
  make-syntax-object
-                                                                               
  build-lexical-var
-                                                                               
  build-letrec
-                                                                               
  build-named-let
-                                                                               
  build-let
-                                                                               
  build-sequence
-                                                                               
  build-data
-                                                                               
  build-primref
-                                                                               
  build-lambda
-                                                                               
  build-global-definition
-                                                                               
  maybe-name-value!
-                                                                               
  build-global-assignment
-                                                                               
  build-global-reference
-                                                                               
  analyze-variable
-                                                                               
  build-lexical-assignment
-                                                                               
  build-lexical-reference
-                                                                               
  build-conditional
-                                                                               
  build-application
-                                                                               
  build-void
-                                                                               
  get-global-definition-hook
-                                                                               
  put-global-definition-hook
-                                                                               
  gensym-hook
-                                                                               
  local-eval-hook
-                                                                               
  top-level-eval-hook
-                                                                               
  fx<
-                                                                               
  fx=
-                                                                               
  fx-
-                                                                               
  fx+
-                                                                               
  *mode*
-                                                                               
  noexpand)
-                                                                               
((top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top)
-                                                                               
 (top))
-                                                                               
("i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"
-                                                                               
 "i"))
-                                                                             
#(ribcage
-                                                                               
(define-structure
-                                                                               
  and-map*)
-                                                                               
((top)
-                                                                               
 (top))
-                                                                               
("i"
-                                                                               
 "i")))
-                                                                            
(hygiene
-                                                                              
guile))
-                                                                         
(wrap142
-                                                                           
(cons args575
-                                                                               
  (cons e1576
-                                                                               
        e2577))
-                                                                           w542
-                                                                           
mod545))
+                                                                   (wrap143
+                                                                     name575
+                                                                     w543
+                                                                     mod546)
+                                                                   
(decorate-source80
+                                                                     (cons 
'#(syntax-object
+                                                                              
lambda
+                                                                              
((top)
+                                                                               
#(ribcage
+                                                                               
  #(_
+                                                                               
    name
+                                                                               
    args
+                                                                               
    e1
+                                                                               
    e2)
+                                                                               
  #((top)
+                                                                               
    (top)
+                                                                               
    (top)
+                                                                               
    (top)
+                                                                               
    (top))
+                                                                               
  #("i"
+                                                                               
    "i"
+                                                                               
    "i"
+                                                                               
    "i"
+                                                                               
    "i"))
+                                                                               
#(ribcage
+                                                                               
  ()
+                                                                               
  ()
+                                                                               
  ())
+                                                                               
#(ribcage
+                                                                               
  ()
+                                                                               
  ()
+                                                                               
  ())
+                                                                               
#(ribcage
+                                                                               
  #(ftype
+                                                                               
    fval
+                                                                               
    fe
+                                                                               
    fw
+                                                                               
    fs
+                                                                               
    fmod)
+                                                                               
  #((top)
+                                                                               
    (top)
+                                                                               
    (top)
+                                                                               
    (top)
+                                                                               
    (top)
+                                                                               
    (top))
+                                                                               
  #("i"
+                                                                               
    "i"
+                                                                               
    "i"
+                                                                               
    "i"
+                                                                               
    "i"
+                                                                               
    "i"))
+                                                                               
#(ribcage
+                                                                               
  ()
+                                                                               
  ()
+                                                                               
  ())
+                                                                               
#(ribcage
+                                                                               
  #(first)
+                                                                               
  #((top))
+                                                                               
  #("i"))
+                                                                               
#(ribcage
+                                                                               
  ()
+                                                                               
  ()
+                                                                               
  ())
+                                                                               
#(ribcage
+                                                                               
  ()
+                                                                               
  ()
+                                                                               
  ())
+                                                                               
#(ribcage
+                                                                               
  ()
+                                                                               
  ()
+                                                                               
  ())
+                                                                               
#(ribcage
+                                                                               
  #(e
+                                                                               
    r
+                                                                               
    w
+                                                                               
    s
+                                                                               
    rib
+                                                                               
    mod
+                                                                               
    for-car?)
+                                                                               
  #((top)
+                                                                               
    (top)
+