extconf.rb in gdkpixbuf-0.20.0 vs extconf.rb in gdkpixbuf-0.20.1
- old
+ new
@@ -4,10 +4,11 @@
PACKAGE_NAME = "gdk_pixbuf2"
PACKAGE_ID = "gdk-pixbuf-2.0"
begin
+ require 'rubygems'
require 'mkmf-gnome2'
USE_GNOME_GEMS=true
TOPDIR = File.expand_path(File.dirname(__FILE__))
SRCDIR = TOPDIR
require 'glib2'
@@ -33,10 +34,11 @@
if PKGConfig.have_package('gdk-2.0')
check_cairo
end
if USE_GNOME_GEMS
- path = File.expand_path(ENV['GEM_HOME'] + "/gems/glib2-#{GLib::BINDING_VERSION.join('.')}/src")
+ # locate the latest glib2 install and add the package dependency
+ path = File.dirname(Gem.find_files('rbglib.h').first)
add_depend_package("glib2", path, '/')
else
add_depend_package("glib2", "glib/src", TOPDIR)
end
create_pkg_config_file("Ruby/GdkPixbuf2", PACKAGE_ID)