Make string literal to frozen object on gemspec of defulte gems.
Added following gemspecs.
* extensions: date, dbm, etc, fiddle, gdbm, sdbm, stringio, strscan, zlib
* pure ruby libraries: cmath, csv, fileutils, scanf, webrick
psych and rdoc is out of scope of this commit. I will merge after
upstream was change to `frozen_string_literal: true`.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59115 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2017-06-19 09:03:06 -04:00
|
|
|
# frozen_string_literal: true
|
2017-02-27 04:20:39 -05:00
|
|
|
|
2019-07-09 23:33:29 -04:00
|
|
|
version = ["", "ext/etc/"].find do |dir|
|
|
|
|
begin
|
|
|
|
break File.open(File.expand_path("../#{dir}/etc.c", __FILE__)) do |f|
|
|
|
|
f.gets "\n#define RUBY_ETC_VERSION "
|
|
|
|
f.gets[/"(.+)"/, 1]
|
|
|
|
end
|
|
|
|
rescue
|
|
|
|
next
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
2017-04-11 05:46:53 -04:00
|
|
|
Gem::Specification.new do |spec|
|
|
|
|
spec.name = "etc"
|
2019-07-09 23:33:29 -04:00
|
|
|
spec.version = version
|
2017-04-11 05:46:53 -04:00
|
|
|
spec.authors = ["Yukihiro Matsumoto"]
|
|
|
|
spec.email = ["matz@ruby-lang.org"]
|
2017-02-27 04:20:39 -05:00
|
|
|
|
2017-04-11 05:46:53 -04:00
|
|
|
spec.summary = %q{Provides access to information typically stored in UNIX /etc directory.}
|
2019-07-09 23:32:35 -04:00
|
|
|
spec.description = spec.summary
|
2017-04-11 05:46:53 -04:00
|
|
|
spec.homepage = "https://github.com/ruby/etc"
|
2020-08-18 07:15:59 -04:00
|
|
|
spec.licenses = ["Ruby", "BSD-2-Clause"]
|
2017-04-11 05:46:53 -04:00
|
|
|
|
2022-01-03 07:38:03 -05:00
|
|
|
changelogs = Dir.glob("logs/ChangeLog-[1-9]*[^~]", base: __dir__)
|
2017-04-11 18:41:21 -04:00
|
|
|
spec.files = %w[
|
|
|
|
LICENSE.txt
|
|
|
|
README.md
|
2022-01-02 00:07:22 -05:00
|
|
|
ChangeLog
|
2019-07-09 23:32:35 -04:00
|
|
|
ext/etc/constdefs.h
|
2017-04-11 18:41:21 -04:00
|
|
|
ext/etc/etc.c
|
|
|
|
ext/etc/extconf.rb
|
|
|
|
ext/etc/mkconstants.rb
|
|
|
|
test/etc/test_etc.rb
|
2022-01-03 04:06:18 -05:00
|
|
|
] + changelogs
|
2022-01-02 00:07:22 -05:00
|
|
|
spec.rdoc_options = ["--main", "README.md"]
|
2022-01-03 04:06:18 -05:00
|
|
|
spec.extra_rdoc_files = spec.files.grep_v(/\.{rb,[ch]}\z/)
|
2017-04-11 05:46:53 -04:00
|
|
|
spec.bindir = "exe"
|
|
|
|
spec.require_paths = ["lib"]
|
2017-04-11 18:41:21 -04:00
|
|
|
spec.extensions = %w{ext/etc/extconf.rb}
|
2017-04-11 05:46:53 -04:00
|
|
|
|
2022-01-01 23:22:36 -05:00
|
|
|
spec.required_ruby_version = ">= 2.6.0"
|
2017-02-27 04:20:39 -05:00
|
|
|
end
|