Permalink
Browse files

windows support added

  • Loading branch information...
1 parent ce19884 commit 31a4e7283c92f985b73d51475f9d41057cf8c309 @banister committed Apr 14, 2012
Showing with 532 additions and 4 deletions.
  1. +18 −4 Rakefile
  2. +488 −0 ext/node.h
  3. +13 −0 ruby18_source_location_mingw32.gemspec
  4. +13 −0 ruby18_source_location_mswin32.gemspec
View
@@ -1,14 +1,18 @@
def dir(*args); Dir.chdir(File.join(File.dirname(__FILE__), *args)); end
+
desc "Compile local copy"
task :compile do
- dir('ext')
- system "ruby extconf.rb && make"
+ cd("ext") do
+ system "ruby extconf.rb"
+ system "make"
+ end
end
task :clean do
- dir('ext')
- system "make clean"
+ cd("ext") do
+ system "make clean"
+ end
end
desc "Package the gem"
@@ -17,6 +21,16 @@ task :gem do
system "gem build ruby18_source_location.gemspec"
end
+desc "Package the windows gem"
+task :win_gem => [:clean, :compile] do
+ dir = File.dirname(__FILE__)
+ cd(dir) do
+ system "cp #{dir}/ext/*.so #{dir}/lib/"
+ system "gem build ruby18_source_location_mswin32.gemspec"
+ system "gem build ruby18_source_location_mingw32.gemspec"
+ end
+end
+
desc "Run the tests"
task :test do
dir("test")
Oops, something went wrong.

0 comments on commit 31a4e72

Please sign in to comment.