Bug #60740 [Com]: compilation of main/main.c stops: 'zend_stream' has no member named 'mmap64'
| From: | lzsiga at freemail dot c3 dot hu | Date: | Thu, 28 Sep 2017 04:22:49 +0000 |
| Subject: | Bug #60740 [Com]: compilation of main/main.c stops: 'zend_stream' has no member named 'mmap64' | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-211406@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=60740&edit=1
ID: 60740
Comment by: lzsiga at freemail dot c3 dot hu
Reported by: lzsiga at freemail dot c3 dot hu
Summary: compilation of main/main.c stops: 'zend_stream' has
no member named 'mmap64'
Status: Feedback
Type: Bug
Package: Compile Failure
Operating System: AIX 6.1
PHP Version: 5.3.9
Assigned To: cmb
Block user comment: N
Private report: N
New Comment:
Sorry, I couldn't tell: I have moved onto 64-bit years ago, that eliminated the
Large-File-Problem.
But I've just checked the source of zend_stream.h in 7.1.9 -- the field's name is still
'mmap', so it still might cause problem on systems where large-file-support is solved via
'#define mmap mmap64'
Note: gcc-based systems use __asm__("mmap64"), so thex don't face this problem.
Previous Comments:
------------------------------------------------------------------------
[2017-09-27 15:54:23] cmb@php.net
Is this still an issue with current PHP versions?
------------------------------------------------------------------------
[2012-01-17 13:44:24] lzsiga at freemail dot c3 dot hu
"Good" news: on AIX, compiling with large-file-support raises other
problems, too; for example there won't be function 'fopen' only function
'fopen64'
------------------------------------------------------------------------
[2012-01-15 16:57:45] lzsiga at freemail dot c3 dot hu
Or simply the inclusion of <sys/mman.h> could come before the inclusion of
"config.h"
------------------------------------------------------------------------
[2012-01-13 10:26:17] lzsiga at freemail dot c3 dot hu
Description:
------------
Compilation of main/main.c fails, the error message is:
/usr/local/src/php-5.3.9/main/main.c:1230: error: 'zend_stream' has no member named
'mmap64'
/usr/local/src/php-5.3.9/main/main.c:1230: error: 'zend_stream' has no member named
'mmap64'
/usr/local/src/php-5.3.9/main/main.c:1239: error: 'zend_stream' has no member named
'mmap64'
/usr/local/src/php-5.3.9/main/main.c:1240: error: 'zend_stream' has no member named
'mmap64'
The compilation went with largefile support (-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
-D_LARGE_FILES), which caused sys/mman.h to define mmap as mmap64; I suppose it would work, if
1. I compiled without largefile support (I don't like this idea)
2. The member 'mmap' of 'struct _zend_stream' had a less problematic name
('zmmap' for example)
3. Header 'zend_stream.h' included 'sys/mman.h'
4. I predefined 'mmap' as 'mmap64': -Dmmap=mmap64
5. I compiled in 64 bits (I'm afraid to do so, to be frank)
Platform: AIX 6.1 (oslevel -r = 6100-05); gcc (gcc --version = 4.4.5)
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=60740&edit=1