if fails with : make[4]: Entering directory `/usr/olocal/gentoo/tmp/portage/dev-db/postgresql-8.0.13/work/postgresql-8.0.13/src/interfaces/ecpg/pgtypeslib' make[4]: Nothing to be done for `all'. make[4]: Leaving directory `/usr/olocal/gentoo/tmp/portage/dev-db/postgresql-8.0.13/work/postgresql-8.0.13/src/interfaces/ecpg/pgtypeslib' make -C ecpglib all make[4]: Entering directory `/usr/olocal/gentoo/tmp/portage/dev-db/postgresql-8.0.13/work/postgresql-8.0.13/src/interfaces/ecpg/ecpglib' i686-pc-linux-gnu-gcc -march=i586 -O3 -pipe -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif-labels -fno-strict-aliasing -fpic -shared -Wl,-soname,libecpg.so.5 execute.o typename.o descriptor.o data.o error.o prepare.o memory.o connect.o misc.o path.o exec.o -L../pgtypeslib -L../../../../src/interfaces/libpq -L../../../../src/port -lpgtypes -lpq -lssl -lcrypto -lcrypt -lm -Wl,-rpath,/usr/lib64 -o libecpg.so.5.0 /usr/lib/gcc/i686-pc-linux-gnu/4.1.1/../../../../i686-pc-linux-gnu/bin/ld: cannot find -lpq collect2: ld returned 1 exit status make[4]: *** [libecpg.so.5.0] Error 1 make[4]: Leaving directory `/usr/olocal/gentoo/tmp/portage/dev-db/postgresql-8.0.13/work/postgresql-8.0.13/src/interfaces/ecpg/ecpglib' make[3]: *** [all] Error 2 make[3]: Leaving directory `/usr/olocal/gentoo/tmp/portage/dev-db/postgresql-8.0.13/work/postgresql-8.0.13/src/interfaces/ecpg' make[2]: *** [all] Error 2 Reproducible: Always If i go to the directory : cd /usr/olocal/gentoo/tmp/portage/dev-db/postgresql-8.0.13/work/postgresql-8.0.13/src/interfaces/ecpg/ecpglib and do make , i have the same error : verdi ecpglib # make i686-pc-linux-gnu-gcc -march=i586 -O3 -pipe -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif-labels -fno-strict-aliasing -fpic -shared -Wl,-soname,libecpg.so.5 execute.o typename.o descriptor.o data.o error.o prepare.o memory.o connect.o misc.o path.o exec.o -L../pgtypeslib -L../../../../src/interfaces/libpq -L../../../../src/port -lpgtypes -lpq -lssl -lcrypto -lcrypt -lm -Wl,-rpath,/usr/lib64 -o libecpg.so.5.0 /usr/lib/gcc/i686-pc-linux-gnu/4.1.1/../../../../i686-pc-linux-gnu/bin/ld: cannot find -lpq collect2: ld returned 1 exit status make: *** [libecpg.so.5.0] Error 1 But if i remove the offending option -lpq, it works : verdi ecpglib #i686-pc-linux-gnu-gcc -march=i586 -O3 -pipe -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif-labels -fno-strict-aliasing -fpic -shared -Wl,-soname,libecpg.so.5 execute.o typename.o descriptor.o data.o error.o prepare.o memory.o connect.o misc.o path.o exec.o -L../pgtypeslib -L../../../../src/interfaces/libpq -L../../../../src/port -lpgtypes -lssl -lcrypto -lcrypt -lm -Wl,-rpath,/usr/lib64 -o libecpg.so.5.0 verdi ecpglib #
i've now noticed about the package libpq. genlop says : Wed Jun 13 19:54:37 2007 >>> dev-db/libpq-8.0.13 so it had been emerged before, but it seems it's not found.. ?
i've got the same problem with dev-db/postgresql-8.0.12 : it emerges dev-db/libpq-8.0.12 without problem and then: i686-pc-linux-gnu-ranlib libecpg.a i686-pc-linux-gnu-gcc -march=i586 -O3 -pipe -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif-labels -fno-strict-aliasing -fpic -shared -Wl,-soname,libecpg.so.5 execute.o typename.o descriptor.o data.o error.o prepare.o memory.o connect.o misc.o path.o exec.o -L../pgtypeslib -L../../../../src/interfaces/libpq -L../../../../src/port -lpgtypes -lpq -lssl -lcrypto -lcrypt -lm -Wl,-rpath,/usr/lib64 -o libecpg.so.5.0 /usr/lib/gcc/i686-pc-linux-gnu/4.1.1/../../../../i686-pc-linux-gnu/bin/ld: cannot find -lpq collect2: ld returned 1 exit status make[4]: *** [libecpg.so.5.0] Error 1
I've finally found the reason. my computer is an amd athlon, 32 bits. And i have this output : verdi ~ # equery files libpq | grep 64 /usr/lib64 /usr/lib64/libpq-4.a /usr/lib64/libpq.a /usr/lib64/libpq.so /usr/lib64/libpq.so.4 /usr/lib64/libpq.so.4.0 and the problem was that i recently changed my profile to 2007.0, and i did a mistake with the symlink. I linked /etc/make.profile to the amd64 profile instead of the x86 ( all my other computers are amd64). Maybe there should be a check somewhere....no?
That's why you should always include emerge --info with bugs.