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

Struggling to create exe with script that requires gsl #185

Open
ruggieroguida opened this issue Jul 8, 2022 · 1 comment
Open

Struggling to create exe with script that requires gsl #185

ruggieroguida opened this issue Jul 8, 2022 · 1 comment

Comments

@ruggieroguida
Copy link

ruggieroguida commented Jul 8, 2022

Ruby 2.7.1

I keep receiving the error when I execute ocra to convert a script that requires gsl. I have tried all the suggestions from the various comments to previous issues, but I keep receiving the error

Traceback (most recent call last):
        2: from C:/Users/ruggiero/AppData/Local/Temp/ocrE82E.tmp/src/ground.rb:17:in `<main>'
        1: from C:/Users/ruggiero/AppData/Local/Temp/ocrE82E.tmp/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
C:/Users/ruggiero/AppData/Local/Temp/ocrE82E.tmp/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require': cannot load such file -- gsl (LoadError)
        6: from C:/Users/ruggiero/AppData/Local/Temp/ocrE82E.tmp/src/ground.rb:17:in `<main>'
        5: from C:/Users/ruggiero/AppData/Local/Temp/ocrE82E.tmp/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:156:in `require'
        4: from C:/Users/ruggiero/AppData/Local/Temp/ocrE82E.tmp/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:168:in `rescue in require'
        3: from C:/Users/ruggiero/AppData/Local/Temp/ocrE82E.tmp/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:168:in `require'
        2: from C:/Users/ruggiero/AppData/Local/Temp/ocrE82E.tmp/lib/ruby/gems/2.7.0/gems/gsl-2.1.0.3/lib/gsl.rb:11:in `<top (required)>'
        1: from C:/Users/ruggiero/AppData/Local/Temp/ocrE82E.tmp/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
C:/Users/ruggiero/AppData/Local/Temp/ocrE82E.tmp/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require': 126: The specified module could not be found.   - C:/Users/ruggiero/AppData/Local/Temp/ocrE82E.tmp/lib/ruby/gems/2.7.0/gems/gsl-2.1.0.3/lib/gsl_native.so (LoadError)

My latest attempt at the command is

ridk exec ocra --verbose ground.rb --gem-full --dll "ruby_builtin_dlls\libgsl-25.dll" --dll "ruby_builtin_dlls\libgslcblas-0.dll" --dll ruby_builtin_dlls\libssp-0.dll --dll ruby_builtin_dlls\libgmp-10.dll --dll ruby_builtin_dlls\libgcc_s_seh-1.dll --dll ruby_builtin_dlls\libwinpthread-1.dll --output ground.exe

The script works as expected when launched with ridk exec ruby ground.rb

Any suggestion? Thanks

@ruggieroguida
Copy link
Author

Just in case it helps someone else, this is the command that ended up working

ocra ground.rb --dll ruby_builtin_dlls\libssp-0.dll --dll libgsl-27.dll --dll libgslcblas-0.dll --console --verbose --gem-full --add-all-core --gem-full=gsl

You need to copy libgsl-27.dll and libgslcblas-0.dll to the Ruby bin directory and not to ruby_builtin_dlls

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

1 participant