Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
R
ruby-ffi
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Debian Ruby Team
ruby-ffi
Commits
e963c038
Commit
e963c038
authored
10 years ago
by
Antonio Terceiro
Browse files
Options
Downloads
Patches
Plain Diff
Fix ppc64el
parent
74d0e2b3
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
debian/changelog
+7
-3
7 additions, 3 deletions
debian/changelog
debian/patches/fix-for-variadic-float-double-values.diff
+35
-0
35 additions, 0 deletions
debian/patches/fix-for-variadic-float-double-values.diff
debian/patches/series
+1
-0
1 addition, 0 deletions
debian/patches/series
with
43 additions
and
3 deletions
debian/changelog
+
7
−
3
View file @
e963c038
ruby-ffi (1.9.3debian-3) UNRELEASED; urgency=medium
* debian/tests/control: also run test suite with
gem2deb-test-runner --autopkgtest
- needed to add './' to spec file glob in debian/ruby-tests.rb
* debian/tests/control: also run test suite with
gem2deb-test-runner --autopkgtest
- needed to add './' to spec file glob in debian/ruby-tests.rb
* Add patch by Anurag Gupta <anurag@linux.vnet.ibm.com> from Ubuntu that
fixes call to functions with float/double variadic arguments. This should
fix ruby-ffi on ppc64el, _and_ be harmless for other architectures.
(debian/patches/fix-for-variadic-float-double-values.diff)
-- Antonio Terceiro <terceiro@debian.org> Sun, 24 Aug 2014 10:40:11 -0300
...
...
This diff is collapsed.
Click to expand it.
debian/patches/fix-for-variadic-float-double-values.diff
0 → 100644
+
35
−
0
View file @
e963c038
Description: Fix for failing float/double variadic args test cases in ruby-ffi package
This patch will fix the problem of passing float/double values as part of variadic
argument list from ruby-ffi package. All the test cases related to float/double arguments
passed as part of ruby variadic list were failing on ppc64le arch. Problem was due to
incorrect way to call C method ffi_prep_cif_var, where third argument was passed as total
number of arguments instead of fixed number of arguments
Author: Anurag Gupta <anurag@linux.vnet.ibm.com>
---
--- ruby-ffi-1.9.3debian.orig/ext/ffi_c/Variadic.c
+++ ruby-ffi-1.9.3debian/ext/ffi_c/Variadic.c
@@ -170,7 +170,7 @@
variadic_invoke(VALUE self, VALUE parame
ffi_type* ffiReturnType;
Type** paramTypes;
VALUE* argv;
- int paramCount = 0, i;
+ int paramCount = 0, fixedCount = 0, i;
ffi_status ffiStatus;
rbffi_frame_t frame = { 0 };
@@ -229,8 +229,12 @@
variadic_invoke(VALUE self, VALUE parame
if (ffiReturnType == NULL) {
rb_raise(rb_eArgError, "Invalid return type");
}
+
+ /*Get the number of fixed args from @fixed array*/
+ fixedCount = RARRAY_LEN(rb_iv_get(self, "@fixed"));
+
#ifdef HAVE_FFI_PREP_CIF_VAR
- ffiStatus = ffi_prep_cif_var(&cif, invoker->abi, paramCount, paramCount, ffiReturnType, ffiParamTypes);
+ ffiStatus = ffi_prep_cif_var(&cif, invoker->abi, fixedCount, paramCount, ffiReturnType, ffiParamTypes);
#else
ffiStatus = ffi_prep_cif(&cif, invoker->abi, paramCount, ffiReturnType, ffiParamTypes);
#endif
This diff is collapsed.
Click to expand it.
debian/patches/series
+
1
−
0
View file @
e963c038
disable-rake-compiler.patch
mip64el.patch
arm64.patch
fix-for-variadic-float-double-values.diff
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment