Description: Revert upstream 0d15cefd0022136de663d6542f079268137c26f1
  The upstream commit introduces a new requirement: Gems would actually
  need to have their gem_full_path directory be present, or otherwise
  bundler would not see them as installed. This is a problem for
  system-provided gems, as they then fail to install.
Author: Christian Hofstaedtler <zeha@debian.org>
Last-Update: 2014-01-16

Index: bundler/lib/bundler/source/rubygems.rb
===================================================================
--- bundler.orig/lib/bundler/source/rubygems.rb	2014-01-06 01:43:11.287872406 +0100
+++ bundler/lib/bundler/source/rubygems.rb	2014-01-16 16:04:37.393818609 +0100
@@ -68,7 +68,7 @@ module Bundler
       end
 
       def install(spec)
-        if installed_specs[spec].any? && gem_dir_exists?(spec)
+        if installed_specs[spec].any?
           return ["Using #{spec.name} (#{spec.version})", nil]
         end
 
@@ -276,16 +276,6 @@ module Bundler
           Bundler.rubygems.sources = old
         end
       end
-
-      def gem_dir_exists?(spec)
-        return true if spec.name == "bundler"
-        # Ruby 2 default gems
-        return true if spec.loaded_from.include?("specifications/default/")
-        # Ruby 1.9 default gems
-        return true if spec.summary =~ /is bundled with Ruby/
-
-        File.directory?(spec.full_gem_path)
-      end
     end
 
   end
Index: bundler/spec/install/gems/simple_case_spec.rb
===================================================================
--- bundler.orig/spec/install/gems/simple_case_spec.rb	2013-12-27 11:49:31.514707011 +0100
+++ bundler/spec/install/gems/simple_case_spec.rb	2014-01-16 16:03:57.814066818 +0100
@@ -337,22 +337,6 @@ describe "bundle install with gem source
       G
       expect(exitstatus).to eq(0)
     end
-
-    it "reinstalls the gem if the gem dir is missing but the specification file exists" do
-      gemfile(<<-G)
-        source "file://#{gem_repo1}"
-
-        gem 'foo'
-      G
-
-      bundle "install --path vendor/bundle"
-
-      FileUtils.rm_rf(vendored_gems('gems/foo-1.0'))
-
-      bundle "install"
-
-      expect(vendored_gems('gems/foo-1.0')).to exist
-    end
   end
 
   describe "when Bundler root contains regex chars" do
