title: Oniguruma 1.1.0 not compatible with Ruby 2.3.1
body: <p>I installed <code>ruby 2.3.1p112 (2016-04-26 revision 54768) [x86_64-linux]</code> and <code>rails 4.2.6</code>. I wrote a <code>Gemfile</code> which has all bundles.<br>
  <strong><code>Gemfile:</code></strong>    </p>
  
  <pre><code>source 'http://rubygems.org'
  source 'http://gems.github.com'
  
  #New gem files from Ajay
  #gem 'activesupport', '4.2.6'
  
  gem 'rails', '4.2.6'
  
  gem 'rake','0.8.7'
  
  # Bundle edge Rails instead:
  # gem 'rails', :git =&gt; 'git://github.com/rails/rails.git'
  
  #gem 'mysql2', '0.2.6'
  gem 'mysql2', '0.3.20'
  
  # GUID generator
  gem 'uuidtools', '2.1.2'
  
  # Paperclip: for image resizing
  gem 'paperclip', '2.4'
  
  # Delayed job
  gem 'delayed_job', '4.1.2'
  
  # Typus, admin interface
  gem 'typus', '3.0.2'
  
  # set attribute value to nil if blank
  gem "nilify_blanks", '1.0.0'
  
  # ssl gem
  gem "bartt-ssl_requirement", "~&gt; 1.2.7", :require =&gt; 'ssl_requirement'
  
  # for social login
  gem 'omniauth', '1.3.1'
  
  # to detect user location
  gem 'geocoder', '1.1.0'
  
  # use to sanitize html
  gem 'sanitize', '4.0.1'
  
  # captcha for registration
  gem 'recaptcha', '0.3.1', :require =&gt; "recaptcha/rails"
  
  # base 32
  gem 'base32', '0.1.3'
  
  # amazon s3
  gem 'aws-s3', '0.6.2'
  
  #json
  gem 'json', '1.8.3'
  
  # pagination
  gem 'will_paginate', '3.0.pre2'
  
  # jammit for asset packaging
  gem 'jammit', '0.6.3'
  
  gem 'oniguruma'
  
  # Use unicorn as the web server
  # gem 'unicorn'
  
  # Deploy with Capistrano
  # gem 'capistrano'
  
  # To use debugger (ruby-debug for Ruby 1.8.7+, ruby-debug19 for Ruby 1.9.2+)
  # gem 'ruby-debug'
  # gem 'ruby-debug19'
  
  # Bundle the extra gems:
  # gem 'bj'
  # gem 'nokogiri', "1.4.4.1"
  # gem 'sqlite3-ruby', :require =&gt; 'sqlite3'
  # gem 'aws-s3', :require =&gt; 'aws/s3'
  
  # Bundle gems for the local environment. Make sure to
  # put test-only gems in this group so their generators
  # and rake tasks are available in development mode:
  # group :development, :test do
  #   gem 'webrat'
  # end
  
  gem "fb_graph", "1.9.5"
  
  gem 'sitemap_generator', '2.1.8'
  
  gem 'fastercsv', "1.5.5"
  
  # to make it the same prior to 3.018 upgrade
  
  gem 'addressable', "2.2.4"
  gem 'arel', "6.0"
  gem 'attr_required', '0.0.3'
  
  gem 'cocaine', "0.2.0"
  gem 'daemons', "1.1.0"
  
  gem 'httpclient', '2.2.1'
  gem 'i18n', '~&gt; 0.7'
  
  gem 'mail', '2.5.4'
  
  gem 'mime-types', '1.16'
  gem 'multipart-post', '1.1.0'
  gem 'nokogiri', '~&gt; 1.6.0'
  gem 'oauth', '0.4.4'
  gem 'open4', '1.2.0'
  gem 'polyglot', '0.3.1'
  gem 'pyu-ruby-sasl', '0.0.3.2'
  gem 'rack', '1.6'
  gem 'rack-mount', '0.6.13'
  gem 'rack-oauth2', '0.9.2'
  gem 'rack-test', '~&gt; 0.6.2'
  gem 'rest-client', '1.6.1'
  gem 'ruby-openid', '2.1.8'
  gem 'treetop', '1.4.9'
  gem 'tzinfo', '1.1'
  gem 'xml-simple', '1.0.15'
  </code></pre>
  
  <p>But when I attempt to install oniguruma, I get the following error:  </p>
  
  <pre><code>Installing oniguruma 1.1.0 with native extensions
  
  Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
  
      current directory: /root/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/oniguruma-1.1.0/ext
  /root/.rbenv/versions/2.3.1/bin/ruby -r ./siteconf20160614-24717-1q0k49a.rb extconf.rb
  checking for main() in -lonig... yes
  creating Makefile
  
  To see why this extension failed to compile, please check the mkmf.log which can be found here:
  
    /root/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/extensions/x86_64-linux/2.3.0-static/oniguruma-1.1.0/mkmf.log
  
  current directory: /root/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/oniguruma-1.1.0/ext
  make "DESTDIR=" clean
  
  current directory: /root/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/oniguruma-1.1.0/ext
  make "DESTDIR="
  compiling oregexp.c
  oregexp.c: In function ‘name_callback’:
  oregexp.c:111:7: warning: pointer targets in passing argument 1 of ‘strlen’ differ in signedness [-Wpointer-sign]
         rb_hash_aset( nameHash, ID2SYM(rb_intern(name)), INT2FIX( gn ) );
         ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/defines.h:45:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:36,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /usr/include/string.h:399:15: note: expected ‘const char *’ but argument is of type ‘const OnigUChar *’
   extern size_t strlen (const char *__s)
                 ^
  oregexp.c:111:7: warning: pointer targets in passing argument 1 of ‘rb_intern2’ differ in signedness [-Wpointer-sign]
         rb_hash_aset( nameHash, ID2SYM(rb_intern(name)), INT2FIX( gn ) );
         ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33:0,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1711:4: note: expected ‘const char *’ but argument is of type ‘const OnigUChar *’
   ID rb_intern2(const char*, long);
      ^
  oregexp.c:111:7: warning: pointer targets in passing argument 1 of ‘rb_intern’ differ in signedness [-Wpointer-sign]
         rb_hash_aset( nameHash, ID2SYM(rb_intern(name)), INT2FIX( gn ) );
         ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33:0,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1710:4: note: expected ‘const char *’ but argument is of type ‘const OnigUChar *’
   ID rb_intern(const char*);
      ^
  oregexp.c: In function ‘oregexp_initialize’:
  oregexp.c:123:41: error: ‘struct RString’ has no member named ‘ptr’
      UChar* pat_ptr = RSTRING(pattern_str)-&gt;ptr;
                                           ^
  oregexp.c:124:38: error: ‘struct RString’ has no member named ‘len’
      int pat_len = RSTRING(pattern_str)-&gt;len;
                                        ^
  oregexp.c:138:7: warning: pointer targets in passing argument 1 of ‘onig_error_code_to_str’ differ in signedness [-Wpointer-sign]
         onig_error_code_to_str(s, r, &amp;einfo);
         ^
  In file included from oregexp.c:2:0:
  /usr/local/include/oniguruma.h:721:5: note: expected ‘OnigUChar *’ but argument is of type ‘char *’
   int onig_error_code_to_str PV_((OnigUChar* s, int err_code, ...));
       ^
  oregexp.c: In function ‘oregexp_make_match_data’:
  oregexp.c:156:5: warning: passing argument 1 of ‘rb_obj_setup’ makes integer from pointer without a cast [enabled by default]
       OBJSETUP(match, rb_cMatch, T_MATCH);
       ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33:0,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:771:7: note: expected ‘VALUE’ but argument is of type ‘struct RMatch *’
   VALUE rb_obj_setup(VALUE obj, VALUE klass, VALUE type);
         ^
  oregexp.c:176:9: warning: passing argument 2 of ‘onig_foreach_name’ from incompatible pointer type [enabled by default]
           onig_foreach_name(oregexp-&gt;reg, name_callback, &amp;packet);
           ^
  In file included from oregexp.c:2:0:
  /usr/local/include/oniguruma.h:760:5: note: expected ‘int (*)(const OnigUChar *, const OnigUChar *, int,  int *, struct OnigRegexType *, void *)’ but argument is of type ‘int (*)(const OnigUChar *, const OnigUChar *, int,  int *, struct regex_t *, struct callback_packet *)’
   int onig_foreach_name P_((OnigRegex reg, int (*func)(const OnigUChar*, const OnigUChar*,int,int*,OnigRegex,void*), void* arg));
       ^
  oregexp.c: In function ‘oregexp_match’:
  oregexp.c:211:7: warning: statement with no effect [-Wunused-value]
         exit;
         ^
  oregexp.c:215:40: error: ‘struct RString’ has no member named ‘ptr’
      UChar* str_ptr = RSTRING(string_str)-&gt;ptr;
                                          ^
  oregexp.c:216:37: error: ‘struct RString’ has no member named ‘len’
      int str_len = RSTRING(string_str)-&gt;len;
                                       ^
  oregexp.c:244:7: warning: pointer targets in passing argument 1 of ‘onig_error_code_to_str’ differ in signedness [-Wpointer-sign]
         onig_error_code_to_str(s, r);
         ^
  In file included from oregexp.c:2:0:
  /usr/local/include/oniguruma.h:721:5: note: expected ‘OnigUChar *’ but argument is of type ‘char *’
   int onig_error_code_to_str PV_((OnigUChar* s, int err_code, ...));
       ^
  oregexp.c: In function ‘oregexp_append_replacement’:
  oregexp.c:267:52: error: ‘struct RString’ has no member named ‘len’
       int32_t  replacementLength = RSTRING(repl_text)-&gt;len;
                                                      ^
  oregexp.c:268:51: error: ‘struct RString’ has no member named ‘ptr’
       UChar    *replacementText = RSTRING(repl_text)-&gt;ptr;
                                                     ^
  oregexp.c:277:34: error: ‘struct RString’ has no member named ‘ptr’
       matchText = RSTRING(src_text)-&gt;ptr;
                                    ^
  oregexp.c:278:34: error: ‘struct RString’ has no member named ‘len’
       matchLen  = RSTRING(src_text)-&gt;len;
                                    ^
  oregexp.c:293:6: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
        rb_str_buf_cat( ret, replacementText+replIdx-c_len, c_len);
        ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c:297:17: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
                   rb_str_buf_cat(ret, replacementText+(replIdx-c_len), c_len);
                   ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c:328:5: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
       rb_str_buf_cat(ret, matchText+region-&gt;beg[0], region-&gt;end[0] - region-&gt;beg[0]);
       ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘const OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c:332:33: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
                                   rb_str_buf_cat(ret, matchText, region-&gt;beg[0]);
                                   ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘const OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c:336:5: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
       rb_str_buf_cat(ret, matchText+region-&gt;end[0], matchLen - region-&gt;end[0]);
       ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘const OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c:341:5: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
       rb_str_buf_cat(ret, replacementText+replIdx, c_len);
       ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c:350:10: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
            rb_str_buf_cat(ret, matchText+g_start, g_end-g_start);
            ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘const OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c:371:8: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
          rb_str_buf_cat(ret, replacementText+(replIdx-p_len), p_len+c_len);
          ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c:379:10: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
            region-&gt;end[groupNum]-region-&gt;beg[groupNum]);
            ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘const OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c:385:33: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
                                   rb_str_buf_cat(ret, replacementText+(replIdx-p_len), p_len+c_len);
                                   ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c:392:9: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
           rb_str_buf_cat(ret, matchText+region-&gt;beg[groupNum], region-&gt;end[groupNum]-region-&gt;beg[groupNum]);
           ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘const OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c: In function ‘str_mod_check’:
  oregexp.c:405:16: error: ‘struct RString’ has no member named ‘ptr’
    if (RSTRING(s)-&gt;ptr != p || RSTRING(s)-&gt;len != len) {
                  ^
  oregexp.c:405:40: error: ‘struct RString’ has no member named ‘len’
    if (RSTRING(s)-&gt;ptr != p || RSTRING(s)-&gt;len != len) {
                                          ^
  oregexp.c: In function ‘oregexp_gsub’:
  oregexp.c:444:41: error: ‘struct RString’ has no member named ‘ptr’
       UChar* str_ptr = RSTRING(string_str)-&gt;ptr;
                                           ^
  oregexp.c:445:38: error: ‘struct RString’ has no member named ‘len’
       int str_len = RSTRING(string_str)-&gt;len;
                                        ^
  oregexp.c:462:2: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
    rb_str_buf_cat(buf, str_ptr+prev_end, beg-prev_end);
    ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c:484:12: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
              rb_str_buf_cat( buf, str_ptr+end, len);
              ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c:491:5: warning: pointer targets in passing argument 2 of ‘rb_str_cat’ differ in signedness [-Wpointer-sign]
       rb_str_buf_cat( buf, str_ptr+end, str_len - end);
       ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1992:0,
                   from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/intern.h:758:7: note: expected ‘const char *’ but argument is of type ‘OnigUChar *’
   VALUE rb_str_cat(VALUE, const char*, long);
         ^
  oregexp.c: In function ‘oregexp_safe_gsub’:
  oregexp.c:527:9: warning: passing argument 3 of ‘rb_ensure’ from incompatible pointer type [enabled by default]
           return rb_ensure( oregexp_packed_gsub, (VALUE)&amp;call_args, oregexp_cleanup_region, (VALUE)region);
           ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33:0,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1840:7: note: expected ‘VALUE (*)()’ but argument is of type ‘void (*)(struct OnigRegion *)’
   VALUE rb_ensure(VALUE(*)(ANYARGS),VALUE,VALUE(*)(ANYARGS),VALUE);
         ^
  oregexp.c: In function ‘oregexp_scan’:
  oregexp.c:614:41: error: ‘struct RString’ has no member named ‘ptr’
       UChar* str_ptr = RSTRING(string_str)-&gt;ptr;
                                           ^
  oregexp.c:615:38: error: ‘struct RString’ has no member named ‘len’
       int str_len = RSTRING(string_str)-&gt;len;
                                        ^
  oregexp.c: In function ‘oregexp_m_scan’:
  oregexp.c:671:5: warning: passing argument 3 of ‘rb_ensure’ from incompatible pointer type [enabled by default]
       return rb_ensure( oregexp_packed_scan, (VALUE)&amp;call_args, oregexp_cleanup_region, (VALUE)region);
       ^
  In file included from /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby.h:33:0,
                   from oregexp.c:1:
  /root/.rbenv/versions/2.3.1/include/ruby-2.3.0/ruby/ruby.h:1840:7: note: expected ‘VALUE (*)()’ but argument is of type ‘void (*)(struct OnigRegion *)’
   VALUE rb_ensure(VALUE(*)(ANYARGS),VALUE,VALUE(*)(ANYARGS),VALUE);
         ^
  make: *** [oregexp.o] Error 1
  
  make failed, exit code 2
  
  Gem files will remain installed in /root/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/oniguruma-1.1.0 for inspection.
  Results logged to /root/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/extensions/x86_64-linux/2.3.0-static/oniguruma-1.1.0/gem_make.out  
  </code></pre>
  
  <p>I tried <a href="https://github.com/kkos/oniguruma" rel="nofollow">to compile my own oniguruma.</a> But it failed. How can I install oniguruma 1.1.0 in <code>Ruby 2.3.1</code> and <code>rails 4.2.6</code>?  </p>
  
  <p><strong>EDIT :</strong><br>
  I know that oniguruma is a standard in <code>Ruby 1.9.x</code>. Is it a standard in <code>Ruby 2.3.x</code>? If not, then how to install the compatible version of oniguruma? </p>