Building a ruby script with Ocra for cross platform uses but i get the 'relative_path_form' with a stacktrace -
i'm trying build .exe execute script on windows without ruby installation. i'm using ocra have stack trace.
also note there 2 files runs whole sc , use rvm , didn't sudo gem install since use rvm.
gems used in first file :
require 'rubygems' require 'nokogiri' require 'open-uri' require 'colorize' require 'colorized_string'
gems used in second file :
require 'libnotify' require './firstfile' require 'os' require 'twilio-ruby'
here ocra gives me:
>ocra --output test.exe firstfile.rb secondfile.rb /home/xxxx/.rvm/gems/ruby-head/gems/ocra-1.3.6/bin/ocra:41:in `relative_path_from': undefined method `path' "/home/xxxx/.rvm/gems/ruby-head@global":string (nomethoderror) /home/xxxx/.rvm/gems/ruby-head/gems/ocra-1.3.6/bin/ocra:779:in `block in build_exe' /home/xxxx/.rvm/gems/ruby-head/gems/ocra-1.3.6/bin/ocra:762:in `each' /home/xxxx/.rvm/gems/ruby-head/gems/ocra-1.3.6/bin/ocra:762:in `build_exe' /home/xxxx/.rvm/gems/ruby-head/gems/ocra-1.3.6/bin/ocra:1177:in `block in <top (required)>'
here more info rvm , ruby version it's exact output of 'rvm info'
system: uname: "linux xxxx 4.7.1-1-arch #1 smp preempt wed aug 17 08:13:35 cest 2016 x86_64 gnu/linux" system: "arch/libc-2.24/x86_64" bash: "/usr/bin/bash => gnu bash, version 4.3.46(1)-release (x86_64-unknown-linux-gnu)" zsh: " => not installed" rvm: version: "rvm 1.27.0 (latest) wayne e. seguin <wayneeseguin@gmail.com>, michal papis <mpapis@gmail.com> [https://rvm.io/]" updated: "1 day 23 hours 44 minutes 51 seconds ago" path: "/home/xxxx/.rvm" ruby: interpreter: "ruby" version: "2.4.0dev" date: "2016-05-20" platform: "x86_64-linux" patchlevel: "2016-05-20 trunk 55077" full_version: "ruby 2.4.0dev (2016-05-20 trunk 55077) [x86_64-linux]" homes: gem: "/home/xxxx/.rvm/gems/ruby-head" ruby: "not set" binaries: ruby: "/home/xxxx/.rvm/rubies/ruby-head/bin/ruby" irb: "/home/xxxx/.rvm/rubies/ruby-head/bin/irb" gem: "/home/xxxx/.rvm/rubies/ruby-head/bin/gem" rake: "/home/xxxx/.rvm/gems/ruby-head/bin/rake" environment: path: "/home/xxxx/.rvm/gems/ruby-head/bin:/home/xxxx/.rvm/gems/ruby-head@global/bin:/home/xxxx/.rvm/rubies/ruby-head/bin:/home/xxxx/.rvm/bin:/usr/bin" gem_home: "/home/xxxx/.rvm/gems/ruby-head" gem_path: "/home/xxxx/.rvm/gems/ruby-head:/home/xxxx/.rvm/gems/ruby-head@global" my_ruby_home: "" irbrc: "" rubyopt: "" gemset: ""
my script parse html page , has create file inside folder is, write/read file , libnotify has set don't know how explain it's kind of path :
libnotify.icon_dirs << '/home/' + env['user'] + '/downloads/notificationicons/'
so maybe 1 of ocra means relative path i'm not sure 100% that's why i'd understand 'relative path' explicitly means , why have stack trace error.
ps: 'xxxx' here privacy !
thanks in advance i'm stuck in packaging project cross-platforms i'm trying on windows.
if need anymore information ask it, gentle if made mistakes first question asked on stack overflow.
ocra doesn't work on linux currently.
doing google search
ocra undefined method `path'
linked here, issues page on ocra github shows many people have had same problem. in turns links here, project maintainer says ocra not work on linux, though may worth shot wine.
Comments
Post a Comment