Closed mscharley closed 9 years ago
Thanks for opening this issue. Now I don't want to let you down, but I'm not entirely sure what this entails. Up until now I've only built binary versions of my gems for 32-bit Windows and judging from sparklemotion/nokogiri#864 and sparklemotion/sqlite3-ruby#90 64-bit support doesn't seem utterly straightforward. Also, I'm only rudimentarily testing them on a 32-bit Windows 7 VM; neither am I a Windows user nor do I feel the urge to spend more time on that platform than necessary (sad but true).
If you can come up with instructions or, better yet, a pull request for the changes necessary to support fat binary gems on 64-bit Windows based on rake-compiler (including cross-ruby
parameters required to cross-compile 64-bit Ruby on Linux), I'm willing to include them in future releases. If you, or someone else, would also step up to offer Windows testing before each release, I'd be even more motivated :)
I'd be more than happy to look at it sometime soonish if you're happy to give me a quick rundown of how the current fat 32 bit releases work as I usually work with pure-ruby applications. I can't imagine how it'd be harder though (from the nokogiri guys, it's an issue with their build system, not an issue with 64b per ce) unless perhaps there's not a 64b version of the library available (not sure if/how that'd affect things).
Sure, let me give it a shot:
cross_platform
defaulting to %w[x86-mswin32-60 x86-mingw32]
and RUBY_CC_VERSION
defaulting to all versions defined in rake-compiler's config.yml
(currently 1.9, 2.0, 2.1 and 2.2).
rake-compiler cross-ruby VERSION=x.y.z
. They are 32-bit by default and I have no idea which parameter or variable would change that../configure --host=i686-w64-mingw32 --enable-static --disable-shared && make
LDFLAGS=-L/path/to/gnurx CFLAGS=-I/path/to/gnurx ./configure --disable-silent-rules --host=i686-w64-mingw32 --enable-static --disable-shared && make
rake gem:native WITH_CROSS_MAGIC=/path/to/file WITH_CROSS_GNURX=/path/to/gnurx
.I concede that this is a heavily customized workflow which might not be easy to reproduce.
I'm running Arch and Windows 8 currently, and Arch only has mingw-w64 which does 32 and 64 bit. So lets see if I can take a crack at this... From the brief look at rake-compiler I had it should be possible though.
Similar to #10, if fat binary gem's are fine by the maintainers, it'd be great to get x86_64 pre-compiled versions as well for those using the 64 bit releases of ruby.