2

I need to install pg gem, but the installation failed. I've tried all the solution propesed in other questions but no luck.

Here is my output, and here is my "mkmf.log" file

Any idea?

[UPDATE]

I've solved the first problem by putting libs in the correct directory. But now I've another problem:

find_executable: checking for pg_config... -------------------- yes
--------------------
"gcc -o conftest -I/usr/include/ruby-1.9.1/i686-linux -I/usr/include/ruby-1.9.1/ruby/backward -I/usr/include/ruby-1.9.1 -I. -I/usr/include/postgresql -D_FILE_OFFSET_BITS=64 -fno-strict-aliasing -g -g -O2 -fPIC conftest.c -L. -L/usr/lib -L/usr/lib -L. -Wl,-Bsymbolic-functions -rdynamic -Wl,-export-dynamic -lruby-1.9.1-static -lpthread -lrt -ldl -lcrypt -lm -lc"
/usr/bin/ld: cannot find crtbegin.o: No such file or directory
collect2: ld returned 1 exit status
checked program was:
/* begin */
1: #include "ruby.h"
2: 
3: int main() {return 0;}
/* end */

[UPDATE2]

Solved it by putting links to "libgcc", "libgcc_s", "crtend.o", "crtendS.o", "crtbeginS.o" and "crtbegin.o" into /usr/lib

asked Nov 16, 2013 at 17:39

1 Answer 1

1

It looks like you are missing development libraries even for glibc. Just install devel packages for glibc and postgresql and try again.

answered Nov 16, 2013 at 17:55
Sign up to request clarification or add additional context in comments.

2 Comments

@Trenza It looks like base header files are not found in standard directories. Does exist /usr/include/sys/cdefs.h ? glibc devel package should place it there.
No! sys dir doesn't exist. I've found it in /usr/include/i386-linux-gnu/sys/cdefs.h

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.