Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jruby fails to alias read_uint32 on windows 10 #4468

Open
hurricup opened this issue Jan 31, 2017 · 1 comment
Open

jruby fails to alias read_uint32 on windows 10 #4468

hurricup opened this issue Jan 31, 2017 · 1 comment

Comments

@hurricup
Copy link

Environment

Provide at least:

  • jruby 9.1.7.0 (2.3.1) 2017-01-11 68056ae OpenJDK 64-Bit Server VM 25.112-b659 on 1.8.0_112-release-b659 +jit [mswin32-x86_64]
  • Operating system and platform: win10 pro

Actual Behavior

Jruby fails to alias read_uint32 with alias_method :read_dword, :read_uint32 , ruby 2.3.1 works fine. I'm pretty new to ruby and guess this is some missing binding to win api. Here is a stacktrace from puppet trying to do this:

NameError: undefined method `read_uint32' for class `FFI::Pointer'
org/jruby/RubyModule.java:2809:in `alias_method'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/util/windows/api_types.rb:42:in `<class:Pointer>'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/util/windows/api_types.rb:20:in `<module:APITypes>'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/util/windows/api_types.rb:4:in `<main>'
org/jruby/RubyKernel.java:961:in `require'
C:/jruby-9.1.7.0/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:55:in `require'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/util/windows.rb:1:in `<module:(root)>'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/util/windows.rb:16:in `<main>'
org/jruby/RubyKernel.java:961:in `require'
C:/jruby-9.1.7.0/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:55:in `require'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/util/windows.rb:1:in `<main>'
org/jruby/RubyKernel.java:961:in `require'
C:/jruby-9.1.7.0/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:55:in `require'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/file_system/windows.rb:1:in `<module:(root)>'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/file_system/windows.rb:2:in `<main>'
org/jruby/RubyKernel.java:961:in `require'
C:/jruby-9.1.7.0/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:55:in `require'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/file_system.rb:1:in `<main>'
org/jruby/RubyKernel.java:961:in `require'
C:/jruby-9.1.7.0/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:55:in `require'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/file_system.rb:11:in `<main>'
org/jruby/RubyKernel.java:961:in `require'
C:/jruby-9.1.7.0/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:55:in `require'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/file_system.rb:1:in `<main>'
org/jruby/RubyKernel.java:961:in `require'
C:/jruby-9.1.7.0/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:133:in `require'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/file_system/uniquefile.rb:1:in `<main>'
org/jruby/RubyKernel.java:961:in `require'
C:/jruby-9.1.7.0/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:55:in `require'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/file_system/uniquefile.rb:1:in `<main>'
org/jruby/RubyKernel.java:961:in `require'
C:/jruby-9.1.7.0/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:55:in `require'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/util.rb:1:in `<main>'
org/jruby/RubyKernel.java:961:in `require'
C:/jruby-9.1.7.0/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:55:in `require'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet/util.rb:11:in `<main>'
org/jruby/RubyKernel.java:961:in `require'
C:/jruby-9.1.7.0/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:133:in `require'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet.rb:1:in `<main>'
org/jruby/RubyKernel.java:979:in `load'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-4.8.2/lib/puppet.rb:12:in `(root)'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-syntax-2.2.0/lib/puppet-syntax/templates.rb:1:in `(root)'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-syntax-2.2.0/lib/puppet-syntax/templates.rb:2:in `block in (root)'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-syntax-2.2.0/lib/puppet-syntax.rb:1:in `(root)'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-syntax-2.2.0/lib/puppet-syntax.rb:3:in `(root)'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-syntax-2.2.0/lib/puppet-syntax/tasks/puppet-syntax.rb:1:in `block in (root)'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppet-syntax-2.2.0/lib/puppet-syntax/tasks/puppet-syntax.rb:1:in `(root)'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppetlabs_spec_helper-1.2.2/lib/puppetlabs_spec_helper/rake_tasks.rb:1:in `(root)'
C:/jruby-9.1.7.0/lib/ruby/gems/shared/gems/puppetlabs_spec_helper-1.2.2/lib/puppetlabs_spec_helper/rake_tasks.rb:439:in `<main>'
org/jruby/RubyKernel.java:979:in `load'
C:/jruby-9.1.7.0/bin/rake:22:in `<main>'

sorry for imperfect issue

@desertkun
Copy link

Have you managed to solve the issue for you? Same here.

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

No branches or pull requests

2 participants