Bug #80176 [NEW]: configure script fails to include required headers

From: Date: Fri, 02 Oct 2020 16:32:14 +0000
Subject: Bug #80176 [NEW]: configure script fails to include required headers
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-229342@lists.php.net to get a copy of this message
From:             php-bugs-2020 at ryandesign dot com
Operating system: macOS 10.15.6
PHP version:      7.4.11
Package:          *General Issues
Bug Type:         Bug
Bug description:configure script fails to include required headers

Description:
------------
php fails to build on macOS with Xcode 12. New in Xcode 12 is that
implicitly declaring functions is now an error; before it was just a
warning. Many of the configure script tests fail to include all of the
required headers, leading to those tests failing to correctly identify
the system's capabilities, such as:


conftest.c:103:5: error: implicitly declaring library function 'exit'
with type 'void (int) __attribute__((noreturn))'
[-Werror,-Wimplicit-function-declaration]
    exit(2);
    ^
conftest.c:103:5: note: include the header <stdlib.h> or explicitly
provide a declaration for 'exit'
conftest.c:111:3: error: implicit declaration of function 'unlink' is
invalid in C99 [-Werror,-Wimplicit-function-declaration]
  unlink(filename);
  ^


The build later fails, for example with this error:


main/reentrancy.c:125:23: error: too few arguments to function call,
expected 3, have 2
        readdir_r(dirp, entry);
        ~~~~~~~~~            ^
/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/usr/include/dirent.h:110:1:
note: 'readdir_r' declared here
int readdir_r(DIR *, struct dirent *, struct dirent **)
__DARWIN_INODE64(readdir_r);
^


This was reported to MacPorts against php73 here:
https://trac.macports.org/ticket/60988 and
against php72 here:
https://trac.macports.org/ticket/61168 but it
also affects php74 and
presumably all other php versions.



-- 
Edit bug report at https://bugs.php.net/bug.php?id=80176&edit=1
-- 
Fix committed:                    https://bugs.php.net/fix.php?id=80176&r=fixed
Fixed in release:                 https://bugs.php.net/fix.php?id=80176&r=alreadyfixed
Need backtrace:                   https://bugs.php.net/fix.php?id=80176&r=needtrace
Need Reproduce Script:            https://bugs.php.net/fix.php?id=80176&r=needscript
Try newer version:                https://bugs.php.net/fix.php?id=80176&r=oldversion
Not developer issue:              https://bugs.php.net/fix.php?id=80176&r=support
Expected behavior:                https://bugs.php.net/fix.php?id=80176&r=notwrong
Not enough info:                  https://bugs.php.net/fix.php?id=80176&r=notenoughinfo
Submitted twice:                  https://bugs.php.net/fix.php?id=80176&r=submittedtwice
register_globals:                 https://bugs.php.net/fix.php?id=80176&r=globals
PHP version support discontinued: https://bugs.php.net/fix.php?id=80176&r=phptooold
Daylight Savings:                 https://bugs.php.net/fix.php?id=80176&r=dst
IIS Stability:                    https://bugs.php.net/fix.php?id=80176&r=isapi
Install GNU Sed:                  https://bugs.php.net/fix.php?id=80176&r=gnused
Floating point limitations:       https://bugs.php.net/fix.php?id=80176&r=float
No Zend Extensions:               https://bugs.php.net/fix.php?id=80176&r=nozend
MySQL Configuration Error:        https://bugs.php.net/fix.php?id=80176&r=mysqlcfg


Thread (3 messages)

« previous php.bugs (#229342) next »