Skip to content

Update jnr-constants for fixes after the updated generation logic#5316

Merged
headius merged 7 commits intojruby:masterfrom
headius:update-jnr-constants=for-1509
Sep 21, 2018
Merged

Update jnr-constants for fixes after the updated generation logic#5316
headius merged 7 commits intojruby:masterfrom
headius:update-jnr-constants=for-1509

Conversation

@headius
Copy link
Member

@headius headius commented Sep 19, 2018

Thanks to @ahorek for help getting these regenerated.

Thanks to @ahorek for help getting these regenerated.
@headius headius added this to the JRuby 9.2.1.0 milestone Sep 19, 2018
@ahorek
Copy link
Contributor

ahorek commented Sep 19, 2018

these tests should be updated

@r186_errcodes=[

and
// FIXME: these descriptions should probably be moved out,

some failures are probably related to missing "O_TMPFILE"
https://github.com/jnr/jnr-constants/pull/46/files#diff-9aec806eac834c0d9bbc7ad7d3bfb024R25

maybe related?
libvips/libvips#922 (comment)
http://lists.busybox.net/pipermail/buildroot/2016-August/171072.html

@ahorek
Copy link
Contributor

ahorek commented Sep 19, 2018

also after this change I have a strange error on windows (master 7ea2895 works)

reproduction

require "bundler/inline"

gemfile(true) do
  source "https://rubygems.org"
  gem "rails", github: "rails/rails"
end
Fetching git://github.com/rails/rails.git

Retrying `git clone "git://github.com/rails/rails.git" "/jruby/lib/ruby/gems/shared/cache/bundler/git/rails-16a5e918a06649ffac24fd5873b875daf66212ad" --bare --no-hardlinks --quiet` due to error (2/4): ArgumentError wrong number of arguments (1 for 0)
Retrying `git clone "git://github.com/rails/rails.git" "/jruby/lib/ruby/gems/shared/cache/bundler/git/rails-16a5e918a06649ffac24fd5873b875daf66212ad" --bare --no-hardlinks --quiet` due to error (3/4): ArgumentError wrong number of arguments (1 for 0)
Retrying `git clone "git://github.com/rails/rails.git" "/jruby/lib/ruby/gems/shared/cache/bundler/git/rails-16a5e918a06649ffac24fd5873b875daf66212ad" --bare --no-hardlinks --quiet` due to error (4/4): ArgumentError wrong number of arguments (1 for 0)
ArgumentError: wrong number of arguments (1 for 0)
                          ` at uri:classloader:/jruby/kernel/jruby/process_manager.rb:28
                          ` at uri:classloader:/jruby/kernel/jruby/process_manager.rb:50
                        git at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/source/git/git_proxy.rb:171
  capture_and_filter_stderr at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/source/git/git_proxy.rb:249
                       open at org/jruby/ext/tempfile/Tempfile.java:260
  capture_and_filter_stderr at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/source/git/git_proxy.rb:247
                        git at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/source/git/git_proxy.rb:171
         with_clean_git_env at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/shared_helpers.rb:83
                        git at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/source/git/git_proxy.rb:170
                  git_retry at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/source/git/git_proxy.rb:162
                        run at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/retry.rb:40
                    attempt at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/retry.rb:30
                  git_retry at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/source/git/git_proxy.rb:161
                   checkout at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/source/git/git_proxy.rb:103
                      fetch at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/source/git.rb:303
                      specs at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/source/git.rb:161
      converge_locked_specs at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/definition.rb:754
                       each at org/jruby/RubyArray.java:1802
      converge_locked_specs at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/definition.rb:740
                    resolve at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/definition.rb:248
                      specs at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/definition.rb:171
          resolve_remotely! at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/definition.rb:159
          resolve_if_needed at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/installer.rb:287
                        run at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/installer.rb:83
                       lock at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/process_lock.rb:12
                       open at org/jruby/RubyIO.java:1154
                       lock at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/process_lock.rb:9
                        run at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/installer.rb:72
                    install at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/installer.rb:25
                    gemfile at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/inline.rb:62
                  temporary at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/settings.rb:136
                    gemfile at /jruby/lib/ruby/gems/shared/gems/bundler-1.16.5/lib/bundler/inline.rb:61
                     <main> at inline.rb:3

headius added a commit to jnr/jnr-constants that referenced this pull request Sep 20, 2018
This allows setting _GNU_SOURCE as needed to get the Linux-
specific O_TMPFILE back into constants.

See:
  http://lists.busybox.net/pipermail/buildroot/2016-August/171072.html
  jruby/jruby#5316 (comment)
@headius
Copy link
Member Author

headius commented Sep 20, 2018

these tests should be updated

I just removed it. It wasn't a large test and there's considerably better coverage for system errors elsewhere.

some failures are probably related to missing "O_TMPFILE"

I've just pushed jnr/jnr-constants@6539638 which adds _GNU_SOURCE for OpenFlags, but I wonder if there's a better way to isolate this per env (without having "if Linux..." all over the generator files).

I'll update OpenFlags and see if it helps.

At least BINARY and TMPFILE now may have a zero value if they are
not defined on the current platform, so comparing a mask with 0 to
0 obviously is not right here.
@headius headius changed the title Update to jnr-constants 0.9.10, so regenerated values fix #1509. Update jnr-constants for fixes after the updated generation logic Sep 20, 2018
@headius headius merged commit 8423a9e into jruby:master Sep 21, 2018
@headius
Copy link
Member Author

headius commented Sep 21, 2018

I went ahead with the merge.

Master went red with my O_CLOEXEC tweak...but only because it had the wrong O_CLOEXEC for Linux. That's resolved by this PR, so it should pass fine now. 🤞

@headius headius deleted the update-jnr-constants=for-1509 branch September 21, 2018 05:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants