Permalink
Browse files

Fixed installing with C-API changes.

  • Loading branch information...
1 parent ae78d54 commit 7ebcd2e592e846e6a6b7d57b07e5b827b2a1e876 @brixen brixen committed Jun 8, 2011
Showing with 12 additions and 8 deletions.
  1. +1 −4 lib/ext/melbourne/Rakefile
  2. +1 −1 rakelib/ext_helper.rb
  3. +3 −0 rakelib/extensions.rake
  4. +7 −3 rakelib/install.rake
@@ -69,9 +69,6 @@ end
add_objects project_files, ext_dir
-oniguruma_h_dir = File.expand_path('../../../../vm/external_libs/onig', __FILE__)
-add_include_dir oniguruma_h_dir
-
# Build the Melbourne extension against Rubinius
directory "rbx"
melbourne_rbx = "rbx/melbourne20.#{$DLEXT}"
@@ -84,7 +81,7 @@ melbourne_build = "build/melbourne20.#{$DLEXT}"
file melbourne_build => project_files
-graph_dependencies source_files, oniguruma_h_dir
+graph_dependencies source_files
import dependency_file
View
@@ -120,7 +120,7 @@ def include18_dir
end
def include19_dir
- File.expand_path("../../vm/capi/18/include", __FILE__)
+ File.expand_path("../../vm/capi/19/include", __FILE__)
end
def add_rbx_capi
View
@@ -44,6 +44,9 @@ def build_extconf(name, opts)
ENV["BUILD_RUBY"] = BUILD_CONFIG[:build_ruby]
+ include18_dir = File.expand_path("../../vm/capi/18/include", __FILE__)
+ include19_dir = File.expand_path("../../vm/capi/19/include", __FILE__)
+
unless File.directory? BUILD_CONFIG[:runtime]
ENV["CFLAGS"] = "-I#{include18_dir} -I#{include19_dir}"
end
View
@@ -16,7 +16,9 @@ end
install_dirs = [
BUILD_CONFIG[:bindir],
BUILD_CONFIG[:libdir],
- BUILD_CONFIG[:includedir],
+ BUILD_CONFIG[:include18dir],
+ BUILD_CONFIG[:include19dir],
+ BUILD_CONFIG[:include20dir],
BUILD_CONFIG[:mandir],
BUILD_CONFIG[:gemsdir]
]
@@ -89,8 +91,10 @@ namespace :install do
else
install_dirs.each { |name| mkdir_p install_dir(name), :verbose => $verbose }
- FileList["vm/capi/include/**/*.h"].each do |name|
- install_file name, %r[^vm/capi/include], BUILD_CONFIG[:includedir]
+ [["18", "18"], ["19", "19"], ["19", "20"]].each do |a, b|
+ FileList["vm/capi/#{a}/include/**/*.h"].each do |name|
+ install_file name, %r[^vm/capi/#{a}/include], BUILD_CONFIG[:"include#{b}dir"]
+ end
end
FileList[

0 comments on commit 7ebcd2e

Please sign in to comment.