Project

General

Profile

Actions

Bug #10572

closed

configure with custom ruby-version does not work

Added by vo.x (Vit Ondruch) over 9 years ago. Updated over 9 years ago.

Status:
Closed
Assignee:
-
Target version:
-
ruby -v:
ruby 2.2.0preview2 (2014-11-28 trunk 48628) [x86_64-linux]
[ruby-core:66724]

Description

$ configure --with-ruby-version=foo
...
snip
...

$ make
...
snip
...

In file included from loadpath.c:12:0:
verconf.h:3:28: warning: missing terminating " character
 #define RUBY_LIB_VERSION  \"foo\"
                            ^
loadpath.c:41:1: error: stray '\' in program
 typedef char ruby_lib_version_string[(int)sizeof(RUBY_LIB_VERSION) - 2];
 ^
loadpath.c:41:51: warning: missing terminating " character
 typedef char ruby_lib_version_string[(int)sizeof(RUBY_LIB_VERSION) - 2];
                                                   ^
loadpath.c:41:1: error: missing terminating " character
 typedef char ruby_lib_version_string[(int)sizeof(RUBY_LIB_VERSION) - 2];
 ^
loadpath.c:59:12: error: expected ')' before 'ruby_exec_prefix'
 const char ruby_exec_prefix[] = RUBY_EXEC_PREFIX;
            ^
loadpath.c:68:5: error: stray '\' in program
     RUBY_SITE_LIB2 "\0"
     ^
loadpath.c:68:5: error: stray '\' in program
loadpath.c:68:51: warning: missing terminating " character
     RUBY_SITE_LIB2 "\0"
                                                   ^
loadpath.c:68:5: error: missing terminating " character
     RUBY_SITE_LIB2 "\0"
     ^
loadpath.c:72:5: error: stray '\' in program
     RUBY_SITE_ARCH_LIB_FOR(RUBY_SITEARCH) "\0"
     ^
loadpath.c:72:5: error: stray '\' in program
loadpath.c:72:68: warning: missing terminating " character
     RUBY_SITE_ARCH_LIB_FOR(RUBY_SITEARCH) "\0"
                                                                    ^
loadpath.c:72:5: error: missing terminating " character
     RUBY_SITE_ARCH_LIB_FOR(RUBY_SITEARCH) "\0"
     ^
loadpath.c:77:5: error: stray '\' in program
     RUBY_VENDOR_LIB2 "\0"
     ^
loadpath.c:77:5: error: stray '\' in program
loadpath.c:77:53: warning: missing terminating " character
     RUBY_VENDOR_LIB2 "\0"
                                                     ^
loadpath.c:77:5: error: missing terminating " character
     RUBY_VENDOR_LIB2 "\0"
     ^
loadpath.c:81:5: error: stray '\' in program
     RUBY_VENDOR_ARCH_LIB_FOR(RUBY_SITEARCH) "\0"
     ^
loadpath.c:81:5: error: stray '\' in program
loadpath.c:81:70: warning: missing terminating " character
     RUBY_VENDOR_ARCH_LIB_FOR(RUBY_SITEARCH) "\0"
                                                                      ^
loadpath.c:81:5: error: missing terminating " character
     RUBY_VENDOR_ARCH_LIB_FOR(RUBY_SITEARCH) "\0"
     ^
loadpath.c:85:5: error: stray '\' in program
     RUBY_LIB "\0"
     ^
loadpath.c:85:5: error: stray '\' in program
loadpath.c:85:38: warning: missing terminating " character
     RUBY_LIB "\0"
                                      ^
loadpath.c:85:5: error: missing terminating " character
     RUBY_LIB "\0"
     ^
loadpath.c:89:5: error: stray '\' in program
     RUBY_ARCH_LIB_FOR(RUBY_ARCH) "\0"
     ^
loadpath.c:89:5: error: stray '\' in program
loadpath.c:89:55: warning: missing terminating " character
     RUBY_ARCH_LIB_FOR(RUBY_ARCH) "\0"
                                                       ^
loadpath.c:89:5: error: missing terminating " character
     RUBY_ARCH_LIB_FOR(RUBY_ARCH) "\0"
     ^
Makefile:349: recipe for target 'loadpath.o' failed

The attached patch fix the issue for me (although I know there were some back and forth with the quotes before [1])

[1] https://github.com/ruby/ruby/commit/f13a0a4ddaad8131e9fe0a4e74108578d8a098a3


Files

Updated by nobu (Nobuyoshi Nakada) over 9 years ago

  • % Done changed from 0 to 100
  • Status changed from Open to Closed

Applied in changeset r48723.


configure.in: fix --with-ruby-version [ci skip]

  • configure.in (RUBY_LIB_VERSION): Fix --with-ruby-version
    configuration option. get rid of quoting in config.status.
  • template/verconf.h.tmpl: quote RUBY_LIB_VERSION here.
    [ruby-core:66724] [Bug #10572]
Actions

Also available in: Atom PDF

Like0
Like0