iptables: correctly reference generated file

Since (14bca55 iptables: use autoconf to process .in man pages),
the file "iptables-extensions.8.tmpl" is generated from
"iptables-extensions.8.tmpl.in" and is consequently no
longer found in ${srcdir} but in the build directory.
(Becomes visible with builddir != srcdir)

Signed-off-by: Lutz Jaenicke <ljaenicke@innominate.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
android: libiptc: Fix socklen_t type mismatch on Android

Bionic defines socklen_t as a signed int, so redefining it as unsigned
breaks the build.

This change comes from AOSP.

Signed-off-by: Kevin Cernekee <cernekee@gmail.com>
android: Don't include conflicting headers

<netinet/ip.h> and <linux/ip.h> redefine a couple of structs, including
iphdr.  Handle this the same way as on glibc, i.e. don't include
<linux/ip.h>.

This change comes from AOSP.

Signed-off-by: Kevin Cernekee <cernekee@gmail.com>
android: build: Blacklist TCPOPTSTRIP on systems that lack TCPOPT_*

Bionic's <netinet/tcp.h> is missing constants needed to build this module,
so have autoconf check for this condition before trying to build it.

Signed-off-by: Kevin Cernekee <cernekee@gmail.com>
Modify iptables to talk to xt_IDLETIMER version 1.

Change-Id: Ib144c5289681cdff21b21be74173164d097710e7
ignore SIGPIPES

During bugreports mostly, when adb goes away it leads to apps crashing
because their output stream got closed.
Let's just ignore it.

Bug: 6447319
Change-Id: I1b293ebef737014162edebd5fd9bf254345b2ce8
android: Import latest libxt_quota2 code from AOSP 4.2.2

Signed-off-by: Kevin Cernekee <cernekee@gmail.com>
android: Work around broken Bionic getaddrinfo()

The first argument to getaddrifo(), "hostname", is normally allowed
to be NULL.  However, some Bionic implementations erroneously call
strlen() on this parameter without first checking to see if it is
NULL.  Work around this by passing in a hostname of "0.0.0.0".

This problem was seen on the HTC One SV stock ROM, JB 4.1.2.

Signed-off-by: Kevin Cernekee <cernekee@gmail.com>