-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
use rubygems/package_task, add --exclude in rdoc_options
- Loading branch information
Showing
4 changed files
with
67 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,7 +13,6 @@ na_op.c | |
|
||
pkg/ | ||
src | ||
ext | ||
doc | ||
|
||
narray-*.gem |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,19 @@ | ||
2013-02-27 Masahiro TANAKA <[email protected]> | ||
|
||
* Rakefile: use rubygems/package_task. | ||
* narray.gemspec: add --exclude in rdoc_options. | ||
* ver 0.6.0.8 | ||
|
||
2013-02-26 Masahiro TANAKA <[email protected]> | ||
|
||
* test/ld.rb: add require "rubygems". | ||
* narray.gemspec: change gem directory from src to ext. | ||
* narray.c: avoid warnings in require "complex" and rdoc parsing. | ||
|
||
2013-02-13 Masahiro TANAKA <[email protected]> | ||
|
||
* lib/narray_ext.rb: new method: NArray.cast | ||
|
||
2013-02-01 Masahiro TANAKA <[email protected]> | ||
|
||
* lib/narray_ext.rb: eql? hash methods implemented. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,24 @@ | ||
require 'rubygems' | ||
require 'rubygems/package_task' | ||
|
||
def version | ||
open("narray.h") do |f| | ||
f.each_line do |l| | ||
return $1 if /NARRAY_VERSION "([\d.]+)"/ =~ l | ||
end | ||
end | ||
end | ||
|
||
GEM = "narray-#{version}.gem" | ||
FileUtils.ln_s('.', 'src') if !File.symlink?('src') | ||
|
||
task :default => GEM | ||
load './narray.gemspec' | ||
|
||
file GEM => "ext" do | ||
sh "gem build narray.gemspec" | ||
pkgtsk = Gem::PackageTask.new(GEMSPEC) do |pkg| | ||
pkg.need_zip = true | ||
pkg.need_tar = true | ||
end | ||
|
||
file "ext" do | ||
sh "ln -s . ext" | ||
end | ||
task :default => "gem" | ||
|
||
#-- | ||
GEMFILE = File.join(pkgtsk.package_dir, GEMSPEC.file_name) | ||
|
||
task :install => GEM do | ||
sh "gem install -V --backtrace #{GEM}" | ||
task :install => GEMFILE do | ||
sh "gem install -V --backtrace #{GEMFILE}" | ||
end | ||
|
||
task :push => GEM do | ||
sh "gem push #{GEM}" | ||
task :push => GEMFILE do | ||
sh "gem push #{GEMFILE}" | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
open("ext/narray.h") do |f| | ||
open("src/narray.h") do |f| | ||
f.each_line do |l| | ||
if /NARRAY_VERSION "([\d.]+)"/ =~ l | ||
NARRAY_VERSION = $1 | ||
|
@@ -7,7 +7,7 @@ open("ext/narray.h") do |f| | |
end | ||
end | ||
|
||
Gem::Specification.new do |s| | ||
GEMSPEC = Gem::Specification.new do |s| | ||
s.name = "narray" | ||
s.version = NARRAY_VERSION | ||
|
||
|
@@ -16,31 +16,42 @@ Gem::Specification.new do |s| | |
s.date = Time.now.strftime("%F") | ||
s.description = "Numerical N-dimensional Array class" | ||
s.email = "[email protected]" | ||
s.extensions = ["ext/extconf.rb"] | ||
s.extensions = ["src/extconf.rb"] | ||
s.files = %w[ | ||
ext/ChangeLog | ||
ext/MANIFEST | ||
ext/README.en | ||
ext/README.ja | ||
ext/SPEC.en | ||
ext/SPEC.ja | ||
ext/depend | ||
ext/extconf.rb | ||
ext/mkmath.rb | ||
ext/mknafunc.rb | ||
ext/mkop.rb | ||
ext/na_array.c | ||
ext/na_func.c | ||
ext/na_index.c | ||
ext/na_linalg.c | ||
ext/na_random.c | ||
ext/narray.c | ||
ext/narray.def | ||
ext/narray.h | ||
ext/narray_local.h | ||
ext/lib/narray_ext.rb | ||
ext/lib/nmatrix.rb | ||
ChangeLog | ||
MANIFEST | ||
README.en | ||
README.ja | ||
SPEC.en | ||
SPEC.ja | ||
src/depend | ||
src/extconf.rb | ||
src/mkmath.rb | ||
src/mknafunc.rb | ||
src/mkop.rb | ||
src/na_array.c | ||
src/na_func.c | ||
src/na_index.c | ||
src/na_linalg.c | ||
src/na_random.c | ||
src/narray.c | ||
src/narray.def | ||
src/narray.h | ||
src/narray_local.h | ||
src/lib/narray_ext.rb | ||
src/lib/nmatrix.rb | ||
] | ||
s.rdoc_options = %w[ | ||
--title NArray | ||
--main NArray | ||
--exclude mk.* | ||
--exclude extconf\.rb | ||
--exclude src/.*\.h | ||
--exclude src/lib/ | ||
--exclude .*\.o | ||
--exclude narray\.so | ||
--exclude libnarray\.* | ||
] | ||
s.homepage = "http://narray.rubyforge.org/" | ||
s.require_paths = ["."] | ||
s.rubyforge_project = "narray" | ||
|