diff options
author | newhook <matthew.newhook@gmail.com> | 2015-04-22 16:17:04 -0230 |
---|---|---|
committer | newhook <matthew.newhook@gmail.com> | 2015-04-22 16:17:04 -0230 |
commit | e95d34aa245abb5c7dba23a2da0d17c90e90f706 (patch) | |
tree | 8e56352ab7b319f883e633622a6802d4a3e23eec /ruby | |
parent | ICE-6457 (diff) | |
download | ice-e95d34aa245abb5c7dba23a2da0d17c90e90f706.tar.bz2 ice-e95d34aa245abb5c7dba23a2da0d17c90e90f706.tar.xz ice-e95d34aa245abb5c7dba23a2da0d17c90e90f706.zip |
ICE-6455 - remove slice2py and slice2rb C++ exe
Fix slice2rb.rb and slice2py.py scripts for Windows.
Fix build issue with IceSSL and MinGW.
Diffstat (limited to 'ruby')
-rwxr-xr-x | ruby/config/slice2rb.rb | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/ruby/config/slice2rb.rb b/ruby/config/slice2rb.rb index 7fcddf9582a..2744db07692 100755 --- a/ruby/config/slice2rb.rb +++ b/ruby/config/slice2rb.rb @@ -10,6 +10,31 @@ $:.unshift File.join(File.dirname(__FILE__), "..", "ruby") +# Fix up the environment PATH under Windows so that the plugin can load. +if RUBY_PLATFORM =~ /mswin|mingw|cygwin/ + path = ENV["PATH"] + + iceBinDir = File.join(File.dirname(__FILE__), "..", "..", "cpp", "bin") + programFiles = "ProgramFiles" + suffix = "" + + # 64 bit windows machine? + arch1 = ENV['PROCESSOR_ARCHITECTURE'] + arch2 = ENV['PROCESSOR_ARCHITEW6432'] + if arch1 == "AMD64" || arch1 == "IA64" || arch2 == "AMD64" || arch2 == "IA64" + programFiles += "(x86)" + + # 64 bit ruby? + if RUBY_PLATFORM == "x64-mingw32" + suffix = "x64" + end + end + path = path + ";" + File.join(ENV[programFiles], "ZeroC","Ice-3.6.0-ThirdParty", "bin", suffix) + path = path + ";" + File.join(iceBinDir, suffix) + + ENV['PATH'] = path +end + require 'IceRuby' rc = Ice::compile(ARGV) |