+++ /dev/null
-diff --git a/ext/typhoeus/Makefile b/ext/typhoeus/Makefile
-index 44741d0..fa53d75 100644
---- a/ext/typhoeus/Makefile
-+++ b/ext/typhoeus/Makefile
-@@ -37,14 +37,14 @@ datadir = $(datarootdir)
- localstatedir = $(prefix)/var
- sitelibdir = $(sitedir)/$(ruby_version)
-
--CC = gcc
-+CC ?= gcc
- LIBRUBY = $(LIBRUBY_A)
- LIBRUBY_A = lib$(RUBY_SO_NAME)-static.a
- LIBRUBYARG_SHARED =
- LIBRUBYARG_STATIC = -l$(RUBY_SO_NAME)-static
-
- RUBY_EXTCONF_H =
--CFLAGS = -fno-common -g -O2 -pipe -fno-common $(cflags) -g -DXP_UNIX -O3 -Wall -Wcast-qual -Wwrite-strings -Wconversion -Wmissing-noreturn -Winline
-+CFLAGS ?= -fno-common -g -O2 -pipe -fno-common $(cflags) -g -DXP_UNIX -O3 -Wall -Wcast-qual -Wwrite-strings -Wconversion -Wmissing-noreturn -Winline
- INCFLAGS = -I. -I. -I/usr/local/lib/ruby/1.8/i686-darwin9.6.0 -I.
- DEFS =
- CPPFLAGS = -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE
-@@ -53,7 +53,7 @@ ldflags = -L.
- dldflags =
- archflag =
- DLDFLAGS = $(ldflags) $(dldflags) $(archflag)
--LDSHARED = cc -dynamic -bundle -undefined suppress -flat_namespace
-+LDSHARED = $(CC) -shared
- AR = ar
- EXEEXT =
-
-@@ -86,7 +86,7 @@ extout =
- extout_prefix =
- target_prefix = /typhoeus
- LOCAL_LIBS =
--LIBS = -lcurl -ldl -lobjc
-+LIBS = -lcurl -ldl
- SRCS = native.c typhoeus_easy.c typhoeus_multi.c
- OBJS = native.o typhoeus_easy.o typhoeus_multi.o
- TARGET = native
+++ /dev/null
-#############################################################
-#
-# ruby-typhoeus
-#
-#############################################################
-RUBY_TYPHOEUS_VERSION:=0.0.16
-RUBY_TYPHOEUS_SOURCE:=git://github.com/pauldix/typhoeus.git
-RUBY_TYPHOEUS_DIR:=$(BUILD_DIR)/ruby-typhoeus-$(RUBY_TYPHOEUS_VERSION)
-RUBY_TYPHOEUS_TARGET:=/lib/ruby/1.9.1
-RUBY_TYPHOEUS_COMMIT=06e896324e2b92771b222c763d5a6693315ae2f0
-
-$(RUBY_TYPHOEUS_DIR)/.checkedout:
- $(GIT) $(RUBY_TYPHOEUS_SOURCE) $(RUBY_TYPHOEUS_DIR)
- ( cd $(RUBY_TYPHOEUS_DIR) git checkout $(RUBY_TYPHOEUS_COMMIT) )
- touch $@
-
-$(RUBY_TYPHOEUS_DIR)/.patched: $(RUBY_TYPHOEUS_DIR)/.checkedout
- toolchain/patch-kernel.sh $(RUBY_TYPHOEUS_DIR) package/ruby-typhoeus \*.patch
-
-$(RUBY_TYPHOEUS_DIR)/.installed: $(RUBY_TYPHOEUS_DIR)/.compiled
- mkdir -p $(TARGET_DIR)/$(RUBY_TYPHOEUS_TARGET)
- rsync -ar $(RUBY_TYPHOEUS_DIR)/lib/ $(TARGET_DIR)/$(RUBY_TYPHOEUS_TARGET)
- mkdir -p $(TARGET_DIR)/$(RUBY_TYPHOEUS_TARGET)/i686-linux/typhoeus
- cp $(RUBY_TYPHOEUS_DIR)/ext/typhoeus/native.bundle $(TARGET_DIR)/$(RUBY_TYPHOEUS_TARGET)/i686-linux/typhoeus/native.so
- touch $@
-
-$(RUBY_TYPHOEUS_DIR)/.compiled: $(RUBY_TYPHOEUS_DIR)/.patched ruby
- cp $(STAGING_DIR)/usr/include/ruby/ruby.h $(RUBY_TYPHOEUS_DIR)/ext/typhoeus
- cp $(STAGING_DIR)/usr/include/ruby/defines.h $(RUBY_TYPHOEUS_DIR)/ext/typhoeus
- mkdir -p $(RUBY_TYPHOEUS_DIR)/ext/typhoeus/ruby
- cp $(STAGING_DIR)/usr/include/i686-linux/ruby/config.h $(RUBY_TYPHOEUS_DIR)/ext/typhoeus/ruby
- $(TARGET_CONFIGURE_ENV) CC=$(TARGET_CC) make -C $(RUBY_TYPHOEUS_DIR)/ext/typhoeus
- touch $@
-
-ruby-typhoeus-source: $(RUBY_TYPHOEUS_DIR)/.checkedout
-
-ruby-typhoeus-dirclean:
- rm -rf $(RUBY_TYPHOEUS_DIR)
-
-ruby-typhoeus-clean:
-
-ruby-typhoeus-install: $(RUBY_TYPHOEUS_DIR)/.installed
-ruby-typhoeus: ruby-typhoeus-install
-
-#############################################################
-#
-# Toplevel Makefile options
-#
-#############################################################
-ifeq ($(BR2_PACKAGE_RUBY_TYPHOEUS),y)
-TARGETS+=ruby-typhoeus
-endif
-
-xenclient-source: ruby-typhoeus-source
--- /dev/null
+#############################################################
+#
+# ruby-typhoeus
+#
+#############################################################
+RUBY_TYPHOEUS_VERSION:=0.0.16
+RUBY_TYPHOEUS_SOURCE:=git://github.com/pauldix/typhoeus.git
+RUBY_TYPHOEUS_DIR:=$(RUBY_DIR)/ext/typhoeus-$(RUBY_TYPHOEUS_VERSION)
+RUBY_TYPHOEUS_TARGET:=/lib/ruby/1.9.1
+RUBY_TYPHOEUS_COMMIT=06e896324e2b92771b222c763d5a6693315ae2f0
+
+$(RUBY_TYPHOEUS_DIR)/.checkedout:
+ $(GIT) $(RUBY_TYPHOEUS_SOURCE) $(RUBY_TYPHOEUS_DIR)
+ ( cd $(RUBY_TYPHOEUS_DIR) && git checkout $(RUBY_TYPHOEUS_COMMIT) )
+ touch $@
+
+$(RUBY_TYPHOEUS_DIR)/.installed: $(RUBY_TYPHOEUS_DIR)/.compiled
+ mkdir -p $(TARGET_DIR)/$(RUBY_TYPHOEUS_TARGET)
+ rsync -ar $(RUBY_TYPHOEUS_DIR)/lib/ $(TARGET_DIR)/$(RUBY_TYPHOEUS_TARGET)
+ cp -r $(RUBY_DIR)/.ext/i686-linux/typhoeus $(TARGET_DIR)/$(RUBY_LIBS_TARGET)/i686-linux
+ touch $@
+
+$(RUBY_TYPHOEUS_DIR)/.compiled: ruby libcurl $(RUBY_TYPHOEUS_DIR)/.checkedout
+ make ruby-compile
+ touch $@
+
+ruby-typhoeus-source: $(RUBY_TYPHOEUS_DIR)/.checkedout
+
+ruby-typhoeus-dirclean:
+ rm -rf $(RUBY_TYPHOEUS_DIR)
+
+ruby-typhoeus-clean:
+
+ruby-typhoeus-install: $(RUBY_TYPHOEUS_DIR)/.installed
+ruby-typhoeus: ruby-typhoeus-install
+
+#############################################################
+#
+# Toplevel Makefile options
+#
+#############################################################
+ifeq ($(BR2_PACKAGE_RUBY_TYPHOEUS),y)
+TARGETS+=ruby-typhoeus
+endif
+
+xenclient-source: ruby-typhoeus-source
include package/ruby/ruby-glib2/ruby-glib2.mk
include package/ruby/ruby-sys-filesystem/ruby-sys-filesystem.mk
+include package/ruby/ruby-typhoeus/ruby-typhoeus.mk