Bug #54925 [Fbk->NoF]: build php on solaris for 64 bits
| From: | php-bugs at lists dot php dot net | Date: | Mon, 18 Feb 2013 00:34:52 +0000 |
| Subject: | Bug #54925 [Fbk->NoF]: build php on solaris for 64 bits | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-177001@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=54925&edit=1
ID: 54925
Updated by: php-bugs@lists.php.net
Reported by: michel dot henaut at everyware dot ch
Summary: build php on solaris for 64 bits
-Status: Feedback
+Status: No Feedback
Type: Bug
Package: *General Issues
Operating System: solaris
PHP Version: 5.2.17
Assigned To: srinatar
New Comment:
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.
Previous Comments:
------------------------------------------------------------------------
[2011-07-19 14:26:56] srinatar@php.net
I am not able to reproduce this behavior on both sparc as well as x86 platforms
? I am using Oracle Solaris Studio 12.2 (formerly Sun Studio compiler)
[sn123202@zod]'php-5.3.6'>cc -V
cc: Sun C 5.10 SunOS_sparc Patch 141861-07 2010/12/09
usage: cc [ options] files. Use 'cc -flags' for details
Possible, you are running into a compiler bug to me. In any case, you are using
a really older version of compiler. So, you might wanna consider upgrading or
installing latest compiler patches.
So, if some thing fixes by using -m64 -O but reproduces with -m64 - is most
likely a compiler issue. this is, -m64 doesn't do much but rather than expands
the compiler flags to build on 64-bit platform.
I would like to close this bug as not a valid bug
------------------------------------------------------------------------
[2011-07-15 11:37:20] dsp@php.net
assigning this to people working at oracle.
------------------------------------------------------------------------
[2011-05-27 07:39:20] eugene at zhegan dot in
Same here.
PHP 5.3.6.
# cc -V
cc: Sun C 5.10 SunOS_i386 2009/06/03
Same workaround does help (thanks, Michael, by the way).
------------------------------------------------------------------------
[2011-05-25 14:31:09] michel dot henaut at everyware dot ch
Description:
------------
Build php on solaris with Sun compiler:
The default build for 64 bits, i.e. CFLAGS='-m64' produces strange results.
Rebuilding all with CFLAGS='-m64 -O -xs -xstrconst -zlazyload' seems to work.
To reproduce it:
$obj[0]['data'][0]['Usr'] = 0.009035;
echo json_encode($obj);
with just CFLAGS='-m64'
[{"data":[{"Usr":INF}]}]
with CFLAGS='-m64 -O -xs -xstrconst -zlazyload'
[{"data":[{"Usr":0.009035}]}]
which is correct.
may be a problem in main/snprintf.c and in main/spprintf.c
regards
Test script:
---------------
$obj[0]['data'][0]['Usr'] = 0.009035;
echo json_encode($obj);
Expected result:
----------------
[{"data":[{"Usr":0.009035}]}]
Actual result:
--------------
[{"data":[{"Usr":INF}]}]
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=54925&edit=1