Creating a multiplatform Gem

Y

Yennifer Chacon

Hi!!

I would like to create a multi-platform gem, but i don't know if there
is a way to do that. I probably could do a gem for each OS, but i want
to know if there is a way to only build one gem that can be use in
different OSs.

The gem not only contains ruby code, i'm using extensions written in C.

I really hope you can answer me!

Thanks!!
 
A

Alex Gore

Yennifer said:
I would like to create a multi-platform gem, but i don't know if there
is a way to do that. I probably could do a gem for each OS, but i want
to know if there is a way to only build one gem that can be use in
different OSs.

you dont specify a os in the gemspec.

that should work.
 
R

Roger Pack

Yennifer said:
Hi!!

I would like to create a multi-platform gem, but i don't know if there
is a way to do that. I probably could do a gem for each OS, but i want
to know if there is a way to only build one gem that can be use in
different OSs.

Typically you publish the source code for your gem, then the source code
is built by the compiler when they run "gem install x"

however, it is possible to release a gem with compiled code, too. The
closest thing to your request currently is there is a helper for
building binaries for windows. [1]


Cheers!
=r
[1] http://github.com/luislavena/rake-compiler/tree/master
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,770
Messages
2,569,584
Members
45,079
Latest member
ElidaWarin

Latest Threads

Top