Index: spec/ide/eclipse_spec.rb
===================================================================
--- spec/ide/eclipse_spec.rb	(revision 814669)
+++ spec/ide/eclipse_spec.rb	(working copy)
@@ -354,6 +354,27 @@
     end
   end
 
+  describe 'local dependency' do
+    before do
+      define('foo') { compile.using(:javac).with('lib/some-local.jar') }
+
+      @local_lib = project('foo').path_to('lib/some-local.jar')
+
+      # util.rb uses Pathname so return a valid object for any call we're not interested in
+      non_file_path = Pathname.new('.')      
+      Pathname.stub!(:new).and_return(non_file_path)
+
+      # If we see our local lib, return a mock instead
+      (file_path = mock('Pathname')).should_receive('file?').and_return(true)
+      Pathname.should_receive(:new).with(@local_lib).and_return(file_path)
+    end
+    
+    it 'should have a lib artifact reference in the .classpath file' do
+      classpath_xml_elements.collect("classpathentry[@kind='lib']") { |n| n.attributes['path'] }.
+        should include(@local_lib)
+    end
+  end
+
   describe 'maven2 artifact dependency' do
     before do
       define('foo') { compile.using(:javac).with('com.example:library:jar:2.0') }
Index: lib/buildr/ide/eclipse.rb
===================================================================
--- lib/buildr/ide/eclipse.rb	(revision 814669)
+++ lib/buildr/ide/eclipse.rb	(working copy)
@@ -16,6 +16,7 @@
 
 require 'buildr/core/project'
 require 'buildr/packaging'
+require 'pathname'
 
 
 module Buildr
@@ -175,8 +176,9 @@
               # Separate artifacts from Maven2 repository
               m2_libs, others = others.partition { |path| path.to_s.index(m2repo) == 0 }
 
-              # Generated: classpath elements in the project are assumed to be generated
-              generated, libs = others.partition { |path| path.to_s.index(project.path_to.to_s) == 0 }
+              # Generated: Any non-file classpath elements in the project are assumed to be generated
+              generated, libs = others.partition { |path| path.to_s.index(project.path_to.to_s) == 0 &&
+                                                          !Pathname.new(path.to_s).file? }
 
               classpathentry.src project.compile.sources + generated
               classpathentry.src project.resources
