简体   繁体   中英

Lacking libgdbm when installing perl

I really want to know where does this libgdbm comes from and it seems it has been in

/usr/lib/libgdbm.so.2.0.0
/usr/local/lib/libgdbm.a
/usr/local/lib/libgdbm.la
/usr/local/lib/libgdbm.so
/usr/local/lib/libgdbm.so.3
/usr/local/lib/libgdbm.so.3.0.0

, but perl says

I used the command:

    cc -o try -O2 -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -fstack-protector -L/usr/local/lib try.c -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc
     ./try

and I got the following output:

./try: error while loading shared libraries: libgdbm.so.4: cannot open shared object file: No such file or directory
The program compiled OK, but exited with status 127.
(The supplied flags or libraries might be incorrect.)

You have a problem.  Shall I abort Configure [y]  
Ok.  Stopping Configure.

so many files, I don't know why perl can't find any of them.

Try adding "-R/usr/local/lib" to LDFLAGS and/or CFLAGS environment variables. If Linux perhaps change the order of searched directories in /etc/ld.so.conf

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM