From 2c82762782150b0def7d86f6effd43b09c7f7cd8 Mon Sep 17 00:00:00 2001 From: Tyler Brock Date: Mon, 6 Feb 2012 20:18:44 -0500 Subject: [PATCH] minor: replace relative requires within .gemspec files to fix testing in 1.9.x -- suggested by mlanett --- bson.gemspec | 3 ++- bson.java.gemspec | 3 ++- bson_ext.gemspec | 4 +++- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/bson.gemspec b/bson.gemspec index daac0e9..49de066 100644 --- a/bson.gemspec +++ b/bson.gemspec @@ -1,4 +1,5 @@ -require "./lib/bson" +$:.unshift(File.join(File.dirname(__FILE__), 'lib')) +require 'bson' Gem::Specification.new do |s| s.name = 'bson' diff --git a/bson.java.gemspec b/bson.java.gemspec index 6bbdb7c..02055b2 100644 --- a/bson.java.gemspec +++ b/bson.java.gemspec @@ -1,4 +1,5 @@ -require "./lib/bson" +$:.unshift(File.join(File.dirname(__FILE__), 'lib')) +require 'bson' Gem::Specification.new do |s| s.name = 'bson' diff --git a/bson_ext.gemspec b/bson_ext.gemspec index f1a6cee..ef98d8f 100644 --- a/bson_ext.gemspec +++ b/bson_ext.gemspec @@ -1,4 +1,6 @@ -require './lib/bson' +$:.unshift(File.join(File.dirname(__FILE__), 'lib')) +require 'bson' + VERSION_HEADER = File.open(File.join(File.dirname(__FILE__), 'ext', 'cbson', 'version.h'), "r") VERSION = VERSION_HEADER.read.scan(/VERSION "(\d[^"]+)"/)[0][0] Gem::Specification.new do |s|