[DRE-commits] [SCM] Packaging for ruby-lapack branch, master, updated. upstream/1.2-6-gf131914

Youhei SASAKI uwabami at gfd-dennou.org
Mon May 2 07:37:32 UTC 2011


The following commit has been merged in the master branch:
commit f131914eb1709c62e60005edc37e4b3cb4be57cc
Author: Youhei SASAKI <uwabami at gfd-dennou.org>
Date:   Mon May 2 16:34:19 2011 +0900

    Add test-suite
    
    Signed-off-by: Youhei SASAKI <uwabami at gfd-dennou.org>

diff --git a/debian/changelog b/debian/changelog
index c503294..551763b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,11 @@
-ruby-lapack (1.2-1) UNRELEASED; urgency=low
+ruby-lapack (1.5-1) unstable; urgency=low
 
+  [ Youhei SASAKI ]
   * Initial release (Closes: #619219) 
-  TODO: need a short test suite
+  * Imported Upstream version 1.5
 
- -- Youhei SASAKI <uwabami at gfd-dennou.org>  Wed, 06 Apr 2011 00:09:42 +0900
+  [ Lucas Nussbaum ]
+  * remove --with quilt, not needed
+  * mention state in changelog
+
+ -- Youhei SASAKI <uwabami at gfd-dennou.org>  Mon, 02 May 2011 15:39:11 +0900
diff --git a/debian/control b/debian/control
index 4ad6723..d5fe37f 100644
--- a/debian/control
+++ b/debian/control
@@ -4,19 +4,20 @@ Priority: optional
 Maintainer: Debian Ruby Extras Maintainers <pkg-ruby-extras-maintainers at lists.alioth.debian.org>
 Uploaders: Youhei SASAKI <uwabami at gfd-dennou.org>
 DM-Upload-Allowed: yes
-Build-Depends: debhelper (>= 7.0.50~), gem2deb (>= 0.1.0), quilt (>= 0.46-7~),
-  ruby1.8-dev, ruby1.8, libnarray-ruby1.8,
-  ruby1.9.1-dev, ruby1.9.1, libnarray-ruby1.9.1,
+Build-Depends: debhelper (>= 7.0.50~), gem2deb (>= 0.2.0), 
+  libnarray-ruby1.8 | ruby-narray,
+  libnarray-ruby1.9.1 | ruby-narray,
   liblapack-dev
 XS-Ruby-Versions: all
-Standards-Version: 3.9.1
+Standards-Version: 3.9.2
 Homepage: http://www.gfd-dennou.org/arch/ruby/products/ruby-lapack/index.html
 Vcs-Git: git://git.debian.org/pkg-ruby-extras/ruby-lapack.git
 Vcs-Browser: http://git.debian.org/?p=pkg-ruby-extras/ruby-lapack.git;a=summary
 
 Package: ruby-lapack
 Architecture: any
-Depends: ${ruby:Version}, ${shlibs:Depends}, ${misc:Depends}
+XB-Ruby-Versions: ${ruby:Version}
+Depends: ${shlibs:Depends}, ${misc:Depends}
 Description: Ruby wrapper of LAPACK
  Ruby-LAPACK is Ruby wrapper of LAPACK library using NArray.
  .
@@ -26,7 +27,8 @@ Package: ruby-lapack-dbg
 Section: debug
 Priority: extra
 Architecture: any
-Depends: ${ruby:Version}, ${shlibs:Depends}, ${misc:Depends}, ruby-lapack (=${binary:Version})
+XB-Ruby-Versions: ${ruby:Version}
+Depends: ${misc:Depends}, ruby-lapack (=${binary:Version})
 Description: Ruby wrapper of LAPACK
  Ruby-LAPACK is Ruby wrapper of LAPACK library using NArray.
  .
diff --git a/debian/patches/AddLAPACKPath b/debian/patches/AddLAPACKPath
deleted file mode 100644
index 67d7767..0000000
--- a/debian/patches/AddLAPACKPath
+++ /dev/null
@@ -1,15 +0,0 @@
---- ruby-lapack.orig/extconf.rb
-+++ ruby-lapack/extconf.rb
-@@ -128,6 +128,12 @@
-   end
- #end
- 
-+dir_config("lapack")
-+unless find_library("lapack", nil, "liblapack.so")
-+  library_not_found("lapack", "liblapack.so")
-+end
-+
-+
- sitearchdir = Config::CONFIG["sitearchdir"]
- dir_config("narray", sitearchdir, sitearchdir)
- unless find_header("narray.h") && have_header("narray_config.h")
diff --git a/debian/patches/FixLibraryPath b/debian/patches/FixLibraryPath
index fe417a9..3911d4d 100644
--- a/debian/patches/FixLibraryPath
+++ b/debian/patches/FixLibraryPath
@@ -1,6 +1,6 @@
---- ruby-lapack.orig/extconf.rb
-+++ ruby-lapack/extconf.rb
-@@ -97,7 +97,7 @@
+--- ruby-lapack.orig/ext/extconf.rb
++++ ruby-lapack/ext/extconf.rb
+@@ -41,7 +41,7 @@
  
    name = with_config("blas-name","blas_LINUX.a")
    unless have_library(name)
@@ -9,7 +9,7 @@
      _libarg = LIBARG
      LIBARG.replace "#{lib_path}/%s"
      unless have_library(name)
-@@ -107,7 +107,7 @@
+@@ -51,7 +51,7 @@
    end
    name = with_config("lapack-name","lapack_LINUX.a")
    unless have_library(name)
@@ -18,14 +18,24 @@
      _libarg = LIBARG
      LIBARG.replace "#{lib_path}/%s"
      unless have_library(name)
-@@ -117,8 +117,8 @@
+@@ -61,17 +61,9 @@
    end
  end
  
 -sitearchdir = Config::CONFIG["sitearchdir"]
 -dir_config("narray", sitearchdir, sitearchdir)
+-gem_path = nil
+-begin
+-  require "rubygems"
+-  if (spec = Gem.source_index.find_name("narray")).any?
+-    gem_path = spec.last.full_gem_path
+-  end
+-rescue LoadError
+-end
+-unless find_header("narray.h",gem_path) && have_header("narray_config.h")
 +archdir = Config::CONFIG["archdir"]
 +dir_config("narray", archdir, archdir)
- unless find_header("narray.h") && have_header("narray_config.h")
++unless find_header("narray.h", archdir) && have_header("narray_config.h")
    header_not_found("narray")
  end
+ 
diff --git a/debian/ruby-lapack.docs b/debian/ruby-lapack.docs
index f528701..e475c53 100644
--- a/debian/ruby-lapack.docs
+++ b/debian/ruby-lapack.docs
@@ -1,2 +1 @@
-README
-doc
+README.rdoc
diff --git a/debian/ruby-tests.rb b/debian/ruby-tests.rb
new file mode 100644
index 0000000..19cb5e4
--- /dev/null
+++ b/debian/ruby-tests.rb
@@ -0,0 +1,5 @@
+if RUBY_VERSION <= '1.9.0'
+  system("#{ENV['RUBY_TEST_BIN']} -Itest-lib /usr/bin/testrb1.8 tests/")
+else
+  system("#{ENV['RUBY_TEST_BIN']} -Itest-lib /usr/bin/testrb1.9.1 tests/")
+end
diff --git a/debian/rules b/debian/rules
index 7784c35..dba64b8 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,13 +1,17 @@
 #!/usr/bin/make -f
 
-RUBY_ARCH=$(strip $(shell ruby -rrbconfig -e 'puts Config::CONFIG["arch"]'))
 %:
 	dh $@ --buildsystem=ruby --with ruby
 
-override_dh_auto_install:
-	dh_auto_install
-	rm -f $(CURDIR)/debian/ruby-lapack/usr/lib/ruby/vendor_ruby/1.8/$(RUBY_ARCH)/numru/lapack.rb
-	rm -f $(CURDIR)/debian/ruby-lapack/usr/lib/ruby/vendor_ruby/1.9.1/$(RUBY_ARCH)/numru/lapack.rb
+override_dh_auto_build:
+	# I know, it's dirty hack ... :-/
+	mkdir -p $(CURDIR)/test-lib/numru
+	ln -s ../../ext/lapack.so $(CURDIR)/test-lib/numru/
+	
 
 override_dh_strip:
 	dh_strip --dbg-package=ruby-lapack-dbg
+
+override_dh_auto_clean:
+	dh_auto_clean
+	rm -fr $(CURDIR)/test-lib
diff --git a/ext/extconf.rb b/ext/extconf.rb
index e7cbb43..517e135 100644
--- a/ext/extconf.rb
+++ b/ext/extconf.rb
@@ -41,7 +41,7 @@ unless find_library("lapack", nil)
 
   name = with_config("blas-name","blas_LINUX.a")
   unless have_library(name)
-    lib_path = with_config("blas-lib","/usr/local/lib")
+    lib_path = with_config("blas-lib","/usr/lib")
     _libarg = LIBARG
     LIBARG.replace "#{lib_path}/%s"
     unless have_library(name)
@@ -51,7 +51,7 @@ unless find_library("lapack", nil)
   end
   name = with_config("lapack-name","lapack_LINUX.a")
   unless have_library(name)
-    lib_path = with_config("lapack-lib","/usr/local/lib")
+    lib_path = with_config("lapack-lib","/usr/lib")
     _libarg = LIBARG
     LIBARG.replace "#{lib_path}/%s"
     unless have_library(name)
@@ -61,17 +61,9 @@ unless find_library("lapack", nil)
   end
 end
 
-sitearchdir = Config::CONFIG["sitearchdir"]
-dir_config("narray", sitearchdir, sitearchdir)
-gem_path = nil
-begin
-  require "rubygems"
-  if (spec = Gem.source_index.find_name("narray")).any?
-    gem_path = spec.last.full_gem_path
-  end
-rescue LoadError
-end
-unless find_header("narray.h",gem_path) && have_header("narray_config.h")
+archdir = Config::CONFIG["archdir"]
+dir_config("narray", archdir, archdir)
+unless find_header("narray.h", archdir) && have_header("narray_config.h")
   header_not_found("narray")
 end
 

-- 
Packaging for ruby-lapack



More information about the Pkg-ruby-extras-commits mailing list