-
Notifications
You must be signed in to change notification settings - Fork 7.9k
Enable -Wundef compiler warning #5526
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
04ee8ee
to
2da480a
Compare
2da480a
to
2d52c13
Compare
Closed
d789c7a
to
a32cc30
Compare
1d9f817
to
ed23794
Compare
Closed
ce4316d
to
5c19ecf
Compare
9cff451
to
c6fad3d
Compare
91b2ad7
to
b859ca2
Compare
b859ca2
to
5ea966d
Compare
5ddec73
to
1e4cf4f
Compare
1e4cf4f
to
ec13b80
Compare
b84801e
to
0057709
Compare
Closing this as the current PR is very outdated and follow-up work for this has been done. |
petk
added a commit
to petk/php-src
that referenced
this pull request
May 31, 2024
These are either undefined or defined to value 1: - HAVE_CRYPT - HAVE_CRYPT_H - HAVE_UNISTD_H Follow up of phpGH-5526 (-Wundef)
petk
added a commit
that referenced
this pull request
Jun 1, 2024
These are either undefined or defined to value 1: - HAVE_CRYPT - HAVE_CRYPT_H - HAVE_UNISTD_H Follow up of GH-5526 (-Wundef)
petk
added a commit
that referenced
this pull request
Jun 7, 2024
These are either undefined or defined to value 1 in Autotools and Windows: - HAVE_COMMONCRYPTO_COMMONRANDOM_H - HAVE_EXIF - HAVE_FOPENCOOKIE - HAVE_IF_NAMETOINDEX - HAVE_LIBICONV - HAVE_SOCKETS - HAVE_STRUCT_STAT_ST_RDEV - HAVE_STRUCT_TM_TM_GMTOFF - HAVE_STRUCT_TM_TM_ZONE Follow up of GH-5526 (-Wundef)
petk
added a commit
to petk/php-src
that referenced
this pull request
Jun 8, 2024
This syncs CPP macro conditions: - _WIN32 - _WIN64 - HAVE_ALLOCA_H - HAVE_ALPHASORT - HAVE_ARPA_INET_H - HAVE_CONFIG_H - HAVE_DIRENT_H - HAVE_DLFCN_H - HAVE_GETTIMEOFDAY - HAVE_LIBDL - HAVE_POLL_H - HAVE_PWD_H - HAVE_SCANDIR - HAVE_SYS_FILE_H - HAVE_SYS_PARAM_H - HAVE_SYS_SOCKET_H - HAVE_SYS_TIME_H - HAVE_SYS_TYPES_H - HAVE_SYS_WAIT_H - HAVE_UNISTD_H - PHP_WIN32 - ZEND_WIN32 Follow up of phpGH-5526 (-Wundef).
petk
added a commit
to petk/php-src
that referenced
this pull request
Jun 8, 2024
This syncs CPP macro conditions: - _WIN32 - _WIN64 - HAVE_ALLOCA_H - HAVE_ALPHASORT - HAVE_ARPA_INET_H - HAVE_CONFIG_H - HAVE_DIRENT_H - HAVE_DLFCN_H - HAVE_GETTIMEOFDAY - HAVE_LIBDL - HAVE_POLL_H - HAVE_PWD_H - HAVE_SCANDIR - HAVE_SYS_FILE_H - HAVE_SYS_PARAM_H - HAVE_SYS_SOCKET_H - HAVE_SYS_TIME_H - HAVE_SYS_TYPES_H - HAVE_SYS_WAIT_H - HAVE_UNISTD_H - PHP_WIN32 - ZEND_WIN32 These are either undefined or defined to 1 in Autotools and Windows. Follow up of phpGH-5526 (-Wundef).
petk
added a commit
to petk/php-src
that referenced
this pull request
Jun 8, 2024
These are either undefined or defined to value 1: - ZEND_INTRIN_SSE4_2_PCLMUL_NATIVE - ZEND_INTRIN_SSE4_2_PCLMUL_RESOLVER - ZEND_INTRIN_SSE4_2_PCLMUL_FUNC_PROTO - ZEND_INTRIN_SSE4_2_PCLMUL_FUNC_PTR Follow up of phpGH-5526 (-Wundef)
petk
added a commit
to petk/php-src
that referenced
this pull request
Jun 8, 2024
These are either undefined or defined to 1: - HAVE_LIBEDIT - HAVE_LIBREADLINE - ZEND_MAX_EXECUTION_TIMERS Follow up of phpGH-5526 (-Wundef)
petk
added a commit
that referenced
this pull request
Jun 9, 2024
These are either undefined or defined to value 1: - ZEND_INTRIN_SSE4_2_PCLMUL_NATIVE - ZEND_INTRIN_SSE4_2_PCLMUL_RESOLVER - ZEND_INTRIN_SSE4_2_PCLMUL_FUNC_PROTO - ZEND_INTRIN_SSE4_2_PCLMUL_FUNC_PTR Follow up of GH-5526 (-Wundef)
petk
added a commit
to petk/php-src
that referenced
this pull request
Jun 9, 2024
These are either undefined or defined (to value 1): - __DragonFly__ - __FreeBSD__ - HAS_MCAST_EXT - HAVE_GETCWD - HAVE_GETWD - HAVE_GLIBC_ICONV - HAVE_JIT - HAVE_LCHOWN - HAVE_NL_LANGINFO - HAVE_RL_CALLBACK_READ_CHAR - HAVE_RL_ON_NEW_LINE - HAVE_SQL_EXTENDED_FETCH - HAVE_UTIME Follow up of phpGH-5526 (-Wundef)
petk
added a commit
that referenced
this pull request
Jun 9, 2024
This syncs CPP macro conditions: - _WIN32 - _WIN64 - HAVE_ALLOCA_H - HAVE_ALPHASORT - HAVE_ARPA_INET_H - HAVE_CONFIG_H - HAVE_DIRENT_H - HAVE_DLFCN_H - HAVE_GETTIMEOFDAY - HAVE_LIBDL - HAVE_POLL_H - HAVE_PWD_H - HAVE_SCANDIR - HAVE_SYS_FILE_H - HAVE_SYS_PARAM_H - HAVE_SYS_SOCKET_H - HAVE_SYS_TIME_H - HAVE_SYS_TYPES_H - HAVE_SYS_WAIT_H - HAVE_UNISTD_H - PHP_WIN32 - ZEND_WIN32 These are either undefined or defined to 1 in Autotools and Windows. Follow up of GH-5526 (-Wundef).
petk
added a commit
to petk/php-src
that referenced
this pull request
Jun 9, 2024
This fixes few more -Wundef warnings in ext/fileinfo. The PHP_FILEINFO_UNCOMPRESS seems to be present to be defined at some point but is currently unused in all build systems. Leaving this intact for now. Follow up of phpGH-5526 (-Wundef)
petk
added a commit
that referenced
this pull request
Jun 10, 2024
This fixes few more -Wundef warnings in ext/fileinfo. The PHP_FILEINFO_UNCOMPRESS seems to be present to be defined at some point but is currently unused in all build systems. Leaving this intact for now. Follow up of GH-5526 (-Wundef)
petk
added a commit
that referenced
this pull request
Jun 10, 2024
These are either undefined or defined to 1: - HAVE_LIBEDIT - HAVE_LIBREADLINE - ZEND_MAX_EXECUTION_TIMERS Follow up of GH-5526 (-Wundef)
petk
added a commit
that referenced
this pull request
Jun 11, 2024
These are either undefined or defined (to value 1): - __DragonFly__ - __FreeBSD__ - HAS_MCAST_EXT - HAVE_GETCWD - HAVE_GETWD - HAVE_GLIBC_ICONV - HAVE_JIT - HAVE_LCHOWN - HAVE_NL_LANGINFO - HAVE_RL_CALLBACK_READ_CHAR - HAVE_RL_ON_NEW_LINE - HAVE_SQL_EXTENDED_FETCH - HAVE_UTIME Follow up of GH-5526 (-Wundef)
petk
added a commit
to petk/php-src
that referenced
this pull request
Jun 20, 2024
The libmagic library also uses the HAVE_VISIBILITY macro that should be defined to 1 if visibility is supported or 0 if not. Follow-up of phpGH-5526 (-Wundef)
petk
added a commit
to petk/php-src
that referenced
this pull request
Jun 21, 2024
These are either define (to value 1) or undefined: - __GNUC__ - DBA_CDB_BUILTIN - DBA_GDBM - HAVE_FORK - HAVE_PUTENV - HAVE_SETENV - HAVE_SYS_SELECT_H - HAVE_SYS_SOCKET_H - HAVE_SYS_WAIT_H - HAVE_UNSETENV - RFC3678_API - ZEND_ENABLE_ZVAL_LONG64 - ZTS Follow-up of phpGH-5526
petk
added a commit
that referenced
this pull request
Jun 21, 2024
The libmagic library also uses the HAVE_VISIBILITY macro that should be defined to 1 if visibility is supported or 0 if not. Follow-up of GH-5526 (-Wundef)
devnexen
pushed a commit
to devnexen/php-src
that referenced
this pull request
Jun 21, 2024
The libmagic library also uses the HAVE_VISIBILITY macro that should be defined to 1 if visibility is supported or 0 if not. Follow-up of phpGH-5526 (-Wundef)
petk
added a commit
that referenced
this pull request
Jun 24, 2024
These are either define (to value 1) or undefined: - __GNUC__ - DBA_CDB_BUILTIN - DBA_GDBM - HAVE_FORK - HAVE_PUTENV - HAVE_SETENV - HAVE_SYS_SELECT_H - HAVE_SYS_SOCKET_H - HAVE_SYS_WAIT_H - HAVE_UNSETENV - RFC3678_API - ZEND_ENABLE_ZVAL_LONG64 - ZTS Follow-up of GH-5526
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is not enabled by -Wextra and seems like something sane to have which is not much effort to make work.
Except for this one:
Which is generated by Bison but I also don't understand why the compilers are complaining as the generated code is (at least locally):
Note, I realized that the following macros are always defined, but only on Windows:
Fixed with: ca6dd7e
AC_DEFINE('HAVE_GETADDRINFO', main_network_has_ipv6);
See https://heap.space/xref/php-src/win32/build/config.w32?r=84854a72#283
Review list:
HAVE_ENCHANT_BROKER_SET_PARAM
or need to always be defined for Nux* or need to drop always defined on Windows and adjust #if/#ifdef accordingly#if FFI_CLOSURES
need to be#ifdef FFI_CLOSURES
?HAVE_GETADDRINFO
issue before finishedHAVE_GETADDRINFO
issue before finishedXMLRPCIgnoring this as it's getting unbundled