Arrange to convert command-line arguments from the right encoding.
authorLudovic Courtès <ludo@gnu.org>
Thu, 15 Dec 2011 00:23:23 +0000 (01:23 +0100)
committerLudovic Courtès <ludo@gnu.org>
Thu, 15 Dec 2011 00:31:23 +0000 (01:31 +0100)
commited4c3739668b4b111b38555b8bc101cb74c87c1c
treebebdd170764e27c853187118cf36d79fec78697c
parentc2c2b5a49b1ce37a42417037c3515864a808e53b
Arrange to convert command-line arguments from the right encoding.

This is a temporary workaround for the 2.0 stable series.  The next
stable series should have an implicit `setlocale (LC_ALL, "")' call,
which will make this unnecessary.

* libguile/feature.c (progargs_fluid): Rename to...
  (scm_program_arguments_fluid): ... this.  Update users.

* libguile/feature.h (scm_program_arguments_fluid): New internal
  declaration.

* libguile/init.c (invoke_main_func): Call
  `scm_i_set_boot_program_arguments' instead of
  `scm_set_program_arguments'.

* libguile/script.c (locale_arguments_to_string_list,
  scm_i_set_boot_program_arguments): New functions.
  (scm_compile_shell_switches): Use `locale_arguments_to_string_list'.

* libguile/script.h (scm_i_set_boot_program_arguments): New internal
  declaration.

* test-suite/standalone/Makefile.am (check_SCRIPTS, TESTS): Add
  `test-command-line-encoding'.
* test-suite/standalone/test-command-line-encoding: New file.
libguile/feature.c
libguile/feature.h
libguile/init.c
libguile/script.c
libguile/script.h
test-suite/standalone/Makefile.am
test-suite/standalone/test-command-line-encoding [new file with mode: 0755]