]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - configure
Merge buildsystem tweaks from darix:
[user/henk/code/inspircd.git] / configure
index 5e598074da3c0d445e9baa34597ac50cdf4bf64e..ea47dd721ac1b4a4b2dabc2148fdbdaf93175919 100755 (executable)
--- a/configure
+++ b/configure
@@ -2,7 +2,7 @@
 
 # InspIRCd Configuration Script
 #
-# Copyright 2002-2006 The ChatSpike Development Team
+# Copyright 2002-2007 The ChatSpike Development Team
 # <brain@chatspike.net>
 # <Craig@chatspike.net>
 #
@@ -14,6 +14,7 @@
 
 
 require 5.6.0;
+use Socket;
 use Cwd;
 use Getopt::Long;
 
@@ -25,7 +26,7 @@ GetOptions (
        'with-channel-length=i' => \$opt_chan_length,
        'with-max-channels=i' => \$opt_maxchans,
        'with-max-oper-channels=i' => \$opt_opermaxchans,
-       'with-max-clients' => \$opt_maxclients,
+       'with-max-clients=i' => \$opt_maxclients,
        'enable-epoll' => \$opt_epoll,
        'enable-kqueue' => \$opt_kqueue,
        'disable-epoll' => \$opt_noepoll,
@@ -209,6 +210,7 @@ $config{STATIC_LINK}            = "no";                                             # are doing static modules?
 chomp($config{MAX_CLIENT_T} = `sh -c \"ulimit -n\"`);                          # FD Limit
 chomp($config{MAX_DESCRIPTORS} = `sh -c \"ulimit -n\"`);                       # Hard FD Limit
 chomp($config{GCCVER}       = `g++ -dumpversion | cut -c 1`);                  # Major GCC Version
+$config{_SOMAXCONN} = SOMAXCONN;                                               # Max connections in accept queue
 $config{OSNAME}            = $^O;                                              # Operating System Name
 $config{CC}                = "g++";                                            # C++ compiler
 if (defined $opt_cc)
@@ -1190,6 +1192,8 @@ sub writefiles {
 #define VERSION "$version"
 #define REVISION "$revision2"
 #define MAXCLIENTS $config{MAX_CLIENT}
+#define MAXCLIENTS_S "$config{MAX_CLIENT}"
+#define SOMAXCONN_S "$config{_SOMAXCONN}"
 #define MAX_DESCRIPTORS $config{MAX_DESCRIPTORS}
 #define NICKMAX $NL
 #define CHANMAX $CL
@@ -1563,7 +1567,7 @@ m_$i.so: m_$i.cpp ../../include/modules.h ../../include/users.h ../../include/ch
        \$(CC) -pipe \$(FLAGS) -shared $liflags -o m_$i.so m_$i.o $extra
 
 EOCHEESE
-       $crud = $crud . "       install -m 0700 m_$i.so \$(MODPATH)\n";
+       $crud = $crud . "       install -m \$(INSTMODE) m_$i.so \$(MODPATH)\n";
 ###
        # End Write Entry to the MakeFile
        ###