gosu / releasy

A rake task generator to help with building/packaging/deploying Ruby applications (⚠️ unmaintained)
https://spooner.github.com/libraries/releasy/
MIT License
378 stars 29 forks source link

Gem json is binary, but 1.8.3 does not have a published binary. What are my options? #62

Open niuage opened 9 years ago

niuage commented 9 years ago

http://i.imgur.com/hGnELuw.png

What are my options? A LOT of gems have this as a dependency I think.

Plus, let's say I get rid of all of them, then I get the same message for libxml-ruby. The thing is, this libxml-ruby is added to my gemfile because of releasy dependencies.

So I removed releasy from my gemfile and installed it with gem install releasy (and it appears in gem list releasy). But when I run rake build, I get cannot load such file -- releasy.

Any ideas what so ever? Thanks :+1:

bil-bas commented 9 years ago

You can put releasy in your development group in the gemfile? Not really sure - don't remember having this issue, but so long since I used Releasy myself - what Ruby version are you using?

niuage commented 9 years ago

I tried it both on 2.0 and 1.9.3-p551.

bil-bas commented 9 years ago

1.9.3 is what Releasy was developed to support (though also tested on 1.8.7), so that should be fine!

bil-bas commented 9 years ago

Shouldn't really require json unless you are using 1.8.7, since json is built in for 1.9

What exactly is pulling in json gem (look at your Gemfile.lock), because Releasy doesn't need it directly.

niuage commented 9 years ago

Adding releasy to the gemfile, in the development group worked!

I still have the issue with json (1.8.3). HTTParty and ActiveSupport use it. I don't know how to get around that.

niuage commented 9 years ago

When I do gem list json --remote --all --prerelease (which is what releasy does), I get:

json (1.8.3 ruby java, 1.8.2 ruby java, 1.8.1 ruby java, 1.8.0 ruby java, 1.7.7 ruby java, 1.7.6 ruby java, 1.7.5 ruby java, 1.7.4 ruby java, 1.7.3 ruby java, 1.7.2 ruby java, 1.7.1 ruby java, 1.7.0 ruby java, 1.6.8 ruby java, 1.6.7 ruby java, 1.6.6 ruby java, 1.6.5 ruby java, 1.6.4 ruby java, 1.6.3 ruby java, 1.6.2 ruby java, 1.6.1 ruby java, 1.6.0.1 java, 1.6.0, 1.5.5 ruby java, 1.5.4 ruby java, 1.5.3 ruby java, 1.5.2 ruby java, 1.5.1 ruby java, 1.5.0 ruby java, 1.4.6 ruby java, 1.4.5 ruby java, 1.4.4 ruby java, 1.4.3 ruby java, 1.4.2, 1.4.1, 1.4.0, 1.2.4, 1.2.3, 1.2.2, 1.2.1, 1.2.0, 1.1.9, 1.1.8, 1.1.7, 1.1.6, 1.1.5 ruby x86-linux, 1.1.4, 1.1.3, 1.1.2, 1.1.1 ruby mswin32, 1.1.0 ruby mswin32, 1.0.4 ruby mswin32, 1.0.3 ruby mswin32, 1.0.2, 1.0.1, 1.0.0, 0.4.3, 0.4.2, 0.4.1, 0.4.0)

So does it mean I would need one the version with mswin?

1.1.1 ruby mswin32, 1.1.0 ruby mswin32, 1.0.4 ruby mswin32, 1.0.3 ruby mswin32
bil-bas commented 9 years ago

Yeah, that is odd. As I say, though, neither of those apps ACTUALLY NEED the json gem unless they are on 1.8.7...bah! Not sure what to suggest!

niuage commented 9 years ago

I don't see what you mean by " neither of those apps ACTUALLY NEED the json gem unless they are on 1.8.7". You mean they could do without this more recent version?

In httparty gemspec: s.add_dependency 'json', "~> 1.8"

It's just that 1.1.x seems so old, isn't it weird that there aren't more recent precompiled versions for windows?

bil-bas commented 9 years ago

I mean that in 1.8.7 "json" was a separate gem. Since 1.9, json has been included in the Ruby release, so isn't needed to be installed as a gem (and is a direct replacement, so you can use require 'json' in both cases of standard library and gem).

niuage commented 9 years ago

Ok I see, didn't know that. Well, I guess one choice I have is to get rid of ActiveSupport which is mainly included for convenience, and use a different lib to make http requests...

Do you have any idea how easy it is to keep my tiny app as is, and use jruby to get a jar that would work on windows by any chance?

(thanks for the quick answers btw)

bil-bas commented 9 years ago

Not a clue. You could just use ocra, of course, if all you are doing is windows build on a windows machine (or use a Windows VM for the build for ocra or releasy). I'm surprised there isn't a better method for building exe in Ruby yet - I stopped using Ruby several years ago now and just use Python for work (which is why Releasy hasn't seen any love for Ruby 2.0+ :blush: )

Using something like restclient instead of httpparty is an option, though removing activesupport isn't ideal if you've used it any amount.

niuage commented 9 years ago

I've personally tried Python a few times and like ruby much more. I guess the biggest difference is the community.

Anyways, I've used ActiveSupport for things like ActiveConcern and convenience methods, removing it wouldn't be terrible.

My issue with Ocra is that I would have LOVED not to have to setup a ruby env on windows. I just hate it ^^.

Thanks for your help.

bil-bas commented 9 years ago

The biggest difference for me is that I can find work using python ;)

Sorry I couldn't be more helpful!