Opened 4 years ago
Last modified 3 years ago
#60988 assigned defect
php73-apache2handler @7.3.16_1: error: too few arguments to function call, expected 3, have 2
Reported by: | murrayE | Owned by: | ryandesign (Ryan Carsten Schmidt) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.6.3 |
Keywords: | bigsur catalina | Cc: | josephsacco, nortcele, HuabinLee (李先生), theq86 (theq86), ndebarnot (Nero), mivancic (Mario Ivancic), elcheco (Miroslav Koula), hostep (Pieter Hoste) |
Port: | php |
Description
There are _many_ errors reported in main.log for building. the log is attached.
(Sorry, I don't understand enough of what's involved to pin this down further.)
Attachments (2)
Change History (24)
Changed 4 years ago by murrayE
comment:1 Changed 4 years ago by mf2k (Frank Schima)
Cc: | ryandesign removed |
---|---|
Keywords: | build failure removed |
Owner: | set to ryandesign |
Port: | @7.3.16_1 removed |
Status: | new → assigned |
comment:2 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
Summary: | Build failure updating php73-apache2handler to 7.3.16_1 → php73-apache2handler @7.3.16_1: error: too few arguments to function call, expected 3, have 2 |
---|
Hmm, the first error is:
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_php/php73-apache2handler/work/php-7.3.16/main/reentrancy.c:125:23: error: too few arguments to function call, expected 3, have 2 :info:build readdir_r(dirp, entry); :info:build ~~~~~~~~~ ^ :info:build /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/usr/include/dirent.h:110:1: note: 'readdir_r' declared here :info:build int readdir_r(DIR *, struct dirent *, struct dirent **) __DARWIN_INODE64(readdir_r); :info:build ^ :info:build 1 error generated.
I have not yet tried to look into what's going on here.
We were able to build this successfully on our build servers for all OS versions, so whatever's happening is not a general problem but is specific to your system.
comment:3 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
Several differences between the configure output from your log and the build server log:
Ours:
checking for broken libc stdio... no checking for getaddrinfo... yes checking for type of readdir_r... POSIX checking for asm goto... no checking whether pwrite works... yes checking whether pread works... yes checking for standard DES crypt... yes checking for extended DES crypt... yes checking whether sprintf is broken... no checking how many arguments gethostbyname_r() takes... cannot find function declaration in netdb.h
Yours:
checking for broken libc stdio... yes checking for getaddrinfo... no checking for type of readdir_r... old-style checking for asm goto... yes checking whether pwrite works... no checking whether pread works... no checking for standard DES crypt... no checking for extended DES crypt... no checking whether sprintf is broken... yes checking how many arguments gethostbyname_r() takes... can't tell
The config.log file might tell us more details about why these various checks returned different and I suspect incorrect results on your system. Could you attach it? It will be in the directory /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_php/php73-apache2handler/work/php-7.3.16/
comment:4 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
The config.log shows the tests are failing because of implicitly declared functions, for example the "broken libc stdio" test:
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); ^
I know that implicitly declared functions will be errors in Xcode 12 and later, so we definitely need to fix them, I just wasn't expecting them to show up in Xcode 11 already, and I can't explain why you're seeing these errors with Xcode 11.6 on macOS 10.15 when we did not on the same system.
Maybe we have different versions of the command line tools. On our server we have:
% pkgutil --pkg-info=com.apple.pkg.CLTools_Executables | grep version: version: 11.5.0.0.1.1588476445
What version do you have?
comment:5 Changed 4 years ago by murrayE
pkgutil --pkg-info=com.apple.pkg.CLTools_Executables | grep version
version: 12.0.0.0.1.1595091463
There were no CLTs for Xcode 11.6, only for Xcode 11.5 and Xcode 12 beta.
comment:6 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
That explains it. So to avoid this problem for now, please install the Xcode 11.5 command line tools. Using Xcode 12 or its command line tools will cause you to run into this problem with lots of ports.
comment:7 Changed 4 years ago by murrayE
I deleted Xcode 11.6, re-downloaded to re-nstall it. But that did *not* get rid of the 12.0 CLT: The pkgutil command still shows version: 12.0.0.0.1.1595091463.
comment:8 Changed 4 years ago by murrayE
Fixed CLT by downloading CLT 11.5 from developer site and installing. That automatically changed active version:
$ pkgutil --pkg-info=com.apple.pkg.CLTools_Executables | grep version version: 11.5.0.0.1.1588476445
I'm making this comment because there seems to be a lot of obsolete information available about dealing with installing CLTs. E.g., some sources say one can change the version from within the Xcode app's Preferences, but I don't see any such place in Xcode 11.6.
That solved the immediate issue: php73-apache2handler upgraded without error (as did inkscape).
comment:9 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | josephsacco added |
---|---|
Port: | php added; php73-apache2handler removed |
Has duplicate #61168.
comment:10 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
Filed upstream bug report: https://bugs.php.net/bug.php?id=80176
comment:11 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | nortcele added |
---|
Has duplicate #61364.
The developers have committed a fix which should be in the next version of php73 but I haven't verified the fix yet.
comment:12 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
comment:13 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
comment:14 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | HuabinLee added |
---|
Has duplicate #61517.
comment:15 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
comment:16 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | theq86 added |
---|---|
Keywords: | bigsur catalina added |
Has duplicate #61844.
comment:17 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | ndebarnot added |
---|
Has duplicate #61900.
If you use Xcode 12 or later, you'll need to use php73 or later for now.
If you want to use php72 or earlier, you'll need to use Xcode 11.x or earlier for now, which means using macOS Catalina 10.15.x or earlier.
comment:18 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
comment:19 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
comment:20 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | mivancic added |
---|
Has duplicate #62888 reminding me I still need to backport the fixes to php56 and earlier.
comment:21 Changed 3 years ago by elcheco (Miroslav Koula)
Cc: | elcheco added |
---|
comment:22 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | hostep added |
---|
Has duplicate #63225.
main.log