all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Building emacs errors: libraries present
@ 2015-02-06  3:27 Tory S. Anderson
  2015-02-06  7:50 ` Eli Zaretskii
  0 siblings, 1 reply; 8+ messages in thread
From: Tory S. Anderson @ 2015-02-06  3:27 UTC (permalink / raw
  To: emacs list

Related but distinct from another post (other post has 24.4 failing at the make stage, but 25.0.5 fails at configure):

I am unable to build emacs with png support, despite my having the libpng and libpng-devel libraries. Why might this be? I'm running Linux Fedora 20.

(abridged) Output of my attempts to configure:
==============================
$ ./configure
... # list omitted
configure: error: The following required libraries were not found:
     libpng libgif/libungif
Maybe some development libraries/packages are missing?
If you don't want to link with them give
     --with-png=no --with-gif=no
as options to configure

$ sudo yum install libpng libpng-devel
... # list omitted
Package 2:libpng-1.6.6-3.fc20.x86_64 already installed and latest version
Package 2:libpng-devel-1.6.6-3.fc20.x86_64 already installed and latest version
Nothing to do

$ whereis libpng
libpng: /usr/lib64/libpng16.so /usr/lib64/libpng.so /usr/share/man/man3/libpng.3.gz
==============================

Of course I've successfully built without the png libraries but I really do need the png libraries for other emacs packages. What's wrong? Why is it ignoring my working libpng? 



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Building emacs errors: libraries present
  2015-02-06  3:27 Building emacs errors: libraries present Tory S. Anderson
@ 2015-02-06  7:50 ` Eli Zaretskii
  2015-02-06 12:47   ` Tory S. Anderson
       [not found]   ` <mailman.19390.1423226883.1147.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 8+ messages in thread
