    # File lib/rubygems/commands/build_command.rb, line 30
      def load_gemspecs(filename)
        if yaml?(filename)
          result = []
          open(filename) do |f|
            begin
              while not f.eof? and spec = Gem::Specification.from_yaml(f)
                result << spec
              end
            rescue Gem::EndOfYAMLException => e
              # OK
            end
          end
        else
          result = [Gem::Specification.load(filename)]
        end
        result
      end