X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=configure;h=7ebe23714b2cff550c1fd49569953a4204da32d0;hb=766ef68519f7fc333476baf8a6d8914af9024612;hp=4677eed252fceabce6d4360247988f51872fe343;hpb=947731d705fc00c4ef66c8eba19e460055b3e94a;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/configure b/configure index 4677eed25..7ebe23714 100755 --- a/configure +++ b/configure @@ -30,6 +30,7 @@ $config{MAXI_MODES} = "20"; # Default Max. $config{HAS_STRLCPY} = "false"; # strlcpy Check. $config{USE_KQUEUE} = "y"; # kqueue enabled $config{USE_EPOLL} = "y"; # epoll enabled +$config{THREADED_DNS} = "n"; # threaded dns (experimental) $config{STATIC_LINK} = "no"; # are doing static modules? chomp($config{MAX_CLIENT_T} = `sh -c \"ulimit -n\"`); # FD Limit chomp($config{GCCVER} = `gcc -dumpversion | cut -c 1`); # Major GCC Version @@ -250,6 +251,9 @@ if (!$chose_hiperf) print "not to enable one. Defaulting to select() engine.\n\n"; } +yesno(THREADED_DNS,"Would you like to enable the experimental multi-threaded DNS lookup?"); +print "\n"; + print "\nThe following questions will ask you for various figures relating\n"; print "To your IRCd install. Please note that these should usually be left\n"; print "as defaults unless you have a real reason to change them. If they\n"; @@ -497,7 +501,8 @@ print "\033[0mMax away length:\033[1;32m\t\t$config{MAX_AWAY}\n"; print "\033[0mGCC Version Found:\033[1;32m\t\t$config{GCCVER}.$config{GCC34}\n"; print "\033[0mOptimatizaton Flag:\033[1;32m\t\t$config{OPTIMISATI}\033[0m\n"; print "\033[0mCompiler program:\033[1;32m\t\t$config{CC}\033[0m\n"; -print "\033[0mStatic modules:\033[1;32m\t\t\t$config{STATIC_LINK}\033[0m\n\n"; +print "\033[0mStatic modules:\033[1;32m\t\t\t$config{STATIC_LINK}\033[0m\n"; +print "\033[0mMultithread DNS:\033[1;32m\t\t$config{THREADED_DNS}\033[0m\n\n"; makecache(); writefiles(); @@ -734,6 +739,9 @@ EOF if ($config{HAS_STRLCPY} eq "true") { print FILEHANDLE "#define HAS_STRLCPY\n"; } + if ($config{THREADED_DNS} =~ /y/i) { + print FILEHANDLE "#define THREADED_DNS\n"; + } my $use_hiperf = 0; if (($has_kqueue) && ($config{USE_KQUEUE} eq "y")) { print FILEHANDLE "#define USE_KQUEUE\n"; @@ -775,6 +783,9 @@ EOF } opendir(DIRHANDLE, $this); + if ($config{THREADED_DNS} =~ /y/i) { + $config{LDLIBS} = $config{LDLIBS} . " -pthread"; + } foreach $name (sort readdir(DIRHANDLE)) { if ($name =~ /^\.(.+)\.inc$/) { @@ -887,7 +898,7 @@ EOENT m_$i.so: m_$i.cpp ../../include/modules.h ../../include/users.h ../../include/channels.h ../../include/base.h \$(CC) -pipe -I../../include \$(FLAGS) $flags -export-dynamic -c m_$i.cpp \$(CC) \$(FLAGS) -shared $flags -o m_$i.so m_$i.o - @-rm -f \$(MODPATH)/m_$i.so + \@-rm -f \$(MODPATH)/m_$i.so cp m_$i.so \$(MODPATH)/ chmod 0700 \$(MODPATH)/m_$i.so