From: Eli Zaretskii @ 2015-02-06  7:50 UTC (permalink / raw
  To: help-gnu-emacs

> From: torys.anderson@gmail.com (Tory S. Anderson)
> Date: Thu, 05 Feb 2015 22:27:08 -0500
> 
> $ ./configure
> ... # list omitted
> configure: error: The following required libraries were not found:
>      libpng libgif/libungif
> Maybe some development libraries/packages are missing?
> If you don't want to link with them give
>      --with-png=no --with-gif=no
> as options to configure
> 
> $ sudo yum install libpng libpng-devel
> ... # list omitted
> Package 2:libpng-1.6.6-3.fc20.x86_64 already installed and latest version
> Package 2:libpng-devel-1.6.6-3.fc20.x86_64 already installed and latest version
> Nothing to do
> 
> $ whereis libpng
> libpng: /usr/lib64/libpng16.so /usr/lib64/libpng.so /usr/share/man/man3/libpng.3.gz
> ==============================
> 
> Of course I've successfully built without the png libraries but I really do need the png libraries for other emacs packages. What's wrong? Why is it ignoring my working libpng? 

Look in config.log for clues: you should see there compiler error
messages when it tried to look for the libraries.



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Building emacs errors: libraries present
  2015-02-06  7:50 ` Eli Zaretskii
@ 2015-02-06 12:47   ` Tory S. Anderson
  2015-02-06 12:54     ` Alexis
  2015-02-06 18:25     ` Dale Snell
       [not found]   ` <mailman.19390.1423226883.1147.help-gnu-emacs@gnu.org>
  1 sibling, 2 replies; 8+ messages in thread
From: Tory S. Anderson @ 2015-02-06 12:47 UTC (permalink / raw
  To: help-gnu-emacs

Okay; I'm making progress. I have identical problems with both 24.4 and 25.0.5 build processes now. LibPNG is being found! But the gif library is not. In summary, I get NO configure errors (as long as I do sudo configure), but I get the following make error (even with sudo make, which I know is probably a dangerous command):

    ./temacs: error while loading shared libraries: libgif.so.7: cannot open shared object file: No such file or directory

But a find locates it just fine: 

    $ sudo find / -name "libgif.so.7"
    /usr/local/lib/libgif.so.7

Indeed, configure apparently found it, right? 

Unabridged config and make outputs for those interested: 

http://www.toryanderson.com/files/emacs-configure-output.txt
http://www.toryanderson.com/files/emacs-make-output.txt     

Any ideas why it can't find libgif? 


Eli Zaretskii <eliz@gnu.org> writes:

>> From: torys.anderson@gmail.com (Tory S. Anderson)
>> Date: Thu, 05 Feb 2015 22:27:08 -0500
>> 
>> $ ./configure
>> ... # list omitted
>> configure: error: The following required libraries were not found:
>>      libpng libgif/libungif
>> Maybe some development libraries/packages are missing?
>> If you don't want to link with them give
>>      --with-png=no --with-gif=no
>> as options to configure
>> 
>> $ sudo yum install libpng libpng-devel
>> ... # list omitted
>> Package 2:libpng-1.6.6-3.fc20.x86_64 already installed and latest version
>> Package 2:libpng-devel-1.6.6-3.fc20.x86_64 already installed and latest version
>> Nothing to do
>> 
>> $ whereis libpng
>> libpng: /usr/lib64/libpng16.so /usr/lib64/libpng.so /usr/share/man/man3/libpng.3.gz
>> ==============================
>> 
>> Of course I've successfully built without the png libraries but I really do need the png libraries for other emacs packages. What's wrong? Why is it ignoring my working libpng? 
>
> Look in config.log for clues: you should see there compiler error
> messages when it tried to look for the libraries.



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Building emacs errors: libraries present
  2015-02-06 12:47   ` Tory S. Anderson
@ 2015-02-06 12:54     ` Alexis
  2015-02-07 13:30       ` Tory S. Anderson
  2015-02-06 18:25     ` Dale Snell
  1 sibling, 1 reply; 8+ messages in thread
From: Alexis @ 2015-02-06 12:54 UTC (permalink / raw
  To: help-gnu-emacs


Tory S. Anderson writes:

> Okay; I'm making progress. I have identical problems with both 
> 24.4 and 25.0.5 build processes now. LibPNG is being found! But 
> the gif library is not. In summary, I get NO configure errors 
> (as long as I do sudo configure), but I get the following make 
> error (even with sudo make, which I know is probably a dangerous 
> command):
>
>     ./temacs: error while loading shared libraries: libgif.so.7: 
>     cannot open shared object file: No such file or directory
>
> But a find locates it just fine: 
>
>     $ sudo find / -name "libgif.so.7" /usr/local/lib/libgif.so.7
>
> Indeed, configure apparently found it, right? 
>
> Unabridged config and make outputs for those interested: 
>
> http://www.toryanderson.com/files/emacs-configure-output.txt 
> http://www.toryanderson.com/files/emacs-make-output.txt     
>
> Any ideas why it can't find libgif? 

Have you run ldconfig(8) after installing libgif?


Alexis.



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Building emacs errors: libraries present
  2015-02-06 12:47   ` Tory S. Anderson
  2015-02-06 12:54     ` Alexis
@ 2015-02-06 18:25     ` Dale Snell
  1 sibling, 0 replies; 8+ messages in thread
From: Dale Snell @ 2015-02-06 18:25 UTC (permalink / raw
  To: help-gnu-emacs

[-- Attachment #1: Type: text/plain, Size: 2118 bytes --]

On Fri, 06 Feb 2015 07:47:57 -0500, in message 87twyzurya.fsf@gmail.com,
Tory S. Anderson wrote:

> Okay; I'm making progress. I have identical problems with both 24.4
> and 25.0.5 build processes now. LibPNG is being found! But the gif
> library is not. In summary, I get NO configure errors (as long as I
> do sudo configure), but I get the following make error (even with
> sudo make, which I know is probably a dangerous command):
> 
>     ./temacs: error while loading shared libraries: libgif.so.7:
> cannot open shared object file: No such file or directory
> 
> But a find locates it just fine: 
> 
>     $ sudo find / -name "libgif.so.7"
>     /usr/local/lib/libgif.so.7
> 
> Indeed, configure apparently found it, right? 
> 
> Unabridged config and make outputs for those interested: 
> 
> http://www.toryanderson.com/files/emacs-configure-output.txt
> http://www.toryanderson.com/files/emacs-make-output.txt     
> 
> Any ideas why it can't find libgif? 

I built Emacs 24.4.1 on my 64-bit Fedora 19 box with no trouble at
all.  Here's what I've got for PNG and GIF libraries:

    $ yum list installed \*png*\ \*gif\*
        <blather deleted>
    libpng.x86_64                 2:1.5.13-3.fc19                   @updates
    libpng-devel.x86_64           2:1.5.13-3.fc19                   @updates
    giflib.x86_64                 4.1.6-7.fc19                      @anaconda
    giflib-devel.x86_64           4.1.6-7.fc19                      @fedora  

Since I'm still running F19, my packages may not be the same as
yours, though I suspect that only the version numbers will have
changed.

When I first ran configure, I didn't have the giflib-devel
package, but it wasn't hard to figure out.  After installing it,
the usual "./configure; make; sudo make install" dance worked
fine.  Note that I didn't have to run configure (or make) as root.
I've _never_ had to do that.  If you do, there's something amiss,
probably in your system library installation.

Anyway, I hope this helps.

--Dale

-- 
"Come, muse, let us sing of rats."  -- James Grainger

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Building emacs errors: libraries present
       [not found]   ` <mailman.19390.1423226883.1147.help-gnu-emacs@gnu.org>
@ 2015-02-07 10:09     ` Anssi Saari
  0 siblings, 0 replies; 8+ messages in thread
From: Anssi Saari @ 2015-02-07 10:09 UTC (permalink / raw
  To: help-gnu-emacs

torys.anderson@gmail.com (Tory S. Anderson) writes:

> Okay; I'm making progress. I have identical problems with both 24.4
> and 25.0.5 build processes now. LibPNG is being found! But the gif
> library is not. In summary, I get NO configure errors (as long as I do
> sudo configure), but I get the following make error (even with sudo
> make, which I know is probably a dangerous command):
>
>     ./temacs: error while loading shared libraries: libgif.so.7: cannot open shared object file: No such file or directory
>
> But a find locates it just fine: 
>
>     $ sudo find / -name "libgif.so.7"
>     /usr/local/lib/libgif.so.7

Why is libgif in /usr/local? If you installed it yourself for some
reason bypassing the normal package manager then have you ever built
anything with it that works?

Does ldd temacs tell you anything interesting? You may want to check
your /etc/ld.so.conf to see where the dynamic linker looks for
libraries. /usr/local isn't always included.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Building emacs errors: libraries present
  2015-02-06 12:54     ` Alexis
@ 2015-02-07 13:30       ` Tory S. Anderson
  2015-02-07 14:02         ` Alexis
  0 siblings, 1 reply; 8+ messages in thread
From: Tory S. Anderson @ 2015-02-07 13:30 UTC (permalink / raw
  To: Alexis; +Cc: help-gnu-emacs

Okay; I've succeeded finally in building by soft-linking all the libraries it SHOULD have been finding into the main directories. I'm not sure why it cannot use libpng 16 and instead requires 15. E.g. I did this:
    sudo ln -s /anaconda/lib/libpng15.so /usr/lib64/
Taking care of any non-found files that way solved all problems. 

ldconfig looks interesting, but I don't seem to have a manpage on it. Unfortunately, it didn't solve the issue. Soft links seemed to do the trick for me. 

Alexis <flexibeast@gmail.com> writes:

> Tory S. Anderson writes:
>
>> Okay; I'm making progress. I have identical problems with both 24.4 and 25.0.5 build processes now. LibPNG is being found! But the gif library is not. In summary, I get NO configure errors (as long as I do sudo configure), but I get the following make error (even with sudo make, which I know is probably a dangerous command):
>>
>>     ./temacs: error while loading shared libraries: libgif.so.7:     cannot open shared object file: No such file or directory
>>
>> But a find locates it just fine: 
>>
>>     $ sudo find / -name "libgif.so.7" /usr/local/lib/libgif.so.7
>>
>> Indeed, configure apparently found it, right? 
>>
>> Unabridged config and make outputs for those interested: 
>>
>> http://www.toryanderson.com/files/emacs-configure-output.txt http://www.toryanderson.com/files/emacs-make-output.txt     
>>
>> Any ideas why it can't find libgif? 
>
> Have you run ldconfig(8) after installing libgif?
>
>
> Alexis.



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Building emacs errors: libraries present
  2015-02-07 13:30       ` Tory S. Anderson
@ 2015-02-07 14:02         ` Alexis
  0 siblings, 0 replies; 8+ messages in thread
From: Alexis @ 2015-02-07 14:02 UTC (permalink / raw
  To: help-gnu-emacs


Tory S. Anderson writes:

> Okay; I've succeeded finally in building by soft-linking all the 
> libraries it SHOULD have been finding into the main 
> directories. I'm not sure why it cannot use libpng 16 and 
> instead requires 15. E.g. I did this:
> 
>     sudo ln -s /anaconda/lib/libpng15.so /usr/lib64/
> 
> Taking care of any non-found files that way solved all 
> problems. 
>
> ldconfig looks interesting, but I don't seem to have a manpage 
> on it. Unfortunately, it didn't solve the issue. Soft links 
> seemed to do the trick for me.

Very odd that your system doesn't have a manpage for ldconfig(8)! 
Here's the opening paragraph of that man page on my system:

"ldconfig creates, updates, and removes the necessary links and 
cache (for use by the run-time linker, ld.so) to the most recent 
shared libraries found in the directories specified on the command 
line, in the file /etc/ld.so.conf, and in the trusted directories 
(/usr/lib and /lib).  ldconfig checks the header and file names of 
the libraries it encounters when determining which versions should 
have their links updated.  ldconfig ignores symbolic links when 
scanning for libraries."

Basically, when you install new shared libraries on your system, 
you need to run /sbin/ldconfig in order to refresh the cache of 
available shared libraries. As someone else has pointed out, the 
directories searched for libraries is specified in /etc/ld.so.conf 
and related files; if you install shared libraries outside of 
those paths, you'll need to add the new paths to /etc/ld.so.conf 
(or possibly some other file, depending on the system's setup).

How are you installing the extra libraries? Are you installing the 
relevant -devel packages from your distro's repos, or are you 
manually compiling and installing them yourself? If the latter, 
then you'll need, as noted elsewhere in this thread, to make sure 
they're being installed in a path specified by /etc/ld.so.conf, or 
modify the latter file appropriately.

Needing to create symbolic links manually, as you have done, 
should normally not be necessary.


Alexis.



^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2015-02-07 14:02 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-06  3:27 Building emacs errors: libraries present Tory S. Anderson
2015-02-06  7:50 ` Eli Zaretskii
2015-02-06 12:47   ` Tory S. Anderson
2015-02-06 12:54     ` Alexis
2015-02-07 13:30       ` Tory S. Anderson
2015-02-07 14:02         ` Alexis
2015-02-06 18:25     ` Dale Snell
     [not found]   ` <mailman.19390.1423226883.1147.help-gnu-emacs@gnu.org>
2015-02-07 10:09     ` Anssi Saari

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.