diff --git a/railties/lib/rails/generators.rb b/railties/lib/rails/generators.rb
index <HASH>..<HASH> 100644
--- a/railties/lib/rails/generators.rb
+++ b/railties/lib/rails/generators.rb
@@ -302,6 +302,7 @@ module Rails
         $LOAD_PATH.each do |base|
           Dir[File.join(base, "{rails/generators,generators}", "**", "*_generator.rb")].each do |path|
             begin
+              path = path.sub("#{base}/", "")
               require path
             rescue Exception => e
               # No problem
Ensure that app generator is not loaded twice to get rid of warnings