Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Apache: Users

httpd crashes with segmentation fault: Incompatible libpng version in application and library

 

 

Apache users RSS feed   Index | Next | Previous | View Threaded


lenin.lee at gmail

Mar 18, 2012, 4:24 AM

Post #1 of 7 (286 views)
Permalink
httpd crashes with segmentation fault: Incompatible libpng version in application and library

Hi,

I've compiled httpd 2.2.21 and php 5.3.10, the version of libpng I used is
1.5.7, and I installed all the three packages under a custom path under
/opt.

The OS is CentOS 6.2, which contains an official distribution of libpng,
the version is 1.2.46.

When I start the server and visit programs hosted on it, the error.log
keeps being appended with the following messages:

*libpng warning: Application was compiled with png.h from libpng-1.5.7
libpng warning: Application is running with png.c from libpng-1.2.46
gd-png: fatal libpng error: Incompatible libpng version in application and
library*

I know the reason is that the version running with is not the one compiled
with. But setting the environment variable LD_LIBRARY_PATH won't solve the
problem.

Can anybody tell me how to fix this ? I know removing the old version of
libpng or recompile the server using the old version may be ok, but there
are some other potential problems, so I just want to run my application
server with the new version of libpng compiled by my self.

Thanks


icicimov at gmail

Mar 18, 2012, 4:08 PM

Post #2 of 7 (275 views)
Permalink
Re: httpd crashes with segmentation fault: Incompatible libpng version in application and library [In reply to]

Two things that come to my mind atm:

1. Link the existing libpng.so installed to the one you compiled
or
2. Try using FileLoad directive in the httpd.conf to load the correct
"libpng.so" file

Igor

On Sun, Mar 18, 2012 at 10:24 PM, Lenin <lenin.lee [at] gmail> wrote:

> Hi,
>
> I've compiled httpd 2.2.21 and php 5.3.10, the version of libpng I used is
> 1.5.7, and I installed all the three packages under a custom path under
> /opt.
>
> The OS is CentOS 6.2, which contains an official distribution of libpng,
> the version is 1.2.46.
>
> When I start the server and visit programs hosted on it, the error.log
> keeps being appended with the following messages:
>
> *libpng warning: Application was compiled with png.h from libpng-1.5.7
> libpng warning: Application is running with png.c from libpng-1.2.46
> gd-png: fatal libpng error: Incompatible libpng version in application
> and library*
>
> I know the reason is that the version running with is not the one compiled
> with. But setting the environment variable LD_LIBRARY_PATH won't solve the
> problem.
>
> Can anybody tell me how to fix this ? I know removing the old version of
> libpng or recompile the server using the old version may be ok, but there
> are some other potential problems, so I just want to run my application
> server with the new version of libpng compiled by my self.
>
> Thanks
>


lenin.lee at gmail

Mar 18, 2012, 6:27 PM

Post #3 of 7 (270 views)
Permalink
Re: httpd crashes with segmentation fault: Incompatible libpng version in application and library [In reply to]

Thanks for your reply.

I've tried he first method before, no luck.

For the second one, I cannot find any useful information about the
'FileLoad' directive, neither from Google nor the official documentation.

Are you sure you didn't misspell the directive ?

2012/3/19 Igor Cicimov <icicimov [at] gmail>

> Two things that come to my mind atm:
>
> 1. Link the existing “libpng.so” installed to the one you compiled
> or
> 2. Try using FileLoad directive in the httpd.conf to load the correct
> "libpng.so" file
>
> Igor
>
>
> On Sun, Mar 18, 2012 at 10:24 PM, Lenin <lenin.lee [at] gmail> wrote:
>
>> Hi,
>>
>> I've compiled httpd 2.2.21 and php 5.3.10, the version of libpng I used
>> is 1.5.7, and I installed all the three packages under a custom path under
>> /opt.
>>
>> The OS is CentOS 6.2, which contains an official distribution of libpng,
>> the version is 1.2.46.
>>
>> When I start the server and visit programs hosted on it, the error.log
>> keeps being appended with the following messages:
>>
>> *libpng warning: Application was compiled with png.h from libpng-1.5.7
>> libpng warning: Application is running with png.c from libpng-1.2.46
>> gd-png: fatal libpng error: Incompatible libpng version in application
>> and library*
>>
>> I know the reason is that the version running with is not the one
>> compiled with. But setting the environment variable LD_LIBRARY_PATH won't
>> solve the problem.
>>
>> Can anybody tell me how to fix this ? I know removing the old version of
>> libpng or recompile the server using the old version may be ok, but there
>> are some other potential problems, so I just want to run my application
>> server with the new version of libpng compiled by my self.
>>
>> Thanks
>>
>
>


--
初从文,三年不第。遂习武,校场发一矢,中鼓吏,逐之出。后学医,有所成,自撰一良方,服之,卒。


icicimov at gmail

Mar 18, 2012, 6:35 PM

Post #4 of 7 (270 views)
Permalink
Re: httpd crashes with segmentation fault: Incompatible libpng version in application and library [In reply to]

LoadFile

On Mon, Mar 19, 2012 at 12:27 PM, Lenin <lenin.lee [at] gmail> wrote:

> Thanks for your reply.
>
> I've tried he first method before, no luck.
>
> For the second one, I cannot find any useful information about the
> 'FileLoad' directive, neither from Google nor the official documentation.
>
> Are you sure you didn't misspell the directive ?
>
>
> 2012/3/19 Igor Cicimov <icicimov [at] gmail>
>
>> Two things that come to my mind atm:
>>
>> 1. Link the existing libpng.so installed to the one you compiled
>> or
>> 2. Try using FileLoad directive in the httpd.conf to load the correct
>> "libpng.so" file
>>
>> Igor
>>
>>
>> On Sun, Mar 18, 2012 at 10:24 PM, Lenin <lenin.lee [at] gmail> wrote:
>>
>>> Hi,
>>>
>>> I've compiled httpd 2.2.21 and php 5.3.10, the version of libpng I used
>>> is 1.5.7, and I installed all the three packages under a custom path under
>>> /opt.
>>>
>>> The OS is CentOS 6.2, which contains an official distribution of libpng,
>>> the version is 1.2.46.
>>>
>>> When I start the server and visit programs hosted on it, the error.log
>>> keeps being appended with the following messages:
>>>
>>> *libpng warning: Application was compiled with png.h from libpng-1.5.7
>>> libpng warning: Application is running with png.c from libpng-1.2.46
>>> gd-png: fatal libpng error: Incompatible libpng version in application
>>> and library*
>>>
>>> I know the reason is that the version running with is not the one
>>> compiled with. But setting the environment variable LD_LIBRARY_PATH won't
>>> solve the problem.
>>>
>>> Can anybody tell me how to fix this ? I know removing the old version of
>>> libpng or recompile the server using the old version may be ok, but there
>>> are some other potential problems, so I just want to run my application
>>> server with the new version of libpng compiled by my self.
>>>
>>> Thanks
>>>
>>
>>
>
>
> --
> ģ겻ڡϰ䣬Уһʸй֮ѧҽɣ׫һ֮䡣
>


lenin.lee at gmail

Mar 19, 2012, 5:55 AM

Post #5 of 7 (272 views)
Permalink
Re: httpd crashes with segmentation fault: Incompatible libpng version in application and library [In reply to]

I tried the directive LoadFile, but with no luck.

Igor Cicimov <icicimov [at] gmail> 於 2012年3月19日上午9:35 寫道:

> LoadFile
>
>
> On Mon, Mar 19, 2012 at 12:27 PM, Lenin <lenin.lee [at] gmail> wrote:
>
>> Thanks for your reply.
>>
>> I've tried he first method before, no luck.
>>
>> For the second one, I cannot find any useful information about the
>> 'FileLoad' directive, neither from Google nor the official documentation.
>>
>> Are you sure you didn't misspell the directive ?
>>
>>
>> 2012/3/19 Igor Cicimov <icicimov [at] gmail>
>>
>>> Two things that come to my mind atm:
>>>
>>> 1. Link the existing “libpng.so” installed to the one you compiled
>>> or
>>> 2. Try using FileLoad directive in the httpd.conf to load the correct
>>> "libpng.so" file
>>>
>>> Igor
>>>
>>>
>>> On Sun, Mar 18, 2012 at 10:24 PM, Lenin <lenin.lee [at] gmail> wrote:
>>>
>>>> Hi,
>>>>
>>>> I've compiled httpd 2.2.21 and php 5.3.10, the version of libpng I used
>>>> is 1.5.7, and I installed all the three packages under a custom path under
>>>> /opt.
>>>>
>>>> The OS is CentOS 6.2, which contains an official distribution of
>>>> libpng, the version is 1.2.46.
>>>>
>>>> When I start the server and visit programs hosted on it, the error.log
>>>> keeps being appended with the following messages:
>>>>
>>>> *libpng warning: Application was compiled with png.h from libpng-1.5.7
>>>> libpng warning: Application is running with png.c from libpng-1.2.46
>>>> gd-png: fatal libpng error: Incompatible libpng version in application
>>>> and library*
>>>>
>>>> I know the reason is that the version running with is not the one
>>>> compiled with. But setting the environment variable LD_LIBRARY_PATH won't
>>>> solve the problem.
>>>>
>>>> Can anybody tell me how to fix this ? I know removing the old version
>>>> of libpng or recompile the server using the old version may be ok, but
>>>> there are some other potential problems, so I just want to run my
>>>> application server with the new version of libpng compiled by my self.
>>>>
>>>> Thanks
>>>>
>>>
>>>
>>
>>
>> --
>> 初从文,三年不第。遂习武,校场发一矢,中鼓吏,逐之出。后学医,有所成,自撰一良方,服之,卒。
>>
>
>


--
初从文,三年不第。遂习武,校场发一矢,中鼓吏,逐之出。后学医,有所成,自撰一良方,服之,卒。


martin.hasicek at gmail

Mar 19, 2012, 6:02 AM

Post #6 of 7 (269 views)
Permalink
Re: httpd crashes with segmentation fault: Incompatible libpng version in application and library [In reply to]

Hi,

you can check if you use prelink feature. In such case, LD_LIBRARY_PATH is
overwriten by LD_PRELOAD or prelink.

mh

On Mon, Mar 19, 2012 at 1:55 PM, Lenin <lenin.lee [at] gmail> wrote:

> I tried the directive LoadFile, but with no luck.
>
> Igor Cicimov <icicimov [at] gmail> 20123199:35
>
> LoadFile
>>
>>
>> On Mon, Mar 19, 2012 at 12:27 PM, Lenin <lenin.lee [at] gmail> wrote:
>>
>>> Thanks for your reply.
>>>
>>> I've tried he first method before, no luck.
>>>
>>> For the second one, I cannot find any useful information about the
>>> 'FileLoad' directive, neither from Google nor the official documentation.
>>>
>>> Are you sure you didn't misspell the directive ?
>>>
>>>
>>> 2012/3/19 Igor Cicimov <icicimov [at] gmail>
>>>
>>>> Two things that come to my mind atm:
>>>>
>>>> 1. Link the existing libpng.so installed to the one you compiled
>>>> or
>>>> 2. Try using FileLoad directive in the httpd.conf to load the correct
>>>> "libpng.so" file
>>>>
>>>> Igor
>>>>
>>>>
>>>> On Sun, Mar 18, 2012 at 10:24 PM, Lenin <lenin.lee [at] gmail> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> I've compiled httpd 2.2.21 and php 5.3.10, the version of libpng I
>>>>> used is 1.5.7, and I installed all the three packages under a custom path
>>>>> under /opt.
>>>>>
>>>>> The OS is CentOS 6.2, which contains an official distribution of
>>>>> libpng, the version is 1.2.46.
>>>>>
>>>>> When I start the server and visit programs hosted on it, the error.log
>>>>> keeps being appended with the following messages:
>>>>>
>>>>> *libpng warning: Application was compiled with png.h from libpng-1.5.7
>>>>> libpng warning: Application is running with png.c from libpng-1.2.46
>>>>> gd-png: fatal libpng error: Incompatible libpng version in
>>>>> application and library*
>>>>>
>>>>> I know the reason is that the version running with is not the one
>>>>> compiled with. But setting the environment variable LD_LIBRARY_PATH won't
>>>>> solve the problem.
>>>>>
>>>>> Can anybody tell me how to fix this ? I know removing the old version
>>>>> of libpng or recompile the server using the old version may be ok, but
>>>>> there are some other potential problems, so I just want to run my
>>>>> application server with the new version of libpng compiled by my self.
>>>>>
>>>>> Thanks
>>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> ģ겻ڡϰ䣬Уһʸй֮ѧҽɣ׫һ֮䡣
>>>
>>
>>
>
>
> --
> ģ겻ڡϰ䣬Уһʸй֮ѧҽɣ׫һ֮䡣
>


lenin.lee at gmail

Mar 19, 2012, 6:10 PM

Post #7 of 7 (276 views)
Permalink
Re: httpd crashes with segmentation fault: Incompatible libpng version in application and library [In reply to]

Hi,

Thank both of you for reply.

I finally discovered that this problem occurs at the stage of linking. The
gd library has hard-coded that only libpng 1.2.x series can be recognized.
Since its configure script cannot find libpng12-config from my libpng 1.5.x
install path, it uses the one under /usr/bin instead.

Regards.

Martin Hasicek <martin.hasicek [at] gmail> 於 2012年3月19日下午9:02 寫道:

> Hi,
>
> you can check if you use prelink feature. In such case, LD_LIBRARY_PATH is
> overwriten by LD_PRELOAD or prelink.
>
> mh
>
>
> On Mon, Mar 19, 2012 at 1:55 PM, Lenin <lenin.lee [at] gmail> wrote:
>
>> I tried the directive LoadFile, but with no luck.
>>
>> Igor Cicimov <icicimov [at] gmail> 於 2012年3月19日上午9:35 寫道:
>>
>> LoadFile
>>>
>>>
>>> On Mon, Mar 19, 2012 at 12:27 PM, Lenin <lenin.lee [at] gmail> wrote:
>>>
>>>> Thanks for your reply.
>>>>
>>>> I've tried he first method before, no luck.
>>>>
>>>> For the second one, I cannot find any useful information about the
>>>> 'FileLoad' directive, neither from Google nor the official documentation.
>>>>
>>>> Are you sure you didn't misspell the directive ?
>>>>
>>>>
>>>> 2012/3/19 Igor Cicimov <icicimov [at] gmail>
>>>>
>>>>> Two things that come to my mind atm:
>>>>>
>>>>> 1. Link the existing “libpng.so” installed to the one you compiled
>>>>> or
>>>>> 2. Try using FileLoad directive in the httpd.conf to load the correct
>>>>> "libpng.so" file
>>>>>
>>>>> Igor
>>>>>
>>>>>
>>>>> On Sun, Mar 18, 2012 at 10:24 PM, Lenin <lenin.lee [at] gmail> wrote:
>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> I've compiled httpd 2.2.21 and php 5.3.10, the version of libpng I
>>>>>> used is 1.5.7, and I installed all the three packages under a custom path
>>>>>> under /opt.
>>>>>>
>>>>>> The OS is CentOS 6.2, which contains an official distribution of
>>>>>> libpng, the version is 1.2.46.
>>>>>>
>>>>>> When I start the server and visit programs hosted on it, the
>>>>>> error.log keeps being appended with the following messages:
>>>>>>
>>>>>> *libpng warning: Application was compiled with png.h from
>>>>>> libpng-1.5.7
>>>>>> libpng warning: Application is running with png.c from libpng-1.2.46
>>>>>> gd-png: fatal libpng error: Incompatible libpng version in
>>>>>> application and library*
>>>>>>
>>>>>> I know the reason is that the version running with is not the one
>>>>>> compiled with. But setting the environment variable LD_LIBRARY_PATH won't
>>>>>> solve the problem.
>>>>>>
>>>>>> Can anybody tell me how to fix this ? I know removing the old version
>>>>>> of libpng or recompile the server using the old version may be ok, but
>>>>>> there are some other potential problems, so I just want to run my
>>>>>> application server with the new version of libpng compiled by my self.
>>>>>>
>>>>>> Thanks
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> 初从文,三年不第。遂习武,校场发一矢,中鼓吏,逐之出。后学医,有所成,自撰一良方,服之,卒。
>>>>
>>>
>>>
>>
>>
>> --
>> 初从文,三年不第。遂习武,校场发一矢,中鼓吏,逐之出。后学医,有所成,自撰一良方,服之,卒。
>>
>
>


--
初从文,三年不第。遂习武,校场发一矢,中鼓吏,逐之出。后学医,有所成,自撰一良方,服之,卒。

Apache users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.