[arch-commits] Commit in facter/trunk (PKGBUILD ruby23.patch)
Jonathan Steel
jsteel at archlinux.org
Fri Mar 18 19:38:20 UTC 2016
Date: Friday, March 18, 2016 @ 20:38:19
Author: jsteel
Revision: 167603
upgpkg: facter 3.1.5-1
Modified:
facter/trunk/PKGBUILD
Deleted:
facter/trunk/ruby23.patch
--------------+
PKGBUILD | 13 +++-----
ruby23.patch | 90 ---------------------------------------------------------
2 files changed, 6 insertions(+), 97 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2016-03-18 19:08:18 UTC (rev 167602)
+++ PKGBUILD 2016-03-18 19:38:19 UTC (rev 167603)
@@ -7,7 +7,7 @@
# Contributor: Niels Abspoel <aboe76 (at) Gmail (dot) com>
pkgname=facter
-pkgver=3.1.4
+pkgver=3.1.5
pkgrel=1
pkgdesc="Collect and display system facts"
arch=('i686' 'x86_64')
@@ -14,13 +14,11 @@
url="http://puppetlabs.com/facter"
license=('APACHE')
depends=('ruby' 'yaml-cpp' 'boost-libs' 'curl')
-makedepends=('boost' 'cmake' 'java-environment')
+makedepends=('boost' 'cmake' 'java-environment' 'leatherman')
optdepends=('java-environment: jruby support')
replaces=('cfacter')
-source=(http://downloads.puppetlabs.com/$pkgname/$pkgname-$pkgver.tar.gz
- ruby23.patch)
-md5sums=('47174a428fb77f5add2e84e8bf6fb894'
- 'cae82c863a8efe27688b7ef6fc66bc6f')
+source=(http://downloads.puppetlabs.com/$pkgname/$pkgname-$pkgver.tar.gz)
+md5sums=('b2a6e316dcda1361f8cfd8f7c9fefffd')
prepare() {
cd $pkgname-$pkgver
@@ -27,7 +25,8 @@
# Replace rb_data_object_alloc symbol with rb_data_object_wrap
# https://tickets.puppetlabs.com/browse/FACT-1291
- patch -Np1 -i ../ruby23.patch
+ sed -i 's/rb_data_object_alloc/rb_data_object_wrap/g' \
+ $( grep -rl rb_data_object_alloc lib/src/ruby )
}
build() {
Deleted: ruby23.patch
===================================================================
--- ruby23.patch 2016-03-18 19:08:18 UTC (rev 167602)
+++ ruby23.patch 2016-03-18 19:38:19 UTC (rev 167603)
@@ -1,90 +0,0 @@
-diff -uprb facter-3.1.3.orig/lib/src/ruby/aggregate_resolution.cc facter-3.1.3/lib/src/ruby/aggregate_resolution.cc
---- facter-3.1.3.orig/lib/src/ruby/aggregate_resolution.cc 2015-11-25 02:13:58.000000000 +0200
-+++ facter-3.1.3/lib/src/ruby/aggregate_resolution.cc 2015-12-29 02:03:30.735361627 +0200
-@@ -138,7 +138,7 @@ namespace facter { namespace ruby {
-
- // Create a resolution and wrap with a Ruby data object
- unique_ptr<aggregate_resolution> r(new aggregate_resolution());
-- VALUE self = r->_self = ruby.rb_data_object_alloc(klass, r.get(), mark, free);
-+ VALUE self = r->_self = ruby.rb_data_object_wrap(klass, r.get(), mark, free);
- ruby.register_data_object(self);
-
- // Release the smart pointer; ownership is now with Ruby's GC
-diff -uprb facter-3.1.3.orig/lib/src/ruby/fact.cc facter-3.1.3/lib/src/ruby/fact.cc
---- facter-3.1.3.orig/lib/src/ruby/fact.cc 2015-11-25 02:13:58.000000000 +0200
-+++ facter-3.1.3/lib/src/ruby/fact.cc 2015-12-29 02:03:30.738695043 +0200
-@@ -285,7 +285,7 @@ namespace facter { namespace ruby {
-
- // Create a fact and wrap with a Ruby data object
- unique_ptr<fact> f(new fact());
-- VALUE self = f->_self = ruby.rb_data_object_alloc(klass, f.get(), mark, free);
-+ VALUE self = f->_self = ruby.rb_data_object_wrap(klass, f.get(), mark, free);
- ruby.register_data_object(self);
-
- // Release the smart pointer; ownership is now with Ruby's GC
-diff -uprb facter-3.1.3.orig/lib/src/ruby/module.cc facter-3.1.3/lib/src/ruby/module.cc
---- facter-3.1.3.orig/lib/src/ruby/module.cc 2015-11-25 02:13:58.000000000 +0200
-+++ facter-3.1.3/lib/src/ruby/module.cc 2015-12-29 02:03:30.738695043 +0200
-@@ -50,7 +50,7 @@ namespace facter { namespace ruby {
- // The easiest way to get notified is to have a global data object that never gets collected
- // until the VM shuts down
- auto const& ruby = api::instance();
-- _canary = ruby.rb_data_object_alloc(*ruby.rb_cObject, this, nullptr, cleanup);
-+ _canary = ruby.rb_data_object_wrap(*ruby.rb_cObject, this, nullptr, cleanup);
- ruby.rb_gc_register_address(&_canary);
- ruby.register_data_object(_canary);
- }
-diff -uprb facter-3.1.3.orig/lib/src/ruby/simple_resolution.cc facter-3.1.3/lib/src/ruby/simple_resolution.cc
---- facter-3.1.3.orig/lib/src/ruby/simple_resolution.cc 2015-11-25 02:13:58.000000000 +0200
-+++ facter-3.1.3/lib/src/ruby/simple_resolution.cc 2015-12-29 02:03:30.738695043 +0200
-@@ -74,7 +74,7 @@ namespace facter { namespace ruby {
-
- // Create a resolution and wrap with a Ruby data object
- unique_ptr<simple_resolution> r(new simple_resolution());
-- VALUE self = r->_self = ruby.rb_data_object_alloc(klass, r.get(), mark, free);
-+ VALUE self = r->_self = ruby.rb_data_object_wrap(klass, r.get(), mark, free);
- ruby.register_data_object(self);
-
- // Release the smart pointer; ownership is now with Ruby's GC
-diff -uprb facter-3.1.3.orig/vendor/leatherman/ruby/inc/leatherman/ruby/api.hpp facter-3.1.3/vendor/leatherman/ruby/inc/leatherman/ruby/api.hpp
---- facter-3.1.3.orig/vendor/leatherman/ruby/inc/leatherman/ruby/api.hpp 2015-11-25 02:14:00.000000000 +0200
-+++ facter-3.1.3/vendor/leatherman/ruby/inc/leatherman/ruby/api.hpp 2015-12-29 02:03:30.738695043 +0200
-@@ -341,7 +341,7 @@ namespace leatherman { namespace ruby {
- /**
- * See MRI documentation.
- */
-- VALUE (* const rb_data_object_alloc)(VALUE, void*, RUBY_DATA_FUNC, RUBY_DATA_FUNC);
-+ VALUE (* const rb_data_object_wrap)(VALUE, void*, RUBY_DATA_FUNC, RUBY_DATA_FUNC);
- /**
- * See MRI documentation.
- */
-@@ -621,7 +621,7 @@ namespace leatherman { namespace ruby {
-
- /**
- * Gets the underlying native instance from a Ruby data object.
-- * The Ruby object must have been allocated with rb_data_object_alloc.
-+ * The Ruby object must have been allocated with rb_data_object_wrap.
- * @tparam T The underlying native type.
- * @param obj The Ruby data object to get the native instance for.
- * @return Returns a pointer to the underlying native type.
-@@ -634,7 +634,7 @@ namespace leatherman { namespace ruby {
-
- /**
- * Registers a data object for cleanup when the API is destructed.
-- * The object must have been created with rb_data_object_alloc.
-+ * The object must have been created with rb_data_object_wrap.
- * @param obj The data object to register.
- */
- void register_data_object(VALUE obj) const
-diff -uprb facter-3.1.3.orig/vendor/leatherman/ruby/src/api.cc facter-3.1.3/vendor/leatherman/ruby/src/api.cc
---- facter-3.1.3.orig/vendor/leatherman/ruby/src/api.cc 2015-11-25 02:14:00.000000000 +0200
-+++ facter-3.1.3/vendor/leatherman/ruby/src/api.cc 2015-12-29 02:03:30.738695043 +0200
-@@ -80,7 +80,7 @@ namespace leatherman { namespace ruby {
- LOAD_SYMBOL(rb_to_id),
- LOAD_SYMBOL(rb_id2name),
- LOAD_SYMBOL(rb_define_alloc_func),
-- LOAD_SYMBOL(rb_data_object_alloc),
-+ LOAD_SYMBOL(rb_data_object_wrap),
- LOAD_SYMBOL(rb_gc_mark),
- LOAD_SYMBOL(rb_yield_values),
- LOAD_SYMBOL(rb_require),
More information about the arch-commits
mailing list