ruby-changes:38188
From: hsbt <ko1@a...>
Date: Sun, 12 Apr 2015 23:22:14 +0900 (JST)
Subject: [ruby-changes:38188] hsbt:r50269 (trunk): * ext/json/json.gemspec, lib/rdoc/rdoc.gemspec: added gemspec directly.
hsbt 2015-04-12 18:12:15 +0900 (Sun, 12 Apr 2015) New Revision: 50269 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=50269 Log: * ext/json/json.gemspec, lib/rdoc/rdoc.gemspec: added gemspec directly. * defs/default_gems, tool/rbinstall.rb: removed default_gems definition. it make simple installation for default gems. Added files: trunk/ext/json/json.gemspec trunk/lib/rdoc/rdoc.gemspec Removed files: trunk/defs/default_gems Modified files: trunk/ChangeLog trunk/tool/rbinstall.rb Index: defs/default_gems =================================================================== --- defs/default_gems (revision 50268) +++ defs/default_gems (revision 50269) @@ -1,3 +0,0 @@ https://github.com/ruby/ruby/blob/trunk/defs/default_gems#L0 -# gem base directory versioning file [executable files under bin] -rdoc lib/rdoc lib/rdoc.rb [rdoc ri] -json ext/json ext/json/lib/json/version.rb Index: ChangeLog =================================================================== --- ChangeLog (revision 50268) +++ ChangeLog (revision 50269) @@ -1,3 +1,9 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Sun Apr 12 18:12:07 2015 SHIBATA Hiroshi <shibata.hiroshi@g...> + + * ext/json/json.gemspec, lib/rdoc/rdoc.gemspec: added gemspec directly. + * defs/default_gems, tool/rbinstall.rb: removed default_gems definition. + it make simple installation for default gems. + Sun Apr 12 17:35:17 2015 SHIBATA Hiroshi <shibata.hiroshi@g...> * ext/json/*, test/json/*: Reverted r50231. Because it's not works with Index: lib/rdoc/rdoc.gemspec =================================================================== --- lib/rdoc/rdoc.gemspec (revision 0) +++ lib/rdoc/rdoc.gemspec (revision 50269) @@ -0,0 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/lib/rdoc/rdoc.gemspec#L1 +Gem::Specification.new do |s| + s.name = "rdoc" + s.version = "4.2.0" + s.summary = "This rdoc is bundled with Ruby" + s.executables = ["rdoc", "ri"] + s.files = ["rdoc.rb", "rdoc/alias.rb", "rdoc/anon_class.rb", "rdoc/any_method.rb", "rdoc/attr.rb", "rdoc/class_module.rb", "rdoc/code_object.rb", "rdoc/code_objects.rb", "rdoc/comment.rb", "rdoc/constant.rb", "rdoc/context.rb", "rdoc/context/section.rb", "rdoc/cross_reference.rb", "rdoc/encoding.rb", "rdoc/erb_partial.rb", "rdoc/erbio.rb", "rdoc/extend.rb", "rdoc/generator.rb", "rdoc/generator/darkfish.rb", "rdoc/generator/json_index.rb", "rdoc/generator/markup.rb", "rdoc/generator/pot.rb", "rdoc/generator/pot/message_extractor.rb", "rdoc/generator/pot/po.rb", "rdoc/generator/pot/po_entry.rb", "rdoc/generator/ri.rb", "rdoc/ghost_method.rb", "rdoc/i18n.rb", "rdoc/i18n/locale.rb", "rdoc/i18n/text.rb", "rdoc/include.rb", "rdoc/known_classes.rb", "rdoc/markdown.rb", "rdoc/markdown/entities.rb", "rdoc/markdown/literals_1_9.rb", "rdoc/markup.rb", "rdoc/markup/attr_changer.rb", "rdoc/markup/attr_span.rb", "rdoc/markup/attribute_manager.rb", "rdoc/markup/attributes.rb", "rdoc/mark up/blank_line.rb", "rdoc/markup/block_quote.rb", "rdoc/markup/document.rb", "rdoc/markup/formatter.rb", "rdoc/markup/formatter_test_case.rb", "rdoc/markup/hard_break.rb", "rdoc/markup/heading.rb", "rdoc/markup/include.rb", "rdoc/markup/indented_paragraph.rb", "rdoc/markup/inline.rb", "rdoc/markup/list.rb", "rdoc/markup/list_item.rb", "rdoc/markup/paragraph.rb", "rdoc/markup/parser.rb", "rdoc/markup/pre_process.rb", "rdoc/markup/raw.rb", "rdoc/markup/rule.rb", "rdoc/markup/special.rb", "rdoc/markup/text_formatter_test_case.rb", "rdoc/markup/to_ansi.rb", "rdoc/markup/to_bs.rb", "rdoc/markup/to_html.rb", "rdoc/markup/to_html_crossref.rb", "rdoc/markup/to_html_snippet.rb", "rdoc/markup/to_joined_paragraph.rb", "rdoc/markup/to_label.rb", "rdoc/markup/to_markdown.rb", "rdoc/markup/to_rdoc.rb", "rdoc/markup/to_table_of_contents.rb", "rdoc/markup/to_test.rb", "rdoc/markup/to_tt_only.rb", "rdoc/markup/verbatim.rb", "rdoc/meta_method.rb", "rdoc/method_attr.rb", "rdoc/mixin.rb", "rdoc/ normal_class.rb", "rdoc/normal_module.rb", "rdoc/options.rb", "rdoc/parser.rb", "rdoc/parser/c.rb", "rdoc/parser/changelog.rb", "rdoc/parser/markdown.rb", "rdoc/parser/rd.rb", "rdoc/parser/ruby.rb", "rdoc/parser/ruby_tools.rb", "rdoc/parser/simple.rb", "rdoc/parser/text.rb", "rdoc/rd.rb", "rdoc/rd/block_parser.rb", "rdoc/rd/inline.rb", "rdoc/rd/inline_parser.rb", "rdoc/rdoc.rb", "rdoc/require.rb", "rdoc/ri.rb", "rdoc/ri/driver.rb", "rdoc/ri/formatter.rb", "rdoc/ri/paths.rb", "rdoc/ri/store.rb", "rdoc/ri/task.rb", "rdoc/ruby_lex.rb", "rdoc/ruby_token.rb", "rdoc/rubygems_hook.rb", "rdoc/servlet.rb", "rdoc/single_class.rb", "rdoc/stats.rb", "rdoc/stats/normal.rb", "rdoc/stats/quiet.rb", "rdoc/stats/verbose.rb", "rdoc/store.rb", "rdoc/task.rb", "rdoc/test_case.rb", "rdoc/text.rb", "rdoc/token_stream.rb", "rdoc/tom_doc.rb", "rdoc/top_level.rb"] +end Index: ext/json/json.gemspec =================================================================== --- ext/json/json.gemspec (revision 0) +++ ext/json/json.gemspec (revision 50269) @@ -0,0 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/ext/json/json.gemspec#L1 +Gem::Specification.new do |s| + s.name = "json" + s.version = "1.8.1" + s.summary = "This json is bundled with Ruby" + s.executables = [] + s.files = ["json.rb", "json/add/bigdecimal.rb", "json/add/complex.rb", "json/add/core.rb", "json/add/date.rb", "json/add/date_time.rb", "json/add/exception.rb", "json/add/ostruct.rb", "json/add/range.rb", "json/add/rational.rb", "json/add/regexp.rb", "json/add/struct.rb", "json/add/symbol.rb", "json/add/time.rb", "json/common.rb", "json/ext.rb", "json/ext/generator.bundle", "json/ext/parser.bundle", "json/generic_object.rb", "json/version.rb"] +end Index: tool/rbinstall.rb =================================================================== --- tool/rbinstall.rb (revision 50268) +++ tool/rbinstall.rb (revision 50269) @@ -620,37 +620,6 @@ module RbInstall https://github.com/ruby/ruby/blob/trunk/tool/rbinstall.rb#L620 @gemspec.to_ruby end end - - class Generator < Struct.new(:name, :base_dir, :src, :execs) - def gemspec - @gemspec ||= eval spec_source - end - - def spec_source - <<-GEMSPEC -Gem::Specification.new do |s| - s.name = #{name.dump} - s.version = #{version.dump} - s.summary = "This #{name} is bundled with Ruby" - s.executables = #{execs.inspect} - s.files = #{files.inspect} -end - GEMSPEC - end - - private - def version - version = open(src) { |f| - f.find { |s| /^\s*\w*VERSION\s*=(?!=)/ =~ s } - } or return - version.split(%r"=\s*", 2)[1].strip[/\A([\'\"])(.*?)\1/, 2] - end - - def files - file_collector = FileCollector.new(base_dir) - file_collector.collect - end - end end class UnpackedInstaller < Gem::Installer @@ -704,22 +673,6 @@ install?(:ext, :comm, :gem) do https://github.com/ruby/ruby/blob/trunk/tool/rbinstall.rb#L673 makedirs(default_spec_dir) gems = {} - File.foreach(File.join(srcdir, "defs/default_gems")) do |line| - line.chomp! - line.sub!(/\s*#.*/, '') - next if line.empty? - words = [] - line.scan(/\G\s*([^\[\]\s]+|\[([^\[\]]*)\])/) do - words << ($2 ? $2.split : $1) - end - name, base_dir, src, execs = *words - next unless name and base_dir and src - - src = File.join(srcdir, src) - base_dir = File.join(srcdir, base_dir) - specgen = RbInstall::Specs::Generator.new(name, base_dir, src, execs || []) - gems[name] ||= specgen - end Dir.glob(srcdir+"/{lib,ext}/**/*.gemspec").each do |src| specgen = RbInstall::Specs::Reader.new(src) -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/