-   Gentoo (
-   -   Why does emacs-23.3-r2 still need (

CollieJim 01-08-2012 05:40 AM

Why does emacs-23.3-r2 still need
I have just completed

emerge -avDu world
cfg-update -u

and cannot run emacs.

$ emacs
emacs: error while loading shared libraries: cannot open shared object file: No such file or directory

Why does emacs still need libpng12?
How do I get past the problem?


segmentation_fault 01-08-2012 06:16 AM

I think there was a thread in about updating libpng. If I remember right I run:

revdep-rebuild --library '/usr/lib64/'
and after that there was a five-line-one-liner that ensured every symbolic link was updated. Have you done these?

CollieJim 01-08-2012 06:46 AM

No, only what I did in the previous message. I have 64-bit hardware but the system is 32-bit.

I have tried linking to other versions, but emacs (or something it calls) checks for an identification string in the library and rejects the link.

Edit: I just tried the above command, changing lib64 to lib, and nothing was rebuilt.

segmentation_fault 01-08-2012 06:50 AM

Restore the link and try the revdep-rebuild I posted above. You can try it with --pretend option first to see what is going to happen. If that fails too, you could try reemerge emacs.

Edit: probably you want this:

revdep-rebuild --pretend --library '/usr/lib/'
Also, check this.

CollieJim 01-08-2012 06:58 AM

All that happens with the revdep-rebuild is it wants to rebuild app-text/xpdf but could not find anything.
I have tried rebuilding emacs to no avail.

CollieJim 01-09-2012 05:02 AM

I got a copy of from a backup.
It's curious, though, that emacs still depends on an old library...

i92guboj 01-09-2012 04:26 PM

There are a few things you should try.

First, check the output for "which emacs" (or whatever the command is) and then double check that the listed binary file is part of the emacs package, using your favourite portage tool (i.e. equery or the like), and not some other emacs version you installed by hand.

It should probably be under /usr/bin/emacs, so try running it with the fully qualified path just to be sure.

Use find or whatever tool you prefer to locate all the libpng versions in your system. There's probably some leftover somewhere causing this pain. Also, see what libpng versions portage lists.

You should also try searching at and read about the issues people experienced when migrating to libpng-1.4 because of the infamous ABI break. I don't remember anything about emacs, concretely, but it might worth a check.

Last, but not least, even if emacs truly needs libpng-1.2 (and I really doubt it, but I am not going to bother installing emacs just to check), you could just do "emerge emacs:1.2" and at least portage will know that the lib is installed. No need to pick random libs and put them into your fs. And in any case, I really disregard that kind of practice, because it can cause issues like the one you are experiencing right now and some darker ones.

CollieJim 01-10-2012 11:21 PM

Thanks. It's not the first time (or even the 10th) that I've been caught out executing something other than what I expect. There was an old copy in /usr/local/bin. The current emacs does not need libpng12 after all.

All times are GMT -5. The time now is 07:07 PM.