- using rvm
- using ruby 1.9.2
- identical gems (and support libs) installed in OS X
- link-grammar installed (via apt-get)
- pkg-config working as expected.
When I run gem install linkparser
I get the following error:
Building native extensions. This could take a while... ERROR: Error installing linkparser: ERROR: Failed to build gem native extension. /home/locallyclient/.rvm/rubies/ruby-1.9.2-p0/bin/ruby extconf.rb checking for pkg-config... yes checking for dictionary_create() in -llink-grammar... *** extconf.rb failed *** Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the mkmf.log file for more details. You may need configuration options.
(plus more including cmd line options and stack trace).
mkmf.log looks like:
"gcc -o conftest -I/~/.rvm/rubies/ruby-1.9.2-p0/include/ruby-1.9.1/i686-linux -I/~/.rvm/rubies/ruby-1.9.2-p0/include/ruby-1.9.1/ruby/backward -I /~/.rvm/rubies/ruby-1.9.2-p0/include/ruby-1.9.1 -I. -D_FILE_OFFSET_BITS=64 -O3 -ggdb -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-st rings -Wno-missing-field-initializers -Wno-long-long -fPIC-I/usr/local/include conftest.c -L. -L/~/.rvm/rubies/ruby-1.9.2-p0/lib -Wl,-R/~/.r vm/rubies/ruby-1.9.2-p0/lib -L. -rdynamic -Wl,-export-dynamic-L/usr/local/lib -Wl,-R -Wl,/~.rvm/rubies/ruby-1.9.2-p0/lib -L/~/.rvm/rubie s/ruby-1.9.2-p0/lib -lruby-static -lpthread -lrt -ldl -lcrypt -lm -lc" cc1: error: unrecognized command line option "-fPIC-I/usr/local/include" checked program was: /* begin / 1: #include "ruby.h" 2: 3: int main() {return 0;} / end */( I replace the home path with '~' for easier reading)
Specifically: cc1: error: unrecognized command line option "-fPIC-I/usr/local/include"
Any ideas as to why this paramater would be mangled and where I can fix it?