9b1730c7b0
Related to: <https://fedoraproject.org/wiki/Changes/PortingToModernC> <https://fedoraproject.org/wiki/Toolchain/PortingToModernC>
28 lines
762 B
Diff
28 lines
762 B
Diff
Avoid C89isms during configure checks.
|
|
|
|
Submitted upstream: <https://github.com/lsof-org/lsof/pull/265>
|
|
|
|
diff --git a/Configure b/Configure
|
|
index d8adfda3e47f87df..ed1e1d60840b3852 100755
|
|
--- a/Configure
|
|
+++ b/Configure
|
|
@@ -2189,7 +2189,7 @@ LOCKF_OWNER4
|
|
#include <netinet/in.h>
|
|
#include <netinet/in_pcb.h>
|
|
#include <netinet/tcp_var.h>
|
|
-main() {
|
|
+int main() {
|
|
struct xtcpcb pcb; pcb.t_maxseg = 0;
|
|
}
|
|
.LSOF_END_HERE_DOC4
|
|
@@ -2755,7 +2755,8 @@ struct xtcpcb pcb; pcb.t_maxseg = 0;
|
|
rm -f ${LSOF_TMPC}.*
|
|
cat > $LSOF_TMPC.c << .LSOF_END_HERE_DOC1
|
|
#include <features.h>
|
|
-main() {
|
|
+#include <stdio.h>
|
|
+int main() {
|
|
#if defined(__GLIBC__) && defined(__GLIBC_MINOR__)
|
|
printf("-DGLIBCV=%d\n",__GLIBC__*100+__GLIBC_MINOR__);
|
|
#elif defined(__GLIBC__)
|