On 10 May 2001 oliver.kowalke@t-online.de wrote: > maybe my first email doesn't exactly describe my problem. > I'd like to test in the source code for some #ifdef's regarding to > IPv4/IPv6/UNIXDomain. > In the book 'UNIX Network Programming. Vol.1' from R.W.Stevens I can > see something like > > #ifdef IPV4 > #ifdef IPV6 > #ifdef UNIXdomain > #ifdef HAVE_SOCK_SA_LEN (couldn't remember exactly) > ... > > The constants should indicate the support from linux. > If I test this macros in my code on linux - it seems they are not > defined. > Where can I find this things? These kind of options don't just automatically get defined. Headers you're including have no way of knowing whether e.g. IPV6 is actually enabled or not. Either you must do it with a test like I mentioned, trying to e.g. use AF_INET6 address family, or run other kind of tests. Tests often defined in GNU Autoconf when creating portable projects. Check out some source code in applications using IPv6, e.g. OpenSSH for ideas. -- Pekka Savola "Tell me of difficulties surmounted, Netcore Oy not those you stumble over and fall" Systems. Networks. Security. -- Robert Jordan: A Crown of Swords - : send the line "unsubscribe linux-net" in the body of a message to majordomo@vger.kernel.org