Top Level Namespace
Defined Under Namespace
Modules: Magick
Constant Summary collapse
- RMAGICK_VERS =
"2.0.0"
- MIN_RUBY_VERS =
"1.8.2"
- MIN_RUBY_VERS_NO =
MIN_RUBY_VERS.tr(".","").to_i
- MIN_IM_VERS =
"6.3.0"
- MIN_IM_VERS_NO =
MIN_IM_VERS.tr(".","").to_i
- SUMMARY =
<<"END_SUMMARY" #{"=" * 70} #{DateTime.now.strftime("%a %d%b%y %T")} This installation of RMagick #{RMAGICK_VERS} is configured for Ruby #{RUBY_VERSION} (#{RUBY_PLATFORM}) and ImageMagick #{`Magick-config --version`.chomp}. #{"=" * 70} END_SUMMARY
Instance Method Summary collapse
- #exit_failure(msg) ⇒ Object
-
#have_enum_value(enum, value, headers = nil, &b) ⇒ Object
Test for a specific value in an enum type.
-
#have_enum_values(enum, values, headers = nil, &b) ⇒ Object
Test for multiple values of the same enum type.
- #have_new_rb_cvar_set(headers = nil, &b) ⇒ Object
Instance Method Details
#exit_failure(msg) ⇒ Object
74 75 76 77 78 |
# File 'ext/RMagick/extconf.rb', line 74 def exit_failure(msg) Logging:: msg msg+"\n" exit(1) end |
#have_enum_value(enum, value, headers = nil, &b) ⇒ Object
Test for a specific value in an enum type
26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 |
# File 'ext/RMagick/extconf.rb', line 26 def have_enum_value(enum, value, headers=nil, &b) checking_for "#{enum}.#{value}" do if try_compile(<<"SRC", &b) #{COMMON_HEADERS} #{cpp_include(headers)} /*top*/ int main() { #{enum} t = #{value}; t = t; return 0; } SRC $defs.push(format("-DHAVE_ENUM_%s", value.upcase)) true else false end end end |
#have_enum_values(enum, values, headers = nil, &b) ⇒ Object
Test for multiple values of the same enum type
65 66 67 68 69 |
# File 'ext/RMagick/extconf.rb', line 65 def have_enum_values(enum, values, headers=nil, &b) values.each do |value| have_enum_value(enum, value, headers, &b) end end |
#have_new_rb_cvar_set(headers = nil, &b) ⇒ Object
45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 |
# File 'ext/RMagick/extconf.rb', line 45 def have_new_rb_cvar_set(headers=nil, &b) checking_for "rb_cvar_set with 3 arguments" do if try_compile(<<"SRC", &b) #{COMMON_HEADERS} #{cpp_include(headers)} /*top*/ int main() { rb_cvar_set(rb_cArray, rb_intern("x"), INT2FIX(0)); return 0; } SRC $defs.push("-DHAVE_NEW_RB_CVAR_SET") true else false end end end |