In C++11 `linux` is not a reserved word, so compilators do not define it.
A correct way to check if we are compiling for linux is to check for
`__linux__`.
There is no more integrated build of dependencies in the build system.
Dependencies are discovered using pkg-config except for ctpp2 where there
is no pkg-config file.
On Mac OS X the ioctl(SIOCGIFCONF) call will return all IPv4, IPv6
and MAC addresses, so we have to filter only the ones that have
sa_family equal to AF_INET.
I also added the common interface names for Mac OS X (en0 and en1),
to the getBestPublicIp() function. I refactored a bit the code so
that addition and reordering are easier.
Bugs: https://sourceforge.net/p/kiwix/bugs/658/