| 
        php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login | 
 PatchesPull Requests
Pull requests: 
 HistoryAllCommentsChangesGit/SVN commits             
             [2020-04-12 14:13 UTC] girgias@php.net
  [2020-04-13 00:12 UTC] girgias@php.net
  [2020-04-13 08:06 UTC] vibhutisawant18 at gmail dot com
  [2020-04-13 11:37 UTC] girgias@php.net
 
-Summary: make command fails on Big endian arch
+Summary: Various compiler warnings on Big endian architecture
          with GCC 5.4.0
-Status:  Open
+Status:  Verified
  [2020-04-13 21:15 UTC] girgias@php.net
  [2020-04-15 21:35 UTC] girgias@php.net
  [2020-04-15 21:35 UTC] girgias@php.net
 
-Status: Verified
+Status: Closed
  | 
    |||||||||||||||||||||||||||
            
                 
                Copyright © 2001-2025 The PHP GroupAll rights reserved.  | 
        Last updated: Tue Nov 04 15:00:01 2025 UTC | 
Description: ------------ With --enable-werror flag enabled in configure command, following warnings were observed on big endian arch while running the make command: 1) /root/php/php-src/ext/ffi/ffi_parser.c: In function 'get_skip_sym': /root/php/php-src/ext/ffi/ffi_parser.c:1664:10: error: 'accept_pos' may be used uninitialized in this function [-Werror=maybe-uninitialized] yy_pos = accept_pos; 2)/root/php/php-src/ext/hash/hash_sha3.c: In function 'store64': /root/php/php-src/ext/hash/hash_sha3.c:54:4: error: array subscript has type 'char' [-Werror=char-subscripts] x[i] = val & 0xFF; ^ /root/php/php-src/ext/hash/hash_sha3.c: In function 'xor64': /root/php/php-src/ext/hash/hash_sha3.c:61:4: error: array subscript has type 'char' [-Werror=char-subscripts] x[i] ^= val & 0xFF; ^ 3) /root/php/php-src/ext/intl/collator/collator_is_numeric.c: In function 'collator_u_strtod': /root/php/php-src/Zend/zend_portability.h:365:10: error: 'use_heap' may be used uninitialized in this function [-Werror=maybe-uninitialized] do { if (UNEXPECTED(use_heap)) efree(p); } while (0) ^ /root/php/php-src/ext/intl/collator/collator_is_numeric.c:72:15: note: 'use_heap' was declared here ALLOCA_FLAG(use_heap); ^ /root/php/php-src/Zend/zend_portability.h:357:12: note: in definition of macro 'ALLOCA_FLAG' zend_bool name; 4)/root/php/php-src/ext/pdo/pdo_stmt.c:753:53: error: missing braces around initializer [-Werror=missing-braces] zval grp_val, *pgrp, retval, old_ctor_args = {{0}, {{0}}, {0}}; ^ /root/php/php-src/ext/pdo/pdo_stmt.c:753:53: note: (near initialization for 'old_ctor_args.u1') /root/php/php-src/ext/pdo/pdo_stmt.c:753:47: error: missing braces around initializer [-Werror=missing-braces] zval grp_val, *pgrp, retval, old_ctor_args = {{0}, {{0}}, {0}}; ^ 5)/root/php/php-src/Zend/zend_execute_API.c:49:62: error: missing braces around initializer [-Werror=missing-braces] ZEND_API const zend_fcall_info empty_fcall_info = { 0, {{0}, {{0}}, {0}}, NULL, NULL, NULL, 0, 0 }; ^ /root/php/php-src/Zend/zend_execute_API.c:49:62: note: (near initialization for 'empty_fcall_info.function_name.u1') /root/php/php-src/Zend/zend_execute_API.c:49:56: error: missing braces around initializer [-Werror=missing-braces] ZEND_API const zend_fcall_info empty_fcall_info = { 0, {{0}, {{0}}, {0}}, NULL, NULL, NULL, 0, 0 }; ^ /root/php/php-src/Zend/zend_execute_API.c:49:56: note: (near initialization for 'empty_fcall_info.function_name') /root/php/php-src/Zend/zend_execute_API.c:49:51: error: missing braces around initializer [-Werror=missing-braces] ZEND_API const zend_fcall_info empty_fcall_info = { 0, {{0}, {{0}}, {0}}, NULL, NULL, NULL, 0, 0 }; All of the above warnings are fixed by making suggested changes in the respective files However no such warnings are observed on amd64 arch. Also by adding the fixes , the build completes successfully on Little Endian arch as well. Added a patch file along with this bug. How can we get rid of this warnings? Are there any x86 specific flags used during compilation?