[DRE-commits] [SCM] ruby-ncurses.git branch, master, updated. upstream/1.2.4-16-gd699268

Per Andersson avtobiff at gmail.com
Thu May 3 22:52:38 UTC 2012


The following commit has been merged in the master branch:
commit 0116e1173ce76627ea1505101e5a79d0da8410e5
Author: Per Andersson <avtobiff at gmail.com>
Date:   Fri May 4 00:32:41 2012 +0200

    Build for all Ruby versions.
    
    * Add Ruby >= 1.9 compatibility patch.
    * Depend on ruby instead of ruby1.8.

diff --git a/debian/control b/debian/control
index 7f6112b..576446e 100644
--- a/debian/control
+++ b/debian/control
@@ -9,12 +9,12 @@ Standards-Version: 3.9.1
 Vcs-Git: git://git.debian.org/pkg-ruby-extras/ruby-ncurses.git
 Vcs-Browser: http://git.debian.org/?p=pkg-ruby-extras/ruby-ncurses.git;a=summary
 Homepage: http://ncurses-ruby.berlios.de/
-XS-Ruby-Versions: ruby1.8
+XS-Ruby-Versions: all
 
 Package: ruby-ncurses
 Architecture: any
 XB-Ruby-Versions: ${ruby:Versions}
-Depends: ${shlibs:Depends}, ${misc:Depends}, ruby1.8 | ruby-interpreter
+Depends: ${shlibs:Depends}, ${misc:Depends}, ruby | ruby-interpreter
 Replaces: libncurses-ruby (<< 1.2.4-1~), libncurses-ruby1.8 (<< 1.2.4-1~), libncurses-ruby1.9.1 (<< 1.2.4-1~), libncurses-ruby1.9 (<< 1.2.4-1~)
 Conflicts: libncurses-ruby (<< 1.2.4-1~), libncurses-ruby1.8 (<< 1.2.4-1~), libncurses-ruby1.9.1 (<< 1.2.4-1~), libncurses-ruby1.9 (<< 1.2.4-1~)
 Provides: libncurses-ruby, libncurses-ruby1.8, libncurses-ruby1.9.1, libncurses-ruby1.9, ruby-ncursesw
diff --git a/debian/patches/0001-Define-STR2CSTR-macro.patch b/debian/patches/0001-Define-STR2CSTR-macro.patch
new file mode 100644
index 0000000..aa3a886
--- /dev/null
+++ b/debian/patches/0001-Define-STR2CSTR-macro.patch
@@ -0,0 +1,78 @@
+From: Per Andersson <avtobiff at gmail.com>
+Date: Mon, 9 Apr 2012 16:49:52 +0200
+Subject: Define STR2CSTR macro
+
+STR2CSTR is removed since Ruby 1.9.0. Define it to make ruby-ncurses
+work for Ruby >= 1.9.0.
+---
+ compat.h       |    8 ++++++++
+ form_wrap.c    |    1 +
+ menu_wrap.c    |    1 +
+ ncurses_wrap.c |    1 +
+ panel_wrap.c   |    1 +
+ 5 files changed, 12 insertions(+), 0 deletions(-)
+ create mode 100644 compat.h
+
+diff --git a/compat.h b/compat.h
+new file mode 100644
+index 0000000..3d07271
+--- /dev/null
++++ b/compat.h
+@@ -0,0 +1,8 @@
++#ifndef _COMPAT_H
++#define _COMPAT_H
++
++#ifndef STR2CSTR
++#define STR2CSTR(x) ({ VALUE *y = (x); StringValuePtr(y); })
++#endif
++
++#endif /* _COMPAT_H */
+diff --git a/form_wrap.c b/form_wrap.c
+index 346d443..c1a9e47 100644
+--- a/form_wrap.c
++++ b/form_wrap.c
+@@ -31,6 +31,7 @@
+ 
+ #include "form_wrap.h"
+ #include "ncurses_wrap.h"
++#include "compat.h"
+ 
+ VALUE mForm;
+ VALUE cFIELD;
+diff --git a/menu_wrap.c b/menu_wrap.c
+index f76582f..2878723 100644
+--- a/menu_wrap.c
++++ b/menu_wrap.c
+@@ -30,6 +30,7 @@
+ 
+ #include "menu_wrap.h"
+ #include "ncurses_wrap.h"
++#include "compat.h"
+ 
+ VALUE mMenu;
+ VALUE cITEM;
+diff --git a/ncurses_wrap.c b/ncurses_wrap.c
+index 09609d1..f342c61 100755
+--- a/ncurses_wrap.c
++++ b/ncurses_wrap.c
+@@ -65,6 +65,7 @@
+ */
+ 
+ #include "ncurses_wrap.h"
++#include "compat.h"
+ #ifdef HAVE_LOCALE_H
+ #include <locale.h>
+ #endif
+diff --git a/panel_wrap.c b/panel_wrap.c
+index 9680b25..53b282b 100644
+--- a/panel_wrap.c
++++ b/panel_wrap.c
+@@ -24,6 +24,7 @@
+ 
+ #include "panel_wrap.h"
+ #include "ncurses_wrap.h"
++#include "compat.h"
+ 
+ VALUE mPanel;
+ VALUE cPANEL;
+-- 
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..9f6de4f
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+0001-Define-STR2CSTR-macro.patch

-- 
ruby-ncurses.git



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