Page MenuHomeFreeBSD

D62079.1795917106.diff
No OneTemporary

Authored By
Unknown
Size
215 KB
Referenced Files
None
Subscribers
None

D62079.1795917106.diff

diff --git a/contrib/libpcap/CHANGES b/contrib/libpcap/CHANGES
--- a/contrib/libpcap/CHANGES
+++ b/contrib/libpcap/CHANGES
@@ -1,3 +1,45 @@
+Saturday, September 5, 2026 / The Tcpdump Group
+ Summary for 1.10.7 libpcap release
+ General:
+ Free p->opt.device on close, not on cleanup (issue #1615). Issue
+ reported by Harrison Green.
+ Source code:
+ Deprecate bpf_filter().
+ Packet filtering:
+ Initialize the scratch memory store to 0.
+ In "net <n> mask <m>" catch ENOMEM for the "m" too.
+ CVE-2026-0799: Access M[] safely in the BPF interpreter.
+ CVE-2026-31912: Mind the program bounds in pcap_offline_filter().
+ CVE-2026-31911: Fail opcodes safely in the BPF interpreter.
+ CVE-2026-6244: Avoid division by zero via pcap_offline_filter().
+ CVE-2026-6554: Limit "ja L" looping in pcap_offline_filter().
+ Validate BPF opcodes stricter.
+ For "lsh" and "rsh" guard "#k" as well.
+ Windows:
+ Fix error return from memory allocation error.
+ rpcap:
+ CVE-2026-18313: Fix a memory leak in rpcapd.
+ CVE-2026-18238: Fix RPCAP_MSG_PACKET validation.
+ Documentation:
+ Remove list of OSes that support "ipv6-icmp"; all the ones we
+ support appear to do so.
+ Fix pcap_next_ex(3PCAP) man page to clarify the PCAP_ERROR_BREAK
+ return value.
+ Building and testing:
+ CMake: Disable remote capture support on Windows by default.
+ RDMA: Avoid valgrind errors when calling rdmasniff_findalldevs().
+ Autoconf: Add QNX support to AC_LBL_LIBRARY_NET().
+ capturetest: Treat SA_RESTART as optional.
+ QNX:
+ Disable zero-copy BPF to work around portability issues.
+ DAG:
+ Fix packet filtering with low snaplen.
+ SNF:
+ Fix packet filtering with low snaplen.
+ Netmap:
+ Set packet captured length based on the snapshot length and return
+ value of the capture filter.
+
Tuesday, December 30, 2025 / The Tcpdump Group
Summary for 1.10.6 libpcap release
General:
diff --git a/contrib/libpcap/CMakeLists.txt b/contrib/libpcap/CMakeLists.txt
--- a/contrib/libpcap/CMakeLists.txt
+++ b/contrib/libpcap/CMakeLists.txt
@@ -492,14 +492,10 @@
set(PCAP_TYPE "" CACHE STRING "Packet capture type")
#
-# Default to having remote capture support on Windows and, for now, to
-# not having it on UN*X.
+# Disable remote capture support by default.
+# This feature is experimental and is not ready for production use.
#
-if(WIN32)
- option(ENABLE_REMOTE "Enable remote capture" ON)
-else()
- option(ENABLE_REMOTE "Enable remote capture" OFF)
-endif(WIN32)
+option(ENABLE_REMOTE "Enable remote capture" OFF)
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
option(BUILD_WITH_LIBNL "Build with libnl" ON)
@@ -3637,3 +3633,12 @@
add_custom_target(uninstall
COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake)
+
+if(ENABLE_REMOTE)
+ message(WARNING "
+ *** REMOTE PACKET CAPTURE IS ENABLED ***
+ The ENABLE_REMOTE feature is experimental and is not ready for
+ production use. Remote packet capture may expose libpcap-based
+ applications to attacks by malicious remote capture servers!"
+ )
+endif()
diff --git a/contrib/libpcap/Makefile.in b/contrib/libpcap/Makefile.in
--- a/contrib/libpcap/Makefile.in
+++ b/contrib/libpcap/Makefile.in
@@ -402,6 +402,7 @@
testprogs/capturetest.c \
testprogs/filtertest.c \
testprogs/findalldevstest.c \
+ testprogs/findalldevstest.supp \
testprogs/findalldevstest-perf.c \
testprogs/nonblocktest.c \
testprogs/opentest.c \
@@ -855,7 +856,7 @@
(cd "$$TAG" && ./autogen.sh && rm -rf autom4te.cache) && \
tar cf "$$DIR/$$TAG".tar "$$TAG" && \
rm -f "$$DIR/$$TAG".tar.gz && \
- gzip --best "$$DIR/$$TAG".tar && \
+ gzip -9 "$$DIR/$$TAG".tar && \
cd "$$DIR" && \
rm -rf "$$AUTORECONF_DIR"
diff --git a/contrib/libpcap/VERSION b/contrib/libpcap/VERSION
--- a/contrib/libpcap/VERSION
+++ b/contrib/libpcap/VERSION
@@ -1 +1 @@
-1.10.6
+1.10.7
diff --git a/contrib/libpcap/aclocal.m4 b/contrib/libpcap/aclocal.m4
--- a/contrib/libpcap/aclocal.m4
+++ b/contrib/libpcap/aclocal.m4
@@ -1049,9 +1049,24 @@
],
[
#
- # We didn't find it.
+ # If this is QNX 8.0, getaddrinfo() and related functions are
+ # in libsocket, but there is no libnsl, hence the check result
+ # above for getaddrinfo() in libsocket with libnsl is negative.
+ # Autoconf caches the result, but does take libnsl into account
+ # as a caching factor, so remove the cached result to prevent
+ # an erroneous "cache hit" in the check below.
#
- AC_MSG_ERROR([getaddrinfo is required, but wasn't found])
+ AS_UNSET(ac_cv_lib_socket_getaddrinfo)
+ AC_CHECK_LIB(socket, getaddrinfo,
+ [
+ LIBS="-lsocket $LIBS"
+ ],
+ [
+ #
+ # We didn't find it.
+ #
+ AC_MSG_ERROR([getaddrinfo is required, but wasn't found])
+ ])
])
], -lnsl)
diff --git a/contrib/libpcap/bpf_filter.c b/contrib/libpcap/bpf_filter.c
--- a/contrib/libpcap/bpf_filter.c
+++ b/contrib/libpcap/bpf_filter.c
@@ -64,11 +64,25 @@
#include <linux/filter.h>
#endif
-enum {
- BPF_S_ANC_NONE,
- BPF_S_ANC_VLAN_TAG,
- BPF_S_ANC_VLAN_TAG_PRESENT,
-};
+#define MAX_BACKWARD_JUMPS 64U
+
+/*
+ * Kernel BPF implementations tend to define BPF_MAXINSNS to 512 or 4096, the
+ * userland interpreter in libpcap is meant to support much longer filter
+ * programs. In the latter case it is important that BPF_MAXINSNS does not
+ * interfere with the safety checks in the validator and the interpreter:
+ * (BPF_MAXINSNS + UINT8_MAX) * sizeof(struct bpf_insn) < UINT32_MAX
+ * It makes the most sense to be able to interpret as many instructions as
+ * pcap_compile() can produce, without optimization, for a valid filter
+ * expression before it consumes as much memory as the current definitions of
+ * NCHUNKS and CHUNKSIZE() allow. For some expressions this can be almost
+ * 1.53 million instructions on a 64-bit machine and twice as many on a 32-bit
+ * machine.
+ */
+#ifdef BPF_MAXINSNS
+#undef BPF_MAXINSNS
+#endif
+#define BPF_MAXINSNS 3060000U
/*
* Execute the filter program starting at pc on the packet p
@@ -84,32 +98,58 @@
*/
#if defined(SKF_AD_VLAN_TAG_PRESENT)
u_int
-pcapint_filter_with_aux_data(const struct bpf_insn *pc, const u_char *p,
- u_int wirelen, u_int buflen, const struct pcap_bpf_aux_data *aux_data)
+pcapint_filter_with_aux_data(const struct bpf_insn *pc, const u_int proglen,
+ const u_char *p, const u_int wirelen, const u_int buflen,
+ const struct pcap_bpf_aux_data *aux_data)
#else
u_int
-pcapint_filter_with_aux_data(const struct bpf_insn *pc, const u_char *p,
- u_int wirelen, u_int buflen, const struct pcap_bpf_aux_data *aux_data _U_)
+pcapint_filter_with_aux_data(const struct bpf_insn *pc, const u_int proglen,
+ const u_char *p, const u_int wirelen, const u_int buflen,
+ const struct pcap_bpf_aux_data *aux_data _U_)
#endif
{
register uint32_t A, X;
register bpf_u_int32 k;
- uint32_t mem[BPF_MEMWORDS];
if (pc == 0)
/*
* No filter means accept all.
+ * In this case the value of 'proglen' is irrelevant.
*/
return (u_int)-1;
+ if (proglen < 1 || proglen > BPF_MAXINSNS)
+ return 0;
+
+ /*
+ * Require the current instruction pointer not to overflow for both the
+ * filter program (where the pointer will be dereferenced) and an
+ * immediately following margin (where it will be not). So long as the
+ * margin is large enough to represent the destination of any single
+ * conditional [forward] jump from within the filter program, a single
+ * guard prevents all filter program over-read attempts that result
+ * from the program running out of instructions before a BPF_RET or a
+ * conditional jump directing the interpreter beyond the program end.
+ * Unconditional jumps mean a larger problem space, which the BPF_JA
+ * case below addresses separately.
+ */
+ const struct bpf_insn *pcend = pc + proglen;
+ if (pcend + UINT8_MAX < pc)
+ return 0;
+
A = 0;
X = 0;
+ uint32_t mem[BPF_MEMWORDS] = {0};
+ const struct bpf_insn *pc0 = pc;
+ unsigned backward_jumps = 0;
--pc;
for (;;) {
++pc;
+ if (pc >= pcend)
+ return 0;
switch (pc->code) {
default:
- abort();
+ return 0;
case BPF_RET|BPF_K:
return (u_int)pc->k;
@@ -217,22 +257,75 @@
continue;
case BPF_LD|BPF_MEM:
+ if (pc->k >= BPF_MEMWORDS)
+ return 0;
A = mem[pc->k];
continue;
case BPF_LDX|BPF_MEM:
+ if (pc->k >= BPF_MEMWORDS)
+ return 0;
X = mem[pc->k];
continue;
case BPF_ST:
+ if (pc->k >= BPF_MEMWORDS)
+ return 0;
mem[pc->k] = A;
continue;
case BPF_STX:
+ if (pc->k >= BPF_MEMWORDS)
+ return 0;
mem[pc->k] = X;
continue;
case BPF_JMP|BPF_JA:
+ /*
+ * The pointer (pc) decrements and increments in units
+ * of sizeof(struct bpf_insn) == 8 bytes. The number
+ * of units is in the [INT32_MIN, INT32_MAX] interval,
+ * hence the result can point before the beginning or
+ * beyond the end of the filter program and can under-
+ * or overflow; also on 32-bit architectures it can
+ * under- or overflow more than once and can test
+ * negative for underflow, overflow and out-of-range
+ * conditions after under- or overflowing at least
+ * once.
+ *
+ * However, it has been verified above that the program
+ * length is sufficiently small and the pointer does
+ * not wrap within the bounds of the filter program, so
+ * there is a one-to-one correspondence between BPF
+ * program counter values [0, proglen) and all valid
+ * values of the pointer. In other words, after this
+ * unconditional jump the pointer arithmetic result
+ * will be valid iff BPF program counter value will be
+ * valid. For the latter problem the solution is
+ * almost the same as in the validator.
+ *
+ * The main difference is that here the current value
+ * of BPF program counter is not a 32-bit unsigned
+ * variable, but a ptrdiff_t expression, which is
+ * 64-bit signed on 64-bit architectures and 32-bit
+ * signed on 32-bit architectures. However, the cast
+ * to 32-bit unsigned is safe in both cases because:
+ * pc0 <= pc < pc0 + proglen, therefore:
+ * 0 <= pc - pc0 < proglen <= BPF_MAXINSNS < INT32_MAX
+ */
+ if ((bpf_u_int32)(pc - pc0) + 1 + pc->k >= proglen)
+ return 0;
+ /*
+ * Terminate the program if this is a non-forward jump
+ * and is:
+ * - a guaranteed infinite loop because it jumps to
+ * itself (exactly the same as in the validator), or
+ * - a backward jump after many enough backward jumps
+ * already made for this packet.
+ */
+ if ((bpf_int32)pc->k < 0 && ((bpf_int32)pc->k == -1 ||
+ backward_jumps++ >= MAX_BACKWARD_JUMPS))
+ return 0;
/*
* XXX - we currently implement "ip6 protochain"
* with backward jumps, so sign-extend pc->k.
@@ -335,10 +428,14 @@
continue;
case BPF_ALU|BPF_DIV|BPF_K:
+ if (pc->k == 0)
+ return 0;
A /= pc->k;
continue;
case BPF_ALU|BPF_MOD|BPF_K:
+ if (pc->k == 0)
+ return 0;
A %= pc->k;
continue;
@@ -355,11 +452,11 @@
continue;
case BPF_ALU|BPF_LSH|BPF_K:
- A <<= pc->k;
+ A = (pc->k < 32) ? A << pc->k : 0;
continue;
case BPF_ALU|BPF_RSH|BPF_K:
- A >>= pc->k;
+ A = (pc->k < 32) ? A >> pc->k : 0;
continue;
case BPF_ALU|BPF_NEG:
@@ -386,19 +483,93 @@
}
u_int
-pcapint_filter(const struct bpf_insn *pc, const u_char *p, u_int wirelen,
- u_int buflen)
+pcapint_filter(const struct bpf_insn *pc, const u_int proglen, const u_char *p,
+ u_int wirelen, u_int buflen)
{
- return pcapint_filter_with_aux_data(pc, p, wirelen, buflen, NULL);
+ return pcapint_filter_with_aux_data(pc, proglen, p, wirelen, buflen, NULL);
+}
+
+/*
+ * Return true if the instruction is valid, as far as is possible to tell
+ * without knowing what the rest of the filter program is.
+ */
+uint8_t
+pcapint_valid_insn(const struct bpf_insn *insn)
+{
+ /*
+ * Require the opcode to be valid, for particular opcodes also require
+ * the value of k to be valid. The list of opcodes below is exactly
+ * the same as in bpf_filter() to make it easier to cross-reference.
+ */
+ switch (insn->code) {
+ case BPF_RET|BPF_K:
+ case BPF_RET|BPF_A:
+ case BPF_LD|BPF_W|BPF_ABS:
+ case BPF_LD|BPF_H|BPF_ABS:
+ case BPF_LD|BPF_B|BPF_ABS:
+ case BPF_LD|BPF_W|BPF_LEN:
+ case BPF_LDX|BPF_W|BPF_LEN:
+ case BPF_LD|BPF_W|BPF_IND:
+ case BPF_LD|BPF_H|BPF_IND:
+ case BPF_LD|BPF_B|BPF_IND:
+ case BPF_LDX|BPF_MSH|BPF_B:
+ case BPF_LD|BPF_IMM:
+ case BPF_LDX|BPF_IMM:
+ return 1;
+ case BPF_LD|BPF_MEM:
+ case BPF_LDX|BPF_MEM:
+ case BPF_ST:
+ case BPF_STX:
+ // Reject a non-existent scratch memory register.
+ return insn->k < BPF_MEMWORDS;
+ case BPF_JMP|BPF_JA:
+ case BPF_JMP|BPF_JGT|BPF_K:
+ case BPF_JMP|BPF_JGE|BPF_K:
+ case BPF_JMP|BPF_JEQ|BPF_K:
+ case BPF_JMP|BPF_JSET|BPF_K:
+ case BPF_JMP|BPF_JGT|BPF_X:
+ case BPF_JMP|BPF_JGE|BPF_X:
+ case BPF_JMP|BPF_JEQ|BPF_X:
+ case BPF_JMP|BPF_JSET|BPF_X:
+ case BPF_ALU|BPF_ADD|BPF_X:
+ case BPF_ALU|BPF_SUB|BPF_X:
+ case BPF_ALU|BPF_MUL|BPF_X:
+ case BPF_ALU|BPF_DIV|BPF_X:
+ case BPF_ALU|BPF_MOD|BPF_X:
+ case BPF_ALU|BPF_AND|BPF_X:
+ case BPF_ALU|BPF_OR|BPF_X:
+ case BPF_ALU|BPF_XOR|BPF_X:
+ case BPF_ALU|BPF_LSH|BPF_X:
+ case BPF_ALU|BPF_RSH|BPF_X:
+ case BPF_ALU|BPF_ADD|BPF_K:
+ case BPF_ALU|BPF_SUB|BPF_K:
+ case BPF_ALU|BPF_MUL|BPF_K:
+ return 1;
+ case BPF_ALU|BPF_DIV|BPF_K:
+ case BPF_ALU|BPF_MOD|BPF_K:
+ // Reject a constant division or modulo by 0.
+ return insn->k != 0;
+ case BPF_ALU|BPF_AND|BPF_K:
+ case BPF_ALU|BPF_OR|BPF_K:
+ case BPF_ALU|BPF_XOR|BPF_K:
+ return 1;
+ case BPF_ALU|BPF_LSH|BPF_K:
+ case BPF_ALU|BPF_RSH|BPF_K:
+ // Reject a constant shift by more than 31 bits.
+ return insn->k < 32;
+ case BPF_ALU|BPF_NEG:
+ case BPF_MISC|BPF_TAX:
+ case BPF_MISC|BPF_TXA:
+ return 1;
+ }
+ // Reject an invalid opcode.
+ return 0;
}
/*
* Return true if the 'fcode' is a valid filter program.
* The constraints are that each jump be forward and to a valid
- * code, that memory accesses are within valid ranges (to the
- * extent that this can be checked statically; loads of packet
- * data have to be, and are, also checked at run time), and that
- * the code terminates with either an accept or reject.
+ * code and that the code terminates with either an accept or reject.
*
* The kernel needs to be able to verify an application's filter code.
* Otherwise, a bogus program could easily crash the system.
@@ -409,101 +580,69 @@
u_int i, from;
const struct bpf_insn *p;
- if (len < 1)
+ if (len < 1 || (u_int)len > BPF_MAXINSNS || f + len < f)
return 0;
for (i = 0; i < (u_int)len; ++i) {
p = &f[i];
+ if (! pcapint_valid_insn(p))
+ return 0;
switch (BPF_CLASS(p->code)) {
- /*
- * Check that memory operations use valid addresses.
- */
- case BPF_LD:
- case BPF_LDX:
- switch (BPF_MODE(p->code)) {
- case BPF_IMM:
- break;
- case BPF_ABS:
- case BPF_IND:
- case BPF_MSH:
- /*
- * There's no maximum packet data size
- * in userland. The runtime packet length
- * check suffices.
- */
- break;
- case BPF_MEM:
- if (p->k >= BPF_MEMWORDS)
- return 0;
- break;
- case BPF_LEN:
- break;
- default:
- return 0;
- }
- break;
- case BPF_ST:
- case BPF_STX:
- if (p->k >= BPF_MEMWORDS)
- return 0;
- break;
- case BPF_ALU:
- switch (BPF_OP(p->code)) {
- case BPF_ADD:
- case BPF_SUB:
- case BPF_MUL:
- case BPF_OR:
- case BPF_AND:
- case BPF_XOR:
- case BPF_LSH:
- case BPF_RSH:
- case BPF_NEG:
- break;
- case BPF_DIV:
- case BPF_MOD:
- /*
- * Check for constant division or modulus
- * by 0.
- */
- if (BPF_SRC(p->code) == BPF_K && p->k == 0)
- return 0;
- break;
- default:
- return 0;
- }
- break;
case BPF_JMP:
/*
* Check that jumps are within the code block,
- * and that unconditional branches don't go
- * backwards as a result of an overflow.
+ * regardless of the direction. libpcap uses
+ * backward jumps to implement the "protochain"
+ * primitive. All offsets that mean a backward
+ * jump in libpcap (whether in-range or not) in
+ * kernel BPF implementations mean out-of-range
+ * or overflow forward jumps -- kernel
+ * implementations must reject that.
+ *
* Unconditional branches have a 32-bit offset,
* so they could overflow; we check to make
* sure they don't. Conditional branches have
* an 8-bit offset, and the from address is <=
- * BPF_MAXINSNS, and we assume that BPF_MAXINSNS
+ * BPF_MAXINSNS, and we know that BPF_MAXINSNS
* is sufficiently small that adding 255 to it
* won't overflow.
*
* We know that len is <= BPF_MAXINSNS, and we
- * assume that BPF_MAXINSNS is < the maximum size
+ * know that BPF_MAXINSNS is < the maximum value
* of a u_int, so that i + 1 doesn't overflow.
- *
- * For userland, we don't know that the from
- * or len are <= BPF_MAXINSNS, but we know that
- * from <= len, and, except on a 64-bit system,
- * it's unlikely that len, if it truly reflects
- * the size of the program we've been handed,
- * will be anywhere near the maximum size of
- * a u_int. We also don't check for backward
- * branches, as we currently support them in
- * userland for the protochain operation.
*/
from = i + 1;
switch (BPF_OP(p->code)) {
case BPF_JA:
+ /*
+ * So long as both 'from' and bpf_insn.k are
+ * 32-bit unsigned, this check rejects any jump
+ * offset that points outside of the valid BPF
+ * address space of the filter program no
+ * matter whether signed interpretation of the
+ * offset is positive or negative.
+ *
+ * Note that this condition is necessary, but
+ * not sufficient to get correct results from
+ * respective pointer arithmetic in the process
+ * address space. Other necessary conditions
+ * are that BPF_MAXINSNS is correctly defined
+ * and enforced, and that the pointer does not
+ * overflow.
+ */
if (from + p->k >= (u_int)len)
return 0;
+ /*
+ * The only type of infinite loop that can be
+ * detected in this function is a "ja L" that
+ * jumps to itself. For this only k == -1
+ * needs to be tested because the check above
+ * has already rejected all other values that
+ * would wrap the pointer equivalently on
+ * 32-bit architectures.
+ */
+ if ((bpf_int32)p->k == -1)
+ return 0;
break;
case BPF_JEQ:
case BPF_JGT:
@@ -512,16 +651,7 @@
if (from + p->jt >= (u_int)len || from + p->jf >= (u_int)len)
return 0;
break;
- default:
- return 0;
}
- break;
- case BPF_RET:
- break;
- case BPF_MISC:
- break;
- default:
- return 0;
}
}
return BPF_CLASS(f[len - 1].code) == BPF_RET;
@@ -529,12 +659,14 @@
/*
* Exported because older versions of libpcap exported them.
+ * This function is deprecated and unsafe, use pcap_offline_filter() instead.
*/
u_int
bpf_filter(const struct bpf_insn *pc, const u_char *p, u_int wirelen,
u_int buflen)
{
- return pcapint_filter(pc, p, wirelen, buflen);
+ // The actual length of the filter program is not known.
+ return pcapint_filter(pc, BPF_MAXINSNS, p, wirelen, buflen);
}
int
diff --git a/contrib/libpcap/bpf_image.c b/contrib/libpcap/bpf_image.c
--- a/contrib/libpcap/bpf_image.c
+++ b/contrib/libpcap/bpf_image.c
@@ -176,6 +176,11 @@
operand = "#pktlen";
break;
+ case BPF_LDX|BPF_W|BPF_LEN:
+ op = "ldx";
+ operand = "#pktlen";
+ break;
+
case BPF_LD|BPF_W|BPF_IND:
op = "ld";
(void)snprintf(operand_buf, sizeof operand_buf, "[x + %d]", p->k);
diff --git a/contrib/libpcap/config.h.in b/contrib/libpcap/config.h.in
--- a/contrib/libpcap/config.h.in
+++ b/contrib/libpcap/config.h.in
@@ -18,7 +18,7 @@
/* define if we have the AIX getprotobyname_r() */
#undef HAVE_AIX_GETPROTOBYNAME_R
-/* Define to 1 if you have the `asprintf' function. */
+/* Define to 1 if you have the 'asprintf' function. */
#undef HAVE_ASPRINTF
/* Define to 1 if you have the <config/HaikuConfig.h> header file. */
@@ -45,22 +45,22 @@
/* Define to 1 if you have the declaration of `ether_hostton' */
#undef HAVE_DECL_ETHER_HOSTTON
-/* Define to 1 if `dl_module_id_1' is a member of `dl_hp_ppa_info_t'. */
+/* Define to 1 if 'dl_module_id_1' is a member of 'dl_hp_ppa_info_t'. */
#undef HAVE_DL_HP_PPA_INFO_T_DL_MODULE_ID_1
-/* Define to 1 if the system has the type `dl_passive_req_t'. */
+/* Define to 1 if the system has the type 'dl_passive_req_t'. */
#undef HAVE_DL_PASSIVE_REQ_T
-/* Define to 1 if you have the `ether_hostton' function. */
+/* Define to 1 if you have the 'ether_hostton' function. */
#undef HAVE_ETHER_HOSTTON
-/* Define to 1 if you have the `ffs' function. */
+/* Define to 1 if you have the 'ffs' function. */
#undef HAVE_FFS
-/* Define to 1 if fseeko (and presumably ftello) exists and is declared. */
+/* Define to 1 if fseeko (and ftello) are declared in stdio.h. */
#undef HAVE_FSEEKO
-/* Define to 1 if you have the `getspnam' function. */
+/* Define to 1 if you have the 'getspnam' function. */
#undef HAVE_GETSPNAM
/* Define to 1 if you have a GNU-style `strerror_r' function. */
@@ -75,7 +75,7 @@
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
-/* Define to 1 if you have the `bsd' library (-lbsd). */
+/* Define to 1 if you have the 'bsd' library (-lbsd). */
#undef HAVE_LIBBSD
/* if libdlpi exists */
@@ -147,7 +147,7 @@
/* define if you have the Myricom SNF API */
#undef HAVE_SNF_API
-/* Define to 1 if the system has the type `socklen_t'. */
+/* Define to 1 if the system has the type 'socklen_t'. */
#undef HAVE_SOCKLEN_T
/* On solaris */
@@ -177,43 +177,43 @@
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
-/* Define to 1 if you have the `strlcat' function. */
+/* Define to 1 if you have the 'strlcat' function. */
#undef HAVE_STRLCAT
-/* Define to 1 if you have the `strlcpy' function. */
+/* Define to 1 if you have the 'strlcpy' function. */
#undef HAVE_STRLCPY
-/* Define to 1 if you have the `strtok_r' function. */
+/* Define to 1 if you have the 'strtok_r' function. */
#undef HAVE_STRTOK_R
-/* Define to 1 if the system has the type `struct BPF_TIMEVAL'. */
+/* Define to 1 if the system has the type 'struct BPF_TIMEVAL'. */
#undef HAVE_STRUCT_BPF_TIMEVAL
-/* Define to 1 if the system has the type `struct ether_addr'. */
+/* Define to 1 if the system has the type 'struct ether_addr'. */
#undef HAVE_STRUCT_ETHER_ADDR
-/* Define to 1 if `msg_control' is a member of `struct msghdr'. */
+/* Define to 1 if 'msg_control' is a member of 'struct msghdr'. */
#undef HAVE_STRUCT_MSGHDR_MSG_CONTROL
-/* Define to 1 if `msg_flags' is a member of `struct msghdr'. */
+/* Define to 1 if 'msg_flags' is a member of 'struct msghdr'. */
#undef HAVE_STRUCT_MSGHDR_MSG_FLAGS
-/* Define to 1 if the system has the type `struct rte_ether_addr'. */
+/* Define to 1 if the system has the type 'struct rte_ether_addr'. */
#undef HAVE_STRUCT_RTE_ETHER_ADDR
-/* Define to 1 if `hci_channel' is a member of `struct sockaddr_hci'. */
+/* Define to 1 if 'hci_channel' is a member of 'struct sockaddr_hci'. */
#undef HAVE_STRUCT_SOCKADDR_HCI_HCI_CHANNEL
-/* Define to 1 if `sa_len' is a member of `struct sockaddr'. */
+/* Define to 1 if 'sa_len' is a member of 'struct sockaddr'. */
#undef HAVE_STRUCT_SOCKADDR_SA_LEN
-/* Define to 1 if the system has the type `struct sockaddr_storage'. */
+/* Define to 1 if the system has the type 'struct sockaddr_storage'. */
#undef HAVE_STRUCT_SOCKADDR_STORAGE
-/* Define to 1 if `tp_vlan_tci' is a member of `struct tpacket_auxdata'. */
+/* Define to 1 if 'tp_vlan_tci' is a member of 'struct tpacket_auxdata'. */
#undef HAVE_STRUCT_TPACKET_AUXDATA_TP_VLAN_TCI
-/* Define to 1 if `bRequestType' is a member of `struct
+/* Define to 1 if 'bRequestType' is a member of 'struct
usbdevfs_ctrltransfer'. */
#undef HAVE_STRUCT_USBDEVFS_CTRLTRANSFER_BREQUESTTYPE
@@ -247,16 +247,16 @@
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
-/* Define to 1 if you have the `vasprintf' function. */
+/* Define to 1 if you have the 'vasprintf' function. */
#undef HAVE_VASPRINTF
-/* Define to 1 if you have the `vsyslog' function. */
+/* Define to 1 if you have the 'vsyslog' function. */
#undef HAVE_VSYSLOG
/* Define to 1 if you have the <zone.h> header file. */
#undef HAVE_ZONE_H
-/* Define to 1 if you have the `_wcserror_s' function. */
+/* Define to 1 if you have the '_wcserror_s' function. */
#undef HAVE__WCSERROR_S
/* define if __atomic_load_n is supported by the compiler */
@@ -322,13 +322,13 @@
/* target host supports RDMA sniffing */
#undef PCAP_SUPPORT_RDMASNIFF
-/* The size of `time_t', as computed by sizeof. */
+/* The size of 'time_t', as computed by sizeof. */
#undef SIZEOF_TIME_T
-/* The size of `void *', as computed by sizeof. */
+/* The size of 'void *', as computed by sizeof. */
#undef SIZEOF_VOID_P
-/* Define to 1 if all of the C90 standard headers exist (not just the ones
+/* Define to 1 if all of the C89 standard headers exist (not just the ones
required in a freestanding environment). This macro is provided for
backward compatibility; new code need not use it. */
#undef STDC_HEADERS
@@ -342,22 +342,28 @@
/* Enable parser debugging */
#undef YYDEBUG
-/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a
- `char[]'. */
+/* Define to 1 if 'lex' declares 'yytext' as a 'char *' by default, not a
+ 'char[]'. */
#undef YYTEXT_POINTER
/* Number of bits in a file offset, on hosts where this is settable. */
#undef _FILE_OFFSET_BITS
-/* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */
+/* Define to 1 if necessary to make fseeko visible. */
#undef _LARGEFILE_SOURCE
-/* Define for large files, on AIX-style hosts. */
+/* Define to 1 on platforms where this makes off_t a 64-bit type. */
#undef _LARGE_FILES
/* define on AIX to get certain functions */
#undef _SUN
+/* Number of bits in time_t, on hosts where this is settable. */
+#undef _TIME_BITS
+
+/* Define to 1 on platforms where this makes time_t a 64-bit type. */
+#undef __MINGW_USE_VC2005_COMPAT
+
/* to handle Ultrix compilers that don't support const in prototypes */
#undef const
diff --git a/contrib/libpcap/configure b/contrib/libpcap/configure
--- a/contrib/libpcap/configure
+++ b/contrib/libpcap/configure
@@ -1,9 +1,9 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.71 for pcap 1.10.6.
+# Generated by GNU Autoconf 2.72 for pcap 1.10.7.
#
#
-# Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation,
+# Copyright (C) 1992-1996, 1998-2017, 2020-2023 Free Software Foundation,
# Inc.
#
#
@@ -15,7 +15,6 @@
# Be more Bourne compatible
DUALCASE=1; export DUALCASE # for MKS sh
-as_nop=:
if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
then :
emulate sh
@@ -24,12 +23,13 @@
# is contrary to our usage. Disable this feature.
alias -g '${1+"$@"}'='"$@"'
setopt NO_GLOB_SUBST
-else $as_nop
- case `(set -o) 2>/dev/null` in #(
+else case e in #(
+ e) case `(set -o) 2>/dev/null` in #(
*posix*) :
set -o posix ;; #(
*) :
;;
+esac ;;
esac
fi
@@ -101,7 +101,7 @@
;;
esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
+# We did not find ourselves, most probably we were run as 'sh COMMAND'
# in which case we are not to be found in the path.
if test "x$as_myself" = x; then
as_myself=$0
@@ -131,15 +131,14 @@
esac
exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
+# out after a failed 'exec'.
printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
exit 255
fi
# We don't want this to propagate to other subprocesses.
{ _as_can_reexec=; unset _as_can_reexec;}
if test "x$CONFIG_SHELL" = x; then
- as_bourne_compatible="as_nop=:
-if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
+ as_bourne_compatible="if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
then :
emulate sh
NULLCMD=:
@@ -147,12 +146,13 @@
# is contrary to our usage. Disable this feature.
alias -g '\${1+\"\$@\"}'='\"\$@\"'
setopt NO_GLOB_SUBST
-else \$as_nop
- case \`(set -o) 2>/dev/null\` in #(
+else case e in #(
+ e) case \`(set -o) 2>/dev/null\` in #(
*posix*) :
set -o posix ;; #(
*) :
;;
+esac ;;
esac
fi
"
@@ -170,8 +170,9 @@
if ( set x; as_fn_ret_success y && test x = \"\$1\" )
then :
-else \$as_nop
- exitcode=1; echo positional parameters were not saved.
+else case e in #(
+ e) exitcode=1; echo positional parameters were not saved. ;;
+esac
fi
test x\$exitcode = x0 || exit 1
blah=\$(echo \$(echo blah))
@@ -185,14 +186,15 @@
if (eval "$as_required") 2>/dev/null
then :
as_have_required=yes
-else $as_nop
- as_have_required=no
+else case e in #(
+ e) as_have_required=no ;;
+esac
fi
if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null
then :
-else $as_nop
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+else case e in #(
+ e) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
as_found=false
for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
do
@@ -225,12 +227,13 @@
if $as_found
then :
-else $as_nop
- if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
+else case e in #(
+ e) if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
as_run=a "$SHELL" -c "$as_bourne_compatible""$as_required" 2>/dev/null
then :
CONFIG_SHELL=$SHELL as_have_required=yes
-fi
+fi ;;
+esac
fi
@@ -252,7 +255,7 @@
esac
exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
+# out after a failed 'exec'.
printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
exit 255
fi
@@ -271,7 +274,8 @@
$0: the script under such a shell if you do have one."
fi
exit 1
-fi
+fi ;;
+esac
fi
fi
SHELL=${CONFIG_SHELL-/bin/sh}
@@ -310,14 +314,6 @@
as_fn_set_status $1
exit $1
} # as_fn_exit
-# as_fn_nop
-# ---------
-# Do nothing but, unlike ":", preserve the value of $?.
-as_fn_nop ()
-{
- return $?
-}
-as_nop=as_fn_nop
# as_fn_mkdir_p
# -------------
@@ -386,11 +382,12 @@
{
eval $1+=\$2
}'
-else $as_nop
- as_fn_append ()
+else case e in #(
+ e) as_fn_append ()
{
eval $1=\$$1\$2
- }
+ } ;;
+esac
fi # as_fn_append
# as_fn_arith ARG...
@@ -404,21 +401,14 @@
{
as_val=$(( $* ))
}'
-else $as_nop
- as_fn_arith ()
+else case e in #(
+ e) as_fn_arith ()
{
as_val=`expr "$@" || test $? -eq 1`
- }
+ } ;;
+esac
fi # as_fn_arith
-# as_fn_nop
-# ---------
-# Do nothing but, unlike ":", preserve the value of $?.
-as_fn_nop ()
-{
- return $?
-}
-as_nop=as_fn_nop
# as_fn_error STATUS ERROR [LINENO LOG_FD]
# ----------------------------------------
@@ -492,6 +482,8 @@
/[$]LINENO/=
' <$as_myself |
sed '
+ t clear
+ :clear
s/[$]LINENO.*/&-/
t lineno
b
@@ -540,7 +532,6 @@
as_echo='printf %s\n'
as_echo_n='printf %s'
-
rm -f conf$$ conf$$.exe conf$$.file
if test -d conf$$.dir; then
rm -f conf$$.dir/conf$$.file
@@ -552,9 +543,9 @@
if ln -s conf$$.file conf$$ 2>/dev/null; then
as_ln_s='ln -s'
# ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
+ # 1) On MSYS, both 'ln -s file dir' and 'ln file dir' fail.
+ # 2) DJGPP < 2.04 has no symlinks; 'ln -s' creates a wrapper executable.
+ # In both cases, we have to default to 'cp -pR'.
ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
as_ln_s='cp -pR'
elif ln conf$$.file conf$$ 2>/dev/null; then
@@ -579,10 +570,12 @@
as_executable_p=as_fn_executable_p
# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
+as_sed_cpp="y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
+as_tr_cpp="eval sed '$as_sed_cpp'" # deprecated
# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
+as_sed_sh="y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
+as_tr_sh="eval sed '$as_sed_sh'" # deprecated
test -n "$DJDIR" || exec 7<&0 </dev/null
@@ -608,8 +601,8 @@
# Identity of this package.
PACKAGE_NAME='pcap'
PACKAGE_TARNAME='pcap'
-PACKAGE_VERSION='1.10.6'
-PACKAGE_STRING='pcap 1.10.6'
+PACKAGE_VERSION='1.10.7'
+PACKAGE_STRING='pcap 1.10.7'
PACKAGE_BUGREPORT=''
PACKAGE_URL=''
@@ -646,6 +639,7 @@
#endif"
ac_header_c_list=
+enable_year2038=no
ac_subst_vars='LTLIBOBJS
RPCAPD_LIBS
INSTALL_RPCAPD
@@ -805,6 +799,7 @@
enable_bluetooth
enable_dbus
enable_rdma
+enable_year2038
'
ac_precious_vars='build_alias
host_alias
@@ -940,7 +935,7 @@
ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
# Reject names that are not valid shell variable names.
expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: \`$ac_useropt'"
+ as_fn_error $? "invalid feature name: '$ac_useropt'"
ac_useropt_orig=$ac_useropt
ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
case $ac_user_opts in
@@ -966,7 +961,7 @@
ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
# Reject names that are not valid shell variable names.
expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: \`$ac_useropt'"
+ as_fn_error $? "invalid feature name: '$ac_useropt'"
ac_useropt_orig=$ac_useropt
ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
case $ac_user_opts in
@@ -1179,7 +1174,7 @@
ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
# Reject names that are not valid shell variable names.
expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: \`$ac_useropt'"
+ as_fn_error $? "invalid package name: '$ac_useropt'"
ac_useropt_orig=$ac_useropt
ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
case $ac_user_opts in
@@ -1195,7 +1190,7 @@
ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
# Reject names that are not valid shell variable names.
expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: \`$ac_useropt'"
+ as_fn_error $? "invalid package name: '$ac_useropt'"
ac_useropt_orig=$ac_useropt
ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
case $ac_user_opts in
@@ -1225,8 +1220,8 @@
| --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
x_libraries=$ac_optarg ;;
- -*) as_fn_error $? "unrecognized option: \`$ac_option'
-Try \`$0 --help' for more information"
+ -*) as_fn_error $? "unrecognized option: '$ac_option'
+Try '$0 --help' for more information"
;;
*=*)
@@ -1234,7 +1229,7 @@
# Reject names that are not valid shell variable names.
case $ac_envvar in #(
'' | [0-9]* | *[!_$as_cr_alnum]* )
- as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
+ as_fn_error $? "invalid variable name: '$ac_envvar'" ;;
esac
eval $ac_envvar=\$ac_optarg
export $ac_envvar ;;
@@ -1284,7 +1279,7 @@
as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
done
-# There might be people who depend on the old broken behavior: `$host'
+# There might be people who depend on the old broken behavior: '$host'
# used to hold the argument of --host etc.
# FIXME: To remove some day.
build=$build_alias
@@ -1352,7 +1347,7 @@
test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
fi
-ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
+ac_msg="sources are in $srcdir, but 'cd $srcdir' does not work"
ac_abs_confdir=`(
cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
pwd)`
@@ -1380,7 +1375,7 @@
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures pcap 1.10.6 to adapt to many kinds of systems.
+'configure' configures pcap 1.10.7 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1394,11 +1389,11 @@
--help=short display options specific to this package
--help=recursive display the short help of all the included packages
-V, --version display version information and exit
- -q, --quiet, --silent do not print \`checking ...' messages
+ -q, --quiet, --silent do not print 'checking ...' messages
--cache-file=FILE cache test results in FILE [disabled]
- -C, --config-cache alias for \`--cache-file=config.cache'
+ -C, --config-cache alias for '--cache-file=config.cache'
-n, --no-create do not create output files
- --srcdir=DIR find the sources in DIR [configure dir or \`..']
+ --srcdir=DIR find the sources in DIR [configure dir or '..']
Installation directories:
--prefix=PREFIX install architecture-independent files in PREFIX
@@ -1406,10 +1401,10 @@
--exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
[PREFIX]
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
+By default, 'make install' will install all the files in
+'$ac_default_prefix/bin', '$ac_default_prefix/lib' etc. You can specify
+an installation prefix other than '$ac_default_prefix' using '--prefix',
+for instance '--prefix=\$HOME'.
For better control, use the options below.
@@ -1447,7 +1442,7 @@
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of pcap 1.10.6:";;
+ short | recursive ) echo "Configuration of pcap 1.10.7:";;
esac
cat <<\_ACEOF
@@ -1476,6 +1471,7 @@
support available]
--enable-rdma enable RDMA capture support [default=yes, if support
available]
+ --enable-year2038 support timestamps after 2038
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
@@ -1544,7 +1540,7 @@
LIBIBVERBS_LIBS_STATIC
static-link linker flags for libibverbs, overriding pkg-config
-Use these variables to override the choices made by `configure' or to help
+Use these variables to override the choices made by 'configure' or to help
it to find libraries and programs with nonstandard names/locations.
Report bugs to the package provider.
@@ -1611,10 +1607,10 @@
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-pcap configure 1.10.6
-generated by GNU Autoconf 2.71
+pcap configure 1.10.7
+generated by GNU Autoconf 2.72
-Copyright (C) 2021 Free Software Foundation, Inc.
+Copyright (C) 2023 Free Software Foundation, Inc.
This configure script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it.
_ACEOF
@@ -1653,63 +1649,17 @@
} && test -s conftest.$ac_objext
then :
ac_retval=0
-else $as_nop
- printf "%s\n" "$as_me: failed program was:" >&5
+else case e in #(
+ e) printf "%s\n" "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_compile
-
-# ac_fn_c_try_link LINENO
-# -----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
+ ac_retval=1 ;;
esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-printf "%s\n" "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- test -x conftest$ac_exeext
- }
-then :
- ac_retval=0
-else $as_nop
- printf "%s\n" "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
as_fn_set_status $ac_retval
-} # ac_fn_c_try_link
+} # ac_fn_c_try_compile
# ac_fn_c_try_run LINENO
# ----------------------
@@ -1741,12 +1691,13 @@
test $ac_status = 0; }; }
then :
ac_retval=0
-else $as_nop
- printf "%s\n" "$as_me: program exited with status $ac_status" >&5
+else case e in #(
+ e) printf "%s\n" "$as_me: program exited with status $ac_status" >&5
printf "%s\n" "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
- ac_retval=$ac_status
+ ac_retval=$ac_status ;;
+esac
fi
rm -rf conftest.dSYM conftest_ipa8_conftest.oo
eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
@@ -1799,18 +1750,19 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_hi=$ac_mid; break
-else $as_nop
- as_fn_arith $ac_mid + 1 && ac_lo=$as_val
+else case e in #(
+ e) as_fn_arith $ac_mid + 1 && ac_lo=$as_val
if test $ac_lo -le $ac_mid; then
ac_lo= ac_hi=
break
fi
- as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
+ as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
done
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
$4
int
@@ -1845,20 +1797,23 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_lo=$ac_mid; break
-else $as_nop
- as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
+else case e in #(
+ e) as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
if test $ac_mid -le $ac_hi; then
ac_lo= ac_hi=
break
fi
- as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
+ as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
done
-else $as_nop
- ac_lo= ac_hi=
+else case e in #(
+ e) ac_lo= ac_hi= ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
# Binary search between lo and hi bounds.
@@ -1881,8 +1836,9 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_hi=$ac_mid
-else $as_nop
- as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
+else case e in #(
+ e) as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
done
@@ -1930,8 +1886,9 @@
if ac_fn_c_try_run "$LINENO"
then :
echo >>conftest.val; read $3 <conftest.val; ac_retval=0
-else $as_nop
- ac_retval=1
+else case e in #(
+ e) ac_retval=1 ;;
+esac
fi
rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
conftest.$ac_objext conftest.beam conftest.$ac_ext
@@ -1955,8 +1912,8 @@
if eval test \${$3+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
$4
#include <$2>
@@ -1964,10 +1921,12 @@
if ac_fn_c_try_compile "$LINENO"
then :
eval "$3=yes"
-else $as_nop
- eval "$3=no"
+else case e in #(
+ e) eval "$3=no" ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
eval ac_res=\$$3
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
@@ -1987,15 +1946,15 @@
if eval test \${$3+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
For example, HP-UX 11i <limits.h> declares gettimeofday. */
#define $2 innocuous_$2
/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $2 (); below. */
+ which can conflict with char $2 (void); below. */
#include <limits.h>
#undef $2
@@ -2006,7 +1965,7 @@
#ifdef __cplusplus
extern "C"
#endif
-char $2 ();
+char $2 (void);
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
@@ -2025,11 +1984,13 @@
if ac_fn_c_try_link "$LINENO"
then :
eval "$3=yes"
-else $as_nop
- eval "$3=no"
+else case e in #(
+ e) eval "$3=no" ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
- conftest$ac_exeext conftest.$ac_ext
+ conftest$ac_exeext conftest.$ac_ext ;;
+esac
fi
eval ac_res=\$$3
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
@@ -2051,8 +2012,8 @@
if eval test \${$3+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
+else case e in #(
+ e) as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
eval ac_save_FLAGS=\$$6
as_fn_append $6 " $5"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -2076,12 +2037,14 @@
if ac_fn_c_try_compile "$LINENO"
then :
eval "$3=yes"
-else $as_nop
- eval "$3=no"
+else case e in #(
+ e) eval "$3=no" ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
eval $6=\$ac_save_FLAGS
-
+ ;;
+esac
fi
eval ac_res=\$$3
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
@@ -2102,8 +2065,8 @@
if eval test \${$3+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- eval "$3=no"
+else case e in #(
+ e) eval "$3=no"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
$4
@@ -2133,12 +2096,14 @@
if ac_fn_c_try_compile "$LINENO"
then :
-else $as_nop
- eval "$3=yes"
+else case e in #(
+ e) eval "$3=yes" ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
eval ac_res=\$$3
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
@@ -2159,8 +2124,8 @@
if eval test \${$4+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
$5
int
@@ -2176,8 +2141,8 @@
if ac_fn_c_try_compile "$LINENO"
then :
eval "$4=yes"
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
$5
int
@@ -2193,12 +2158,15 @@
if ac_fn_c_try_compile "$LINENO"
then :
eval "$4=yes"
-else $as_nop
- eval "$4=no"
+else case e in #(
+ e) eval "$4=no" ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
eval ac_res=\$$4
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
@@ -2230,8 +2198,8 @@
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by pcap $as_me 1.10.6, which was
-generated by GNU Autoconf 2.71. Invocation command line was
+It was created by pcap $as_me 1.10.7, which was
+generated by GNU Autoconf 2.72. Invocation command line was
$ $0$ac_configure_args_raw
@@ -2477,10 +2445,10 @@
printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;}
sed 's/^/| /' "$ac_site_file" >&5
. "$ac_site_file" \
- || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+ || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
as_fn_error $? "failed to load site script $ac_site_file
-See \`config.log' for more details" "$LINENO" 5; }
+See 'config.log' for more details" "$LINENO" 5; }
fi
done
@@ -2516,9 +2484,7 @@
/* Most of the following tests are stolen from RCS 5.7 src/conf.sh. */
struct buf { int x; };
struct buf * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
+static char *e (char **p, int i)
{
return p[i];
}
@@ -2532,6 +2498,21 @@
return s;
}
+/* C89 style stringification. */
+#define noexpand_stringify(a) #a
+const char *stringified = noexpand_stringify(arbitrary+token=sequence);
+
+/* C89 style token pasting. Exercises some of the corner cases that
+ e.g. old MSVC gets wrong, but not very hard. */
+#define noexpand_concat(a,b) a##b
+#define expand_concat(a,b) noexpand_concat(a,b)
+extern int vA;
+extern int vbee;
+#define aye A
+#define bee B
+int *pvA = &expand_concat(v,aye);
+int *pvbee = &noexpand_concat(v,bee);
+
/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
function prototypes and stuff, but not \xHH hex character constants.
These do not provoke an error unfortunately, instead are silently treated
@@ -2559,16 +2540,19 @@
# Test code for whether the C compiler supports C99 (global declarations)
ac_c_conftest_c99_globals='
-// Does the compiler advertise C99 conformance?
+/* Does the compiler advertise C99 conformance? */
#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L
# error "Compiler does not advertise C99 conformance"
#endif
+// See if C++-style comments work.
+
#include <stdbool.h>
extern int puts (const char *);
extern int printf (const char *, ...);
extern int dprintf (int, const char *, ...);
extern void *malloc (size_t);
+extern void free (void *);
// Check varargs macros. These examples are taken from C99 6.10.3.5.
// dprintf is used instead of fprintf to avoid needing to declare
@@ -2618,7 +2602,6 @@
static inline int
test_restrict (ccp restrict text)
{
- // See if C++-style comments work.
// Iterate through items via the restricted pointer.
// Also check for declarations in for loops.
for (unsigned int i = 0; *(text+i) != '\''\0'\''; ++i)
@@ -2684,6 +2667,8 @@
ia->datasize = 10;
for (int i = 0; i < ia->datasize; ++i)
ia->data[i] = i * 1.234;
+ // Work around memory leak warnings.
+ free (ia);
// Check named initializers.
struct named_init ni = {
@@ -2705,7 +2690,7 @@
# Test code for whether the C compiler supports C11 (global declarations)
ac_c_conftest_c11_globals='
-// Does the compiler advertise C11 conformance?
+/* Does the compiler advertise C11 conformance? */
#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L
# error "Compiler does not advertise C11 conformance"
#endif
@@ -2897,8 +2882,9 @@
if $as_found
then :
-else $as_nop
- as_fn_error $? "cannot find required auxiliary files:$ac_missing_aux_files" "$LINENO" 5
+else case e in #(
+ e) as_fn_error $? "cannot find required auxiliary files:$ac_missing_aux_files" "$LINENO" 5 ;;
+esac
fi
@@ -2926,12 +2912,12 @@
eval ac_new_val=\$ac_env_${ac_var}_value
case $ac_old_set,$ac_new_set in
set,)
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-printf "%s\n" "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: '$ac_var' was set to '$ac_old_val' in the previous run" >&5
+printf "%s\n" "$as_me: error: '$ac_var' was set to '$ac_old_val' in the previous run" >&2;}
ac_cache_corrupted=: ;;
,set)
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
-printf "%s\n" "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: '$ac_var' was not set in the previous run" >&5
+printf "%s\n" "$as_me: error: '$ac_var' was not set in the previous run" >&2;}
ac_cache_corrupted=: ;;
,);;
*)
@@ -2940,18 +2926,18 @@
ac_old_val_w=`echo x $ac_old_val`
ac_new_val_w=`echo x $ac_new_val`
if test "$ac_old_val_w" != "$ac_new_val_w"; then
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
-printf "%s\n" "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: '$ac_var' has changed since the previous run:" >&5
+printf "%s\n" "$as_me: error: '$ac_var' has changed since the previous run:" >&2;}
ac_cache_corrupted=:
else
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
-printf "%s\n" "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in '$ac_var' since the previous run:" >&5
+printf "%s\n" "$as_me: warning: ignoring whitespace changes in '$ac_var' since the previous run:" >&2;}
eval $ac_var=\$ac_old_val
fi
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
-printf "%s\n" "$as_me: former value: \`$ac_old_val'" >&2;}
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
-printf "%s\n" "$as_me: current value: \`$ac_new_val'" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: former value: '$ac_old_val'" >&5
+printf "%s\n" "$as_me: former value: '$ac_old_val'" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: current value: '$ac_new_val'" >&5
+printf "%s\n" "$as_me: current value: '$ac_new_val'" >&2;}
fi;;
esac
# Pass precious variables to config.status.
@@ -2967,11 +2953,11 @@
fi
done
if $ac_cache_corrupted; then
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;}
- as_fn_error $? "run \`${MAKE-make} distclean' and/or \`rm $cache_file'
+ as_fn_error $? "run '${MAKE-make} distclean' and/or 'rm $cache_file'
and start over" "$LINENO" 5
fi
## -------------------- ##
@@ -3078,15 +3064,16 @@
if test ${ac_cv_build+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_build_alias=$build_alias
+else case e in #(
+ e) ac_build_alias=$build_alias
test "x$ac_build_alias" = x &&
ac_build_alias=`$SHELL "${ac_aux_dir}config.guess"`
test "x$ac_build_alias" = x &&
as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
ac_cv_build=`$SHELL "${ac_aux_dir}config.sub" $ac_build_alias` ||
as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $ac_build_alias failed" "$LINENO" 5
-
+ ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
printf "%s\n" "$ac_cv_build" >&6; }
@@ -3113,14 +3100,15 @@
if test ${ac_cv_host+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test "x$host_alias" = x; then
+else case e in #(
+ e) if test "x$host_alias" = x; then
ac_cv_host=$ac_cv_build
else
ac_cv_host=`$SHELL "${ac_aux_dir}config.sub" $host_alias` ||
as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $host_alias failed" "$LINENO" 5
fi
-
+ ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
printf "%s\n" "$ac_cv_host" >&6; }
@@ -3147,14 +3135,15 @@
if test ${ac_cv_target+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test "x$target_alias" = x; then
+else case e in #(
+ e) if test "x$target_alias" = x; then
ac_cv_target=$ac_cv_host
else
ac_cv_target=`$SHELL "${ac_aux_dir}config.sub" $target_alias` ||
as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $target_alias failed" "$LINENO" 5
fi
-
+ ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
printf "%s\n" "$ac_cv_target" >&6; }
@@ -3214,8 +3203,8 @@
if test ${ac_cv_prog_SHLICC2+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$SHLICC2"; then
+else case e in #(
+ e) if test -n "$SHLICC2"; then
ac_cv_prog_SHLICC2="$SHLICC2" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -3238,7 +3227,8 @@
IFS=$as_save_IFS
test -z "$ac_cv_prog_SHLICC2" && ac_cv_prog_SHLICC2="no"
-fi
+fi ;;
+esac
fi
SHLICC2=$ac_cv_prog_SHLICC2
if test -n "$SHLICC2"; then
@@ -3289,8 +3279,8 @@
if test ${ac_cv_prog_CC+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$CC"; then
+else case e in #(
+ e) if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -3312,7 +3302,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
@@ -3334,8 +3325,8 @@
if test ${ac_cv_prog_ac_ct_CC+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$ac_ct_CC"; then
+else case e in #(
+ e) if test -n "$ac_ct_CC"; then
ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -3357,7 +3348,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
@@ -3392,8 +3384,8 @@
if test ${ac_cv_prog_CC+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$CC"; then
+else case e in #(
+ e) if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -3415,7 +3407,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
@@ -3437,8 +3430,8 @@
if test ${ac_cv_prog_CC+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$CC"; then
+else case e in #(
+ e) if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
ac_prog_rejected=no
@@ -3477,7 +3470,8 @@
ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@"
fi
fi
-fi
+fi ;;
+esac
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
@@ -3501,8 +3495,8 @@
if test ${ac_cv_prog_CC+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$CC"; then
+else case e in #(
+ e) if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -3524,7 +3518,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
@@ -3550,8 +3545,8 @@
if test ${ac_cv_prog_ac_ct_CC+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$ac_ct_CC"; then
+else case e in #(
+ e) if test -n "$ac_ct_CC"; then
ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -3573,7 +3568,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
@@ -3611,8 +3607,8 @@
if test ${ac_cv_prog_CC+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$CC"; then
+else case e in #(
+ e) if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -3634,7 +3630,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
@@ -3656,8 +3653,8 @@
if test ${ac_cv_prog_ac_ct_CC+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$ac_ct_CC"; then
+else case e in #(
+ e) if test -n "$ac_ct_CC"; then
ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -3679,7 +3676,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
@@ -3708,10 +3706,10 @@
fi
-test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
as_fn_error $? "no acceptable C compiler found in \$PATH
-See \`config.log' for more details" "$LINENO" 5; }
+See 'config.log' for more details" "$LINENO" 5; }
# Provide some information about the compiler.
printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
@@ -3783,8 +3781,8 @@
printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }
then :
- # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
-# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
+ # Autoconf-2.13 could set the ac_cv_exeext variable to 'no'.
+# So ignore a value of 'no', otherwise this would lead to 'EXEEXT = no'
# in a Makefile. We should not override ac_cv_exeext if it was cached,
# so that the user can short-circuit this test for compilers unknown to
# Autoconf.
@@ -3804,7 +3802,7 @@
ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
fi
# We set ac_cv_exeext here because the later test for it is not
- # safe: cross compilers may not add the suffix if given an `-o'
+ # safe: cross compilers may not add the suffix if given an '-o'
# argument, so we may need to know it at that point already.
# Even if this section looks crufty: it has the advantage of
# actually working.
@@ -3815,8 +3813,9 @@
done
test "$ac_cv_exeext" = no && ac_cv_exeext=
-else $as_nop
- ac_file=''
+else case e in #(
+ e) ac_file='' ;;
+esac
fi
if test -z "$ac_file"
then :
@@ -3825,13 +3824,14 @@
printf "%s\n" "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
as_fn_error 77 "C compiler cannot create executables
-See \`config.log' for more details" "$LINENO" 5; }
-else $as_nop
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-printf "%s\n" "yes" >&6; }
+See 'config.log' for more details" "$LINENO" 5; }
+else case e in #(
+ e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+printf "%s\n" "yes" >&6; } ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
printf %s "checking for C compiler default output file name... " >&6; }
@@ -3855,10 +3855,10 @@
printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
test $ac_status = 0; }
then :
- # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
+ # If both 'conftest.exe' and 'conftest' are 'present' (well, observable)
+# catch 'conftest.exe'. For instance with Cygwin, 'ls conftest' will
+# work properly (i.e., refer to 'conftest.exe'), while it won't with
+# 'rm'.
for ac_file in conftest.exe conftest conftest.*; do
test -f "$ac_file" || continue
case $ac_file in
@@ -3868,11 +3868,12 @@
* ) break;;
esac
done
-else $as_nop
- { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+else case e in #(
+ e) { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
as_fn_error $? "cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details" "$LINENO" 5; }
+See 'config.log' for more details" "$LINENO" 5; } ;;
+esac
fi
rm -f conftest conftest$ac_cv_exeext
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
@@ -3888,6 +3889,8 @@
main (void)
{
FILE *f = fopen ("conftest.out", "w");
+ if (!f)
+ return 1;
return ferror (f) || fclose (f) != 0;
;
@@ -3927,26 +3930,27 @@
if test "$cross_compiling" = maybe; then
cross_compiling=yes
else
- { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
as_fn_error 77 "cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details" "$LINENO" 5; }
+If you meant to cross compile, use '--host'.
+See 'config.log' for more details" "$LINENO" 5; }
fi
fi
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
printf "%s\n" "$cross_compiling" >&6; }
-rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
+rm -f conftest.$ac_ext conftest$ac_cv_exeext \
+ conftest.o conftest.obj conftest.out
ac_clean_files=$ac_clean_files_save
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
printf %s "checking for suffix of object files... " >&6; }
if test ${ac_cv_objext+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
@@ -3978,16 +3982,18 @@
break;;
esac
done
-else $as_nop
- printf "%s\n" "$as_me: failed program was:" >&5
+else case e in #(
+ e) printf "%s\n" "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
as_fn_error $? "cannot compute suffix of object files: cannot compile
-See \`config.log' for more details" "$LINENO" 5; }
+See 'config.log' for more details" "$LINENO" 5; } ;;
+esac
fi
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
+rm -f conftest.$ac_cv_objext conftest.$ac_ext ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
printf "%s\n" "$ac_cv_objext" >&6; }
@@ -3998,8 +4004,8 @@
if test ${ac_cv_c_compiler_gnu+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
@@ -4016,12 +4022,14 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_compiler_gnu=yes
-else $as_nop
- ac_compiler_gnu=no
+else case e in #(
+ e) ac_compiler_gnu=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
+ ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; }
@@ -4039,8 +4047,8 @@
if test ${ac_cv_prog_cc_g+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_save_c_werror_flag=$ac_c_werror_flag
+else case e in #(
+ e) ac_save_c_werror_flag=$ac_c_werror_flag
ac_c_werror_flag=yes
ac_cv_prog_cc_g=no
CFLAGS="-g"
@@ -4058,8 +4066,8 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_cv_prog_cc_g=yes
-else $as_nop
- CFLAGS=""
+else case e in #(
+ e) CFLAGS=""
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -4074,8 +4082,8 @@
if ac_fn_c_try_compile "$LINENO"
then :
-else $as_nop
- ac_c_werror_flag=$ac_save_c_werror_flag
+else case e in #(
+ e) ac_c_werror_flag=$ac_save_c_werror_flag
CFLAGS="-g"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -4092,12 +4100,15 @@
then :
ac_cv_prog_cc_g=yes
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
- ac_c_werror_flag=$ac_save_c_werror_flag
+ ac_c_werror_flag=$ac_save_c_werror_flag ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
printf "%s\n" "$ac_cv_prog_cc_g" >&6; }
@@ -4124,8 +4135,8 @@
if test ${ac_cv_prog_cc_c11+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_cv_prog_cc_c11=no
+else case e in #(
+ e) ac_cv_prog_cc_c11=no
ac_save_CC=$CC
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -4142,25 +4153,28 @@
test "x$ac_cv_prog_cc_c11" != "xno" && break
done
rm -f conftest.$ac_ext
-CC=$ac_save_CC
+CC=$ac_save_CC ;;
+esac
fi
if test "x$ac_cv_prog_cc_c11" = xno
then :
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
printf "%s\n" "unsupported" >&6; }
-else $as_nop
- if test "x$ac_cv_prog_cc_c11" = x
+else case e in #(
+ e) if test "x$ac_cv_prog_cc_c11" = x
then :
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
printf "%s\n" "none needed" >&6; }
-else $as_nop
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
+else case e in #(
+ e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
printf "%s\n" "$ac_cv_prog_cc_c11" >&6; }
- CC="$CC $ac_cv_prog_cc_c11"
+ CC="$CC $ac_cv_prog_cc_c11" ;;
+esac
fi
ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
- ac_prog_cc_stdc=c11
+ ac_prog_cc_stdc=c11 ;;
+esac
fi
fi
if test x$ac_prog_cc_stdc = xno
@@ -4170,8 +4184,8 @@
if test ${ac_cv_prog_cc_c99+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_cv_prog_cc_c99=no
+else case e in #(
+ e) ac_cv_prog_cc_c99=no
ac_save_CC=$CC
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -4188,25 +4202,28 @@
test "x$ac_cv_prog_cc_c99" != "xno" && break
done
rm -f conftest.$ac_ext
-CC=$ac_save_CC
+CC=$ac_save_CC ;;
+esac
fi
if test "x$ac_cv_prog_cc_c99" = xno
then :
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
printf "%s\n" "unsupported" >&6; }
-else $as_nop
- if test "x$ac_cv_prog_cc_c99" = x
+else case e in #(
+ e) if test "x$ac_cv_prog_cc_c99" = x
then :
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
printf "%s\n" "none needed" >&6; }
-else $as_nop
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
+else case e in #(
+ e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
printf "%s\n" "$ac_cv_prog_cc_c99" >&6; }
- CC="$CC $ac_cv_prog_cc_c99"
+ CC="$CC $ac_cv_prog_cc_c99" ;;
+esac
fi
ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
- ac_prog_cc_stdc=c99
+ ac_prog_cc_stdc=c99 ;;
+esac
fi
fi
if test x$ac_prog_cc_stdc = xno
@@ -4216,8 +4233,8 @@
if test ${ac_cv_prog_cc_c89+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_cv_prog_cc_c89=no
+else case e in #(
+ e) ac_cv_prog_cc_c89=no
ac_save_CC=$CC
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -4234,25 +4251,28 @@
test "x$ac_cv_prog_cc_c89" != "xno" && break
done
rm -f conftest.$ac_ext
-CC=$ac_save_CC
+CC=$ac_save_CC ;;
+esac
fi
if test "x$ac_cv_prog_cc_c89" = xno
then :
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
printf "%s\n" "unsupported" >&6; }
-else $as_nop
- if test "x$ac_cv_prog_cc_c89" = x
+else case e in #(
+ e) if test "x$ac_cv_prog_cc_c89" = x
then :
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
printf "%s\n" "none needed" >&6; }
-else $as_nop
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
+else case e in #(
+ e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
printf "%s\n" "$ac_cv_prog_cc_c89" >&6; }
- CC="$CC $ac_cv_prog_cc_c89"
+ CC="$CC $ac_cv_prog_cc_c89" ;;
+esac
fi
ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
- ac_prog_cc_stdc=c89
+ ac_prog_cc_stdc=c89 ;;
+esac
fi
fi
@@ -4276,31 +4296,34 @@
then :
enableval=$enable_largefile;
fi
-
-if test "$enable_largefile" != no; then
-
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
-printf %s "checking for special C compiler options needed for large files... " >&6; }
-if test ${ac_cv_sys_largefile_CC+y}
+if test "$enable_largefile,$enable_year2038" != no,no
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CPPFLAGS option for large files" >&5
+printf %s "checking for $CPPFLAGS option for large files... " >&6; }
+if test ${ac_cv_sys_largefile_opts+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_cv_sys_largefile_CC=no
- if test "$GCC" != yes; then
- ac_save_CC=$CC
- while :; do
- # IRIX 6.2 and later do not support large files by default,
- # so use the C compiler's -n32 option if that helps.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) ac_save_CPPFLAGS=$CPPFLAGS
+ ac_opt_found=no
+ for ac_opt in "none needed" "-D_FILE_OFFSET_BITS=64" "-D_LARGE_FILES=1"; do
+ if test x"$ac_opt" != x"none needed"
+then :
+ CPPFLAGS="$ac_save_CPPFLAGS $ac_opt"
+fi
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
+#ifndef FTYPE
+# define FTYPE off_t
+#endif
+ /* Check that FTYPE can represent 2**63 - 1 correctly.
+ We can't simply define LARGE_FTYPE to be 9223372036854775807,
since some C++ compilers masquerading as C compilers
incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
+#define LARGE_FTYPE (((FTYPE) 1 << 31 << 31) - 1 + ((FTYPE) 1 << 31 << 31))
+ int FTYPE_is_large[(LARGE_FTYPE % 2147483629 == 721
+ && LARGE_FTYPE % 2147483647 == 1)
? 1 : -1];
int
main (void)
@@ -4310,47 +4333,86 @@
return 0;
}
_ACEOF
- if ac_fn_c_try_compile "$LINENO"
+if ac_fn_c_try_compile "$LINENO"
then :
- break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam
- CC="$CC -n32"
+ if test x"$ac_opt" = x"none needed"
+then :
+ # GNU/Linux s390x and alpha need _FILE_OFFSET_BITS=64 for wide ino_t.
+ CPPFLAGS="$CPPFLAGS -DFTYPE=ino_t"
if ac_fn_c_try_compile "$LINENO"
then :
- ac_cv_sys_largefile_CC=' -n32'; break
+
+else case e in #(
+ e) CPPFLAGS="$CPPFLAGS -D_FILE_OFFSET_BITS=64"
+ if ac_fn_c_try_compile "$LINENO"
+then :
+ ac_opt='-D_FILE_OFFSET_BITS=64'
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.beam ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam
- break
- done
- CC=$ac_save_CC
- rm -f conftest.$ac_ext
- fi
fi
-{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
-printf "%s\n" "$ac_cv_sys_largefile_CC" >&6; }
- if test "$ac_cv_sys_largefile_CC" != no; then
- CC=$CC$ac_cv_sys_largefile_CC
- fi
+ ac_cv_sys_largefile_opts=$ac_opt
+ ac_opt_found=yes
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+ test $ac_opt_found = no || break
+ done
+ CPPFLAGS=$ac_save_CPPFLAGS
+
+ test $ac_opt_found = yes || ac_cv_sys_largefile_opts="support not detected" ;;
+esac
+fi
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_opts" >&5
+printf "%s\n" "$ac_cv_sys_largefile_opts" >&6; }
+
+ac_have_largefile=yes
+case $ac_cv_sys_largefile_opts in #(
+ "none needed") :
+ ;; #(
+ "supported through gnulib") :
+ ;; #(
+ "support not detected") :
+ ac_have_largefile=no ;; #(
+ "-D_FILE_OFFSET_BITS=64") :
+
+printf "%s\n" "#define _FILE_OFFSET_BITS 64" >>confdefs.h
+ ;; #(
+ "-D_LARGE_FILES=1") :
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
-printf %s "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
-if test ${ac_cv_sys_file_offset_bits+y}
+printf "%s\n" "#define _LARGE_FILES 1" >>confdefs.h
+ ;; #(
+ *) :
+ as_fn_error $? "internal error: bad value for \$ac_cv_sys_largefile_opts" "$LINENO" 5 ;;
+esac
+
+if test "$enable_year2038" != no
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CPPFLAGS option for timestamps after 2038" >&5
+printf %s "checking for $CPPFLAGS option for timestamps after 2038... " >&6; }
+if test ${ac_cv_sys_year2038_opts+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) ac_save_CPPFLAGS="$CPPFLAGS"
+ ac_opt_found=no
+ for ac_opt in "none needed" "-D_TIME_BITS=64" "-D__MINGW_USE_VC2005_COMPAT" "-U_USE_32_BIT_TIME_T -D__MINGW_USE_VC2005_COMPAT"; do
+ if test x"$ac_opt" != x"none needed"
+then :
+ CPPFLAGS="$ac_save_CPPFLAGS $ac_opt"
+fi
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
+
+ #include <time.h>
+ /* Check that time_t can represent 2**32 - 1 correctly. */
+ #define LARGE_TIME_T \\
+ ((time_t) (((time_t) 1 << 30) - 1 + 3 * ((time_t) 1 << 30)))
+ int verify_time_t_range[(LARGE_TIME_T / 65537 == 65535
+ && LARGE_TIME_T % 65537 == 0)
+ ? 1 : -1];
+
int
main (void)
{
@@ -4361,186 +4423,138 @@
_ACEOF
if ac_fn_c_try_compile "$LINENO"
then :
- ac_cv_sys_file_offset_bits=no; break
+ ac_cv_sys_year2038_opts="$ac_opt"
+ ac_opt_found=yes
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ test $ac_opt_found = no || break
+ done
+ CPPFLAGS="$ac_save_CPPFLAGS"
+ test $ac_opt_found = yes || ac_cv_sys_year2038_opts="support not detected" ;;
+esac
+fi
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_year2038_opts" >&5
+printf "%s\n" "$ac_cv_sys_year2038_opts" >&6; }
+
+ac_have_year2038=yes
+case $ac_cv_sys_year2038_opts in #(
+ "none needed") :
+ ;; #(
+ "support not detected") :
+ ac_have_year2038=no ;; #(
+ "-D_TIME_BITS=64") :
+
+printf "%s\n" "#define _TIME_BITS 64" >>confdefs.h
+ ;; #(
+ "-D__MINGW_USE_VC2005_COMPAT") :
+
+printf "%s\n" "#define __MINGW_USE_VC2005_COMPAT 1" >>confdefs.h
+ ;; #(
+ "-U_USE_32_BIT_TIME_T"*) :
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
+as_fn_error $? "the 'time_t' type is currently forced to be 32-bit. It
+will stop working after mid-January 2038. Remove
+_USE_32BIT_TIME_T from the compiler flags.
+See 'config.log' for more details" "$LINENO" 5; } ;; #(
+ *) :
+ as_fn_error $? "internal error: bad value for \$ac_cv_sys_year2038_opts" "$LINENO" 5 ;;
+esac
+
+fi
+
+fi
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for declarations of fseeko and ftello" >&5
+printf %s "checking for declarations of fseeko and ftello... " >&6; }
+if test ${ac_cv_func_fseeko_ftello+y}
+then :
+ printf %s "(cached) " >&6
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
-#define _FILE_OFFSET_BITS 64
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
+
+#if defined __hpux && !defined _LARGEFILE_SOURCE
+# include <limits.h>
+# if LONG_MAX >> 31 == 0
+# error "32-bit HP-UX 11/ia64 needs _LARGEFILE_SOURCE for fseeko in C++"
+# endif
+#endif
+#include <sys/types.h> /* for off_t */
+#include <stdio.h>
+
int
main (void)
{
+ int (*fp1) (FILE *, off_t, int) = fseeko;
+ off_t (*fp2) (FILE *) = ftello;
+ return fseeko (stdin, 0, 0)
+ && fp1 (stdin, 0, 0)
+ && ftello (stdin) >= 0
+ && fp2 (stdin) >= 0;
+
;
return 0;
}
_ACEOF
if ac_fn_c_try_compile "$LINENO"
then :
- ac_cv_sys_file_offset_bits=64; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
- ac_cv_sys_file_offset_bits=unknown
- break
-done
-fi
-{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
-printf "%s\n" "$ac_cv_sys_file_offset_bits" >&6; }
-case $ac_cv_sys_file_offset_bits in #(
- no | unknown) ;;
- *)
-printf "%s\n" "#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits" >>confdefs.h
-;;
-esac
-rm -rf conftest*
- if test $ac_cv_sys_file_offset_bits = unknown; then
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
-printf %s "checking for _LARGE_FILES value needed for large files... " >&6; }
-if test ${ac_cv_sys_large_files+y}
-then :
- printf %s "(cached) " >&6
-else $as_nop
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ ac_cv_func_fseeko_ftello=yes
+else case e in #(
+ e) ac_save_CPPFLAGS="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE=1"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
+
+#if defined __hpux && !defined _LARGEFILE_SOURCE
+# include <limits.h>
+# if LONG_MAX >> 31 == 0
+# error "32-bit HP-UX 11/ia64 needs _LARGEFILE_SOURCE for fseeko in C++"
+# endif
+#endif
+#include <sys/types.h> /* for off_t */
+#include <stdio.h>
+
int
main (void)
{
+ int (*fp1) (FILE *, off_t, int) = fseeko;
+ off_t (*fp2) (FILE *) = ftello;
+ return fseeko (stdin, 0, 0)
+ && fp1 (stdin, 0, 0)
+ && ftello (stdin) >= 0
+ && fp2 (stdin) >= 0;
+
;
return 0;
}
_ACEOF
if ac_fn_c_try_compile "$LINENO"
then :
- ac_cv_sys_large_files=no; break
+ ac_cv_func_fseeko_ftello="need _LARGEFILE_SOURCE"
+else case e in #(
+ e) ac_cv_func_fseeko_ftello=no ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _LARGE_FILES 1
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main (void)
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"
-then :
- ac_cv_sys_large_files=1; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
- ac_cv_sys_large_files=unknown
- break
-done
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
-{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
-printf "%s\n" "$ac_cv_sys_large_files" >&6; }
-case $ac_cv_sys_large_files in #(
- no | unknown) ;;
- *)
-printf "%s\n" "#define _LARGE_FILES $ac_cv_sys_large_files" >>confdefs.h
-;;
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
esac
-rm -rf conftest*
- fi
fi
-
-{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
-printf %s "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
-if test ${ac_cv_sys_largefile_source+y}
-then :
- printf %s "(cached) " >&6
-else $as_nop
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h> /* for off_t */
- #include <stdio.h>
-int
-main (void)
-{
-int (*fp) (FILE *, off_t, int) = fseeko;
- return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fseeko_ftello" >&5
+printf "%s\n" "$ac_cv_func_fseeko_ftello" >&6; }
+if test "$ac_cv_func_fseeko_ftello" != no
then :
- ac_cv_sys_largefile_source=no; break
+
+printf "%s\n" "#define HAVE_FSEEKO 1" >>confdefs.h
+
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam \
- conftest$ac_exeext conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _LARGEFILE_SOURCE 1
-#include <sys/types.h> /* for off_t */
- #include <stdio.h>
-int
-main (void)
-{
-int (*fp) (FILE *, off_t, int) = fseeko;
- return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"
+if test "$ac_cv_func_fseeko_ftello" = "need _LARGEFILE_SOURCE"
then :
- ac_cv_sys_largefile_source=1; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam \
- conftest$ac_exeext conftest.$ac_ext
- ac_cv_sys_largefile_source=unknown
- break
-done
-fi
-{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
-printf "%s\n" "$ac_cv_sys_largefile_source" >&6; }
-case $ac_cv_sys_largefile_source in #(
- no | unknown) ;;
- *)
-printf "%s\n" "#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source" >>confdefs.h
-;;
-esac
-rm -rf conftest*
-
-# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
-# in glibc 2.1.3, but that breaks too many other things.
-# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
-if test $ac_cv_sys_largefile_source != unknown; then
-printf "%s\n" "#define HAVE_FSEEKO 1" >>confdefs.h
+printf "%s\n" "#define _LARGEFILE_SOURCE 1" >>confdefs.h
fi
@@ -4580,28 +4594,30 @@
fi
# The cast to long int works around a bug in the HP C Compiler
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
-# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
+# declarations like 'int a3[[(sizeof (unsigned char)) >= 0]];'.
# This bug is HP SR number 8606223364.
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
printf %s "checking size of void *... " >&6; }
if test ${ac_cv_sizeof_void_p+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"
+else case e in #(
+ e) if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"
then :
-else $as_nop
- if test "$ac_cv_type_void_p" = yes; then
- { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+else case e in #(
+ e) if test "$ac_cv_type_void_p" = yes; then
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
as_fn_error 77 "cannot compute sizeof (void *)
-See \`config.log' for more details" "$LINENO" 5; }
+See 'config.log' for more details" "$LINENO" 5; }
else
ac_cv_sizeof_void_p=0
- fi
+ fi ;;
+esac
fi
-
+ ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
printf "%s\n" "$ac_cv_sizeof_void_p" >&6; }
@@ -4618,29 +4634,31 @@
#
# The cast to long int works around a bug in the HP C Compiler
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
-# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
+# declarations like 'int a3[[(sizeof (unsigned char)) >= 0]];'.
# This bug is HP SR number 8606223364.
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
printf %s "checking size of time_t... " >&6; }
if test ${ac_cv_sizeof_time_t+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" "#include <time.h>
+else case e in #(
+ e) if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" "#include <time.h>
"
then :
-else $as_nop
- if test "$ac_cv_type_time_t" = yes; then
- { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+else case e in #(
+ e) if test "$ac_cv_type_time_t" = yes; then
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
as_fn_error 77 "cannot compute sizeof (time_t)
-See \`config.log' for more details" "$LINENO" 5; }
+See 'config.log' for more details" "$LINENO" 5; }
else
ac_cv_sizeof_time_t=0
- fi
+ fi ;;
+esac
fi
-
+ ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
printf "%s\n" "$ac_cv_sizeof_time_t" >&6; }
@@ -4731,15 +4749,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -4749,12 +4768,13 @@
V_CCOPT="$V_CCOPT -fvisibility=hidden"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -4842,15 +4862,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -4860,12 +4881,13 @@
V_CCOPT="$V_CCOPT -fvisibility=hidden"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -5015,15 +5037,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -5033,12 +5056,13 @@
V_CCOPT="$V_CCOPT -xldscope=hidden"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -5051,8 +5075,8 @@
if test ${ac_cv_lbl_cc_const_proto+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include <sys/types.h>
int
@@ -5067,10 +5091,12 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_cv_lbl_cc_const_proto=yes
-else $as_nop
- ac_cv_lbl_cc_const_proto=no
+else case e in #(
+ e) ac_cv_lbl_cc_const_proto=no ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_cc_const_proto" >&5
@@ -5248,8 +5274,8 @@
if test ${ac_cv_lbl_inline+y}
then :
printf %s "(cached) " >&6
-else $as_nop
-
+else case e in #(
+ e)
ac_cv_lbl_inline=""
ac_lbl_cc_inline=no
for ac_lbl_inline in inline __inline__ __inline
@@ -5289,7 +5315,8 @@
done
if test "$ac_lbl_cc_inline" = yes ; then
ac_cv_lbl_inline=$ac_lbl_inline
- fi
+ fi ;;
+esac
fi
CFLAGS="$save_CFLAGS"
@@ -5309,8 +5336,56 @@
if test ${ac_cv_have___atomic_load_n+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e)
+# ac_fn_c_try_link LINENO
+# -----------------------
+# Try to link conftest.$ac_ext, and return whether this succeeded.
+ac_fn_c_try_link ()
+{
+ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+ rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext
+ if { { ac_try="$ac_link"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+printf "%s\n" "$ac_try_echo"; } >&5
+ (eval "$ac_link") 2>conftest.err
+ ac_status=$?
+ if test -s conftest.err; then
+ grep -v '^ *+' conftest.err >conftest.er1
+ cat conftest.er1 >&5
+ mv -f conftest.er1 conftest.err
+ fi
+ printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest$ac_exeext && {
+ test "$cross_compiling" = yes ||
+ test -x conftest$ac_exeext
+ }
+then :
+ ac_retval=0
+else case e in #(
+ e) printf "%s\n" "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ ac_retval=1 ;;
+esac
+fi
+ # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
+ # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
+ # interfere with the next link command; also delete a directory that is
+ # left behind by Apple's compiler. We do this before executing the actions.
+ rm -rf conftest.dSYM conftest_ipa8_conftest.oo
+ eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
+ as_fn_set_status $ac_retval
+
+} # ac_fn_c_try_link
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
@@ -5328,11 +5403,13 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_have___atomic_load_n=yes
-else $as_nop
- ac_have___atomic_load_n=no
+else case e in #(
+ e) ac_have___atomic_load_n=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
- conftest$ac_exeext conftest.$ac_ext
+ conftest$ac_exeext conftest.$ac_ext ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_have___atomic_load_n" >&5
@@ -5348,8 +5425,8 @@
if test ${ac_cv_have___atomic_store_n+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
@@ -5366,11 +5443,13 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_have___atomic_store_n=yes
-else $as_nop
- ac_have___atomic_store_n=no
+else case e in #(
+ e) ac_have___atomic_store_n=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
- conftest$ac_exeext conftest.$ac_ext
+ conftest$ac_exeext conftest.$ac_ext ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_have___atomic_store_n" >&5
@@ -5422,16 +5501,22 @@
if test ${ac_cv_lib_bsd_getpass+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-lbsd $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char getpass ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char getpass (void);
int
main (void)
{
@@ -5443,12 +5528,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_bsd_getpass=yes
-else $as_nop
- ac_cv_lib_bsd_getpass=no
+else case e in #(
+ e) ac_cv_lib_bsd_getpass=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getpass" >&5
printf "%s\n" "$ac_cv_lib_bsd_getpass" >&6; }
@@ -5474,8 +5561,8 @@
if test ${ac_cv_lbl_gcc_fixincludes+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/*
* This generates a "duplicate case value" when fixincludes
@@ -5501,10 +5588,12 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_cv_lbl_gcc_fixincludes=yes
-else $as_nop
- ac_cv_lbl_gcc_fixincludes=no
+else case e in #(
+ e) ac_cv_lbl_gcc_fixincludes=no ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_gcc_fixincludes" >&5
@@ -5558,19 +5647,20 @@
printf "%s\n" "#define HAVE_GNU_STRERROR_R /**/" >>confdefs.h
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
printf "%s\n" "#define HAVE_POSIX_STRERROR_R /**/" >>confdefs.h
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
-else $as_nop
-
+else case e in #(
+ e)
#
# We don't have strerror_r; do we have _wcserror_s?
#
@@ -5581,7 +5671,8 @@
fi
-
+ ;;
+esac
fi
@@ -5603,16 +5694,18 @@
if test "x$ac_cv_func_vsnprintf" = xyes
then :
-else $as_nop
- as_fn_error $? "vsnprintf() is required but wasn't found" "$LINENO" 5
+else case e in #(
+ e) as_fn_error $? "vsnprintf() is required but wasn't found" "$LINENO" 5 ;;
+esac
fi
ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
if test "x$ac_cv_func_snprintf" = xyes
then :
-else $as_nop
- as_fn_error $? "snprintf() is required but wasn't found" "$LINENO" 5
+else case e in #(
+ e) as_fn_error $? "snprintf() is required but wasn't found" "$LINENO" 5 ;;
+esac
fi
@@ -5620,16 +5713,17 @@
for ac_func in vasprintf asprintf
do :
- as_ac_var=`printf "%s\n" "ac_cv_func_$ac_func" | $as_tr_sh`
+ as_ac_var=`printf "%s\n" "ac_cv_func_$ac_func" | sed "$as_sed_sh"`
ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
if eval test \"x\$"$as_ac_var"\" = x"yes"
then :
cat >>confdefs.h <<_ACEOF
-#define `printf "%s\n" "HAVE_$ac_func" | $as_tr_cpp` 1
+#define `printf "%s\n" "HAVE_$ac_func" | sed "$as_sed_cpp"` 1
_ACEOF
-else $as_nop
- needasprintf=yes
+else case e in #(
+ e) needasprintf=yes ;;
+esac
fi
done
@@ -5651,8 +5745,9 @@
then :
printf "%s\n" "#define HAVE_STRLCAT 1" >>confdefs.h
-else $as_nop
- needstrlcat=yes
+else case e in #(
+ e) needstrlcat=yes ;;
+esac
fi
done
@@ -5674,8 +5769,9 @@
then :
printf "%s\n" "#define HAVE_STRLCPY 1" >>confdefs.h
-else $as_nop
- needstrlcpy=yes
+else case e in #(
+ e) needstrlcpy=yes ;;
+esac
fi
done
@@ -5697,8 +5793,9 @@
then :
printf "%s\n" "#define HAVE_STRTOK_R 1" >>confdefs.h
-else $as_nop
- needstrtok_r=yes
+else case e in #(
+ e) needstrtok_r=yes ;;
+esac
fi
done
@@ -5733,8 +5830,8 @@
if test ${ac_cv_c_undeclared_builtin_options+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_save_CFLAGS=$CFLAGS
+else case e in #(
+ e) ac_save_CFLAGS=$CFLAGS
ac_cv_c_undeclared_builtin_options='cannot detect'
for ac_arg in '' -fno-builtin; do
CFLAGS="$ac_save_CFLAGS $ac_arg"
@@ -5753,8 +5850,8 @@
if ac_fn_c_try_compile "$LINENO"
then :
-else $as_nop
- # This test program should compile successfully.
+else case e in #(
+ e) # This test program should compile successfully.
# No library function is consistently available on
# freestanding implementations, so test against a dummy
# declaration. Include always-available headers on the
@@ -5782,26 +5879,29 @@
if test x"$ac_arg" = x
then :
ac_cv_c_undeclared_builtin_options='none needed'
-else $as_nop
- ac_cv_c_undeclared_builtin_options=$ac_arg
+else case e in #(
+ e) ac_cv_c_undeclared_builtin_options=$ac_arg ;;
+esac
fi
break
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
done
CFLAGS=$ac_save_CFLAGS
-
+ ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_undeclared_builtin_options" >&5
printf "%s\n" "$ac_cv_c_undeclared_builtin_options" >&6; }
case $ac_cv_c_undeclared_builtin_options in #(
'cannot detect') :
- { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
+printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
as_fn_error $? "cannot make $CC report undeclared builtins
-See \`config.log' for more details" "$LINENO" 5; } ;; #(
+See 'config.log' for more details" "$LINENO" 5; } ;; #(
'none needed') :
ac_c_undeclared_builtin_options='' ;; #(
*) :
@@ -5836,8 +5936,8 @@
if test "x$ac_cv_func_getaddrinfo" = xyes
then :
-else $as_nop
-
+else case e in #(
+ e)
#
# Not found in the standard system libraries.
#
@@ -5853,16 +5953,22 @@
if test ${ac_cv_lib_socket_getaddrinfo+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-lsocket -lnsl $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char getaddrinfo ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char getaddrinfo (void);
int
main (void)
{
@@ -5874,12 +5980,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_socket_getaddrinfo=yes
-else $as_nop
- ac_cv_lib_socket_getaddrinfo=no
+else case e in #(
+ e) ac_cv_lib_socket_getaddrinfo=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_getaddrinfo" >&5
printf "%s\n" "$ac_cv_lib_socket_getaddrinfo" >&6; }
@@ -5891,8 +5999,8 @@
#
LIBS="-lsocket -lnsl $LIBS"
-else $as_nop
-
+else case e in #(
+ e)
#
# Not found in libsocket; test for it in libnetwork, which
# is where it is in Haiku.
@@ -5905,16 +6013,22 @@
if test ${ac_cv_lib_network_getaddrinfo+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-lnetwork $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char getaddrinfo ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char getaddrinfo (void);
int
main (void)
{
@@ -5926,12 +6040,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_network_getaddrinfo=yes
-else $as_nop
- ac_cv_lib_network_getaddrinfo=no
+else case e in #(
+ e) ac_cv_lib_network_getaddrinfo=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_getaddrinfo" >&5
printf "%s\n" "$ac_cv_lib_network_getaddrinfo" >&6; }
@@ -5943,16 +6059,81 @@
#
LIBS="-lnetwork $LIBS"
-else $as_nop
-
+else case e in #(
+ e)
#
- # We didn't find it.
+ # If this is QNX 8.0, getaddrinfo() and related functions are
+ # in libsocket, but there is no libnsl, hence the check result
+ # above for getaddrinfo() in libsocket with libnsl is negative.
+ # Autoconf caches the result, but does take libnsl into account
+ # as a caching factor, so remove the cached result to prevent
+ # an erroneous "cache hit" in the check below.
#
- as_fn_error $? "getaddrinfo is required, but wasn't found" "$LINENO" 5
+ { ac_cv_lib_socket_getaddrinfo=; unset ac_cv_lib_socket_getaddrinfo;}
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo in -lsocket" >&5
+printf %s "checking for getaddrinfo in -lsocket... " >&6; }
+if test ${ac_cv_lib_socket_getaddrinfo+y}
+then :
+ printf %s "(cached) " >&6
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
+LIBS="-lsocket $LIBS"
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+/* Override any GCC internal prototype to avoid an error.
+ Use char because int might match the return type of a GCC
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char getaddrinfo (void);
+int
+main (void)
+{
+return getaddrinfo ();
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_link "$LINENO"
+then :
+ ac_cv_lib_socket_getaddrinfo=yes
+else case e in #(
+ e) ac_cv_lib_socket_getaddrinfo=no ;;
+esac
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.beam \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
+fi
+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_getaddrinfo" >&5
+printf "%s\n" "$ac_cv_lib_socket_getaddrinfo" >&6; }
+if test "x$ac_cv_lib_socket_getaddrinfo" = xyes
+then :
+ LIBS="-lsocket $LIBS"
+
+else case e in #(
+ e)
+ #
+ # We didn't find it.
+ #
+ as_fn_error $? "getaddrinfo is required, but wasn't found" "$LINENO" 5
+ ;;
+esac
fi
+ ;;
+esac
+fi
+ ;;
+esac
fi
@@ -5980,16 +6161,22 @@
if test ${ac_cv_lib_xnet_recvmsg+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-lxnet -lsocket -lnsl $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char recvmsg ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char recvmsg (void);
int
main (void)
{
@@ -6001,12 +6188,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_xnet_recvmsg=yes
-else $as_nop
- ac_cv_lib_xnet_recvmsg=no
+else case e in #(
+ e) ac_cv_lib_xnet_recvmsg=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xnet_recvmsg" >&5
printf "%s\n" "$ac_cv_lib_xnet_recvmsg" >&6; }
@@ -6020,7 +6209,8 @@
fi
-
+ ;;
+esac
fi
@@ -6032,15 +6222,21 @@
if test ${ac_cv_search_putmsg+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_func_search_save_LIBS=$LIBS
+else case e in #(
+ e) ac_func_search_save_LIBS=$LIBS
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char putmsg ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char putmsg (void);
int
main (void)
{
@@ -6071,11 +6267,13 @@
if test ${ac_cv_search_putmsg+y}
then :
-else $as_nop
- ac_cv_search_putmsg=no
+else case e in #(
+ e) ac_cv_search_putmsg=no ;;
+esac
fi
rm conftest.$ac_ext
-LIBS=$ac_func_search_save_LIBS
+LIBS=$ac_func_search_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_putmsg" >&5
printf "%s\n" "$ac_cv_search_putmsg" >&6; }
@@ -6135,8 +6333,8 @@
printf "%s\n" "#define HAVE_LINUX_GETNETBYNAME_R 1" >>confdefs.h
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
@@ -6167,8 +6365,8 @@
printf "%s\n" "#define HAVE_SOLARIS_IRIX_GETNETBYNAME_R 1" >>confdefs.h
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
@@ -6199,19 +6397,22 @@
printf "%s\n" "#define HAVE_AIX_GETNETBYNAME_R 1" >>confdefs.h
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
@@ -6264,8 +6465,8 @@
printf "%s\n" "#define HAVE_LINUX_GETPROTOBYNAME_R 1" >>confdefs.h
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
@@ -6296,8 +6497,8 @@
printf "%s\n" "#define HAVE_SOLARIS_IRIX_GETPROTOBYNAME_R 1" >>confdefs.h
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
@@ -6328,19 +6529,22 @@
printf "%s\n" "#define HAVE_AIX_GETPROTOBYNAME_R 1" >>confdefs.h
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
@@ -6564,8 +6768,8 @@
#
ac_lbl_have_pthreads="found"
-else $as_nop
-
+else case e in #(
+ e)
#
# No - do we have it in -lpthreads?
#
@@ -6574,16 +6778,22 @@
if test ${ac_cv_lib_pthreads_pthread_create+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-lpthreads $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char pthread_create ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char pthread_create (void);
int
main (void)
{
@@ -6595,12 +6805,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_pthreads_pthread_create=yes
-else $as_nop
- ac_cv_lib_pthreads_pthread_create=no
+else case e in #(
+ e) ac_cv_lib_pthreads_pthread_create=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_pthread_create" >&5
printf "%s\n" "$ac_cv_lib_pthreads_pthread_create" >&6; }
@@ -6613,8 +6825,8 @@
ac_lbl_have_pthreads="found"
PTHREAD_LIBS="$PTHREAD_LIBS -lpthreads"
-else $as_nop
-
+else case e in #(
+ e)
#
# No - do we have it in -lpthread?
#
@@ -6623,16 +6835,22 @@
if test ${ac_cv_lib_pthread_pthread_create+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-lpthread $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char pthread_create ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char pthread_create (void);
int
main (void)
{
@@ -6644,12 +6862,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_pthread_pthread_create=yes
-else $as_nop
- ac_cv_lib_pthread_pthread_create=no
+else case e in #(
+ e) ac_cv_lib_pthread_pthread_create=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_create" >&5
printf "%s\n" "$ac_cv_lib_pthread_pthread_create" >&6; }
@@ -6662,30 +6882,34 @@
ac_lbl_have_pthreads="found"
PTHREAD_LIBS="$PTHREAD_LIBS -lpthread"
-else $as_nop
-
+else case e in #(
+ e)
#
# No.
#
ac_lbl_have_pthreads="not found"
-
+ ;;
+esac
fi
-
+ ;;
+esac
fi
-
+ ;;
+esac
fi
-else $as_nop
-
+else case e in #(
+ e)
#
# We didn't find pthread.h.
#
ac_lbl_have_pthreads="not found"
-
+ ;;
+esac
fi
@@ -6695,8 +6919,9 @@
if test ${enable_instrument_functions+y}
then :
enableval=$enable_instrument_functions;
-else $as_nop
- enableval=no
+else case e in #(
+ e) enableval=no ;;
+esac
fi
case "$enableval" in
@@ -6804,8 +7029,8 @@
if test ${ac_cv_lbl_bpf_h_defines_biocsetif+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include <sys/types.h>
@@ -6829,10 +7054,12 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_cv_lbl_bpf_h_defines_biocsetif=yes
-else $as_nop
- ac_cv_lbl_bpf_h_defines_biocsetif=no
+else case e in #(
+ e) ac_cv_lbl_bpf_h_defines_biocsetif=no ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_bpf_h_defines_biocsetif" >&5
@@ -6992,8 +7219,8 @@
if test ${ac_cv_path_PKG_CONFIG+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- case $PKG_CONFIG in
+else case e in #(
+ e) case $PKG_CONFIG in
[\\/]* | ?:[\\/]*)
ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
;;
@@ -7018,6 +7245,7 @@
IFS=$as_save_IFS
;;
+esac ;;
esac
fi
PKG_CONFIG=$ac_cv_path_PKG_CONFIG
@@ -7040,8 +7268,8 @@
if test ${ac_cv_path_ac_pt_PKG_CONFIG+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- case $ac_pt_PKG_CONFIG in
+else case e in #(
+ e) case $ac_pt_PKG_CONFIG in
[\\/]* | ?:[\\/]*)
ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
;;
@@ -7066,6 +7294,7 @@
IFS=$as_save_IFS
;;
+esac ;;
esac
fi
ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
@@ -7117,8 +7346,8 @@
if test ${ac_cv_path_BREW+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- case $BREW in
+else case e in #(
+ e) case $BREW in
[\\/]* | ?:[\\/]*)
ac_cv_path_BREW="$BREW" # Let the user override the test with a path.
;;
@@ -7143,6 +7372,7 @@
IFS=$as_save_IFS
;;
+esac ;;
esac
fi
BREW=$ac_cv_path_BREW
@@ -7259,16 +7489,22 @@
if test ${ac_cv_lib_dlpi_dlpi_walk+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-ldlpi $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char dlpi_walk ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char dlpi_walk (void);
int
main (void)
{
@@ -7280,12 +7516,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_dlpi_dlpi_walk=yes
-else $as_nop
- ac_cv_lib_dlpi_dlpi_walk=no
+else case e in #(
+ e) ac_cv_lib_dlpi_dlpi_walk=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dlpi_dlpi_walk" >&5
printf "%s\n" "$ac_cv_lib_dlpi_dlpi_walk" >&6; }
@@ -7306,8 +7544,8 @@
printf "%s\n" "#define HAVE_LIBDLPI 1" >>confdefs.h
-else $as_nop
-
+else case e in #(
+ e)
V_PCAP=dlpi
#
@@ -7315,7 +7553,8 @@
# common functions used by pcap-[dlpi,libdlpi].c
#
PLATFORM_C_SRC="pcap-dlpi.c dlpisubs.c"
-
+ ;;
+esac
fi
LDFLAGS="$save_LDFLAGS"
@@ -7329,8 +7568,8 @@
if test ${ac_cv_sys_dlpi_usable+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include <sys/types.h>
@@ -7348,10 +7587,12 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_cv_sys_dlpi_usable=yes
-else $as_nop
- ac_cv_sys_dlpi_usable=no
+else case e in #(
+ e) ac_cv_sys_dlpi_usable=no ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_dlpi_usable" >&5
@@ -7438,8 +7679,9 @@
if test ${with_libnl+y}
then :
withval=$with_libnl; with_libnl=$withval
-else $as_nop
- with_libnl=if_available
+else case e in #(
+ e) with_libnl=if_available ;;
+esac
fi
@@ -7583,16 +7825,22 @@
if test ${ac_cv_lib_nl_3_nl_socket_alloc+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-lnl-3 ${incdir} ${libnldir} -lnl-genl-3 -lnl-3 $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char nl_socket_alloc ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char nl_socket_alloc (void);
int
main (void)
{
@@ -7604,12 +7852,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_nl_3_nl_socket_alloc=yes
-else $as_nop
- ac_cv_lib_nl_3_nl_socket_alloc=no
+else case e in #(
+ e) ac_cv_lib_nl_3_nl_socket_alloc=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nl_3_nl_socket_alloc" >&5
printf "%s\n" "$ac_cv_lib_nl_3_nl_socket_alloc" >&6; }
@@ -7627,8 +7877,8 @@
V_INCLS="$V_INCLS ${incdir}"
-else $as_nop
-
+else case e in #(
+ e)
#
# No, we don't have libnl at all.
# Fail if the user explicitly requested
@@ -7637,7 +7887,8 @@
if test x$with_libnl = xyes ; then
as_fn_error $? "libnl support requested but libnl not found" "$LINENO" 5
fi
-
+ ;;
+esac
fi
fi
@@ -7822,8 +8073,8 @@
#
PLATFORM_C_SRC="$PLATFORM_C_SRC fad-getad.c"
-else $as_nop
-
+else case e in #(
+ e)
#
# We don't have the header - give up.
# XXX - we could also fall back on some other
@@ -7834,12 +8085,13 @@
# we can do on those systems.
#
as_fn_error $? "Your system has getifaddrs() but doesn't have a usable <ifaddrs.h>." "$LINENO" 5
-
+ ;;
+esac
fi
-else $as_nop
-
+else case e in #(
+ e)
#
# Well, we don't have "getifaddrs()", at least not with the
# libraries with which we've decided we need to link
@@ -7862,8 +8114,8 @@
if test ${ac_cv_lbl_have_siocglifconf+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include <sys/param.h>
#include <sys/file.h>
@@ -7881,10 +8133,12 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_cv_lbl_have_siocglifconf=yes
-else $as_nop
- ac_cv_lbl_have_siocglifconf=no
+else case e in #(
+ e) ac_cv_lbl_have_siocglifconf=no ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lbl_have_siocglifconf" >&5
@@ -7894,7 +8148,8 @@
else
PLATFORM_C_SRC="$PLATFORM_C_SRC fad-gifc.c"
fi
-
+ ;;
+esac
fi
fi
@@ -7936,8 +8191,9 @@
if test ${enable_ipv6+y}
then :
enableval=$enable_ipv6;
-else $as_nop
- enable_ipv6=yes
+else case e in #(
+ e) enable_ipv6=yes ;;
+esac
fi
if test "$enable_ipv6" != "no"; then
@@ -7970,8 +8226,8 @@
dag_root=$withval
fi
-else $as_nop
-
+else case e in #(
+ e)
if test "$V_PCAP" = dag; then
# User requested DAG-only libpcap, so we'd better have
# the DAG API.
@@ -7986,7 +8242,8 @@
#
want_dag=ifpresent
fi
-
+ ;;
+esac
fi
@@ -8077,16 +8334,22 @@
if test ${ac_cv_lib_dag_dag_attach_stream+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-ldag $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char dag_attach_stream ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char dag_attach_stream (void);
int
main (void)
{
@@ -8098,12 +8361,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_dag_dag_attach_stream=yes
-else $as_nop
- ac_cv_lib_dag_dag_attach_stream=no
+else case e in #(
+ e) ac_cv_lib_dag_dag_attach_stream=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dag_dag_attach_stream" >&5
printf "%s\n" "$ac_cv_lib_dag_dag_attach_stream" >&6; }
@@ -8119,8 +8384,9 @@
ADDITIONAL_LIBS_STATIC="-L$dag_lib_dir $ADDITIONAL_LIBS_STATIC -ldag -ldagconf"
LIBS_PRIVATE="-L$dag_lib_dir $LIBS_PRIVATE -ldag -ldagconf"
-else $as_nop
- as_fn_error $? "DAG library lacks streams support" "$LINENO" 5
+else case e in #(
+ e) as_fn_error $? "DAG library lacks streams support" "$LINENO" 5 ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dag_attach_stream64 in -ldag" >&5
@@ -8128,16 +8394,22 @@
if test ${ac_cv_lib_dag_dag_attach_stream64+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-ldag $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char dag_attach_stream64 ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char dag_attach_stream64 (void);
int
main (void)
{
@@ -8149,20 +8421,23 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_dag_dag_attach_stream64=yes
-else $as_nop
- ac_cv_lib_dag_dag_attach_stream64=no
+else case e in #(
+ e) ac_cv_lib_dag_dag_attach_stream64=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dag_dag_attach_stream64" >&5
printf "%s\n" "$ac_cv_lib_dag_dag_attach_stream64" >&6; }
if test "x$ac_cv_lib_dag_dag_attach_stream64" = xyes
then :
dag_large_streams="1"
-else $as_nop
- dag_large_streams="0"
+else case e in #(
+ e) dag_large_streams="0" ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dag_get_erf_types in -ldag" >&5
@@ -8170,16 +8445,22 @@
if test ${ac_cv_lib_dag_dag_get_erf_types+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-ldag $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char dag_get_erf_types ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char dag_get_erf_types (void);
int
main (void)
{
@@ -8191,12 +8472,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_dag_dag_get_erf_types=yes
-else $as_nop
- ac_cv_lib_dag_dag_get_erf_types=no
+else case e in #(
+ e) ac_cv_lib_dag_dag_get_erf_types=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dag_dag_get_erf_types" >&5
printf "%s\n" "$ac_cv_lib_dag_dag_get_erf_types" >&6; }
@@ -8213,16 +8496,22 @@
if test ${ac_cv_lib_dag_dag_get_stream_erf_types+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-ldag $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char dag_get_stream_erf_types ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char dag_get_stream_erf_types (void);
int
main (void)
{
@@ -8234,12 +8523,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_dag_dag_get_stream_erf_types=yes
-else $as_nop
- ac_cv_lib_dag_dag_get_stream_erf_types=no
+else case e in #(
+ e) ac_cv_lib_dag_dag_get_stream_erf_types=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dag_dag_get_stream_erf_types" >&5
printf "%s\n" "$ac_cv_lib_dag_dag_get_stream_erf_types" >&6; }
@@ -8278,16 +8569,22 @@
if test ${ac_cv_lib_vdag_vdag_set_device_info+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-lvdag $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char vdag_set_device_info ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char vdag_set_device_info (void);
int
main (void)
{
@@ -8299,20 +8596,23 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_vdag_vdag_set_device_info=yes
-else $as_nop
- ac_cv_lib_vdag_vdag_set_device_info=no
+else case e in #(
+ e) ac_cv_lib_vdag_vdag_set_device_info=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_vdag_vdag_set_device_info" >&5
printf "%s\n" "$ac_cv_lib_vdag_vdag_set_device_info" >&6; }
if test "x$ac_cv_lib_vdag_vdag_set_device_info" = xyes
then :
ac_dag_have_vdag="1"
-else $as_nop
- ac_dag_have_vdag="0"
+else case e in #(
+ e) ac_dag_have_vdag="0" ;;
+esac
fi
@@ -8368,8 +8668,8 @@
septel_root=$withval
fi
-else $as_nop
-
+else case e in #(
+ e)
if test "$V_PCAP" = septel; then
# User requested Septel-only libpcap, so we'd better have
# the Septel API.
@@ -8384,7 +8684,8 @@
#
want_septel=ifpresent
fi
-
+ ;;
+esac
fi
@@ -8458,8 +8759,8 @@
snf_root=$withval
fi
-else $as_nop
-
+else case e in #(
+ e)
if test "$V_PCAP" = snf; then
# User requested Sniffer-only libpcap, so we'd better have
# the Sniffer API.
@@ -8474,7 +8775,8 @@
#
want_snf=ifpresent
fi
-
+ ;;
+esac
fi
@@ -8541,16 +8843,22 @@
if test ${ac_cv_lib_snf_snf_init+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-lsnf $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char snf_init ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char snf_init (void);
int
main (void)
{
@@ -8562,12 +8870,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_snf_snf_init=yes
-else $as_nop
- ac_cv_lib_snf_snf_init=no
+else case e in #(
+ e) ac_cv_lib_snf_snf_init=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_snf_snf_init" >&5
printf "%s\n" "$ac_cv_lib_snf_snf_init" >&6; }
@@ -8638,8 +8948,8 @@
turbocap_root=$withval
fi
-else $as_nop
-
+else case e in #(
+ e)
if test "xxx_only" = yes; then
# User requested something-else-only pcap, so they don't
# want TurboCap support.
@@ -8650,7 +8960,8 @@
#
want_turbocap=ifpresent
fi
-
+ ;;
+esac
fi
@@ -8730,17 +9041,14 @@
if test ${enable_remote+y}
then :
enableval=$enable_remote;
-else $as_nop
- enableval=no
+else case e in #(
+ e) enableval=no ;;
+esac
fi
case "$enableval" in
yes) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Remote packet capture may expose libpcap-based applications" >&5
-printf "%s\n" "$as_me: WARNING: Remote packet capture may expose libpcap-based applications" >&2;}
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: to attacks by malicious remote capture servers!" >&5
-printf "%s\n" "$as_me: WARNING: to attacks by malicious remote capture servers!" >&2;}
#
# rpcapd requires pthreads on UN*X.
#
@@ -8755,8 +9063,8 @@
if test "x$ac_cv_func_crypt" = xyes
then :
-else $as_nop
-
+else case e in #(
+ e)
#
# No. Do we have it in -lcrypt?
#
@@ -8765,16 +9073,22 @@
if test ${ac_cv_lib_crypt_crypt+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-lcrypt $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char crypt ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char crypt (void);
int
main (void)
{
@@ -8786,12 +9100,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_crypt_crypt=yes
-else $as_nop
- ac_cv_lib_crypt_crypt=no
+else case e in #(
+ e) ac_cv_lib_crypt_crypt=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypt_crypt" >&5
printf "%s\n" "$ac_cv_lib_crypt_crypt" >&6; }
@@ -8803,13 +9119,15 @@
#
RPCAPD_LIBS="$RPCAPD_LIBS -lcrypt"
-else $as_nop
-
+else case e in #(
+ e)
as_fn_error $? "rpcapd requires crypt(), but we didn't find it" "$LINENO" 5
-
+ ;;
+esac
fi
-
+ ;;
+esac
fi
@@ -9077,9 +9395,10 @@
OPENSSL_LIBS_STATIC="-L/usr/local/lib -lssl -lcrypto"
OPENSSL_LIBS_PRIVATE="-L/usr/local/lib -lssl -lcrypto"
-else $as_nop
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
-printf "%s\n" "no" >&6; }
+else case e in #(
+ e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; } ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
@@ -9135,9 +9454,10 @@
OPENSSL_LIBS_STATIC="-lssl -lcrypto"
OPENSSL_LIBS_PRIVATE="-lssl -lcrypto"
-else $as_nop
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
-printf "%s\n" "no" >&6; }
+else case e in #(
+ e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+printf "%s\n" "no" >&6; } ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
@@ -9222,8 +9542,8 @@
if test ${ac_cv_prog_LEX+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$LEX"; then
+else case e in #(
+ e) if test -n "$LEX"; then
ac_cv_prog_LEX="$LEX" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -9245,7 +9565,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
LEX=$ac_cv_prog_LEX
if test -n "$LEX"; then
@@ -9303,8 +9624,8 @@
if test ${ac_cv_prog_lex_root+y}
then :
printf %s "(cached) " >&6
-else $as_nop
-
+else case e in #(
+ e)
ac_cv_prog_lex_root=unknown
{ { ac_try="$LEX conftest.l"
case "(($ac_try" in
@@ -9321,7 +9642,8 @@
ac_cv_prog_lex_root=lex.yy
elif test -f lexyy.c; then
ac_cv_prog_lex_root=lexyy
-fi
+fi ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5
printf "%s\n" "$ac_cv_prog_lex_root" >&6; }
@@ -9336,15 +9658,15 @@
if test ${LEXLIB+y}
then :
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for lex library" >&5
printf %s "checking for lex library... " >&6; }
if test ${ac_cv_lib_lex+y}
then :
printf %s "(cached) " >&6
-else $as_nop
-
+else case e in #(
+ e)
ac_save_LIBS="$LIBS"
ac_found=false
for ac_cv_lib_lex in 'none needed' -lfl -ll 'not found'; do
@@ -9374,7 +9696,8 @@
fi
done
LIBS="$ac_save_LIBS"
-
+ ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5
printf "%s\n" "$ac_cv_lib_lex" >&6; }
@@ -9386,8 +9709,9 @@
elif test "$ac_cv_lib_lex" = 'none needed'
then :
LEXLIB=''
-else $as_nop
- LEXLIB=$ac_cv_lib_lex
+else case e in #(
+ e) LEXLIB=$ac_cv_lib_lex ;;
+esac
fi
ac_save_LIBS="$LIBS"
LIBS=
@@ -9396,15 +9720,21 @@
if test ${ac_cv_search_yywrap+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_func_search_save_LIBS=$LIBS
+else case e in #(
+ e) ac_func_search_save_LIBS=$LIBS
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char yywrap ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char yywrap (void);
int
main (void)
{
@@ -9435,11 +9765,13 @@
if test ${ac_cv_search_yywrap+y}
then :
-else $as_nop
- ac_cv_search_yywrap=no
+else case e in #(
+ e) ac_cv_search_yywrap=no ;;
+esac
fi
rm conftest.$ac_ext
-LIBS=$ac_func_search_save_LIBS
+LIBS=$ac_func_search_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_yywrap" >&5
printf "%s\n" "$ac_cv_search_yywrap" >&6; }
@@ -9450,7 +9782,8 @@
LEXLIB="$LIBS"
fi
- LIBS="$ac_save_LIBS"
+ LIBS="$ac_save_LIBS" ;;
+esac
fi
@@ -9462,8 +9795,8 @@
if test ${ac_cv_prog_lex_yytext_pointer+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- # POSIX says lex can declare yytext either as a pointer or an array; the
+else case e in #(
+ e) # POSIX says lex can declare yytext either as a pointer or an array; the
# default is implementation-dependent. Figure out which it is, since
# not all implementations provide the %pointer and %array declarations.
ac_cv_prog_lex_yytext_pointer=no
@@ -9478,7 +9811,8 @@
ac_cv_prog_lex_yytext_pointer=yes
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
-
+ ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5
printf "%s\n" "$ac_cv_prog_lex_yytext_pointer" >&6; }
@@ -9505,12 +9839,13 @@
if test ${tcpdump_cv_capable_lex+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if $LEX -P pcap_ --header-file=/dev/null --nounput -t $srcdir/scanner.l > /dev/null 2>&1; then
+else case e in #(
+ e) if $LEX -P pcap_ --header-file=/dev/null --nounput -t $srcdir/scanner.l > /dev/null 2>&1; then
tcpdump_cv_capable_lex=yes
else
tcpdump_cv_capable_lex=insufficient
- fi
+ fi ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcpdump_cv_capable_lex" >&5
printf "%s\n" "$tcpdump_cv_capable_lex" >&6; }
@@ -9546,8 +9881,8 @@
if test ${ac_cv_prog_BISON_BYACC+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$BISON_BYACC"; then
+else case e in #(
+ e) if test -n "$BISON_BYACC"; then
ac_cv_prog_BISON_BYACC="$BISON_BYACC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -9569,7 +9904,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
BISON_BYACC=$ac_cv_prog_BISON_BYACC
if test -n "$BISON_BYACC"; then
@@ -9614,8 +9950,8 @@
if test ${ac_cv_prog_BISON_BYACC+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$BISON_BYACC"; then
+else case e in #(
+ e) if test -n "$BISON_BYACC"; then
ac_cv_prog_BISON_BYACC="$BISON_BYACC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -9637,7 +9973,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
BISON_BYACC=$ac_cv_prog_BISON_BYACC
if test -n "$BISON_BYACC"; then
@@ -9670,12 +10007,13 @@
if test ${tcpdump_cv_capable_yacc+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if $BISON_BYACC -V >/dev/null 2>&1; then
+else case e in #(
+ e) if $BISON_BYACC -V >/dev/null 2>&1; then
tcpdump_cv_capable_yacc=yes
else
tcpdump_cv_capable_yacc=insufficient
- fi
+ fi ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $tcpdump_cv_capable_yacc" >&5
printf "%s\n" "$tcpdump_cv_capable_yacc" >&6; }
@@ -9917,8 +10255,8 @@
V_LIB_LDFLAGS_FAT="$V_LIB_LDFLAGS_FAT -arch i386"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
V_LIB_CCOPT_FAT="-arch x86_64"
@@ -9945,7 +10283,8 @@
printf "%s\n" "$as_me: WARNING: Compiling for 32-bit x86 gives an error; try installing the command-line tools" >&2;}
;;
esac
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
@@ -10021,10 +10360,11 @@
V_PROG_CCOPT_FAT="-arch x86_64 -arch arm64"
V_PROG_LDFLAGS_FAT="-arch x86_64 -arch arm64"
-else $as_nop
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
+else case e in #(
+ e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
@@ -10134,8 +10474,8 @@
if test ${ac_cv_cc_sinix_defined+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
@@ -10149,10 +10489,12 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_cv_cc_sinix_defined=yes
-else $as_nop
- ac_cv_cc_sinix_defined=no
+else case e in #(
+ e) ac_cv_cc_sinix_defined=no ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_sinix_defined" >&5
@@ -10223,8 +10565,8 @@
if test ${ac_cv_prog_RANLIB+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$RANLIB"; then
+else case e in #(
+ e) if test -n "$RANLIB"; then
ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -10246,7 +10588,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
RANLIB=$ac_cv_prog_RANLIB
if test -n "$RANLIB"; then
@@ -10268,8 +10611,8 @@
if test ${ac_cv_prog_ac_ct_RANLIB+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$ac_ct_RANLIB"; then
+else case e in #(
+ e) if test -n "$ac_ct_RANLIB"; then
ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -10291,7 +10634,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
if test -n "$ac_ct_RANLIB"; then
@@ -10325,8 +10669,8 @@
if test ${ac_cv_prog_AR+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$AR"; then
+else case e in #(
+ e) if test -n "$AR"; then
ac_cv_prog_AR="$AR" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -10348,7 +10692,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
AR=$ac_cv_prog_AR
if test -n "$AR"; then
@@ -10370,8 +10715,8 @@
if test ${ac_cv_prog_ac_ct_AR+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- if test -n "$ac_ct_AR"; then
+else case e in #(
+ e) if test -n "$ac_ct_AR"; then
ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
@@ -10393,7 +10738,8 @@
done
IFS=$as_save_IFS
-fi
+fi ;;
+esac
fi
ac_ct_AR=$ac_cv_prog_ac_ct_AR
if test -n "$ac_ct_AR"; then
@@ -10512,15 +10858,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -10530,12 +10877,13 @@
V_CCOPT="$V_CCOPT -W"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -10605,15 +10953,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -10623,12 +10972,13 @@
V_CCOPT="$V_CCOPT -Wall"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -10698,15 +11048,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -10716,12 +11067,13 @@
V_CCOPT="$V_CCOPT -Wcomma"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -10794,15 +11146,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -10812,12 +11165,13 @@
V_CCOPT="$V_CCOPT -Wdocumentation"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -10887,15 +11241,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -10905,12 +11260,13 @@
V_CCOPT="$V_CCOPT -Wformat-nonliteral"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -10980,15 +11336,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -10998,12 +11355,13 @@
V_CCOPT="$V_CCOPT -Wmissing-noreturn"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -11073,15 +11431,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -11091,12 +11450,13 @@
V_CCOPT="$V_CCOPT -Wmissing-prototypes"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -11166,15 +11526,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -11184,12 +11545,13 @@
V_CCOPT="$V_CCOPT -Wmissing-variable-declarations"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -11259,15 +11621,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -11277,12 +11640,13 @@
V_CCOPT="$V_CCOPT -Wnull-pointer-subtraction"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -11352,15 +11716,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -11370,12 +11735,13 @@
V_CCOPT="$V_CCOPT -Wpointer-arith"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -11445,15 +11811,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -11463,12 +11830,13 @@
V_CCOPT="$V_CCOPT -Wpointer-sign"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -11538,15 +11906,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -11556,12 +11925,13 @@
V_CCOPT="$V_CCOPT -Wshadow"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -11631,15 +12001,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -11649,12 +12020,13 @@
V_CCOPT="$V_CCOPT -Wshorten-64-to-32"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -11724,15 +12096,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -11742,12 +12115,13 @@
V_CCOPT="$V_CCOPT -Wsign-compare"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -11817,15 +12191,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -11835,12 +12210,13 @@
V_CCOPT="$V_CCOPT -Wstrict-prototypes"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -11910,15 +12286,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -11928,12 +12305,13 @@
V_CCOPT="$V_CCOPT -Wundef"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -12034,15 +12412,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -12052,12 +12431,13 @@
V_CCOPT="$V_CCOPT -Wunreachable-code"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -12127,15 +12507,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -12145,12 +12526,13 @@
V_CCOPT="$V_CCOPT -Wunused-but-set-parameter"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -12220,15 +12602,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -12238,12 +12621,13 @@
V_CCOPT="$V_CCOPT -Wunused-but-set-variable"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -12313,15 +12697,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -12331,12 +12716,13 @@
V_CCOPT="$V_CCOPT -Wunused-parameter"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -12406,15 +12792,16 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-else $as_nop
-
+else case e in #(
+ e)
#
# A problem.
#
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
can_add_to_cflags=no
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
fi
@@ -12424,12 +12811,13 @@
V_CCOPT="$V_CCOPT -Wused-but-marked-unused"
fi
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
CFLAGS="$save_CFLAGS"
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ac_c_werror_flag="$save_ac_c_werror_flag"
@@ -12629,8 +13017,9 @@
if test ${enable_usb+y}
then :
enableval=$enable_usb;
-else $as_nop
- enable_usb=yes
+else case e in #(
+ e) enable_usb=yes ;;
+esac
fi
@@ -12735,8 +13124,8 @@
if test ${ac_cv_netfilter_can_compile+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
$ac_includes_default
@@ -12760,10 +13149,12 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_cv_netfilter_can_compile=yes
-else $as_nop
- ac_cv_netfilter_can_compile=no
+else case e in #(
+ e) ac_cv_netfilter_can_compile=no ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_netfilter_can_compile" >&5
@@ -12784,8 +13175,9 @@
if test ${enable_netmap+y}
then :
enableval=$enable_netmap;
-else $as_nop
- enable_netmap=yes
+else case e in #(
+ e) enable_netmap=yes ;;
+esac
fi
@@ -12801,8 +13193,8 @@
if test ${ac_cv_net_netmap_user_can_compile+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
$ac_includes_default
@@ -12819,10 +13211,12 @@
if ac_fn_c_try_compile "$LINENO"
then :
ac_cv_net_netmap_user_can_compile=yes
-else $as_nop
- ac_cv_net_netmap_user_can_compile=no
+else case e in #(
+ e) ac_cv_net_netmap_user_can_compile=no ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_net_netmap_user_can_compile" >&5
@@ -12857,8 +13251,8 @@
dpdk_dir=$withval
fi
-else $as_nop
-
+else case e in #(
+ e)
if test "$V_PCAP" = dpdk; then
# User requested DPDK-only libpcap, so we'd better have
# the DPDK API.
@@ -12876,7 +13270,8 @@
#
want_dpdk=no
fi
-
+ ;;
+esac
fi
@@ -13184,8 +13579,9 @@
if test ${enable_bluetooth+y}
then :
enableval=$enable_bluetooth;
-else $as_nop
- enable_bluetooth=ifsupportavailable
+else case e in #(
+ e) enable_bluetooth=ifsupportavailable ;;
+esac
fi
@@ -13237,8 +13633,8 @@
if test ${ac_cv_lbl_hci_channel_monitor_is_defined+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+else case e in #(
+ e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include <bluetooth/bluetooth.h>
@@ -13264,21 +13660,23 @@
MODULE_C_SRC="$MODULE_C_SRC pcap-bt-monitor-linux.c"
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-
+ ;;
+esac
fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
+esac
fi
fi
-else $as_nop
-
+else case e in #(
+ e)
#
# We don't have bluetooth.h, so we don't support
# Bluetooth sniffing.
@@ -13289,7 +13687,8 @@
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: Bluetooth sniffing is not supported; install a Bluetooth devel library (libbluetooth-dev|bluez-libs-devel|bluez-dev|libbluetooth-devel|...) to enable it" >&5
printf "%s\n" "$as_me: Bluetooth sniffing is not supported; install a Bluetooth devel library (libbluetooth-dev|bluez-libs-devel|bluez-dev|libbluetooth-devel|...) to enable it" >&6;}
fi
-
+ ;;
+esac
fi
;;
@@ -13309,8 +13708,9 @@
if test ${enable_dbus+y}
then :
enableval=$enable_dbus;
-else $as_nop
- enable_dbus=ifavailable
+else case e in #(
+ e) enable_dbus=ifavailable ;;
+esac
fi
@@ -13481,14 +13881,15 @@
ADDITIONAL_LIBS_STATIC="$ADDITIONAL_LIBS_STATIC $DBUS_LIBS_STATIC"
REQUIRES_PRIVATE="$REQUIRES_PRIVATE dbus-1"
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
if test "x$enable_dbus" = "xyes"; then
as_fn_error $? "--enable-dbus was given, but the D-Bus library doesn't define dbus_connection_read_write()" "$LINENO" 5
fi
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
@@ -13525,8 +13926,9 @@
if test ${enable_rdma+y}
then :
enableval=$enable_rdma;
-else $as_nop
- enable_rdma=ifavailable
+else case e in #(
+ e) enable_rdma=ifavailable ;;
+esac
fi
@@ -13648,16 +14050,22 @@
if test ${ac_cv_lib_ibverbs_ibv_get_device_list+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- ac_check_lib_save_LIBS=$LIBS
+else case e in #(
+ e) ac_check_lib_save_LIBS=$LIBS
LIBS="-libverbs $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-char ibv_get_device_list ();
+ builtin and then its argument prototype would still apply.
+ The 'extern "C"' is for builds by C++ compilers;
+ although this is not generally supported in C code supporting it here
+ has little cost and some practical benefit (sr 110532). */
+#ifdef __cplusplus
+extern "C"
+#endif
+char ibv_get_device_list (void);
int
main (void)
{
@@ -13669,12 +14077,14 @@
if ac_fn_c_try_link "$LINENO"
then :
ac_cv_lib_ibverbs_ibv_get_device_list=yes
-else $as_nop
- ac_cv_lib_ibverbs_ibv_get_device_list=no
+else case e in #(
+ e) ac_cv_lib_ibverbs_ibv_get_device_list=no ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+LIBS=$ac_check_lib_save_LIBS ;;
+esac
fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ibverbs_ibv_get_device_list" >&5
printf "%s\n" "$ac_cv_lib_ibverbs_ibv_get_device_list" >&6; }
@@ -13745,12 +14155,13 @@
printf "%s\n" "yes" >&6; }
found_usable_libibverbs=yes
-else $as_nop
-
+else case e in #(
+ e)
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
-
+ ;;
+esac
fi
rm -f core conftest.err conftest.$ac_objext conftest.beam \
conftest$ac_exeext conftest.$ac_ext
@@ -13855,8 +14266,8 @@
if test ${ac_cv_path_install+y}
then :
printf %s "(cached) " >&6
-else $as_nop
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+else case e in #(
+ e) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
@@ -13910,7 +14321,8 @@
IFS=$as_save_IFS
rm -rf conftest.one conftest.two conftest.dir
-
+ ;;
+esac
fi
if test ${ac_cv_path_install+y}; then
INSTALL=$ac_cv_path_install
@@ -13973,8 +14385,8 @@
# config.status only pays attention to the cache file if you give it
# the --recheck option to rerun configure.
#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
+# 'ac_cv_env_foo' variables (set or unset) will be overridden when
+# loading this file, other *unset* 'ac_cv_foo' will be assigned the
# following values.
_ACEOF
@@ -14004,14 +14416,14 @@
(set) 2>&1 |
case $as_nl`(ac_space=' '; set) 2>&1` in #(
*${as_nl}ac_space=\ *)
- # `set' does not quote correctly, so add quotes: double-quote
+ # 'set' does not quote correctly, so add quotes: double-quote
# substitution turns \\\\ into \\, and sed turns \\ into \.
sed -n \
"s/'/'\\\\''/g;
s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
;; #(
*)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
+ # 'set' quotes correctly as required by POSIX, so do not add quotes.
sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
;;
esac |
@@ -14072,6 +14484,12 @@
LTLIBOBJS=$ac_ltlibobjs
+# Check whether --enable-year2038 was given.
+if test ${enable_year2038+y}
+then :
+ enableval=$enable_year2038;
+fi
+
: "${CONFIG_STATUS=./config.status}"
ac_write_fail=0
@@ -14101,7 +14519,6 @@
# Be more Bourne compatible
DUALCASE=1; export DUALCASE # for MKS sh
-as_nop=:
if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
then :
emulate sh
@@ -14110,12 +14527,13 @@
# is contrary to our usage. Disable this feature.
alias -g '${1+"$@"}'='"$@"'
setopt NO_GLOB_SUBST
-else $as_nop
- case `(set -o) 2>/dev/null` in #(
+else case e in #(
+ e) case `(set -o) 2>/dev/null` in #(
*posix*) :
set -o posix ;; #(
*) :
;;
+esac ;;
esac
fi
@@ -14187,7 +14605,7 @@
;;
esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
+# We did not find ourselves, most probably we were run as 'sh COMMAND'
# in which case we are not to be found in the path.
if test "x$as_myself" = x; then
as_myself=$0
@@ -14216,7 +14634,6 @@
} # as_fn_error
-
# as_fn_set_status STATUS
# -----------------------
# Set $? to STATUS, without forking.
@@ -14256,11 +14673,12 @@
{
eval $1+=\$2
}'
-else $as_nop
- as_fn_append ()
+else case e in #(
+ e) as_fn_append ()
{
eval $1=\$$1\$2
- }
+ } ;;
+esac
fi # as_fn_append
# as_fn_arith ARG...
@@ -14274,11 +14692,12 @@
{
as_val=$(( $* ))
}'
-else $as_nop
- as_fn_arith ()
+else case e in #(
+ e) as_fn_arith ()
{
as_val=`expr "$@" || test $? -eq 1`
- }
+ } ;;
+esac
fi # as_fn_arith
@@ -14361,9 +14780,9 @@
if ln -s conf$$.file conf$$ 2>/dev/null; then
as_ln_s='ln -s'
# ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
+ # 1) On MSYS, both 'ln -s file dir' and 'ln file dir' fail.
+ # 2) DJGPP < 2.04 has no symlinks; 'ln -s' creates a wrapper executable.
+ # In both cases, we have to default to 'cp -pR'.
ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
as_ln_s='cp -pR'
elif ln conf$$.file conf$$ 2>/dev/null; then
@@ -14444,10 +14863,12 @@
as_executable_p=as_fn_executable_p
# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
+as_sed_cpp="y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
+as_tr_cpp="eval sed '$as_sed_cpp'" # deprecated
# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
+as_sed_sh="y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
+as_tr_sh="eval sed '$as_sed_sh'" # deprecated
exec 6>&1
@@ -14462,8 +14883,8 @@
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by pcap $as_me 1.10.6, which was
-generated by GNU Autoconf 2.71. Invocation command line was
+This file was extended by pcap $as_me 1.10.7, which was
+generated by GNU Autoconf 2.72. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
CONFIG_HEADERS = $CONFIG_HEADERS
@@ -14495,7 +14916,7 @@
cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
ac_cs_usage="\
-\`$as_me' instantiates files and other configuration actions
+'$as_me' instantiates files and other configuration actions
from templates according to the current configuration. Unless the files
and actions are specified as TAGs, all are instantiated by default.
@@ -14530,11 +14951,11 @@
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config='$ac_cs_config_escaped'
ac_cs_version="\\
-pcap config.status 1.10.6
-configured by $0, generated by GNU Autoconf 2.71,
+pcap config.status 1.10.7
+configured by $0, generated by GNU Autoconf 2.72,
with options \\"\$ac_cs_config\\"
-Copyright (C) 2021 Free Software Foundation, Inc.
+Copyright (C) 2023 Free Software Foundation, Inc.
This config.status script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it."
@@ -14594,8 +15015,8 @@
ac_need_defaults=false;;
--he | --h)
# Conflict between --help and --header
- as_fn_error $? "ambiguous option: \`$1'
-Try \`$0 --help' for more information.";;
+ as_fn_error $? "ambiguous option: '$1'
+Try '$0 --help' for more information.";;
--help | --hel | -h )
printf "%s\n" "$ac_cs_usage"; exit ;;
-q | -quiet | --quiet | --quie | --qui | --qu | --q \
@@ -14603,8 +15024,8 @@
ac_cs_silent=: ;;
# This is an error.
- -*) as_fn_error $? "unrecognized option: \`$1'
-Try \`$0 --help' for more information." ;;
+ -*) as_fn_error $? "unrecognized option: '$1'
+Try '$0 --help' for more information." ;;
*) as_fn_append ac_config_targets " $1"
ac_need_defaults=false ;;
@@ -14682,7 +15103,7 @@
"rpcapd/rpcapd-config.manfile") CONFIG_FILES="$CONFIG_FILES rpcapd/rpcapd-config.manfile" ;;
"testprogs/Makefile") CONFIG_FILES="$CONFIG_FILES testprogs/Makefile" ;;
- *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
+ *) as_fn_error $? "invalid argument: '$ac_config_target'" "$LINENO" 5;;
esac
done
@@ -14702,7 +15123,7 @@
# creating and moving files from /tmp can sometimes cause problems.
# Hook for its removal unless debugging.
# Note that there is a small window in which the directory will not be cleaned:
-# after its creation but before its name has been assigned to `$tmp'.
+# after its creation but before its name has been assigned to '$tmp'.
$debug ||
{
tmp= ac_tmp=
@@ -14726,7 +15147,7 @@
# Set up the scripts for CONFIG_FILES section.
# No need to generate them if there are no CONFIG_FILES.
-# This happens for instance with `./config.status config.h'.
+# This happens for instance with './config.status config.h'.
if test -n "$CONFIG_FILES"; then
@@ -14884,13 +15305,13 @@
# Set up the scripts for CONFIG_HEADERS section.
# No need to generate them if there are no CONFIG_HEADERS.
-# This happens for instance with `./config.status Makefile'.
+# This happens for instance with './config.status Makefile'.
if test -n "$CONFIG_HEADERS"; then
cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
BEGIN {
_ACEOF
-# Transform confdefs.h into an awk script `defines.awk', embedded as
+# Transform confdefs.h into an awk script 'defines.awk', embedded as
# here-document in config.status, that substitutes the proper values into
# config.h.in to produce config.h.
@@ -15000,7 +15421,7 @@
esac
case $ac_mode$ac_tag in
:[FHL]*:*);;
- :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
+ :L* | :C*:*) as_fn_error $? "invalid tag '$ac_tag'" "$LINENO" 5;;
:[FH]-) ac_tag=-:-;;
:[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
esac
@@ -15022,19 +15443,19 @@
-) ac_f="$ac_tmp/stdin";;
*) # Look for the file first in the build tree, then in the source tree
# (if the path is not absolute). The absolute path cannot be DOS-style,
- # because $ac_f cannot contain `:'.
+ # because $ac_f cannot contain ':'.
test -f "$ac_f" ||
case $ac_f in
[\\/$]*) false;;
*) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
esac ||
- as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
+ as_fn_error 1 "cannot find input file: '$ac_f'" "$LINENO" 5;;
esac
case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
as_fn_append ac_file_inputs " '$ac_f'"
done
- # Let's still pretend it is `configure' which instantiates (i.e., don't
+ # Let's still pretend it is 'configure' which instantiates (i.e., don't
# use $as_me), people would be surprised to read:
# /* config.h. Generated by config.status. */
configure_input='Generated from '`
@@ -15162,7 +15583,7 @@
esac
_ACEOF
-# Neutralize VPATH when `$srcdir' = `.'.
+# Neutralize VPATH when '$srcdir' = '.'.
# Shell code in configure.ac might set extrasub.
# FIXME: do we really want to maintain this feature?
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
@@ -15192,9 +15613,9 @@
{ ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
{ ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
"$ac_tmp/out"`; test -z "$ac_out"; } &&
- { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable 'datarootdir'
which seems to be undefined. Please make sure it is defined" >&5
-printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
+printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable 'datarootdir'
which seems to be undefined. Please make sure it is defined" >&2;}
rm -f "$ac_tmp/stdin"
@@ -15279,4 +15700,23 @@
printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
fi
+if test "x$enable_remote" = xyes
+then :
+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING:
+
+ *** REMOTE PACKET CAPTURE IS ENABLED ***
+
+ The --enable-remote feature is experimental and is not ready for
+ production use. Remote packet capture may expose libpcap-based
+ applications to attacks by malicious remote capture servers!
+ " >&5
+printf "%s\n" "$as_me: WARNING:
+
+ *** REMOTE PACKET CAPTURE IS ENABLED ***
+
+ The --enable-remote feature is experimental and is not ready for
+ production use. Remote packet capture may expose libpcap-based
+ applications to attacks by malicious remote capture servers!
+ " >&2;}
+fi
exit 0
diff --git a/contrib/libpcap/configure.ac b/contrib/libpcap/configure.ac
--- a/contrib/libpcap/configure.ac
+++ b/contrib/libpcap/configure.ac
@@ -1730,8 +1730,6 @@
[enableval=no])
case "$enableval" in
yes) AC_MSG_RESULT(yes)
- AC_WARN([Remote packet capture may expose libpcap-based applications])
- AC_WARN([to attacks by malicious remote capture servers!])
#
# rpcapd requires pthreads on UN*X.
#
@@ -3224,4 +3222,13 @@
pcap_set_tstamp_precision.3pcap pcap_set_tstamp_type.3pcap
rpcapd/Makefile rpcapd/rpcapd.manadmin rpcapd/rpcapd-config.manfile
testprogs/Makefile)
+AS_IF([test "x$enable_remote" = xyes],
+ [AC_MSG_WARN([
+
+ *** REMOTE PACKET CAPTURE IS ENABLED ***
+
+ The --enable-remote feature is experimental and is not ready for
+ production use. Remote packet capture may expose libpcap-based
+ applications to attacks by malicious remote capture servers!
+ ])])
exit 0
diff --git a/contrib/libpcap/diag-control.h b/contrib/libpcap/diag-control.h
--- a/contrib/libpcap/diag-control.h
+++ b/contrib/libpcap/diag-control.h
@@ -149,6 +149,15 @@
PCAP_DO_PRAGMA(clang diagnostic ignored "-Wsign-compare")
#define DIAG_ON_SIGN_COMPARE \
PCAP_DO_PRAGMA(clang diagnostic pop)
+
+ #if PCAP_IS_AT_LEAST_CLANG_VERSION(21,1)
+ #define DIAG_OFF_UNINITIALIZED_CONST_POINTER \
+ PCAP_DO_PRAGMA(clang diagnostic push) \
+ PCAP_DO_PRAGMA(clang diagnostic ignored "-Wuninitialized-const-pointer")
+ #define DIAG_ON_UNINITIALIZED_CONST_POINTER \
+ PCAP_DO_PRAGMA(clang diagnostic pop)
+ #endif
+
#elif defined(_MSC_VER)
/*
* This is Microsoft Visual Studio; we can use __pragma(warning(disable:XXXX))
@@ -423,6 +432,12 @@
#ifndef DIAG_ON_SIGN_COMPARE
#define DIAG_ON_SIGN_COMPARE
#endif
+#ifndef DIAG_OFF_UNINITIALIZED_CONST_POINTER
+#define DIAG_OFF_UNINITIALIZED_CONST_POINTER
+#endif
+#ifndef DIAG_ON_UNINITIALIZED_CONST_POINTER
+#define DIAG_ON_UNINITIALIZED_CONST_POINTER
+#endif
#ifndef PCAP_UNREACHABLE
#define PCAP_UNREACHABLE
#endif
diff --git a/contrib/libpcap/dlpisubs.c b/contrib/libpcap/dlpisubs.c
--- a/contrib/libpcap/dlpisubs.c
+++ b/contrib/libpcap/dlpisubs.c
@@ -203,7 +203,8 @@
bufp += caplen;
#endif
++pd->stat.ps_recv;
- if (pcapint_filter(p->fcode.bf_insns, pk, origlen, caplen)) {
+ if (pcapint_filter(p->fcode.bf_insns, p->fcode.bf_len,
+ pk, origlen, caplen)) {
#ifdef HAVE_SYS_BUFMOD_H
pkthdr.ts.tv_sec = sbp->sbh_timestamp.tv_sec;
pkthdr.ts.tv_usec = sbp->sbh_timestamp.tv_usec;
diff --git a/contrib/libpcap/grammar.y.in b/contrib/libpcap/grammar.y.in
--- a/contrib/libpcap/grammar.y.in
+++ b/contrib/libpcap/grammar.y.in
@@ -468,6 +468,7 @@
}
| HID NETMASK HID {
CHECK_PTR_VAL($1);
+ CHECK_PTR_VAL($3);
/* Check whether HID mask HID is being used when appropriate */
$$.q = $<blk>0.q;
if ($$.q.addr == Q_PORT) {
diff --git a/contrib/libpcap/instrument-functions.c b/contrib/libpcap/instrument-functions.c
--- a/contrib/libpcap/instrument-functions.c
+++ b/contrib/libpcap/instrument-functions.c
@@ -1,14 +1,32 @@
/*
+ * Copyright (c) 2022, 2023
+ * The Tcpdump Group and contributors. All rights reserved.
+ *
+ * SPDX-License-Identifier: BSD-2-Clause
+ *
* Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that: (1) source code
- * distributions retain the above copyright notice and this paragraph
- * in its entirety, and (2) distributions including binary code include
- * the above copyright notice and this paragraph in its entirety in
- * the documentation or other materials provided with the distribution.
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND
- * WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT
- * LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE.
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+ * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
*/
#include <stdio.h>
diff --git a/contrib/libpcap/nametoaddr.c b/contrib/libpcap/nametoaddr.c
--- a/contrib/libpcap/nametoaddr.c
+++ b/contrib/libpcap/nametoaddr.c
@@ -900,7 +900,14 @@
} fsm_state = START;
uint8_t buf[6];
const char *seplist = ":.-";
- char sep;
+ /*
+ * XXX - the state diagram indicates that we cannot get to states
+ * BYTEn_X or BYTEn_XX, for n > 0, without first going through
+ * states BYTE0_X or BYTE0_XX, but at least some versions of
+ * MSVC complain that sep may be used uninitialized, so we
+ * initialize it here.
+ */
+ char sep = '\0';
while (*s) {
switch (fsm_state) {
diff --git a/contrib/libpcap/optimize.c b/contrib/libpcap/optimize.c
--- a/contrib/libpcap/optimize.c
+++ b/contrib/libpcap/optimize.c
@@ -827,11 +827,7 @@
* is undefined in C; we'll just treat it as shifting
* all the bits out.
*
- * XXX - the BPF interpreter doesn't check for this,
- * so its behavior is dependent on the behavior of
- * the processor on which it's running. There are
- * processors on which it shifts all the bits out
- * and processors on which it does no shift.
+ * The BPF interpreter in libpcap does the same.
*/
if (b < 32)
a <<= b;
@@ -845,11 +841,7 @@
* is undefined in C; we'll just treat it as shifting
* all the bits out.
*
- * XXX - the BPF interpreter doesn't check for this,
- * so its behavior is dependent on the behavior of
- * the processor on which it's running. There are
- * processors on which it shifts all the bits out
- * and processors on which it does no shift.
+ * The BPF interpreter in libpcap does the same.
*/
if (b < 32)
a >>= b;
diff --git a/contrib/libpcap/pcap-bpf.c b/contrib/libpcap/pcap-bpf.c
--- a/contrib/libpcap/pcap-bpf.c
+++ b/contrib/libpcap/pcap-bpf.c
@@ -119,8 +119,14 @@
/*
* If both BIOCROTZBUF and BPF_BUFMODE_ZBUF are defined, we have
* zero-copy BPF.
+ *
+ * However, the current implementation of pcap_next_zbuf_shm() and
+ * pcap_ack_zbuf() is not compatible with QNX. Both FreeBSD and QNX implement
+ * atomic operations as C11 generic functions in <stdatomic.h>, FreeBSD
+ * implements additional FreeBSDisms in <machine/atomic.h> and QNX implements
+ * additional QNXisms in <atomic.h>. These two functions use FreeBSDisms.
*/
-#if defined(BIOCROTZBUF) && defined(BPF_BUFMODE_ZBUF)
+#if !defined(__QNX__) && defined(BIOCROTZBUF) && defined(BPF_BUFMODE_ZBUF)
#define HAVE_ZEROCOPY_BPF
#include <sys/mman.h>
#include <machine/atomic.h>
@@ -1372,7 +1378,8 @@
#endif
*/
if (pb->filtering_in_kernel ||
- pcapint_filter(p->fcode.bf_insns, datap, bhp->bh_datalen, caplen)) {
+ pcapint_filter(p->fcode.bf_insns, p->fcode.bf_len,
+ datap, bhp->bh_datalen, caplen)) {
struct pcap_pkthdr pkthdr;
#ifdef BIOCSTSTAMP
struct bintime bt;
diff --git a/contrib/libpcap/pcap-bt-linux.c b/contrib/libpcap/pcap-bt-linux.c
--- a/contrib/libpcap/pcap-bt-linux.c
+++ b/contrib/libpcap/pcap-bt-linux.c
@@ -396,7 +396,8 @@
pkth.caplen+=sizeof(pcap_bluetooth_h4_header);
pkth.len = pkth.caplen;
if (handle->fcode.bf_insns == NULL ||
- pcapint_filter(handle->fcode.bf_insns, pktd, pkth.len, pkth.caplen)) {
+ pcapint_filter(handle->fcode.bf_insns, handle->fcode.bf_len,
+ pktd, pkth.len, pkth.caplen)) {
callback(user, &pkth, pktd);
return 1;
}
diff --git a/contrib/libpcap/pcap-bt-monitor-linux.c b/contrib/libpcap/pcap-bt-monitor-linux.c
--- a/contrib/libpcap/pcap-bt-monitor-linux.c
+++ b/contrib/libpcap/pcap-bt-monitor-linux.c
@@ -153,7 +153,8 @@
bthdr->opcode = htons(hdr.opcode);
if (handle->fcode.bf_insns == NULL ||
- pcapint_filter(handle->fcode.bf_insns, pktd, pkth.len, pkth.caplen)) {
+ pcapint_filter(handle->fcode.bf_insns, handle->fcode.bf_len,
+ pktd, pkth.len, pkth.caplen)) {
callback(user, &pkth, pktd);
return 1;
}
diff --git a/contrib/libpcap/pcap-dag.c b/contrib/libpcap/pcap-dag.c
--- a/contrib/libpcap/pcap-dag.c
+++ b/contrib/libpcap/pcap-dag.c
@@ -662,12 +662,20 @@
} /* ERF encapsulation */
- if (caplen > p->snapshot)
- caplen = p->snapshot;
-
- /* Run the packet filter if there is one. */
- if ((p->fcode.bf_insns == NULL) || pcapint_filter(p->fcode.bf_insns, dp, packet_len, caplen)) {
-
+ /*
+ * In this libpcap module the two length arguments of
+ * pcapint_filter() (the wire length and the captured length)
+ * can have different values.
+ *
+ * The wire length of this packet is packet_len, which is
+ * derived from ERF wlen; the captured length of this packet
+ * is caplen, which is derived from ERF rlen, which in turn
+ * depends on the card/stream slen; the snapshot length
+ * configured for this pcap handle is p->snapshot.
+ */
+ if (p->fcode.bf_insns == NULL ||
+ pcapint_filter(p->fcode.bf_insns, p->fcode.bf_len,
+ dp, packet_len, caplen)) {
/* convert between timestamp formats */
register unsigned long long ts;
@@ -697,7 +705,7 @@
}
/* Fill in our own header data */
- pcap_header.caplen = caplen;
+ pcap_header.caplen = min(caplen, p->snapshot);
pcap_header.len = packet_len;
/* Count the packet. */
diff --git a/contrib/libpcap/pcap-dbus.c b/contrib/libpcap/pcap-dbus.c
--- a/contrib/libpcap/pcap-dbus.c
+++ b/contrib/libpcap/pcap-dbus.c
@@ -90,7 +90,8 @@
gettimeofday(&pkth.ts, NULL);
if (handle->fcode.bf_insns == NULL ||
- pcapint_filter(handle->fcode.bf_insns, (u_char *)raw_msg, pkth.len, pkth.caplen)) {
+ pcapint_filter(handle->fcode.bf_insns, handle->fcode.bf_len,
+ (u_char *)raw_msg, pkth.len, pkth.caplen)) {
handlep->packets_read++;
callback(user, &pkth, (u_char *)raw_msg);
count++;
diff --git a/contrib/libpcap/pcap-dpdk.c b/contrib/libpcap/pcap-dpdk.c
--- a/contrib/libpcap/pcap-dpdk.c
+++ b/contrib/libpcap/pcap-dpdk.c
@@ -405,7 +405,9 @@
}
if (bp){
- if (p->fcode.bf_insns==NULL || pcapint_filter(p->fcode.bf_insns, bp, pcap_header.len, pcap_header.caplen)){
+ if (p->fcode.bf_insns==NULL ||
+ pcapint_filter(p->fcode.bf_insns, p->fcode.bf_len,
+ bp, pcap_header.len, pcap_header.caplen)){
cb(cb_arg, &pcap_header, bp);
}else{
pd->bpf_drop++;
diff --git a/contrib/libpcap/pcap-filter.manmisc.in b/contrib/libpcap/pcap-filter.manmisc.in
--- a/contrib/libpcap/pcap-filter.manmisc.in
+++ b/contrib/libpcap/pcap-filter.manmisc.in
@@ -323,8 +323,7 @@
True if the packet is an IPv6 packet of protocol type \fIprotocol\fP.
(See `\fBip proto\fP' above for the meaning of \fIprotocol\fR.)
Note that the IPv6 variant of ICMP uses a different protocol number, named
-.B \%ipv6-icmp
-in AIX, FreeBSD, illumos, Linux, macOS, NetBSD, OpenBSD, Solaris and Windows.
+.BR \%ipv6-icmp .
Note that this primitive does not chase the protocol header chain.
.IP "\fBicmp6\fR"
Abbreviation for:
diff --git a/contrib/libpcap/pcap-haiku.c b/contrib/libpcap/pcap-haiku.c
--- a/contrib/libpcap/pcap-haiku.c
+++ b/contrib/libpcap/pcap-haiku.c
@@ -112,8 +112,8 @@
if (handle->fcode.bf_insns) {
// NB: pcapint_filter() takes the wire length and the captured
// length, not the snapshot length of the pcap_t handle.
- if (pcapint_filter(handle->fcode.bf_insns, buffer, wireLength,
- captureLength) == 0)
+ if (pcapint_filter(handle->fcode.bf_insns, handle->fcode.bf_len,
+ buffer, wireLength, captureLength) == 0)
goto drop;
}
diff --git a/contrib/libpcap/pcap-int.h b/contrib/libpcap/pcap-int.h
--- a/contrib/libpcap/pcap-int.h
+++ b/contrib/libpcap/pcap-int.h
@@ -579,18 +579,21 @@
* Filtering routine that takes the auxiliary data as an additional
* argument.
*/
-u_int pcapint_filter_with_aux_data(const struct bpf_insn *,
- const u_char *, u_int, u_int, const struct pcap_bpf_aux_data *);
+u_int pcapint_filter_with_aux_data(const struct bpf_insn *, const u_int,
+ const u_char *, const u_int, const u_int,
+ const struct pcap_bpf_aux_data *);
/*
* Filtering routine that doesn't.
*/
-u_int pcapint_filter(const struct bpf_insn *, const u_char *, u_int, u_int);
+u_int pcapint_filter(const struct bpf_insn *, const u_int, const u_char *,
+ u_int, u_int);
/*
* Routine to validate a BPF program.
*/
int pcapint_validate_filter(const struct bpf_insn *, int);
+uint8_t pcapint_valid_insn(const struct bpf_insn *);
/*
* Internal interfaces for both "pcap_create()" and routines that
diff --git a/contrib/libpcap/pcap-linux.c b/contrib/libpcap/pcap-linux.c
--- a/contrib/libpcap/pcap-linux.c
+++ b/contrib/libpcap/pcap-linux.c
@@ -4279,6 +4279,7 @@
aux_data.vlan_tag = tp_vlan_tci & 0x0fff;
if (pcapint_filter_with_aux_data(handle->fcode.bf_insns,
+ handle->fcode.bf_len,
bp,
tp_len,
snaplen,
diff --git a/contrib/libpcap/pcap-netfilter-linux.c b/contrib/libpcap/pcap-netfilter-linux.c
--- a/contrib/libpcap/pcap-netfilter-linux.c
+++ b/contrib/libpcap/pcap-netfilter-linux.c
@@ -257,8 +257,8 @@
gettimeofday(&pkth.ts, NULL);
if (handle->fcode.bf_insns == NULL ||
- pcapint_filter(handle->fcode.bf_insns, payload, pkth.len, pkth.caplen))
- {
+ pcapint_filter(handle->fcode.bf_insns, handle->fcode.bf_len,
+ payload, pkth.len, pkth.caplen)) {
handlep->packets_read++;
callback(user, &pkth, payload);
count++;
diff --git a/contrib/libpcap/pcap-netmap.c b/contrib/libpcap/pcap-netmap.c
--- a/contrib/libpcap/pcap-netmap.c
+++ b/contrib/libpcap/pcap-netmap.c
@@ -77,10 +77,19 @@
pcap_t *p = (pcap_t *)arg;
struct pcap_netmap *pn = p->priv;
const struct bpf_insn *pc = p->fcode.bf_insns;
+ u_int snaplen = (u_int)p->snapshot; /* guaranteed not to be negative */
++pn->rx_pkts;
- if (pc == NULL || pcapint_filter(pc, buf, h->len, h->caplen))
+ if (pc == NULL ||
+ (snaplen = pcapint_filter(pc, p->fcode.bf_len,
+ buf, h->len, h->caplen)) != 0) {
+ /*
+ * Trim the packet to the snapshot length.
+ */
+ if (h->caplen > snaplen)
+ h->caplen = snaplen;
pn->cb(pn->cb_arg, h, buf);
+ }
}
diff --git a/contrib/libpcap/pcap-npf.c b/contrib/libpcap/pcap-npf.c
--- a/contrib/libpcap/pcap-npf.c
+++ b/contrib/libpcap/pcap-npf.c
@@ -720,7 +720,8 @@
*/
if (pw->filtering_in_kernel ||
p->fcode.bf_insns == NULL ||
- pcapint_filter(p->fcode.bf_insns, datap, bhp->bh_datalen, caplen)) {
+ pcapint_filter(p->fcode.bf_insns, p->fcode.bf_len,
+ datap, bhp->bh_datalen, caplen)) {
#ifdef ENABLE_REMOTE
switch (p->rmt_samp.method) {
@@ -1922,7 +1923,8 @@
pcapint_fmt_errmsg_for_errno(ebuf, PCAP_ERRBUF_SIZE,
errno, "malloc");
pcap_close(p);
- return (NULL);
+ status = -1;
+ break;
}
p->tstamp_precision_list[0] = PCAP_TSTAMP_PRECISION_MICRO;
p->tstamp_precision_list[1] = PCAP_TSTAMP_PRECISION_NANO;
diff --git a/contrib/libpcap/pcap-rdmasniff.c b/contrib/libpcap/pcap-rdmasniff.c
--- a/contrib/libpcap/pcap-rdmasniff.c
+++ b/contrib/libpcap/pcap-rdmasniff.c
@@ -170,7 +170,8 @@
pktd = (u_char *) handle->buffer + wc.wr_id * RDMASNIFF_RECEIVE_SIZE;
if (handle->fcode.bf_insns == NULL ||
- pcapint_filter(handle->fcode.bf_insns, pktd, pkth.len, pkth.caplen)) {
+ pcapint_filter(handle->fcode.bf_insns, handle->fcode.bf_len,
+ pktd, pkth.len, pkth.caplen)) {
callback(user, &pkth, pktd);
++priv->packets_recv;
++count;
diff --git a/contrib/libpcap/pcap-rpcap.c b/contrib/libpcap/pcap-rpcap.c
--- a/contrib/libpcap/pcap-rpcap.c
+++ b/contrib/libpcap/pcap-rpcap.c
@@ -389,10 +389,9 @@
static int pcap_read_nocb_remote(pcap_t *p, struct pcap_pkthdr *pkt_header, u_char **pkt_data)
{
struct pcap_rpcap *pr = p->priv; /* structure used when doing a remote live capture */
- struct rpcap_header *header; /* general header according to the RPCAP format */
- struct rpcap_pkthdr *net_pkt_header; /* header of the packet, from the message */
+ struct rpcap_header *gen_header; /* rpcap general header */
+ struct rpcap_pkthdr *net_pkt_header; /* RPCAP_MSG_PACKET header */
u_char *net_pkt_data; /* packet data from the message */
- uint32 plen;
int retval = 0; /* generic return value */
int msglen;
@@ -449,13 +448,35 @@
return 0;
/*
- * We have to define 'header' as a pointer to a larger buffer,
- * because in case of UDP we have to read all the message within a single call
+ * pcap_startcapture_remote() has pointed p->buffer to a buffer large
+ * enough to contain all of the following data at once:
+ *
+ * - a fixed-size rpcap general header
+ * - a fixed-size RPCAP_MSG_PACKET header
+ * - p->snapshot worth of bytes of a captured packet
+ *
+ * This is sufficient for all code paths below.
*/
- header = (struct rpcap_header *) p->buffer;
+ gen_header = (struct rpcap_header *)p->buffer;
net_pkt_header = (struct rpcap_pkthdr *) ((char *)p->buffer + sizeof(struct rpcap_header));
net_pkt_data = (u_char *)p->buffer + sizeof(struct rpcap_header) + sizeof(struct rpcap_pkthdr);
+ /*
+ * Step 1: to receive a message that does not immediately look
+ * malformed, consider it as a fixed-size rpcap general header followed
+ * by a variable-size rpcap general payload and require:
+ *
+ * - a complete rpcap general header to land in the buffer, and
+ * - the header to declare an rpcap general payload length that fits
+ * in the buffer after the header, and
+ * - the complete declared payload to land in the buffer after the
+ * header.
+ *
+ * Since this step loosely corresponds to rpcap_process_msg_header(),
+ * which among other things converts rpcap_header.plen to host byte
+ * order, mimic that as well to produce a valid argument for
+ * rpcap_check_msg_ver() later on.
+ */
if (pr->rmt_flags & PCAP_OPENFLAG_DATATX_UDP)
{
/* Read the entire message from the network */
@@ -471,6 +492,8 @@
/* Interrupted receive. */
return 0;
}
+
+ // Require a complete rpcap general header to be present.
if ((size_t)msglen < sizeof(struct rpcap_header))
{
/*
@@ -480,8 +503,18 @@
"UDP packet message is shorter than an rpcap header");
return -1;
}
- plen = ntohl(header->plen);
- if ((size_t)msglen < sizeof(struct rpcap_header) + plen)
+ gen_header->plen = ntohl(gen_header->plen);
+
+ /*
+ * Validate the rpcap general payload length declared in the
+ * rpcap general header. Use subtraction to avoid an integer
+ * overflow:
+ *
+ * 0 <= gen_header->plen <= UINT32_MAX
+ * sizeof(struct rpcap_header) <= msglen <= p->bufsize
+ * p->bufsize is significantly less than UINT32_MAX
+ */
+ if (gen_header->plen > (size_t)msglen - sizeof(struct rpcap_header))
{
/*
* Message is shorter than the header claims it
@@ -496,6 +529,7 @@
{
int status;
+ // Receive a complete rpcap general header from the network.
if ((size_t)p->cc < sizeof(struct rpcap_header))
{
/*
@@ -515,27 +549,35 @@
return 0;
}
}
+ gen_header->plen = ntohl(gen_header->plen);
/*
- * We have the header, so we know how long the
- * message payload is. The size we should get
- * is the size of the packet header plus the
- * size of the payload.
+ * Validate the rpcap general payload length declared in the
+ * rpcap general header. Use subtraction to avoid an integer
+ * overflow:
+ *
+ * 0 <= gen_header->plen <= UINT32_MAX
+ * sizeof(struct rpcap_header) < p->bufsize
+ * p->bufsize is significantly less than UINT32_MAX
*/
- plen = ntohl(header->plen);
- if (plen > p->bufsize - sizeof(struct rpcap_header))
+ if (gen_header->plen > p->bufsize - sizeof(struct rpcap_header))
{
/*
* This is bigger than the largest
- * record we'd expect. (We do it by
- * subtracting in order to avoid an
- * overflow.)
+ * record we'd expect.
*/
snprintf(p->errbuf, PCAP_ERRBUF_SIZE,
"Server sent us a message larger than the largest expected packet message");
return -1;
}
- status = rpcap_read_packet_msg(pr, p, sizeof(struct rpcap_header) + plen);
+
+ /*
+ * Receive the declared rpcap general payload from the network.
+ *
+ * p->cc == sizeof(struct rpcap_header)
+ * p->bp == p->buffer + sizeof(struct rpcap_header)
+ */
+ status = rpcap_read_packet_msg(pr, p, sizeof(struct rpcap_header) + gen_header->plen);
if (status == -1)
{
/* Network error. */
@@ -558,27 +600,36 @@
/*
* We have the entire message.
- */
- header->plen = plen;
-
- /*
- * Did the server specify the version we negotiated?
+ * Step 2: to validate the received message further, require:
+ *
+ * - the rpcap general header to have the correct version and type, and
+ * - the rpcap general payload to be large enough to contain at least a
+ * complete RPCAP_MSG_PACKET header, and
+ * - the RPCAP_MSG_PACKET header to declare an RPCAP_MSG_PACKET payload
+ * (i.e. the captured packet) length that fits in the rpcap general
+ * payload (not the entire buffer) after the RPCAP_MSG_PACKET header.
*/
if (rpcap_check_msg_ver(pr->rmt_sockdata, pr->data_ssl, pr->protocol_version,
- header, p->errbuf) == -1)
- {
+ gen_header, p->errbuf) == -1)
+ return 0; /* Return 'no packets received' */
+ if (gen_header->type != RPCAP_MSG_PACKET)
return 0; /* Return 'no packets received' */
+ if (gen_header->plen < sizeof(struct rpcap_pkthdr))
+ {
+ snprintf(p->errbuf, PCAP_ERRBUF_SIZE,
+ "Received an incomplete RPCAP_MSG_PACKET header.");
+ return -1;
}
-
/*
- * Is this a RPCAP_MSG_PACKET message?
+ * Validate the RPCAP_MSG_PACKET payload length declared in the
+ * RPCAP_MSG_PACKET header. Use subtraction to avoid an integer
+ * overflow:
+ *
+ * 0 <= ntohl(net_pkt_header->caplen) <= UINT32_MAX
+ * sizeof(struct rpcap_pkthdr) <= gen_header->plen
+ * gen_header->plen is significantly less than UINT32_MAX
*/
- if (header->type != RPCAP_MSG_PACKET)
- {
- return 0; /* Return 'no packets received' */
- }
-
- if (ntohl(net_pkt_header->caplen) > plen)
+ if (ntohl(net_pkt_header->caplen) > gen_header->plen - sizeof(struct rpcap_pkthdr))
{
snprintf(p->errbuf, PCAP_ERRBUF_SIZE,
"Packet's captured data goes past the end of the received packet message.");
diff --git a/contrib/libpcap/pcap-snf.c b/contrib/libpcap/pcap-snf.c
--- a/contrib/libpcap/pcap-snf.c
+++ b/contrib/libpcap/pcap-snf.c
@@ -185,12 +185,22 @@
}
}
+ /*
+ * In this libpcap module the two length arguments of
+ * pcapint_filter() (the wire length and the captured length)
+ * are always equal because SNF captures full packets.
+ *
+ * The wire and the capture length of this packet is
+ * req.length, the snapshot length configured for this pcap
+ * handle is p->snapshot.
+ */
caplen = req.length;
if (caplen > p->snapshot)
caplen = p->snapshot;
if ((p->fcode.bf_insns == NULL) ||
- pcapint_filter(p->fcode.bf_insns, req.pkt_addr, req.length, caplen)) {
+ pcapint_filter(p->fcode.bf_insns, p->fcode.bf_len,
+ req.pkt_addr, req.length, req.length)) {
hdr.ts = snf_timestamp_to_timeval(req.timestamp, p->opt.tstamp_precision);
hdr.caplen = caplen;
hdr.len = req.length;
diff --git a/contrib/libpcap/pcap-usb-linux.c b/contrib/libpcap/pcap-usb-linux.c
--- a/contrib/libpcap/pcap-usb-linux.c
+++ b/contrib/libpcap/pcap-usb-linux.c
@@ -733,8 +733,8 @@
pkth.ts.tv_usec = info.hdr->ts_usec;
if (handle->fcode.bf_insns == NULL ||
- pcapint_filter(handle->fcode.bf_insns, handle->buffer,
- pkth.len, pkth.caplen)) {
+ pcapint_filter(handle->fcode.bf_insns, handle->fcode.bf_len,
+ handle->buffer, pkth.len, pkth.caplen)) {
handlep->packets_read++;
callback(user, &pkth, handle->buffer);
return 1;
@@ -921,8 +921,8 @@
pkth.ts.tv_usec = hdr->ts_usec;
if (handle->fcode.bf_insns == NULL ||
- pcapint_filter(handle->fcode.bf_insns, (u_char*) hdr,
- pkth.len, pkth.caplen)) {
+ pcapint_filter(handle->fcode.bf_insns, handle->fcode.bf_len,
+ (u_char*) hdr, pkth.len, pkth.caplen)) {
handlep->packets_read++;
callback(user, &pkth, (u_char*) hdr);
packets++;
diff --git a/contrib/libpcap/pcap.c b/contrib/libpcap/pcap.c
--- a/contrib/libpcap/pcap.c
+++ b/contrib/libpcap/pcap.c
@@ -4162,10 +4162,15 @@
void
pcapint_cleanup_live_common(pcap_t *p)
{
- if (p->opt.device != NULL) {
- free(p->opt.device);
- p->opt.device = NULL;
- }
+ /*
+ * This must not free p->opt.device; that must only be done
+ * in pcap_close(), as this might be cleaning up after a
+ * failed pcap_activate(), in which case p->opt.device must
+ * still be valid, in case further actions are done on the
+ * not-yet-activated pcap_t.
+ *
+ * See GitHub issue #1615.
+ */
if (p->buffer != NULL) {
free(p->buffer);
p->buffer = NULL;
@@ -4245,6 +4250,17 @@
pcap_close(pcap_t *p)
{
p->cleanup_op(p);
+
+ /*
+ * Free information set by pcap_create() *after* calling
+ * the module's cleanup routine; that routine might have
+ * to use p->opt.device (see commit
+ * e333a6044f7d2d3225a6a22205b6b7c1e389945f).
+ */
+ if (p->opt.device != NULL) {
+ free(p->opt.device);
+ p->opt.device = NULL;
+ }
free(p);
}
@@ -4349,7 +4365,7 @@
const struct bpf_insn *fcode = fp->bf_insns;
if (fcode != NULL)
- return (pcapint_filter(fcode, pkt, h->len, h->caplen));
+ return (pcapint_filter(fcode, fp->bf_len, pkt, h->len, h->caplen));
else
return (0);
}
diff --git a/contrib/libpcap/pcap/bpf.h b/contrib/libpcap/pcap/bpf.h
--- a/contrib/libpcap/pcap/bpf.h
+++ b/contrib/libpcap/pcap/bpf.h
@@ -282,6 +282,7 @@
#endif /* defined(__FreeBSD__) */
PCAP_AVAILABLE_0_4
+PCAP_DEPRECATED("use pcap_offline_filter()")
PCAP_API u_int bpf_filter(const struct bpf_insn *, const u_char *, u_int, u_int);
PCAP_AVAILABLE_0_6
diff --git a/contrib/libpcap/pcap_next_ex.3pcap b/contrib/libpcap/pcap_next_ex.3pcap
--- a/contrib/libpcap/pcap_next_ex.3pcap
+++ b/contrib/libpcap/pcap_next_ex.3pcap
@@ -17,7 +17,7 @@
.\" WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
.\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
.\"
-.TH PCAP_NEXT_EX 3PCAP "5 March 2022"
+.TH PCAP_NEXT_EX 3PCAP "26 March 2026"
.SH NAME
pcap_next_ex, pcap_next \- read the next packet from a pcap_t
.SH SYNOPSIS
@@ -122,7 +122,9 @@
.B PCAP_ERROR_BREAK
if packets
are being read from a ``savefile'' and there are no more packets to read
-from the savefile,
+from the savefile or if
+.BR pcap_breakloop (3PCAP)
+has been called,
.B PCAP_ERROR_NOT_ACTIVATED
if called on a capture handle that has been created but not activated,
or
diff --git a/contrib/libpcap/pcap_offline_filter.3pcap b/contrib/libpcap/pcap_offline_filter.3pcap
--- a/contrib/libpcap/pcap_offline_filter.3pcap
+++ b/contrib/libpcap/pcap_offline_filter.3pcap
@@ -17,7 +17,7 @@
.\" WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
.\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
.\"
-.TH PCAP_OFFLINE_FILTER 3PCAP "7 April 2014"
+.TH PCAP_OFFLINE_FILTER 3PCAP "12 March 2026"
.SH NAME
pcap_offline_filter \- check whether a filter matches a packet
.SH SYNOPSIS
@@ -45,10 +45,35 @@
structure for the packet, and
.I pkt
points to the data in the packet.
+.PP
+In the
+.B \%bpf_program
+structure the
+.B \%bf_insns
+member is either
+.B NULL
+(which means to reject all packets) or points to an array of one or more
+.B \%struct bpf_insn
+elements, in which case the
+.B \%bf_len
+member must be set to the number of elements (this is what
+.BR \%pcap_compile ()
+produces).
+.PP
+The filter program must have been compiled for a link-layer header type
+that matches the packet data; also on Linux the filter must not use
+BPF extensions, see
+.BR \%pcap_compile ()
+for more information.
.SH RETURN VALUE
.BR pcap_offline_filter ()
returns the return value of the filter program. This will be zero if
the packet doesn't match the filter and non-zero if the packet matches
the filter.
+.SH BACKWARD COMPATIBILITY
+.PP
+In libpcap releases before 1.10.7 this function ignored the provided
+.B \%bf_len
+value.
.SH SEE ALSO
.BR pcap (3PCAP)
diff --git a/contrib/libpcap/rpcapd/daemon.c b/contrib/libpcap/rpcapd/daemon.c
--- a/contrib/libpcap/rpcapd/daemon.c
+++ b/contrib/libpcap/rpcapd/daemon.c
@@ -2380,14 +2380,8 @@
{
status = rpcapd_recv(sockctrl, ctrl_ssl, (char *) &insn,
sizeof(struct rpcap_filterbpf_insn), plenp, errmsgbuf);
- if (status == -1)
- {
- return -1;
- }
- if (status == -2)
- {
- return -2;
- }
+ if (status == -1 || status == -2)
+ goto free_and_return_status;
bf_insn->code = ntohs(insn.code);
bf_insn->jf = insn.jf;
@@ -2402,17 +2396,20 @@
//
if (bpf_validate(bf_prog.bf_insns, bf_prog.bf_len) == 0)
{
- snprintf(errmsgbuf, PCAP_ERRBUF_SIZE, "The filter contains bogus instructions");
- return -2;
+ snprintf(errmsgbuf, PCAP_ERRBUF_SIZE, "The filter contains invalid instructions");
+ status = -2;
+ goto free_and_return_status;
}
if (pcap_setfilter(session->fp, &bf_prog))
{
snprintf(errmsgbuf, PCAP_ERRBUF_SIZE, "RPCAP error: %s", pcap_geterr(session->fp));
- return -2;
+ status = -2;
}
- return 0;
+free_and_return_status:
+ free(bf_prog.bf_insns);
+ return status;
}
static int
diff --git a/contrib/libpcap/savefile.c b/contrib/libpcap/savefile.c
--- a/contrib/libpcap/savefile.c
+++ b/contrib/libpcap/savefile.c
@@ -685,7 +685,8 @@
* and, if it passes, process it.
*/
if ((fcode = p->fcode.bf_insns) == NULL ||
- pcapint_filter(fcode, data, h.len, h.caplen)) {
+ pcapint_filter(fcode, p->fcode.bf_len,
+ data, h.len, h.caplen)) {
(*callback)(user, &h, data);
n++; /* count the packet */
if (n >= cnt)
diff --git a/contrib/libpcap/scanner.l b/contrib/libpcap/scanner.l
--- a/contrib/libpcap/scanner.l
+++ b/contrib/libpcap/scanner.l
@@ -402,7 +402,7 @@
hints.ai_family = AF_INET6;
hints.ai_flags = AI_NUMERICHOST;
if (getaddrinfo(yytext, NULL, &hints, &res)) {
- bpf_set_error(yyextra, "bogus IPv6 address %s", yytext);
+ bpf_set_error(yyextra, "invalid IPv6 address %s", yytext);
yylval->s = NULL;
} else {
freeaddrinfo(res);
@@ -414,7 +414,7 @@
#endif /*INET6*/
return HID6;
}
-{B}:+({B}:+)+ { bpf_set_error(yyextra, "bogus ethernet address %s", yytext); yylval->s = NULL; return EID; }
+{B}:+({B}:+)+ { bpf_set_error(yyextra, "invalid ethernet address %s", yytext); yylval->s = NULL; return EID; }
icmptype { yylval->h = 0; return NUM; }
icmpcode { yylval->h = 1; return NUM; }
icmp-echoreply { yylval->h = 0; return NUM; }
diff --git a/contrib/libpcap/testprogs/capturetest.c b/contrib/libpcap/testprogs/capturetest.c
--- a/contrib/libpcap/testprogs/capturetest.c
+++ b/contrib/libpcap/testprogs/capturetest.c
@@ -86,7 +86,14 @@
* We do have UN*X-style signals (we assume that "not Windows" means "UN*X").
*/
#define B_OPTION "b"
+
+#ifdef SA_RESTART
#define R_OPTION "r"
+#else
+// QNX 8.0 neither defines not supports SA_RESTART.
+#define R_OPTION ""
+#endif // SA_RESTART
+
#define S_OPTION "s"
#endif
@@ -104,7 +111,9 @@
int immediate = 0;
int nonblock = 0;
#ifndef _WIN32
+#ifdef SA_RESTART
int sigrestart = 0;
+#endif // SA_RESTART
int catchsigint = 0;
#endif
pcap_if_t *devlist;
@@ -143,9 +152,11 @@
break;
#ifndef _WIN32
+#ifdef SA_RESTART
case 'r':
sigrestart = 1;
break;
+#endif // SA_RESTART
case 's':
catchsigint = 1;
@@ -200,7 +211,11 @@
/*
* Should SIGINT interrupt, or restart, system calls?
*/
+#ifdef SA_RESTART
action.sa_flags = sigrestart ? SA_RESTART : 0;
+#else
+ action.sa_flags = 0;
+#endif // SA_RESTART
if (sigaction(SIGINT, &action, NULL) == -1)
error("Can't catch SIGINT: %s\n",
diff --git a/contrib/libpcap/testprogs/findalldevstest.supp b/contrib/libpcap/testprogs/findalldevstest.supp
new file mode 100644
--- /dev/null
+++ b/contrib/libpcap/testprogs/findalldevstest.supp
@@ -0,0 +1,28 @@
+{
+ ignore_leak_1
+ Memcheck:Leak
+ match-leak-kinds: possible
+ fun:calloc
+ obj:/usr/lib/aarch64-linux-gnu/libmlx5.so*
+ obj:/usr/lib/aarch64-linux-gnu/libibverbs.so*
+ obj:/usr/lib/aarch64-linux-gnu/libibverbs.so*
+ fun:ibv_get_device_list
+ fun:rdmasniff_findalldevs
+ fun:pcap_findalldevs
+ fun:main
+}
+
+{
+ ignore_leak_2
+ Memcheck:Leak
+ match-leak-kinds: possible
+ fun:calloc
+ obj:/usr/lib/aarch64-linux-gnu/libibverbs.so*
+ fun:nl_recvmsgs_report
+ fun:nl_recvmsgs
+ obj:/usr/lib/aarch64-linux-gnu/libibverbs.so*
+ fun:ibv_get_device_list
+ fun:rdmasniff_findalldevs
+ fun:pcap_findalldevs
+ fun:main
+}
diff --git a/contrib/libpcap/testprogs/valgrindtest.c b/contrib/libpcap/testprogs/valgrindtest.c
--- a/contrib/libpcap/testprogs/valgrindtest.c
+++ b/contrib/libpcap/testprogs/valgrindtest.c
@@ -20,6 +20,7 @@
*/
#include "varattrs.h"
+#include "diag-control.h"
/*
* This doesn't actually test libpcap itself; it tests whether
@@ -404,8 +405,15 @@
#if defined(USE_BPF)
ioctl(pcap_fd, BIOCSETF, &bad_fcode);
#elif defined(USE_SOCKET_FILTERS)
+ /*
+ * The point of this test is not to initialize bad_fcode, as we're
+ * testing to make sure that valgrind will complain that the structure
+ * isn't initialized.
+ */
+DIAG_OFF_UNINITIALIZED_CONST_POINTER
setsockopt(pcap_fd, SOL_SOCKET, SO_ATTACH_FILTER, &bad_fcode,
sizeof(bad_fcode));
+DIAG_ON_UNINITIALIZED_CONST_POINTER
#endif
/*
diff --git a/lib/libpcap/config.h b/lib/libpcap/config.h
--- a/lib/libpcap/config.h
+++ b/lib/libpcap/config.h
@@ -295,7 +295,7 @@
#define PACKAGE_NAME "pcap"
/* Define to the full name and version of this package. */
-#define PACKAGE_STRING "pcap 1.10.6"
+#define PACKAGE_STRING "pcap 1.10.7"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "pcap"
@@ -304,7 +304,7 @@
#define PACKAGE_URL ""
/* Define to the version of this package. */
-#define PACKAGE_VERSION "1.10.6"
+#define PACKAGE_VERSION "1.10.7"
/* target host supports Bluetooth sniffing */
/* #undef PCAP_SUPPORT_BT */

File Metadata

Mime Type
text/plain
Expires
Sun, Nov 29, 1:51 AM (13 h, 56 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
42080670
Default Alt Text
D62079.1795917106.diff (215 KB)

Event Timeline