Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make fails on Cygwin64bit #317

Closed
DQNEO opened this issue Dec 28, 2013 · 11 comments
Closed

make fails on Cygwin64bit #317

DQNEO opened this issue Dec 28, 2013 · 11 comments

Comments

@DQNEO
Copy link

@DQNEO DQNEO commented Dec 28, 2013

$ gem install ffi
...
Call.o: In function `call_blocking_function':
/home/DK/.rbenv/versions/2.1.0-rc1/lib/ruby/gems/2.1.0/gems/ffi-1.9.3/ext/ffi_c/Call.c:294: undefined reference to `ffi_call'
/home/DK/.rbenv/versions/2.1.0-rc1/lib/ruby/gems/2.1.0/gems/ffi-1.9.3/ext/ffi_c/Call.c:294:(.text+0xa4): relocation truncated to fit: R_X86_64_PC32 against undefined symbol `ffi_call'
Call.o: In function `rbffi_CallFunction':
/home/DK/.rbenv/versions/2.1.0-rc1/lib/ruby/gems/2.1.0/gems/ffi-1.9.3/ext/ffi_c/Call.c:378: undefined reference to `ffi_call'
/home/DK/.rbenv/versions/2.1.0-rc1/lib/ruby/gems/2.1.0/gems/ffi-1.9.3/ext/ffi_c/Call.c:378:(.text+0xa89): relocation truncated to fit: R_X86_64_PC32 against undefined symbol `ffi_call'
Variadic.o: In function `variadic_invoke':
/home/DK/.rbenv/versions/2.1.0-rc1/lib/ruby/gems/2.1.0/gems/ffi-1.9.3/ext/ffi_c/Variadic.c:252: undefined reference to `ffi_call'
/home/DK/.rbenv/versions/2.1.0-rc1/lib/ruby/gems/2.1.0/gems/ffi-1.9.3/ext/ffi_c/Variadic.c:252:(.text+0x36d): relocation truncated to fit: R_X86_64_PC32 against undefined symbol `ffi_call'
/home/DK/.rbenv/versions/2.1.0-rc1/lib/ruby/gems/2.1.0/gems/ffi-1.9.3/ext/ffi_c/libffi-x86_64-cygwin/.libs/libffi_convenience.a(prep_cif.o): In function `ffi_prep_cif':
/home/DK/.rbenv/versions/2.1.0-rc1/lib/ruby/gems/2.1.0/gems/ffi-1.9.3/ext/ffi_c/libffi/src/prep_cif.c:162: undefined reference to `ffi_prep_cif_machdep'
/home/DK/.rbenv/versions/2.1.0-rc1/lib/ruby/gems/2.1.0/gems/ffi-1.9.3/ext/ffi_c/libffi/src/prep_cif.c:162:(.text+0x272): relocation truncated to fit: R_X86_64_PC32 against undefined symbol `ffi_prep_cif_machdep'
/home/DK/.rbenv/versions/2.1.0-rc1/lib/ruby/gems/2.1.0/gems/ffi-1.9.3/ext/ffi_c/libffi-x86_64-cygwin/.libs/libffi_convenience.a(prep_cif.o): In function `ffi_prep_closure':
/home/DK/.rbenv/versions/2.1.0-rc1/lib/ruby/gems/2.1.0/gems/ffi-1.9.3/ext/ffi_c/libffi/src/prep_cif.c:174: undefined reference to `ffi_prep_closure_loc'
/home/DK/.rbenv/versions/2.1.0-rc1/lib/ruby/gems/2.1.0/gems/ffi-1.9.3/ext/ffi_c/libffi/src/prep_cif.c:174:(.text+0x2b7): relocation truncated to fit: R_X86_64_PC32 against undefined symbol `ffi_prep_closure_loc'
collect2: error: ld returned 1 exit status
Makefile:232: recipe for target 'ffi_c.so' failed
make: *** [ffi_c.so] Error 1
@gailu
Copy link

@gailu gailu commented Jan 2, 2014

I am also getting exact same issue on cygwin64. Following ruby on rails tutorial.

@qnighy
Copy link

@qnighy qnighy commented Apr 1, 2014

@isaacwaller
Copy link

@isaacwaller isaacwaller commented Apr 7, 2014

that patch worked amazing for me as well. thanks @qnighy

simi referenced this issue in msys2/MSYS2-packages Apr 7, 2014
@DQNEO
Copy link
Author

@DQNEO DQNEO commented May 3, 2014

I solved it!!
see #284 (comment)

@DQNEO DQNEO closed this May 3, 2014
@iray-tno
Copy link

@iray-tno iray-tno commented Oct 13, 2014

I solved it by installing following packages

  • libffi6
  • libffi-devel
  • cygwin32-libffi
  • ruby-pkg-config

no need to edit PKG_CONFIG_PATH

@clacke
Copy link

@clacke clacke commented Oct 31, 2014

No need for cygwin32-libffi.

@seantunwin
Copy link

@seantunwin seantunwin commented Nov 7, 2014

Thanks @iray-tno.
ruby-pkg-config was the one I didn't have that I needed.

@whitelancer
Copy link

@whitelancer whitelancer commented Nov 26, 2014

+1 @iray-tno and @seantunwin; ruby-pkg-config is also what I needed. Not sure how I would have figured that out based on the error messages!

@dansheffler
Copy link

@dansheffler dansheffler commented Dec 24, 2014

This error came up for me while installing Jekyll under Cygwin. I also was able to solve it be installing ruby-pkg-config and libffi-devel via setup.

@amccrea
Copy link

@amccrea amccrea commented Feb 1, 2015

Thanks iray-tno, those libraries fixed it for me as well.

@keithdtyler
Copy link

@keithdtyler keithdtyler commented Jun 18, 2015

I just needed libffi and libffi-devel. cygwin32-libffi and ruby-pkg-config weren't necessary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet