NetBSD Problem Report #46663

From www@NetBSD.org  Fri Jul  6 07:43:37 2012
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [149.20.53.66])
	by www.NetBSD.org (Postfix) with ESMTP id 5891863B882
	for <gnats-bugs@gnats.NetBSD.org>; Fri,  6 Jul 2012 07:43:37 +0000 (UTC)
Message-Id: <20120706074336.B554363B85F@www.NetBSD.org>
Date: Fri,  6 Jul 2012 07:43:36 +0000 (UTC)
From: frederic@fauberteau.org
Reply-To: frederic@fauberteau.org
To: gnats-bugs@NetBSD.org
Subject: php zlib undefined weak symbol
X-Send-Pr-Version: www-1.0

>Number:         46663
>Category:       pkg
>Synopsis:       php zlib undefined weak symbol
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Jul 06 07:45:00 +0000 2012
>Last-Modified:  Wed Jul 11 08:40:03 +0000 2012
>Originator:     Frédéric Fauberteau
>Release:        5.1
>Organization:
>Environment:
NetBSD trashware 5.1 NetBSD 5.1 (TRASHWARE) #1: Mer mar  7 11:13:30 CET 2012  root@trashware:/usr/src/sys/arch/amd64/compile/TRASHWARE amd64
>Description:
php returns error code 1 when zlib extension is activated. The installed programs are :
- php-5.3.14
- php53-zlib-5.3.14
This leads to fail pear package installation.
>How-To-Repeat:
> php
<?php print("hello world\n"); ?>
Ctrl+d
hello world
/usr/pkg/lib/php/20090630/zlib.so: Trying to call undefined weak symbol `__deregister_frame_info'
> echo $?
1
>Fix:
disable zlib extension fix the problem , but it is a temporary trick

>Release-Note:

>Audit-Trail:
From: "OBATA Akio" <obache@netbsd.org>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: pkg/46663: php zlib undefined weak symbol
Date: Mon, 09 Jul 2012 21:17:26 +0900

 On Fri, 06 Jul 2012 16:45:00 +0900, <frederic@fauberteau.org> wrote:

 >> Description:
 > php returns error code 1 when zlib extension is activated. The installed programs are :
 > - php-5.3.14
 > - php53-zlib-5.3.14
 > This leads to fail pear package installation.

 Don't you have any other PHP extensions?
 If so, how about reorder "extension=..." in php.ini?

 >> How-To-Repeat:
 >> php
 > <?php print("hello world\n"); ?>
 > Ctrl+d
 > hello world
 > /usr/pkg/lib/php/20090630/zlib.so: Trying to call undefined weak symbol `__deregister_frame_info'
 >> echo $?
 > 1

 I cannot reproduce on NetBSD-5.1.2 (but i386).

 -- 
 OBATA Akio / obache@NetBSD.org

Responsible-Changed-From-To: pkg-manager->wennmach
Responsible-Changed-By: obache@NetBSD.org
Responsible-Changed-When: Mon, 09 Jul 2012 12:31:01 +0000
Responsible-Changed-Why:
Over to maintainer.


From: =?UTF-8?Q?Fr=C3=A9d=C3=A9ric_Fauberteau?= <frederic@fauberteau.org>
To: <gnats-bugs@netbsd.org>
Cc: <pkg-manager@netbsd.org>, <gnats-admin@netbsd.org>,
 <pkgsrc-bugs@netbsd.org>
Subject: Re: pkg/46663: php zlib undefined weak symbol
Date: Mon, 09 Jul 2012 14:35:05 +0200

 Le 09.07.2012 14:20, OBATA Akio a écrit :
 > The following reply was made to PR pkg/46663; it has been noted by 
 > GNATS.
 >
 > From: "OBATA Akio" <obache@netbsd.org>
 > To: gnats-bugs@netbsd.org
 > Cc:
 > Subject: Re: pkg/46663: php zlib undefined weak symbol
 > Date: Mon, 09 Jul 2012 21:17:26 +0900
 >
 >  On Fri, 06 Jul 2012 16:45:00 +0900, <frederic@fauberteau.org> wrote:
 >
 >  >> Description:
 >  > php returns error code 1 when zlib extension is activated. The
 > installed programs are :
 >  > - php-5.3.14
 >  > - php53-zlib-5.3.14
 >  > This leads to fail pear package installation.
 >
 >  Don't you have any other PHP extensions?
 >  If so, how about reorder "extension=..." in php.ini?

 Ok, I had these extensions where zlib was the last one:

 extension=bz2.so
 extension=dom.so
 extension=exif.so
 extension=gd.so
 extension=gettext.so
 extension=iconv.so
 extension=imap.so
 extension=json.so
 extension=mbstring.so
 extension=mcrypt.so
 extension=mysql.so
 extension=mysqli.so
 extension=pgsql.so
 extension=sockets.so
 extension=zlib.so

 and it didn't work.
 If I put zlib on top, it works fine. But where I can find the good 
 extension declaration order?

 Thank you and sorry for this report which actually was not a bug.

 >  >> How-To-Repeat:
 >  >> php
 >  > <?php print("hello world\n"); ?>
 >  > Ctrl+d
 >  > hello world
 >  > /usr/pkg/lib/php/20090630/zlib.so: Trying to call undefined weak
 > symbol `__deregister_frame_info'
 >  >> echo $?
 >  > 1
 >
 >  I cannot reproduce on NetBSD-5.1.2 (but i386).
 >
 >  --
 >  OBATA Akio / obache@NetBSD.org

 -- 
 Frédéric Fauberteau

From: "OBATA Akio" <obache@netbsd.org>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: pkg/46663: php zlib undefined weak symbol
Date: Mon, 09 Jul 2012 22:04:26 +0900

 On Mon, 09 Jul 2012 21:40:08 +0900, Fr=C3=A9d=C3=A9ric Fauberteau <frede=
 ric@fauberteau.org> wrote:

 >  Ok, I had these extensions where zlib was the last one:
 > extension=3Dbz2.so
 >  extension=3Ddom.so
 >  extension=3Dexif.so
 >  extension=3Dgd.so
 >  extension=3Dgettext.so
 >  extension=3Diconv.so
 >  extension=3Dimap.so
 >  extension=3Djson.so
 >  extension=3Dmbstring.so
 >  extension=3Dmcrypt.so
 >  extension=3Dmysql.so
 >  extension=3Dmysqli.so
 >  extension=3Dpgsql.so
 >  extension=3Dsockets.so
 >  extension=3Dzlib.so
 > and it didn't work.
 >  If I put zlib on top, it works fine. But where I can find the good
 >  extension declaration order?

 Could you minimanize order reproducible the issue?
 for example, just foo.so and zlib.so.

 >  Thank you and sorry for this report which actually was not a bug.

 I know same problems will be happened when dlclose C++ so, then C so on =
 NetBSD.

 -- =

 OBATA Akio / obache@NetBSD.org

From: =?UTF-8?Q?Fr=C3=A9d=C3=A9ric_Fauberteau?= <frederic@fauberteau.org>
To: <gnats-bugs@netbsd.org>
Cc: 
Subject: Re: pkg/46663: php zlib undefined weak symbol
Date: Mon, 09 Jul 2012 15:37:19 +0200

 Le 09.07.2012 15:05, OBATA Akio a écrit :
 > The following reply was made to PR pkg/46663; it has been noted by 
 > GNATS.
 >
 > From: "OBATA Akio" <obache@netbsd.org>
 > To: gnats-bugs@netbsd.org
 > Cc:
 > Subject: Re: pkg/46663: php zlib undefined weak symbol
 > Date: Mon, 09 Jul 2012 22:04:26 +0900
 >
 >  On Mon, 09 Jul 2012 21:40:08 +0900, Fr=C3=A9d=C3=A9ric Fauberteau 
 > <frede=
 >  ric@fauberteau.org> wrote:
 >
 >  >  Ok, I had these extensions where zlib was the last one:
 >  > extension=3Dbz2.so
 >  >  extension=3Ddom.so
 >  >  extension=3Dexif.so
 >  >  extension=3Dgd.so
 >  >  extension=3Dgettext.so
 >  >  extension=3Diconv.so
 >  >  extension=3Dimap.so
 >  >  extension=3Djson.so
 >  >  extension=3Dmbstring.so
 >  >  extension=3Dmcrypt.so
 >  >  extension=3Dmysql.so
 >  >  extension=3Dmysqli.so
 >  >  extension=3Dpgsql.so
 >  >  extension=3Dsockets.so
 >  >  extension=3Dzlib.so
 >  > and it didn't work.
 >  >  If I put zlib on top, it works fine. But where I can find the 
 > good
 >  >  extension declaration order?
 >
 >  Could you minimanize order reproducible the issue?
 >  for example, just foo.so and zlib.so.

 The issue is reproductible with:

 extension=mysqli.so
 extension=zlib.so

 >  >  Thank you and sorry for this report which actually was not a bug.
 >
 >  I know same problems will be happened when dlclose C++ so, then C so 
 > on =
 >  NetBSD.
 >
 >  -- =
 >
 >  OBATA Akio / obache@NetBSD.org

 -- 
 Frédéric Fauberteau

From: Takahiro Kambe <taca@back-street.net>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/46663: php zlib undefined weak symbol
Date: Tue, 10 Jul 2012 10:42:04 +0900 (JST)

 Just FYI.

 In message <20120706074500.368A563B882@www.NetBSD.org>
 	on Fri,  6 Jul 2012 07:45:00 +0000 (UTC),
 	frederic@fauberteau.org wrote:
 >>Description:
 > php returns error code 1 when zlib extension is activated. The installed programs are :
 > - php-5.3.14
 > - php53-zlib-5.3.14
 > This leads to fail pear package installation.
 >>How-To-Repeat:
 >> php
 > <?php print("hello world\n"); ?>
 > Ctrl+d
 > hello world
 > /usr/pkg/lib/php/20090630/zlib.so: Trying to call undefined weak symbol `__deregister_frame_info'
 On NetBSD 6.0_BETA2, it resides in /lib/libgcc_s.so.1.0.

 I don't have accessible 5.1 environment for now, dose it exist in
 /lib/libgcc_s.so?

 Have you built these packages on your NetBSD 5.1 machine or using
 binary packages from some where?

 -- 
 Takahiro Kambe <taca@back-street.net>

From: =?UTF-8?Q?Fr=C3=A9d=C3=A9ric_Fauberteau?= <frederic@fauberteau.org>
To: <gnats-bugs@netbsd.org>
Cc: 
Subject: Re: pkg/46663: php zlib undefined weak symbol
Date: Tue, 10 Jul 2012 13:15:26 +0200

 Le 10.07.2012 04:30, Takahiro Kambe a écrit :
 >  Just FYI.
 >
 >  In message <20120706074500.368A563B882@www.NetBSD.org>
 >  	on Fri,  6 Jul 2012 07:45:00 +0000 (UTC),
 >  	frederic@fauberteau.org wrote:
 >  >>Description:
 >  > php returns error code 1 when zlib extension is activated. The
 > installed programs are :
 >  > - php-5.3.14
 >  > - php53-zlib-5.3.14
 >  > This leads to fail pear package installation.
 >  >>How-To-Repeat:
 >  >> php
 >  > <?php print("hello world\n"); ?>
 >  > Ctrl+d
 >  > hello world
 >  > /usr/pkg/lib/php/20090630/zlib.so: Trying to call undefined weak
 > symbol `__deregister_frame_info'
 >  On NetBSD 6.0_BETA2, it resides in /lib/libgcc_s.so.1.0.
 >
 >  I don't have accessible 5.1 environment for now, dose it exist in
 >  /lib/libgcc_s.so?

 $ nm /usr/lib/libgcc_s.so.1.0 | grep "__deregister_frame_info$"
 0000000000009a70 T __deregister_frame_info

 >  Have you built these packages on your NetBSD 5.1 machine or using
 >  binary packages from some where?

 I have built these packages on my NetBSD 5.1 using pkgsrc.

 -- 
 Frédéric Fauberteau

From: "OBATA Akio" <obache@netbsd.org>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: pkg/46663: php zlib undefined weak symbol
Date: Tue, 10 Jul 2012 21:12:55 +0900

 On Tue, 10 Jul 2012 20:20:04 +0900, Fr=C3=A9d=C3=A9ric Fauberteau <frede=
 ric@fauberteau.org> wrote:

 >  >  Have you built these packages on your NetBSD 5.1 machine or using
 >  >  binary packages from some where?
 > I have built these packages on my NetBSD 5.1 using pkgsrc.

 Which version of MySQL are you using?
 I cannot reproduce with mysqli-5.1.63.

 -- =

 OBATA Akio / obache@NetBSD.org

From: =?UTF-8?Q?Fr=C3=A9d=C3=A9ric_Fauberteau?= <frederic@fauberteau.org>
To: <gnats-bugs@netbsd.org>
Cc: 
Subject: Re: pkg/46663: php zlib undefined weak symbol
Date: Tue, 10 Jul 2012 14:26:01 +0200

 Le 10.07.2012 14:15, OBATA Akio a écrit :
 > The following reply was made to PR pkg/46663; it has been noted by 
 > GNATS.
 >
 > From: "OBATA Akio" <obache@netbsd.org>
 > To: gnats-bugs@netbsd.org
 > Cc:
 > Subject: Re: pkg/46663: php zlib undefined weak symbol
 > Date: Tue, 10 Jul 2012 21:12:55 +0900
 >
 >  On Tue, 10 Jul 2012 20:20:04 +0900, Fr=C3=A9d=C3=A9ric Fauberteau 
 > <frede=
 >  ric@fauberteau.org> wrote:
 >
 >  >  >  Have you built these packages on your NetBSD 5.1 machine or 
 > using
 >  >  >  binary packages from some where?
 >  > I have built these packages on my NetBSD 5.1 using pkgsrc.
 >
 >  Which version of MySQL are you using?
 >  I cannot reproduce with mysqli-5.1.63.

 I use the last available version from pkgsrc-2012Q2:
 - mysql-{client,server}-5.5.25
 - php53-mysqli-5.3.14

 -- 
 Frédéric Fauberteau

From: Takahiro Kambe <taca@back-street.net>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/46663: php zlib undefined weak symbol
Date: Tue, 10 Jul 2012 21:39:23 +0900 (JST)

 In message <20120710123004.B364763B85F@www.NetBSD.org>
 	on Tue, 10 Jul 2012 12:30:04 +0000 (UTC),
 	Fr=E9d=E9ric Fauberteau <frederic@fauberteau.org> wrote:
 >  >  Which version of MySQL are you using?
 >  >  I cannot reproduce with mysqli-5.1.63.
 >  =

 >  I use the last available version from pkgsrc-2012Q2:
 >  - mysql-{client,server}-5.5.25
 >  - php53-mysqli-5.3.14
 What about output of ldd(1)?

 % ldd /usr/pkg/lib/php/20090630/mysqli.so =

 /usr/pkg/lib/php/20090630/mysqli.so:
         -lmysqlclient.18 =3D> /usr/pkg/lib/libmysqlclient.so.18
         -lpthread.1 =3D> /usr/lib/libpthread.so.1
         -lgcc_s.1 =3D> /lib/libgcc_s.so.1
         -lc.12 =3D> /usr/lib/libc.so.12
         -lz.1 =3D> /usr/lib/libz.so.1
         -lssl.9 =3D> /usr/lib/libssl.so.9
         -lcrypto.7 =3D> /usr/lib/libcrypto.so.7
         -lcrypt.1 =3D> /lib/libcrypt.so.1
         -lstdc++.7 =3D> /usr/lib/libstdc++.so.7
         -lm.0 =3D> /usr/lib/libm.so.0

 -- =

 Takahiro Kambe <taca@back-street.net>

From: =?UTF-8?Q?Fr=C3=A9d=C3=A9ric_Fauberteau?= <frederic@fauberteau.org>
To: <gnats-bugs@netbsd.org>
Cc: 
Subject: Re: pkg/46663: php zlib undefined weak symbol
Date: Tue, 10 Jul 2012 15:13:41 +0200

 Le 10.07.2012 14:40, Takahiro Kambe a écrit :
 > The following reply was made to PR pkg/46663; it has been noted by 
 > GNATS.
 >
 > From: Takahiro Kambe <taca@back-street.net>
 > To: gnats-bugs@NetBSD.org
 > Cc:
 > Subject: Re: pkg/46663: php zlib undefined weak symbol
 > Date: Tue, 10 Jul 2012 21:39:23 +0900 (JST)
 >
 >  In message <20120710123004.B364763B85F@www.NetBSD.org>
 >  	on Tue, 10 Jul 2012 12:30:04 +0000 (UTC),
 >  	Fr=E9d=E9ric Fauberteau <frederic@fauberteau.org> wrote:
 >  >  >  Which version of MySQL are you using?
 >  >  >  I cannot reproduce with mysqli-5.1.63.
 >  >  =
 >
 >  >  I use the last available version from pkgsrc-2012Q2:
 >  >  - mysql-{client,server}-5.5.25
 >  >  - php53-mysqli-5.3.14
 >  What about output of ldd(1)?
 >
 >  % ldd /usr/pkg/lib/php/20090630/mysqli.so =
 >
 >  /usr/pkg/lib/php/20090630/mysqli.so:
 >          -lmysqlclient.18 =3D> /usr/pkg/lib/libmysqlclient.so.18
 >          -lpthread.1 =3D> /usr/lib/libpthread.so.1
 >          -lgcc_s.1 =3D> /lib/libgcc_s.so.1
 >          -lc.12 =3D> /usr/lib/libc.so.12
 >          -lz.1 =3D> /usr/lib/libz.so.1
 >          -lssl.9 =3D> /usr/lib/libssl.so.9
 >          -lcrypto.7 =3D> /usr/lib/libcrypto.so.7
 >          -lcrypt.1 =3D> /lib/libcrypt.so.1
 >          -lstdc++.7 =3D> /usr/lib/libstdc++.so.7
 >          -lm.0 =3D> /usr/lib/libm.so.0

 $ ldd /usr/pkg/lib/php/20090630/mysqli.so
 /usr/pkg/lib/php/20090630/mysqli.so:
          -lmysqlclient.18 => /usr/pkg/lib/libmysqlclient.so.18
          -lpthread.0 => /usr/lib/libpthread.so.0
          -lc.12 => /usr/lib/libc.so.12
          -lz.1 => /usr/lib/libz.so.1
          -lssl.6 => /usr/lib/libssl.so.6
          -lcrypto.4 => /usr/lib/libcrypto.so.4
          -lcrypt.0 => /lib/libcrypt.so.0
          -lstdc++.6 => /usr/lib/libstdc++.so.6
          -lm.0 => /usr/lib/libm.so.0
          -lgcc_s.1 => /usr/lib/libgcc_s.so.1

 -- 
 Frédéric Fauberteau

Responsible-Changed-From-To: wennmach->pkg-manager
Responsible-Changed-By: obache@NetBSD.org
Responsible-Changed-When: Tue, 10 Jul 2012 23:24:41 +0000
Responsible-Changed-Why:
mis-assigned.


From: "OBATA Akio" <obache@netbsd.org>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: pkg/46663: php zlib undefined weak symbol
Date: Wed, 11 Jul 2012 09:04:30 +0900

 On Tue, 10 Jul 2012 21:40:03 +0900, Takahiro Kambe <taca@back-street.net> wrote:

 >  % ldd /usr/pkg/lib/php/20090630/mysqli.so
 > /usr/pkg/lib/php/20090630/mysqli.so:
 >          -lmysqlclient.18 => /usr/pkg/lib/libmysqlclient.so.18
 >          -lpthread.1 => /usr/lib/libpthread.so.1
 >          -lgcc_s.1 => /lib/libgcc_s.so.1
 >          -lc.12 => /usr/lib/libc.so.12
 >          -lz.1 => /usr/lib/libz.so.1
 >          -lssl.9 => /usr/lib/libssl.so.9
 >          -lcrypto.7 => /usr/lib/libcrypto.so.7
 >          -lcrypt.1 => /lib/libcrypt.so.1
 >          -lstdc++.7 => /usr/lib/libstdc++.so.7
 >          -lm.0 => /usr/lib/libm.so.0

 Why is it linked against C++ library?
 With mysql-5.1, some tools will be linked against libstdc++,
 but client library is not.

 It is known problem on NetBSD-5 (lib/39986).
 workarounds are
   * put C++ modules at the last
   * link main executable with libgcc_s.so

 -- 
 OBATA Akio / obache@NetBSD.org

From: Takahiro Kambe <taca@back-street.net>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/46663: php zlib undefined weak symbol
Date: Wed, 11 Jul 2012 16:57:07 +0900 (JST)

 In message <20120711075502.5AF2163B85F@www.NetBSD.org>
 	on Wed, 11 Jul 2012 07:55:02 +0000 (UTC),
 	"OBATA Akio" <obache@netbsd.org> wrote:
 >  On Tue, 10 Jul 2012 21:40:03 +0900, Takahiro Kambe <taca@back-street.net> wrote:
 >  
 >  >  % ldd /usr/pkg/lib/php/20090630/mysqli.so
 >  > /usr/pkg/lib/php/20090630/mysqli.so:
 >  >          -lmysqlclient.18 => /usr/pkg/lib/libmysqlclient.so.18
 >  >          -lpthread.1 => /usr/lib/libpthread.so.1
 >  >          -lgcc_s.1 => /lib/libgcc_s.so.1
 >  >          -lc.12 => /usr/lib/libc.so.12
 >  >          -lz.1 => /usr/lib/libz.so.1
 >  >          -lssl.9 => /usr/lib/libssl.so.9
 >  >          -lcrypto.7 => /usr/lib/libcrypto.so.7
 >  >          -lcrypt.1 => /lib/libcrypt.so.1
 >  >          -lstdc++.7 => /usr/lib/libstdc++.so.7
 >  >          -lm.0 => /usr/lib/libm.so.0
 >  
 >  Why is it linked against C++ library?
 >  With mysql-5.1, some tools will be linked against libstdc++,
 >  but client library is not.
 I don't know but mysql-5.5 on NetBSD 6.1_BETA2:

 % ldd /usr/pkg/lib/libmysqlclient.so.18.0.0 
 /usr/pkg/lib/libmysqlclient.so.18.0.0:
         -lpthread.1 => /usr/lib/libpthread.so.1
         -lgcc_s.1 => /usr/lib/libgcc_s.so.1
         -lc.12 => /usr/lib/libc.so.12
         -lz.1 => /usr/lib/libz.so.1
         -lssl.9 => /usr/lib/libssl.so.9
         -lcrypto.7 => /usr/lib/libcrypto.so.7
         -lcrypt.1 => /lib/libcrypt.so.1
         -lstdc++.7 => /usr/lib/libstdc++.so.7
         -lm.0 => /usr/lib/libm.so.0

 -- 
 Takahiro Kambe <taca@back-street.net>

>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.