php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #30779 Compile of Zend/zend_strtod.c fails
Submitted: 2004-11-14 06:13 UTC Modified: 2004-11-15 20:27 UTC
From: hakan at lisas dot de Assigned: derick (profile)
Status: Closed Package: Compile Failure
PHP Version: 5CVS-2004-11-14 (dev) OS: Solaris 9
Private report: No CVE-ID: None
 [2004-11-14 06:13 UTC] hakan at lisas dot de
Description:
------------
Compile of Zend/zend_strtod.c fails.

When I include:

#if defined(__sparc__)
#define u_int32_t uint32_t
#endif

it compiles.

sys/types.h has no u_int32_t but a uint32_t.



Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-11-14 18:22 UTC] derick@php.net
Does the following work too:

Index: Zend/zend_strtod.c
===================================================================
RCS file: /repository/ZendEngine2/zend_strtod.c,v
retrieving revision 1.2
diff -u -p -r1.2 zend_strtod.c
--- Zend/zend_strtod.c  4 Nov 2004 02:04:39 -0000       1.2
+++ Zend/zend_strtod.c  14 Nov 2004 17:22:20 -0000
@@ -126,6 +126,10 @@ static char *rcsid = "$OpenBSD: strtod.c
 #define IEEE_LITTLE_ENDIAN
 #endif

+#if !defined(u_int32_t) && defined(uint32_t)
+#define u_int32_t uint32_t
+#endif
+
 #define Long   int32_t
 #define ULong  u_int32_t


This is a bit more generic...

 [2004-11-15 04:23 UTC] hakan at lisas dot de
No, your solution does not work for me.

I get following error message:
/bin/sh /usr/local/php-src/libtool --silent --preserve-dup-deps --mode=compile gcc  -IZend/ -I/usr/local/php-src/Zend/ -DPHP_ATOM_INC -I/usr/local/php-src/include -I/usr/local/php-src/main -I/usr/local/php-src -I/usr/local/php-src/Zend -I/usr/local/include/libxml2 -I/opt/csw/include -I/opt/csw/include/freetype2 -I/usr/local/mysql/include/mysql -I/usr/local/pgsql/include  -D_POSIX_PTHREAD_SEMANTICS -I/usr/local/php-src/TSRM  -g -O2  -prefer-pic -c /usr/local/php-src/Zend/zend_strtod.c -o Zend/zend_strtod.lo
/usr/local/php-src/Zend/zend_strtod.c:234: error: parse error before "u_int32_t"
/usr/local/php-src/Zend/zend_strtod.c:234: warning: no semicolon at end of struct or union
 [2004-11-15 20:27 UTC] derick@php.net
This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 12:01:31 2024 UTC