<bcardarella>
I'm compiling ruby 1.9.3 and get the missing libyaml error for psych. So I install the libyaml and recompile. In the make output I see "configuring psych" with no warnings or errors about not being able to build. After I install the new ruby I am still getting the psych errors. Anything I can do to diagnose this issue any more?
<bcardarella>
I'm at a loss
nerd has joined #ruby-lang
postmodern has joined #ruby-lang
kurko_ has joined #ruby-lang
nazty has joined #ruby-lang
<reppard>
bcardarella: is there a libyaml-devel or libyaml-dev package available with your package mananger?
<havenn>
bcardarella: What distro?
saward has joined #ruby-lang
stardiviner has joined #ruby-lang
<saward>
Hi - is there a way to have two ruby apps, run them both, and have them communicate with each other directly (i.e., not writing and reading the same files, or mediating communication via sql)? I'm thinking of this as a way to make use of multiple cores
<whitequark>
yfeldblum: bidirectional communication plus synchronization. that's too complex for simple forking. dcell on the other hand is well-suited for that.
<saward>
why won't I need c extensions with jruby?
<yfeldblum>
whitequark, you don't need to fork each time
<whitequark>
saward: because C extensions (mostly) fix the fact that MRI is slow. JRuby isn't.
<yfeldblum>
whitequark, you maintain a process pool and send messages ("compute this" and "here's the result") over pipes
<whitequark>
yfeldblum: that doesn't matter, fork is really cheap on modern OSes
<whitequark>
esp given that his task is CPU bound
<yfeldblum>
saward, if you're using jruby, then you can also write java extensions (a class in a jar)
<saward>
only trouble is I don't know java. Not hard to pick up, i'm guessing, but still…
<whitequark>
saward: why do you want to write/use interpreter extensions?
<whitequark>
your task doesn't seem to require those
<yfeldblum>
saward, then, when you find a bottleneck, rewrite just that bit in java and learn enough java to do it
<saward>
My initial plan was to use ruby for quick development, and write slow parts in c
<saward>
I will check out jruby too
<saward>
perhaps the speed gains from true threads will be enough of a speed boost anyway.
<havenn>
Fork gets cheaper yet in Ruby 2.0.0 (or falcon patch 1.9), with Copy-On-Write.
<whitequark>
havenn: but 1.9 already had COW in GC. has falcon added more?
<whitequark>
saward: for non-arithmetic tasks jruby is mostly on par with java, from what I know
<whitequark>
also with C, you introduce *huge* additional complexity
<saward>
and now for a newbie question - will my ruby gems work with jruby?
<whitequark>
with java, not so much.
<whitequark>
saward: mostly. if they don't use C extensions, almost always. all popular ones work for a very long time.
<whitequark>
there are some which use C extensions by design, and they have equivalents in jruby-land
<whitequark>
yfeldblum: the problem with process pool is that you often need to request some dataset, not always in a database.
<whitequark>
eg a list of positions of active users, to name an example
<whitequark>
it can be huge (costly to copy) and volatile
<yfeldblum>
whitequark, true; depends on the particular details of the case
<whitequark>
yfeldblum: personally, I find the fork&compute model to work only in very simple cases
<whitequark>
definitely not for interactive software
<whitequark>
(interactive as in response time)
<yfeldblum>
whitequark, plenty of interactive software works in client/server and master/worker mode
<whitequark>
yfeldblum: yes, and it needs to resort to awful hacks to maintain consistency
<whitequark>
just look at the statelessness of HTTP and the amount of workarounds it requires
<yfeldblum>
whitequark, sometimes, but that's a completely new topic
<havenn>
whitequark: CoW optimized with falcon bitmap GC.
<whitequark>
yfeldblum: that's the exact reason I adviced against using fork&compute model
<yfeldblum>
whitequark, but that just happens in some implementations, not all
<saward>
So any opinions on if I'm a fool to make my server in ruby, and should just use c/c++?
<havenn>
cow friendly :)
<yfeldblum>
saward, your best best is probably jruby or rubinius
<whitequark>
saward: definitely no. development times in ruby are order of magnitude smaller from my experience.
<whitequark>
in worst case you'd try several different techniques, figure out which is faster and rewrite the complete design in C++
<whitequark>
which is WAY easier than doing it in C++ from scratch
<saward>
that's very important for me, since this is a spare-time project. And I've been able to do some quite neat things quickly using ruby so far…just don't want to shoot myself in the foot for later.
<havenn>
IPC Forking in MRI or Threading in JRuby or RBX are both good options.
<whitequark>
saward: but my opinion is that you won't probably bump into Ruby's limits if you'd use jruby
<whitequark>
havenn, yfeldblum: have you used rbx in production?
<whitequark>
I tried migrating my various projects to it, somewhere between 5-8 times. it never worked. I sent pull requests, reported bugs, next time it exploded again
<whitequark>
I just gave up
<yfeldblum>
whitequark, no
<whitequark>
sometimes it was easily fixable 1.9 changes, sometimes (often!) segfaults, sometimes just random weird crap
<whitequark>
not to mention that it doesn't work on Windows yet
<whitequark>
saward: I guess your players need that
<whitequark>
I have actually yet to meet a single person who used rbx in production.
<saward>
players need what?
<whitequark>
saward: windows?
<whitequark>
bbl
<saward>
yep, ideally it will run on os x, windows, and linux…thus far using mri ruby it works on all three
<whitequark>
saward: jruby does either
mercwithamouth has joined #ruby-lang
djinni` has joined #ruby-lang
havenn has joined #ruby-lang
jtoy has joined #ruby-lang
djinni` has joined #ruby-lang
djinni` has joined #ruby-lang
methods has joined #ruby-lang
<saward>
well, looks like it runs on jruby with some modifications. One of my gems didn't work with jruby so had to find an alternative
ryanlecompte has joined #ruby-lang
WillMarshall has joined #ruby-lang
charliesome has joined #ruby-lang
aedorn has joined #ruby-lang
ryanlecompte has left #ruby-lang [#ruby-lang]
havenn has joined #ruby-lang
gix has joined #ruby-lang
thufir_ has joined #ruby-lang
Tabrenus has joined #ruby-lang
drbrain has joined #ruby-lang
znouza has joined #ruby-lang
dous has joined #ruby-lang
dous has joined #ruby-lang
wyhaines has joined #ruby-lang
methods has left #ruby-lang [#ruby-lang]
kurko_ has joined #ruby-lang
Spaceghostc2c has joined #ruby-lang
<saward>
anyone here had familiarity with running jruby on os x? I have cruby and gems installed, and now it seems jruby is looking only at my cruby gems and not the ones I installed via jruby -S gem install
<micaeked>
saward: are you using rvm?
<saward>
nope, should I be? I just installed from the pkg on the jruby website
<saward>
hmm, maybe I am for cruby. It's been a while since I set it pu
drbrain has joined #ruby-lang
<saward>
on second thoughts, yes I am using rvm :) should I uninstall jruby and reinstall using dvm?
<micaeked>
saward: rvm makes multiple rubies much simpler, imo
<saward>
dvm=rvm
<micaeked>
saward: yep, i'd do that. do `rvm get stable` before if you haven't touched it in a while
<saward>
ok thanks
My_Hearing has joined #ruby-lang
srbaker has joined #ruby-lang
havenn has joined #ruby-lang
havenn has joined #ruby-lang
mercwithamouth has joined #ruby-lang
drbrain has joined #ruby-lang
dkannan_ has left #ruby-lang [#ruby-lang]
SirRamonGabriel has joined #ruby-lang
jaz-hands has joined #ruby-lang
<jaz-hands>
Anyone have any luck compiling src 1.8.7 p 370 on OS X 10.8?
<jaz-hands>
Or getting ssh-gateway gem to work on 1.9.3?
dkannan_ has joined #ruby-lang
drbrain has joined #ruby-lang
<dkannan_>
hi
dous has joined #ruby-lang
dous has joined #ruby-lang
<jaz-hands>
Ohhh I see what I did, I replaced system ruby. Oops :P
Banistergalaxy has quit [Ping timeout: 252 seconds]
chendo_ has quit [Ping timeout: 256 seconds]
mercwithamouth has joined #ruby-lang
cyri_ has joined #ruby-lang
mercwithamouth has quit [Ping timeout: 265 seconds]
thone has joined #ruby-lang
kurko_ has joined #ruby-lang
thone_ has quit [Ping timeout: 250 seconds]
mercwithamouth has joined #ruby-lang
dkannan has left #ruby-lang [#ruby-lang]
sush24 has joined #ruby-lang
Banistergalaxy has joined #ruby-lang
adambeynon has joined #ruby-lang
jtoy has quit [Quit: jtoy]
jtoy has joined #ruby-lang
dkannan has joined #ruby-lang
zmack has quit [Remote host closed the connection]
diegoviola has joined #ruby-lang
zmack has joined #ruby-lang
JohnBat26 has quit [Ping timeout: 244 seconds]
sush24 has quit [Quit: This computer has gone to sleep]
ebouchut has quit [Quit: This computer has gone to sleep]
cultureulterior_ has quit [Quit: cultureulterior_]
sepp2k has quit [Remote host closed the connection]
gnufied has quit [Quit: Leaving.]
zmack has quit [Remote host closed the connection]
dkannan has quit [Quit: dkannan]
rippa has joined #ruby-lang
gnufied has joined #ruby-lang
emocakes has joined #ruby-lang
gnufied has quit [Quit: Leaving.]
sush24 has joined #ruby-lang
davidbalber|away is now known as davidbalbert
sepp2k has joined #ruby-lang
gnufied has joined #ruby-lang
jtoy has quit [Quit: jtoy]
tonni has quit [Remote host closed the connection]
jtoy has joined #ruby-lang
kurko_ has quit [Ping timeout: 252 seconds]
kurko_ has joined #ruby-lang
facest has quit [Ping timeout: 252 seconds]
Artheist has joined #ruby-lang
schaerli has joined #ruby-lang
<diegoviola>
i'm trying to pass some ruby object to a rake task, could i pass it directly as an argument or i have to json encode the object to pass it?
Asher has joined #ruby-lang
Tabrenus has joined #ruby-lang
z180 has joined #ruby-lang
z180 has quit [Client Quit]
ebouchut has joined #ruby-lang
anannie has joined #ruby-lang
srbaker has quit [Quit: Computer has gone to sleep.]
jondot has quit [Quit: Leaving]
wyhaines has joined #ruby-lang
cyri_ has quit [Quit: cyri_]
s1n4 has joined #ruby-lang
Banistergalaxy has quit [Ping timeout: 244 seconds]
nyuszika7h has quit [Quit: Here we are, going far to save all that we love - If we give all we've got, we will make it through - Here we are, like a star shining bright on your world - Today, make evil go away!]
Banistergalaxy has joined #ruby-lang
larrylv has quit [Remote host closed the connection]
tonni has joined #ruby-lang
nick_h has quit [Ping timeout: 245 seconds]
schaerli has quit [Remote host closed the connection]
zmack has joined #ruby-lang
briantrust has quit [Remote host closed the connection]
zmack has quit [Read error: Connection reset by peer]
nyuszika7h has joined #ruby-lang
zmack has joined #ruby-lang
tonni has quit [Ping timeout: 250 seconds]
nick_h has joined #ruby-lang
Tabrenus has quit [Quit: Tabrenus]
intellitech has quit [Read error: Operation timed out]
fowl has joined #ruby-lang
richardjortega has joined #ruby-lang
stonerfish has joined #ruby-lang
zmack has quit [Remote host closed the connection]
jtoy has quit [Quit: jtoy]
canton7 has joined #ruby-lang
glebm has quit [Quit: Computer has gone to sleep.]
<tubbo>
is there a way to "compile" ruby into a binary, so it doesn't have to look for dependencies anywhere?
<tubbo>
it'd be cool if the program was self-contained, so it could be run anywhere. additionally, there's nothing about it that really requires thor or any other dependency, if that's an issue
<tubbo>
note that i do not want to run a script "as" a binary, like chmod'ding a file in ./bin to executable and then calling that in my shell as a command
<tubbo>
i'd like it if i could compile ruby to binary and run that self-contained program
breakingthings has quit [Ping timeout: 255 seconds]
<micaeked>
tubbo: don't think you can do that with mri. you can compile jruby projects into jars though
breakingthings has joined #ruby-lang
<tubbo>
ah cool, i figured.
<tubbo>
i wish there was a way to specify fall-through's for GEM_HOME
<tubbo>
that way i could have a set of gems that i could use everywhere, without needing rvm.
ddd1 has joined #ruby-lang
ddd is now known as Guest29851
ddd1 is now known as ddd
Guest29851 has quit [Ping timeout: 245 seconds]
breakingthings has quit [Quit: mer chrimmus]
mistym has joined #ruby-lang
drbrain has joined #ruby-lang
drbrain has quit [Ping timeout: 255 seconds]
<darix>
tubbo: there are tool for mri too
<darix>
though dont ask me for the exact names
<darix>
but i would google for ruby script exe windows
<darix>
which should get you started
jackhammer2022 has joined #ruby-lang
<tubbo>
darix: i saw a few things related to that, but that's not quite was i was after since i'm looking to build executables on OS X, not windows.
tubbo is now known as tubbho
foca_ has left #ruby-lang [#ruby-lang]
foca has joined #ruby-lang
<foca>
tubbho: I know this doesn't quite answer your question, but OS X already ships with ruby, so if your script runs with the system ruby then you can just distribute it and it will run :)
<tubbho>
foca: right. i use bundler to manage gems within other applications, and just a ruby installed to /usr/local..
<tubbho>
foca: the problem is, if i try to run that command in other directories where i've overridden GEM_HOME, it fails to recognize the gem.
<tubbho>
so i need to return GEM_HOME to the /usr/local/lib/whatever path and then i can use it
<tubbho>
or i have to reinstall the gem all the time (lame)
<foca>
you can provide a wrapper script that runs yours overriding GEM_HOME
<foca>
a simple shellscript that just runs "GEM_HOME=/usr/local… ruby ./my_script"
<darix>
tubbho: just overriding GEM_HOME is dangerous
<tubbho>
foca: that's a good idea. thanks!
<darix>
as you can never be sure that e.g. natively compiled extensions match your current ruby
<tubbho>
darix: you can if you use the same ruby every time.
<darix>
why not just have your script always exec with a) systemruby or b) a specific rvm maintained ruby
<darix>
all it would need is the proper shebang line for that .
<darix>
no fiddling with gem home
<tubbho>
well 1.) because i don't use RVM, and 2.) because i've just been running it with #!/usr/bin/env ruby and never thought of that =D
<tubbho>
darix: the issue is, GEM_HOME will be overridden in certain dirs to isolate my bundled gems from each other
<tubbho>
it's how i work on multiple projects at the same time on the same machine
<tubbho>
so i still will need to write a wrapper that overrides GEM_HOME temporarily.
<darix>
if bundler is already managing your gems
<darix>
why yet another hack around that?
<darix>
o.O
<tubbho>
because i am a l33t h4x0r
<tubbho>
<3
<darix>
okay
<tubbho>
well let's think.
<darix>
the easier and less error prone way
<darix>
wouldnt that be a .bundle/config file
<darix>
with the setting to discard all system gems set
<tubbho>
hmm, not sure
<tubbho>
i actually haven't dived too deeply into bundler. i just modified the config to install everything to vendor/gems since i like that directory structure better
<manveru>
just make a gemset?
<tubbho>
manveru: with rvm? yeah i guess i could do that.
<tubbho>
i have no problems with using rvm by the way i just thought this might be a more simple approach
<tubbho>
darix: i have `BUNDLE_DISABLE_SHARED_GEMS: "1"` in my ~/.bundle/config, is that what you were talking about?
<manveru>
`rvm 1.9.3@whatever do yourscript.rb`
<manveru>
no need for bundler insanity :)
<lianj>
manveru: trading one for the other
<darix>
tubbho: yes.
<tubbho>
ok. so from what i'm reading that might be what i'm looking for
<manveru>
lianj: bundler is a big reason why i don't use ruby anymore
<darix>
manveru: in case people didnt tell you yet ... you can still happily use ruby without bundler.
<lianj>
manveru: why, didnt it improve over the years? whats your issues?
<manveru>
yeah, for my own stuff
<manveru>
but as soon as i look at other stuff, there's insanity waiting for me :P
<havenn>
<3 bundler
<darix>
manveru: well even for apps that use bundler. i dont use bundler to install the gems.
<manveru>
darix: i have a script that converts Gemfiles to gemsets
<chris2>
haha
<chris2>
copying statically linked binaries around is a lot more fun, tho :P
<manveru>
indeed
<darix>
manveru: i just package everything they need into rpms and use my normal package manager for them ;)
<chris2>
i dont know anyone who makes rpms of other's stuff who doesnt work for some distributor :P
mrb_bk___ has left #ruby-lang [#ruby-lang]
<manveru>
darix happens to work for suse, i think
<chris2>
(i know)
<manveru>
:)
<darix>
works well until you run into a rails app that actually had set BUNDLE_DISABLE_SHARED_GEMS and you start wondering why it ignores all the gems i just installed
<lianj>
nah, bundle install --path .bundle, totally decoupled, never had problems with it except for one small git repo bug
<chris2>
we actually made some .debs here
<manveru>
lianj: just had an infinite dependency loop that made bundler despair a few days ago
<lianj>
manveru: im lucky then :)
<darix>
lianj: i dont want to have n copies of the libs on my system. if having it in one place would be enough.
<manveru>
lianj: you probably keep your dependencies low :)
<manveru>
can't say that about our customers
<chris2>
hehe
<darix>
manveru: i know your problem. :p
<chris2>
who was it that said npm is the only thing that works... even if you end up with 10 copies of everything
<darix>
ugh
<darix>
i saw that madness
<manveru>
lianj: basically, bundler provides a way to make it no problem to depend on a hundred libs, and people use that feature like crazy...
apeiros_ has quit [Remote host closed the connection]
<chris2>
actually, the node package system allows for multiple version to be in the same program
<chris2>
i'm not sure i've seen that work before
apeiros_ has joined #ruby-lang
<darix>
manveru: well the other option would be lots of NIH infected code?
<manveru>
chris2: as long as no lib touches the core stuff?
<chris2>
manveru: probably
<manveru>
that multiple exports would work, seems possible
<chris2>
but then library writers font seem to fuck around in core as much as some rubyists like to
<lianj>
darix: i hate using crap gems for every little thing too
<chris2>
yeah
<manveru>
darix: ever taken a look at the rubygems repo? does it look like there's less NIH?
<tubbho>
darix: thanks so much man, you have truly enlightened me on this christmas eve. <3
<darix>
tubbho: removed all your hacks?
<darix>
also welcome
<darix>
manveru: there is tons of NIH code. like N libraries to do the same thing again. but i mean ... it isnt like you havent done that either eh?:)
jackhammer2022 is now known as mclovin
<manveru>
i always made things that weren't there yet :)
<chris2>
like a web framework
<chris2>
:P
mclovin is now known as McLovin
<chris2>
or an editor :D
McLovin is now known as Guest41084
<darix>
chris2: ^5
<manveru>
or a program :P
Guest41084 is now known as jackhammer2022
<chris2>
;)
<chris2>
darix: xor five?
<manveru>
you can make categories broad enough to fit my stuff in there with others, of course
<chris2>
just kidding
jackhammer2022 is now known as McL0vin
<manveru>
i'm not complaining about bacon either, it's unmatched, as far as i'm concerned :)
McL0vin is now known as jackhammer2022
solars has quit [Ping timeout: 252 seconds]
<manveru>
it's easy to read and made my specs 10x faster
<chris2>
yeah
<darix>
<homer>hmm bacon</homer>
srbaker has joined #ruby-lang
<chris2>
and its got the best name ever :P
<lianj>
dont feed anyone to prove otherwise :|
<manveru>
:)
<chris2>
its not like i dont NIH :P
<chris2>
but i have less problems with my own code than with other's :P
<darix>
lol
<micaeked>
what does NIH stand for?
<darix>
not invented here
<manveru>
not invented here
<chris2>
usually because it doesnt break if i dont change it :P
<darix>
chris2: excuses. :p
<manveru>
don't fix what's not broken :)
<chris2>
but i dont show my code down others throats either :P
<chris2>
s/show/shove/
mistym has quit [Remote host closed the connection]
<manveru>
i love libs that stay the same for a long time while staying useful
<chris2>
hehe
<manveru>
unless of course there's a technically better alternative, like nokogiri superseding hpricot