Kaynağa Gözat

* Initial working commit with .deps support
Still need to make ./configure GENERATE:
*/.deps/
*/.deps/includes (derived from misc places)
*/.deps/*.Po (just blank files that are included in .deps/includes)
* Renamed bootstrap/ to autotools/


svn: 609

Bryan Drewery 22 yıl önce
ebeveyn
işleme
9ae6852437

+ 30 - 0
autotools/Makefile

@@ -0,0 +1,30 @@
+
+all: clean autoconf autoheader clean_again
+
+autoconf: 
+	@rm -rf ../configure
+	@echo "Autoconf...."
+	@autoconf
+	@echo "Fixing configure for cache_file"
+	@(if ! sed configure -e "s/^cache_file=\/dev\/null/cache_file=\.\/config.cache/" \
+	-e "s/&& echo \"updating cache .cache_file\"//" > ../configure; then \
+	cp configure ../configure; \
+	rm configure; \
+	fi)
+	@chmod 700 ../configure
+	@ls -al ../configure
+
+autoheader:
+	@rm -rf ../config.h.in
+	@echo "Autoheader..."
+	@autoheader
+	@mv -f config.h.in ../config.h.in
+	@ls -al ../config.h.in
+
+clean:
+	@echo "Cleaning..."
+	@rm -rf autom4te.cache/ configure config.h.in
+
+clean_again:
+	@echo "Cleaning..."
+	@rm -rf autom4te.cache/ configure config.h.in

+ 6 - 0
autotools/README

@@ -0,0 +1,6 @@
+Type 'make' whenever one of these conditions are met:
+
+- Any files in bootstrap/ are modified.
+- Any files are added or removed in src/
+- Any files change their dependancies (#include "file.h")
+

+ 1218 - 0
autotools/aclocal.m4

@@ -0,0 +1,1218 @@
+dnl aclocal.m4
+dnl   macros autoconf uses when building configure from configure.in
+dnl
+dnl
+
+dnl  EGG_CHECK_CC()
+dnl
+dnl  FIXME: make a better test
+dnl
+AC_DEFUN(EGG_CHECK_CC, [dnl
+if test "${cross_compiling-x}" = "x"
+then
+  cat << 'EOF' >&2
+configure: error:
+
+  This system does not appear to have a working C compiler.
+  A working C compiler is required to compile Eggdrop.
+
+EOF
+  exit 1
+fi
+])dnl
+
+dnl  EGG_IPV6_OPTIONS()
+dnl
+AC_DEFUN(EGG_IPV6_OPTIONS, [dnl
+AC_MSG_CHECKING(whether or not you disabled IPv6 support)
+AC_ARG_ENABLE(ipv6, [  --disable-ipv6           disable IPv6 support],
+[ ac_cv_dipv6="yes"
+  AC_MSG_RESULT(yes)
+],
+[ ac_cv_dipv6="no"
+  if test "$egg_cv_ipv6_supported" = "no"; then
+    ac_cv_dipv6="no"
+  fi
+  AC_MSG_RESULT($ac_cv_dipv6)
+])
+if test "$ac_cv_dipv6" = "no"; then
+  AC_DEFINE(USE_IPV6, 1, [Define if you want ipv6 support])
+fi
+])dnl
+
+
+dnl  EGG_CHECK_SOCKLEN_T()
+dnl
+AC_DEFUN(EGG_CHECK_SOCKLEN_T, [dnl
+AC_MSG_CHECKING(for socklen_t)
+AC_CACHE_VAL(egg_cv_socklen_t,[
+  AC_TRY_RUN([
+#include <unistd.h>
+#include <sys/types.h>
+#include <sys/socket.h>
+#include <netinet/in.h>
+#include <arpa/inet.h>
+
+int main()
+{
+  socklen_t test = sizeof(int);
+
+  return 0;
+}
+  ],
+egg_cv_socklen_t=yes, egg_cv_socklen_t=no, egg_cv_socklen_t=no)])
+if test "$egg_cv_socklen_t" = "yes"; then
+  AC_DEFINE(HAVE_SOCKLEN_T, 1, [Define if you have support for socklen_t])
+  AC_MSG_RESULT(yes)
+else
+  AC_MSG_RESULT(no)
+fi
+])dnl
+
+
+dnl  EGG_CHECK_CCPIPE()
+dnl
+dnl  Checks whether the compiler supports the `-pipe' flag, which
+dnl  speeds up the compilation.
+AC_DEFUN(EGG_CHECK_CCPIPE, [dnl
+if test -z "$no_pipe"
+then
+  if test -n "$GCC"
+  then
+    AC_CACHE_CHECK(whether the compiler understands -pipe, egg_cv_var_ccpipe, [dnl
+      ac_old_CC="$CC"
+      CC="$CC -pipe"
+      AC_TRY_COMPILE(,, egg_cv_var_ccpipe="yes", egg_cv_var_ccpipe="no")
+      CC="$ac_old_CC"
+    ])
+    if test "$egg_cv_var_ccpipe" = "yes"
+    then
+      CC="$CC -pipe"
+    fi
+  fi
+fi
+])dnl
+
+dnl  EGG_CHECK_CCSTATIC()
+dnl
+dnl  Checks whether the compiler supports the `-static' flag.
+AC_DEFUN(EGG_CHECK_CCSTATIC, [dnl
+if test -z "$no_static"
+then
+  if test -n "$GCC"
+  then
+    AC_CACHE_CHECK(whether the compiler understands -static, egg_cv_var_ccstatic, [dnl
+      ac_old_CC="$CC"
+      CC="$CC -static"
+      AC_TRY_COMPILE(,, egg_cv_var_ccstatic="yes", egg_cv_var_ccstatic="no")
+      CC="$ac_old_CC"
+    ])
+    if test "$egg_cv_var_ccstatic" = "yes"
+    then
+      CC="$CC -static"
+    else
+      cat << 'EOF' >&2
+configure: error:
+
+  Your C compiler does not support -static.
+  This compile flag is required for the botpack.
+
+EOF
+  exit 1
+    fi
+  fi
+fi
+])dnl
+
+dnl EGG_PROG_HEAD_1()
+dnl
+AC_DEFUN(EGG_PROG_HEAD_1,
+[cat << 'EOF' > conftest.head
+a
+b
+c
+EOF
+
+for ac_prog in 'head -1' 'head -n 1' 'sed 1q';
+do
+  AC_MSG_CHECKING([whether $ac_prog works])
+  AC_CACHE_VAL(ac_cv_prog_HEAD_1,
+[  if test -n "$HEAD_1"
+  then
+    ac_cv_prog_HEAD_1="$HEAD_1" # Let the user override the test.
+  else
+   if test "`cat conftest.head | $ac_prog`" = "a";
+   then
+     AC_MSG_RESULT([yes])
+     ac_cv_prog_HEAD_1=$ac_prog
+   else
+     AC_MSG_RESULT([no])
+   fi
+  fi])dnl
+  test -n "$ac_cv_prog_HEAD_1" && break
+done
+
+if test "${ac_cv_prog_HEAD_1-x}" = "x"
+then
+  cat << 'EOF' >&2
+configure: error:
+
+  This system seems to lack a working 'head -1' or 'head -n 1' command.
+  A working 'head -1' (or equivalent) command is required to compile Eggdrop.
+
+EOF
+  exit 1
+fi
+
+rm -f conftest.head
+HEAD_1=$ac_cv_prog_HEAD_1
+AC_SUBST(HEAD_1)dnl
+])dnl
+
+
+
+dnl  EGG_PROG_STRIP()
+dnl
+AC_DEFUN(EGG_PROG_STRIP, [dnl
+AC_CHECK_PROG(STRIP, strip, strip)
+if test "${STRIP-x}" = "x"
+then
+  STRIP=touch
+fi
+])dnl
+
+
+dnl  EGG_PROG_AWK()
+dnl
+AC_DEFUN(EGG_PROG_AWK, [dnl
+# awk is needed for Tcl library and header checks, and eggdrop version subst
+AC_PROG_AWK
+if test "${AWK-x}" = "x"
+then
+  cat << 'EOF' >&2
+configure: error:
+
+  This system seems to lack a working 'awk' command.
+  A working 'awk' command is required to compile Eggdrop.
+
+EOF
+  exit 1
+fi
+])dnl
+
+
+dnl  EGG_PROG_BASENAME()
+dnl
+AC_DEFUN(EGG_PROG_BASENAME, [dnl
+# basename is needed for Tcl library and header checks
+AC_CHECK_PROG(BASENAME, basename, basename)
+if test "${BASENAME-x}" = "x"
+then
+  cat << 'EOF' >&2
+configure: error:
+
+  This system seems to lack a working 'basename' command.
+  A working 'basename' command is required to compile Eggdrop.
+
+EOF
+  exit 1
+fi
+])dnl
+
+
+dnl  EGG_CHECK_OS()
+dnl
+dnl  FIXME/NOTICE:
+dnl    This function is obsolete. Any NEW code/checks should be written
+dnl    as individual tests that will be checked on ALL operating systems.
+dnl
+AC_DEFUN(EGG_CHECK_OS, [dnl
+LINUX=no
+IRIX=no
+SUNOS=no
+HPUX=no
+EGG_CYGWIN=no
+
+AC_CACHE_CHECK(system type, egg_cv_var_system_type, egg_cv_var_system_type=`$UNAME -s`)
+AC_CACHE_CHECK(system release, egg_cv_var_system_release, egg_cv_var_system_release=`$UNAME -r`)
+
+case "$egg_cv_var_system_type" in
+  BSD/OS)
+    case "`echo $egg_cv_var_system_release | cut -d . -f 1`" in
+      2)
+      ;;
+      *)
+        CFLAGS="$CFLAGS -Wall"
+      ;;
+    esac
+  ;;
+  CYGWI*)
+    case "`echo $egg_cv_var_system_release | cut -c 1-3`" in
+      1.*)
+        AC_PROG_CC_WIN32
+        CC="$CC $WIN32FLAGS"
+        AC_MSG_CHECKING(for /usr/lib/binmode.o)
+        if test -r /usr/lib/binmode.o
+        then
+          AC_MSG_RESULT(yes)
+          LIBS="$LIBS /usr/lib/binmode.o"
+        else
+          AC_MSG_RESULT(no)
+          AC_MSG_WARN(Make sure the directory Eggdrop is installed into is mounted in binary mode.)
+        fi
+      ;;
+      *)
+        AC_MSG_WARN(Make sure the directory Eggdrop is installed into is mounted in binary mode.)
+      ;;
+    esac
+    EGG_CYGWIN=yes
+    AC_DEFINE(CYGWIN_HACKS, 1, [Define if running under cygwin])
+  ;;
+  HP-UX)
+    HPUX=yes
+    AC_DEFINE(HPUX_HACKS, 1, [Define if running on hpux that supports dynamic linking])dnl
+    if test "`echo $egg_cv_var_system_release | cut -d . -f 2`" = "10"
+    then
+      AC_DEFINE(HPUX10_HACKS, 1, [Define if running on hpux 10.x])dnl
+    fi
+  ;;
+  dell)
+    AC_MSG_RESULT(Dell SVR4)
+  ;;
+  IRIX)
+    IRIX=yes
+  ;;
+  Ultrix)
+    SHELL=/bin/sh5
+  ;;
+  SINIX*)
+  ;;
+  BeOS)
+  ;;
+  Linux)
+    LINUX=yes
+    CFLAGS="$CFLAGS -Wall"
+  ;;
+  Lynx)
+  ;;
+  QNX)
+  ;;
+  OSF1)
+    case "`echo $egg_cv_var_system_release | cut -d . -f 1`" in
+      V*)
+        # FIXME: we should check this in a separate test
+        # Digital OSF uses an ancient version of gawk
+        if test "$AWK" = "gawk"
+        then
+          AWK=awk
+        fi
+      ;;
+      1.0|1.1|1.2)
+        AC_DEFINE(OSF1_HACKS, 1, [Define if running on OSF/1 platform])dnl
+      ;;
+      1.*)
+        AC_DEFINE(OSF1_HACKS, 1, [Define if running on OSF/1 platform])dnl
+      ;;
+      *)
+      ;;
+    esac
+    AC_DEFINE(STOP_UAC, 1, [Define if running on OSF/1 platform])dnl
+    AC_DEFINE(BROKEN_SNPRINTF, 1, [Define to use Eggdrop's snprintf functions without regard to HAVE_SNPRINTF])dnl
+  ;;
+  SunOS)
+    if ! test "`echo $egg_cv_var_system_release | cut -d . -f 1`" = "5"
+      then
+      # SunOS 4
+      SUNOS=yes
+    fi
+  ;;
+  *BSD)
+    # FreeBSD/OpenBSD/NetBSD
+  ;;
+  *)
+    AC_MSG_CHECKING(if system is Mach based)
+    if test -r /mach
+    then
+      AC_MSG_RESULT(yes)
+      AC_DEFINE(BORGCUBES, 1, [Define if running on NeXT Step])dnl
+    else
+      AC_MSG_RESULT(no)
+      AC_MSG_CHECKING(if system is QNX)
+      if test -r /cmds
+      then
+        AC_MSG_RESULT(yes)
+      else
+        AC_MSG_RESULT(no)
+        AC_MSG_RESULT(Something unknown!)
+        AC_MSG_RESULT([If you get dynamic modules to work, be sure to let the devel team know HOW :)])
+      fi
+    fi
+  ;;
+esac
+])dnl
+
+
+dnl  EGG_CHECK_LIBS()
+dnl
+AC_DEFUN(EGG_CHECK_LIBS, [dnl
+# FIXME: this needs to be fixed so that it works on IRIX
+if test "$IRIX" = "yes"
+then
+  AC_MSG_WARN(Skipping library tests because they CONFUSE Irix.)
+else
+  AC_CHECK_LIB(socket, socket)
+  AC_CHECK_LIB(nsl, connect)
+  AC_CHECK_LIB(dns, gethostbyname)
+  AC_CHECK_LIB(z, gzopen, ZLIB="-lz")
+  AC_CHECK_LIB(ssl, SSL_accept, SSL="-lssl -lcrypto", SSL="", -lcrypto) 
+  AC_CHECK_LIB(dl, dlopen)
+  AC_CHECK_LIB(m, tan, EGG_MATH_LIB="-lm")
+  # This is needed for Tcl libraries compiled with thread support
+  AC_CHECK_LIB(pthread, pthread_mutex_init, [dnl
+  ac_cv_lib_pthread_pthread_mutex_init=yes
+  ac_cv_lib_pthread="-lpthread"], [dnl
+    AC_CHECK_LIB(pthread, __pthread_mutex_init, [dnl
+    ac_cv_lib_pthread_pthread_mutex_init=yes
+    ac_cv_lib_pthread="-lpthread"], [dnl
+      AC_CHECK_LIB(pthreads, pthread_mutex_init, [dnl
+      ac_cv_lib_pthread_pthread_mutex_init=yes
+      ac_cv_lib_pthread="-lpthreads"], [dnl
+        AC_CHECK_FUNC(pthread_mutex_init, [dnl
+        ac_cv_lib_pthread_pthread_mutex_init=yes
+        ac_cv_lib_pthread=""],
+        ac_cv_lib_pthread_pthread_mutex_init=no)])])])
+  if test "$SUNOS" = "yes"
+  then
+    # For suns without yp or something like that
+    AC_CHECK_LIB(dl, main)
+  else
+    if test "$HPUX" = "yes"
+    then
+      AC_CHECK_LIB(dld, shl_load)
+    fi
+  fi
+fi
+])dnl
+
+dnl  EGG_CHECK_FUNC_VSPRINTF()
+dnl
+AC_DEFUN(EGG_CHECK_FUNC_VSPRINTF, [dnl
+AC_CHECK_FUNCS(vsprintf)
+if test "$ac_cv_func_vsprintf" = "no"
+then
+  cat << 'EOF' >&2
+configure: error:
+
+  Your system does not have the sprintf/vsprintf libraries.
+  These are required to compile almost anything.  Sorry.
+
+EOF
+  exit 1
+fi
+])dnl
+
+dnl  EGG_CHECK_FUNC_UNAME()
+dnl
+AC_DEFUN(EGG_CHECK_FUNC_UNAME, [dnl
+AC_CHECK_FUNCS(uname)
+if test "$ac_cv_func_uname" = "no"
+then
+  cat << 'EOF' >&2
+configure: error:
+
+  Your system does not have the uname() function.
+  This is required for the botpack.
+
+EOF
+  exit 1
+fi
+])dnl
+
+dnl  EGG_CHECK_ZLIB()
+dnl
+AC_DEFUN(EGG_CHECK_ZLIB, [dnl
+if test "x${ZLIB}" = x; then
+  cat >&2 <<EOF
+configure: error:
+
+  Your system does not provide a working zlib compression library. 
+  It is required.
+
+EOF
+  exit 1
+else
+  if test "${ac_cv_header_zlib_h}" != yes; then
+    cat >&2 <<EOF
+configure: error:
+
+  Your system does not provide the necessary zlib header file. 
+  It is required.
+
+EOF
+    exit 1
+  fi
+fi
+])dnl
+
+
+dnl  EGG_CHECK_SSL()
+dnl
+AC_DEFUN(EGG_CHECK_SSL, [dnl
+if test "x${SSL}" = x; then
+  cat >&2 <<EOF
+configure: error:
+
+  Your system does not provide a working ssl library. 
+  It is required. Download openssl at www.openssl.org
+
+EOF
+  exit 1
+else
+  if test "${ac_cv_header_openssl_ssl_h}" != yes; then
+    cat >&2 <<EOF
+configure: error:
+
+  Your system does not provide the necessary ssl header file. 
+  It is required. Download openssl at www.openssl.org
+
+EOF
+    exit 1
+  fi
+fi
+])dnl
+
+dnl  EGG_HEADER_STDC()
+dnl
+AC_DEFUN(EGG_HEADER_STDC, [dnl
+if test "$ac_cv_header_stdc" = "no"
+then
+  cat << 'EOF' >&2
+configure: error:
+
+  Your system must support ANSI C Header files.
+  These are required for the language support.  Sorry.
+
+EOF
+  exit 1
+fi
+])dnl
+
+
+dnl  EGG_TCL_ARG_WITH()
+dnl
+AC_DEFUN(EGG_TCL_ARG_WITH, [dnl
+# oohh new configure --variables for those with multiple Tcl libs
+AC_ARG_WITH(tcllib, [  --with-tcllib=PATH      full path to Tcl library], tcllibname="$withval")
+AC_ARG_WITH(tclinc, [  --with-tclinc=PATH      full path to Tcl header], tclincname="$withval")
+
+WARN=0
+# Make sure either both or neither $tcllibname and $tclincname are set
+if test ! "${tcllibname-x}" = "x"
+then
+  if test "${tclincname-x}" = "x"
+  then
+    WARN=1
+    tcllibname=""
+    TCLLIB=""
+    TCLINC=""
+  fi
+else
+  if test ! "${tclincname-x}" = "x"
+  then
+    WARN=1
+    tclincname=""
+    TCLLIB=""
+    TCLINC=""
+  fi
+fi
+if test "$WARN" = 1
+then
+  cat << 'EOF' >&2
+configure: warning:
+
+  You must specify both --with-tcllib and --with-tclinc for them to work.
+  configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+fi
+])dnl
+
+
+dnl  EGG_TCL_ENV()
+dnl
+AC_DEFUN(EGG_TCL_ENV, [dnl
+WARN=0
+# Make sure either both or neither $TCLLIB and $TCLINC are set
+if test ! "${TCLLIB-x}" = "x"
+then
+  if test "${TCLINC-x}" = "x"
+  then
+    WARN=1
+    WVAR1=TCLLIB
+    WVAR2=TCLINC
+    TCLLIB=""
+  fi
+else
+  if test ! "${TCLINC-x}" = "x"
+  then
+    WARN=1
+    WVAR1=TCLINC
+    WVAR2=TCLLIB
+    TCLINC=""
+  fi
+fi
+if test "$WARN" = 1
+then
+  cat << EOF >&2
+configure: warning:
+
+  Environment variable $WVAR1 was set, but I did not detect ${WVAR2}.
+  Please set both TCLLIB and TCLINC correctly if you wish to use them.
+  configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+fi
+])dnl
+
+
+dnl  EGG_TCL_WITH_TCLLIB()
+dnl
+AC_DEFUN(EGG_TCL_WITH_TCLLIB, [dnl
+# Look for Tcl library: if $tcllibname is set, check there first
+if test ! "${tcllibname-x}" = "x"
+then
+  if test -f "$tcllibname" && test -r "$tcllibname"
+  then
+    TCLLIB=`echo $tcllibname | sed 's%/[[^/]][[^/]]*$%%'`
+    TCLLIBFN=`$BASENAME $tcllibname | cut -c4-`
+    TCLLIBEXT=".`echo $TCLLIBFN | $AWK '{j=split([$]1, i, "."); print i[[j]]}'`"
+    TCLLIBFNS=`$BASENAME $tcllibname $TCLLIBEXT | cut -c4-`
+  else
+    cat << EOF >&2
+configure: warning:
+
+  The file '$tcllibname' given to option --with-tcllib is not valid.
+  configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+    tcllibname=""
+    tclincname=""
+    TCLLIB=""
+    TCLLIBFN=""
+    TCLINC=""
+    TCLINCFN=""
+  fi
+fi
+])dnl
+
+
+dnl  EGG_TCL_WITH_TCLINC()
+dnl
+AC_DEFUN(EGG_TCL_WITH_TCLINC, [dnl
+# Look for Tcl header: if $tclincname is set, check there first
+if test ! "${tclincname-x}" = "x"
+then
+  if test -f "$tclincname" && test -r "$tclincname"
+  then
+    TCLINC=`echo $tclincname | sed 's%/[[^/]][[^/]]*$%%'`
+    TCLINCFN=`$BASENAME $tclincname`
+  else
+    cat << EOF >&2
+configure: warning:
+
+  The file '$tclincname' given to option --with-tclinc is not valid.
+  configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+    tcllibname=""
+    tclincname=""
+    TCLLIB=""
+    TCLLIBFN=""
+    TCLINC=""
+    TCLINCFN=""
+  fi
+fi
+])dnl
+
+
+dnl  EGG_TCL_FIND_LIBRARY()
+dnl
+AC_DEFUN(EGG_TCL_FIND_LIBRARY, [dnl
+# Look for Tcl library: if $TCLLIB is set, check there first
+if test "${TCLLIBFN-x}" = "x"
+then
+  if test ! "${TCLLIB-x}" = "x"
+  then
+    if test -d "$TCLLIB"
+    then
+      for tcllibfns in $tcllibnames
+      do
+        for tcllibext in $tcllibextensions
+        do
+          if test -r "$TCLLIB/lib$tcllibfns$tcllibext"
+          then
+            TCLLIBFN="$tcllibfns$tcllibext"
+            TCLLIBEXT="$tcllibext"
+            TCLLIBFNS="$tcllibfns"
+            break 2
+          fi
+        done
+      done
+    fi
+    if test "${TCLLIBFN-x}" = "x"
+    then
+      cat << 'EOF' >&2
+configure: warning:
+
+  Environment variable TCLLIB was set, but incorrect.
+  Please set both TCLLIB and TCLINC correctly if you wish to use them.
+  configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+      TCLLIB=""
+      TCLLIBFN=""
+      TCLINC=""
+      TCLINCFN=""
+    fi
+  fi
+fi
+])dnl
+
+
+dnl  EGG_TCL_FIND_HEADER()
+dnl
+AC_DEFUN(EGG_TCL_FIND_HEADER, [dnl
+# Look for Tcl header: if $TCLINC is set, check there first
+if test "${TCLINCFN-x}" = "x"
+then
+  if test ! "${TCLINC-x}" = "x"
+  then
+    if test -d "$TCLINC"
+    then
+      for tclheaderfn in $tclheadernames
+      do
+        if test -r "$TCLINC/$tclheaderfn"
+        then
+          TCLINCFN="$tclheaderfn"
+          break
+        fi
+      done
+    fi
+    if test "${TCLINCFN-x}" = "x"
+    then
+      cat << 'EOF' >&2
+configure: warning:
+
+  Environment variable TCLINC was set, but incorrect.
+  Please set both TCLLIB and TCLINC correctly if you wish to use them.
+  configure will now attempt to autodetect both the Tcl library and header...
+
+EOF
+      TCLLIB=""
+      TCLLIBFN=""
+      TCLINC=""
+      TCLINCFN=""
+    fi
+  fi
+fi
+])dnl
+
+
+dnl  EGG_TCL_CHECK_LIBRARY()
+dnl
+AC_DEFUN(EGG_TCL_CHECK_LIBRARY, [dnl
+AC_MSG_CHECKING(for Tcl library)
+
+# Attempt autodetect for $TCLLIBFN if it's not set
+if test ! "${TCLLIBFN-x}" = "x"
+then
+  AC_MSG_RESULT(using $TCLLIB/lib$TCLLIBFN)
+else
+  for tcllibfns in $tcllibnames
+  do
+    for tcllibext in $tcllibextensions
+    do
+      for tcllibpath in $tcllibpaths
+      do
+        if test -r "$tcllibpath/lib$tcllibfns$tcllibext"
+        then
+          AC_MSG_RESULT(found $tcllibpath/lib$tcllibfns$tcllibext)
+          TCLLIB="$tcllibpath"
+          TCLLIBFN="$tcllibfns$tcllibext"
+          TCLLIBEXT="$tcllibext"
+          TCLLIBFNS="$tcllibfns"
+          break 3
+        fi
+      done
+    done
+  done
+fi
+
+# Show if $TCLLIBFN wasn't found
+if test "${TCLLIBFN-x}" = "x"
+then
+  AC_MSG_RESULT(not found)
+fi
+AC_SUBST(TCLLIB)dnl
+AC_SUBST(TCLLIBFN)dnl
+])dnl
+
+
+dnl  EGG_TCL_CHECK_HEADER()
+dnl
+AC_DEFUN(EGG_TCL_CHECK_HEADER, [dnl
+AC_MSG_CHECKING(for Tcl header)
+
+# Attempt autodetect for $TCLINCFN if it's not set
+if test ! "${TCLINCFN-x}" = "x"
+then
+  AC_MSG_RESULT(using $TCLINC/$TCLINCFN)
+else
+  for tclheaderpath in $tclheaderpaths
+  do
+    for tclheaderfn in $tclheadernames
+    do
+      if test -r "$tclheaderpath/$tclheaderfn"
+      then
+        AC_MSG_RESULT(found $tclheaderpath/$tclheaderfn)
+        TCLINC="$tclheaderpath"
+        TCLINCFN="$tclheaderfn"
+        break 2
+      fi
+    done
+  done
+  # FreeBSD hack ...
+  if test "${TCLINCFN-x}" = "x"
+  then
+    for tcllibfns in $tcllibnames
+    do
+      for tclheaderpath in $tclheaderpaths
+      do
+        for tclheaderfn in $tclheadernames
+        do
+          if test -r "$tclheaderpath/$tcllibfns/$tclheaderfn"
+          then
+            AC_MSG_RESULT(found $tclheaderpath/$tcllibfns/$tclheaderfn)
+            TCLINC="$tclheaderpath/$tcllibfns"
+            TCLINCFN="$tclheaderfn"
+            break 3
+          fi
+        done
+      done
+    done
+  fi
+fi
+
+# Show if $TCLINCFN wasn't found
+if test "${TCLINCFN-x}" = "x"
+then
+  AC_MSG_RESULT(not found)
+fi
+AC_SUBST(TCLINC)dnl
+AC_SUBST(TCLINCFN)dnl
+])dnl
+
+
+dnl  EGG_CACHE_UNSET(CACHE-ID)
+dnl
+dnl  Unsets a certain cache item. Typically called before using
+dnl  the AC_CACHE_*() macros.
+AC_DEFUN(EGG_CACHE_UNSET, [dnl
+  unset $1
+])
+
+
+dnl  EGG_TCL_DETECT_CHANGE()
+dnl
+dnl  Detect whether the Tcl system has changed since our last
+dnl  configure run. Set egg_tcl_changed accordingly.
+dnl
+dnl  Tcl related feature and version checks should re-run their
+dnl  checks as soon as egg_tcl_changed is set to "yes".
+AC_DEFUN(EGG_TCL_DETECT_CHANGE, [dnl
+  AC_MSG_CHECKING(whether the Tcl system has changed)
+  egg_tcl_changed=yes
+  egg_tcl_id="$TCLLIB:$TCLLIBFN:$TCLINC:$TCLINCFN"
+  if test ! "$egg_tcl_id" = ":::"
+  then
+    egg_tcl_cached=yes
+    AC_CACHE_VAL(egg_cv_var_tcl_id, [dnl
+      egg_cv_var_tcl_id="$egg_tcl_id"
+      egg_tcl_cached=no
+    ])
+    if test "$egg_tcl_cached" = "yes"
+    then
+      if test "${egg_cv_var_tcl_id-x}" = "${egg_tcl_id-x}"
+      then
+        egg_tcl_changed=no
+      else
+        egg_cv_var_tcl_id="$egg_tcl_id"
+      fi
+    fi
+  fi
+  if test "$egg_tcl_changed" = "yes"
+  then
+    AC_MSG_RESULT(yes)
+  else
+    AC_MSG_RESULT(no)
+  fi
+])
+
+
+dnl  EGG_TCL_CHECK_VERSION()
+dnl
+AC_DEFUN(EGG_TCL_CHECK_VERSION, [dnl
+# Both TCLLIBFN & TCLINCFN must be set, or we bail
+TCL_FOUND=0
+if test ! "${TCLLIBFN-x}" = "x" && test ! "${TCLINCFN-x}" = "x"
+then
+  TCL_FOUND=1
+
+  # Check Tcl's version
+  if test "$egg_tcl_changed" = "yes"
+  then
+    EGG_CACHE_UNSET(egg_cv_var_tcl_version)
+  fi
+  AC_MSG_CHECKING(for Tcl version)
+  AC_CACHE_VAL(egg_cv_var_tcl_version, [dnl
+    egg_cv_var_tcl_version=`grep TCL_VERSION $TCLINC/$TCLINCFN | $HEAD_1 | $AWK '{gsub(/\"/, "", [$]3); print [$]3}'`
+  ])
+
+  if test ! "${egg_cv_var_tcl_version-x}" = "x"
+  then
+    AC_MSG_RESULT($egg_cv_var_tcl_version)
+  else
+    AC_MSG_RESULT(not found)
+    TCL_FOUND=0
+  fi
+
+  # Check Tcl's patch level (if available)
+  if test "$egg_tcl_changed" = "yes"
+  then
+    EGG_CACHE_UNSET(egg_cv_var_tcl_patch_level)
+  fi
+  AC_MSG_CHECKING(for Tcl patch level)
+  AC_CACHE_VAL(egg_cv_var_tcl_patch_level, [dnl
+    eval "egg_cv_var_tcl_patch_level=`grep TCL_PATCH_LEVEL $TCLINC/$TCLINCFN | $HEAD_1 | $AWK '{gsub(/\"/, "", [$]3); print [$]3}'`"
+  ])
+
+  if test ! "${egg_cv_var_tcl_patch_level-x}" = "x"
+  then
+    AC_MSG_RESULT($egg_cv_var_tcl_patch_level)
+  else
+    egg_cv_var_tcl_patch_level="unknown"
+    AC_MSG_RESULT(unknown)
+  fi
+fi
+
+# Check if we found Tcl's version
+if test "$TCL_FOUND" = 0
+then
+  cat << 'EOF' >&2
+configure: error:
+
+  I can't find Tcl on this system.
+
+  The download website is at:
+        http://www.tcl.tk/software/tcltk/download84.html
+  A nice direct link for the tarball is:
+        http://aleron.dl.sourceforge.net/sourceforge/tcl/tcl8.4.4-src.tar.gz
+
+  OR
+
+  Just type: ./build -T
+
+EOF
+  exit 1
+fi
+])dnl
+
+
+dnl  EGG_TCL_CHECK_PRE80()
+dnl
+AC_DEFUN(EGG_TCL_CHECK_PRE80, [dnl
+# Is this version of Tcl too old for us to use ?
+TCL_VER_PRE80=`echo $egg_cv_var_tcl_version | $AWK '{split([$]1, i, "."); if (i[[1]] < 8) print "yes"; else print "no"}'`
+if test "$TCL_VER_PRE80" = "yes"
+then
+  cat << EOF >&2
+configure: error:
+
+  Your Tcl version is much too old for Eggdrop to use.
+  I suggest you download and compile a more recent version.
+  The most reliable current version is $tclrecommendver and
+  can be downloaded from $tclrecommendsite
+
+EOF
+  exit 1
+fi
+])dnl
+
+
+dnl  EGG_TCL_TESTLIBS()
+dnl
+AC_DEFUN(EGG_TCL_TESTLIBS, [dnl
+# Set variables for Tcl library tests
+TCL_TEST_LIB="$TCLLIBFNS"
+TCL_TEST_OTHERLIBS="-L$TCLLIB $EGG_MATH_LIB"
+
+if test ! "${ac_cv_lib_pthread-x}" = "x"
+then
+  TCL_TEST_OTHERLIBS="$TCL_TEST_OTHERLIBS $ac_cv_lib_pthread"
+fi
+])dnl
+
+
+dnl  EGG_TCL_CHECK_FREE()
+dnl
+AC_DEFUN(EGG_TCL_CHECK_FREE, [dnl
+if test "$egg_tcl_changed" = "yes"
+then
+  EGG_CACHE_UNSET(egg_cv_var_tcl_free)
+fi
+
+# Check for Tcl_Free()
+AC_CHECK_LIB($TCL_TEST_LIB, Tcl_Free, egg_cv_var_tcl_free="yes", egg_cv_var_tcl_free="no", $TCL_TEST_OTHERLIBS)
+
+if test "$egg_cv_var_tcl_free" = "yes"
+then
+  AC_DEFINE(HAVE_TCL_FREE, 1, [Define for Tcl that has Tcl_Free() (7.5p1 and later)])dnl
+fi
+])dnl
+
+
+dnl  EGG_TCL_CHECK_THREADS()
+dnl
+AC_DEFUN(EGG_TCL_CHECK_THREADS, [dnl
+if test "$egg_tcl_changed" = "yes"
+then
+  EGG_CACHE_UNSET(egg_cv_var_tcl_threaded)
+fi
+
+# Check for TclpFinalizeThreadData()
+AC_CHECK_LIB($TCL_TEST_LIB, TclpFinalizeThreadData, egg_cv_var_tcl_threaded="yes", egg_cv_var_tcl_threaded="no", $TCL_TEST_OTHERLIBS)
+enable_tcl_threads=no
+if test "$egg_cv_var_tcl_threaded" = "yes"
+then
+  if test "$enable_tcl_threads" = "no"
+  then
+
+    cat << 'EOF' >&2
+configure: warning:
+
+  You have disabled threads support on a system with a threaded Tcl library.
+  Tcl features that rely on scheduled events may not function properly.
+
+EOF
+  fi
+
+  # Add pthread library to $LIBS if we need it
+  if test ! "${ac_cv_lib_pthread-x}" = "x"
+  then
+    LIBS="$ac_cv_lib_pthread $LIBS"
+  fi
+fi
+])dnl
+
+
+dnl  EGG_TCL_LIB_REQS()
+dnl
+AC_DEFUN(EGG_TCL_LIB_REQS, [dnl
+if test "$EGG_CYGWIN" = "yes"
+then
+  TCL_REQS="$TCLLIB/lib$TCLLIBFN"
+  TCL_LIBS="-L$TCLLIB -l$TCLLIBFNS $EGG_MATH_LIB"
+else
+ if test ! "$TCLLIBEXT" = ".a"
+ then
+    cat << 'EOF' >&2
+configure: warning:
+
+  Your Tcl library is not compiled statically.
+  You will need to compile Tcl statically to successfully compile wraith.
+
+EOF
+  exit 1
+ else
+  # Was the --with-tcllib option given ?
+  if test ! "${tcllibname-x}" = "x"
+  then
+    TCL_REQS="$TCLLIB/lib$TCLLIBFN"
+    TCL_LIBS="$TCLLIB/lib$TCLLIBFN $EGG_MATH_LIB"
+  else
+    TCL_REQS="$TCLLIB/lib$TCLLIBFN"
+    TCL_LIBS="-L$TCLLIB -l$TCLLIBFNS $EGG_MATH_LIB"
+  fi
+ fi
+fi
+AC_SUBST(TCL_REQS)dnl
+AC_SUBST(TCL_LIBS)dnl
+])dnl
+
+
+dnl  EGG_SUBST_VERSION()
+dnl
+AC_DEFUN(EGG_SUBST_VERSION, [dnl
+VERSION=`grep "char" $srcdir/src/main.c | $AWK '/egg_version/ {print [$]5}' | sed -e 's/\"//g' | sed -e 's/\;//g'`
+NUMVER=`grep "int" $srcdir/src/main.c | $AWK '/egg_numver =/ {print [$]5}' |  sed -e 's/\;//g'`
+if ! test -f $srcdir/pack/pack.cfg; then
+ cat << 'EOF' >&2
+configure: error:
+
+  Your pack cfg is missing, please copy it to $srcdir/pack/pack.cfg
+
+EOF
+ exit 1
+fi
+PACKNAME=`grep "PACKNAME " $srcdir/pack/pack.cfg | $AWK '/PACKNAME/ {print [$]2}'`
+version_num=`echo $VERSION | $AWK 'BEGIN {FS = "."} {printf("%d%02d%02d", [$]1, [$]2, [$]3)}'`
+AC_DEFINE_UNQUOTED(EGG_VERSION, $version_num, [Defines the current pack version])dnl
+AC_SUBST(VERSION)dnl
+AC_SUBST(NUMVER)dnl
+AC_SUBST(PACKNAME)dnl
+])dnl
+
+
+dnl  EGG_SUBST_MOD_UPDIR()
+dnl
+dnl  Since module's Makefiles aren't generated by configure, some
+dnl  paths in src/mod/Makefile.in take care of them. For correct
+dnl  path "calculation", we need to keep absolute paths in mind
+dnl  (which don't need a "../" pre-pended).
+AC_DEFUN(EGG_SUBST_MOD_UPDIR, [dnl
+case "$srcdir" in
+  [[\\/]]* | ?:[[\\/]]*)
+    MOD_UPDIR=""
+  ;;
+  *)
+    MOD_UPDIR="../"
+  ;;
+esac
+AC_SUBST(MOD_UPDIR)dnl
+])dnl
+
+
+dnl EGG_REPLACE_IF_CHANGED(FILE-NAME, CONTENTS-CMDS, INIT-CMDS)
+dnl
+dnl Replace FILE-NAME if the newly created contents differs from the existing
+dnl file contents. Otherwise, leave the file alone. This avoids needless
+dnl recompiles.
+m4_define(EGG_REPLACE_IF_CHANGED,
+[
+  AC_CONFIG_COMMANDS([replace-if-changed],
+  [[
+    egg_replace_file="$1"
+    $2
+    if test -f "$egg_replace_file" && cmp -s conftest.out $egg_replace_file; then
+      echo "$1 is unchanged"
+    else
+      echo "creating $1"
+      mv conftest.out $egg_replace_file
+    fi
+    rm -f conftest.out
+  ]],
+  [[$3]])
+])
+
+dnl EGG_TCL_LUSH()
+AC_DEFUN([EGG_TCL_LUSH],
+[
+  EGG_REPLACE_IF_CHANGED(lush.h,
+  [
+    cat > conftest.out << EOF
+
+/* Ignore me but do not erase me. I am a kludge. */
+
+#include "${egg_tclinc}/${egg_tclincfn}"
+
+EOF
+  ], [
+    egg_tclinc="$TCLINC"
+    egg_tclincfn="$TCLINCFN"
+  ])
+])
+
+
+dnl EGG_CATCH_MAKEFILE_REBUILD()
+AC_DEFUN([EGG_CATCH_MAKEFILE_REBUILD],
+[
+  AC_CONFIG_COMMANDS([catch-make-rebuild],
+  [[
+    if test -f .modules; then
+      $srcdir/misc/modconfig --top_srcdir="$srcdir/src" Makefile
+    fi
+  ]])
+])
+
+
+dnl  EGG_SAVE_PARAMETERS()
+dnl
+AC_DEFUN(EGG_SAVE_PARAMETERS, [dnl
+  # Remove --cache-file and --srcdir arguments so they do not pile up.
+  egg_ac_parameters=
+  ac_prev=
+  for ac_arg in $ac_configure_args; do
+    if test -n "$ac_prev"; then
+      ac_prev=
+      continue
+    fi
+    case $ac_arg in
+    -cache-file | --cache-file | --cache-fil | --cache-fi \
+    | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
+      ac_prev=cache_file ;;
+    -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
+    | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
+    | --c=*)
+      ;;
+    --config-cache | -C)
+      ;;
+    -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
+      ac_prev=srcdir ;;
+    -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
+      ;;
+    *) egg_ac_parameters="$egg_ac_parameters $ac_arg" ;;
+    esac
+  done
+
+  AC_SUBST(egg_ac_parameters)dnl
+])dnl
+
+
+AC_DEFUN([AC_PROG_CC_WIN32], [
+AC_MSG_CHECKING([how to access the Win32 API])
+WIN32FLAGS=
+AC_TRY_COMPILE(,[
+#ifndef WIN32
+# ifndef _WIN32
+#  error WIN32 or _WIN32 not defined
+# endif
+#endif], [
+dnl found windows.h with the current config.
+AC_MSG_RESULT([present by default])
+], [
+dnl try -mwin32
+ac_compile_save="$ac_compile"
+dnl we change CC so config.log looks correct
+save_CC="$CC"
+ac_compile="$ac_compile -mwin32"
+CC="$CC -mwin32"
+AC_TRY_COMPILE(,[
+#ifndef WIN32
+# ifndef _WIN32
+#  error WIN32 or _WIN32 not defined
+# endif
+#endif], [
+dnl found windows.h using -mwin32
+AC_MSG_RESULT([found via -mwin32])
+ac_compile="$ac_compile_save"
+CC="$save_CC"
+WIN32FLAGS="-mwin32"
+], [
+ac_compile="$ac_compile_save"
+CC="$save_CC"
+AC_MSG_RESULT([not found])
+])
+])
+
+])
+dnl

+ 200 - 0
autotools/configure.ac

@@ -0,0 +1,200 @@
+dnl Process this file with autoconf to produce a configure script.
+dnl
+dnl
+
+AC_PREREQ(2.59)
+AC_INIT([wraith],[],[wraith@shatow.net])
+AC_CONFIG_SRCDIR(src/eggdrop.h)
+AC_CONFIG_HEADER(config.h)
+AC_COPYRIGHT([Copyright (c) 2003, 2004 Bryan Drewery (bryan)])
+AC_REVISION($Revision$)
+
+EGG_SAVE_PARAMETERS
+
+# Setup build environment
+AC_PROG_CC
+EGG_CHECK_CC
+
+# Crazy machines
+AC_AIX
+AC_ISC_POSIX
+AC_MINIX
+
+#checkpoint
+AC_CACHE_SAVE 
+
+# Speedup compile
+EGG_CHECK_CCPIPE
+
+# Create static binaries
+EGG_CHECK_CCSTATIC
+
+# Checks for programs
+AC_PROG_MAKE_SET
+EGG_PROG_HEAD_1
+EGG_PROG_STRIP
+EGG_PROG_AWK
+EGG_PROG_BASENAME
+AC_CHECK_PROG(UNAME,uname,uname)
+
+# Test the os and set the module linking settings
+EGG_CHECK_OS
+
+#checkpoint
+AC_CACHE_SAVE 
+
+# Checks for system libraries
+EGG_CHECK_LIBS
+
+# Checks for header files
+AC_HEADER_DIRENT
+AC_HEADER_SYS_WAIT
+AC_HEADER_TIME
+AC_HEADER_STAT
+#checkpoint
+AC_CACHE_SAVE 
+AC_CHECK_HEADERS([arpa/inet.h fcntl.h limits.h locale.h netdb.h netinet/in.h])
+AC_CHECK_HEADERS([sys/file.h sys/ioctl.h sys/param.h sys/socket.h wchar.h])
+
+#checkpoint
+AC_CACHE_SAVE
+AC_CHECK_HEADERS(openssl/ssl.h openssl/crypto.h)
+AC_CHECK_HEADERS(zlib.h)
+EGG_CHECK_ZLIB
+EGG_CHECK_SSL
+
+
+AC_SUBST(ZLIB)dnl
+AC_SUBST(SSL)dnl
+
+
+
+# Checks for typedefs, structures, and compiler characteristics
+AC_TYPE_PID_T
+AC_TYPE_SIZE_T
+AC_TYPE_UID_T
+
+AC_C_CONST
+AC_C_BIGENDIAN
+AC_C_INLINE
+AC_CHECK_SIZEOF(long, 0)
+AC_CHECK_SIZEOF(int, 0)
+
+
+#checkpoint
+AC_CACHE_SAVE 
+
+AC_C_VOLATILE
+AC_PROG_GCC_TRADITIONAL
+AC_STRUCT_TIMEZONE
+AC_STRUCT_TM
+
+#checkpoint
+AC_CACHE_SAVE 
+
+# Check for IPv6 support
+#EGG_IPV6_SUPPORTED
+EGG_IPV6_OPTIONS
+EGG_CHECK_SOCKLEN_T
+
+# Checks for library functions
+
+#checkpoint
+AC_CACHE_SAVE
+
+# Checks for library functions.
+AC_FUNC_FORK
+AC_FUNC_LSTAT
+AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK
+AC_FUNC_MALLOC
+AC_FUNC_MKTIME
+AC_FUNC_MMAP
+AC_FUNC_REALLOC
+AC_FUNC_SELECT_ARGTYPES
+AC_FUNC_STAT
+AC_FUNC_STRFTIME
+
+#checkpoint
+AC_CACHE_SAVE
+AC_CHECK_FUNCS([clock dprintf fsync getdtablesize getrusage inet_aton isascii gethostbyname2])
+AC_CHECK_FUNCS([getipnodebyname memcpy memset random rename setpgid sigaction sigemptyset snprintf srandom])
+#checkpoint
+AC_CACHE_SAVE
+AC_CHECK_FUNCS([strcasecmp strncasecmp vsnprintf])
+
+#autoscan suggested this....
+#These are recommended by autoscan, but no code supports it currently
+#AC_CHECK_FUNCS([alarm bzero dup2 getcwd gethostbyaddr gethostbyname gethostname getpass gettimeofday inet_ntoa mbrlen mkdir munmap realpath select setlocale socket strchr strerror strpbrk strrchr strstr strtol tzset])
+EGG_CHECK_FUNC_VSPRINTF
+EGG_CHECK_FUNC_UNAME
+
+# Make sure we have stdc headers, since we can't compile without them
+EGG_HEADER_STDC
+
+#checkpoint
+AC_CACHE_SAVE 
+
+# Where is Tcl?  Is it here?
+# ---------- begin robey's Tcl thingies
+# (well, what used to be robey's Tcl thingies...)
+
+# Latest tested Tcl version to recommend if Tcl isn't found
+tclrecommendver="8.4"
+
+# Site recommended to download Tcl from
+tclrecommendsite="http://www.tcl.tk/software/tcltk/download84.html"
+
+# Tcl library filename prefixes (also used for Tcl header dir on FreeBSD)
+tcllibnames="tcl tcl8.4 tcl84 tcl8.3 tcl83 tcl8.2 tcl82 tcl8.1 tcl81 \
+	tcl8.0 tcl80"
+
+# Tcl library filename suffixes
+tcllibextensions=".a .so .so.1 .so.1.0 .so.1.2 .sl .dll .dylib"
+
+# Tcl library search paths
+tcllibpaths="${HOME}/lib ${HOME}/tcl/lib ${HOME} \
+        /usr/local/lib /usr/local/pkgs/tcl/lib \
+	/usr/lib /lib /usr/i486-linuxaout/lib \
+	/beos/system/lib /sys/lib"
+
+# Tcl header filenames
+tclheadernames="tcl.h"
+
+# Tcl header search paths
+tclheaderpaths="${HOME}/include ${HOME}/tcl/include ${HOME} \
+        /usr/local/include /usr/local/pkgs/tcl/include \
+	/usr/include /beos/system/include /beos/devel/include \
+       /sys/include"
+
+EGG_TCL_ARG_WITH
+EGG_TCL_ENV
+EGG_TCL_WITH_TCLLIB
+EGG_TCL_WITH_TCLINC
+EGG_TCL_FIND_LIBRARY
+EGG_TCL_FIND_HEADER
+EGG_TCL_CHECK_LIBRARY
+EGG_TCL_CHECK_HEADER
+EGG_TCL_DETECT_CHANGE
+
+#checkpoint
+AC_CACHE_SAVE 
+
+EGG_TCL_CHECK_VERSION
+EGG_TCL_CHECK_PRE80
+EGG_TCL_TESTLIBS
+EGG_TCL_CHECK_FREE
+EGG_TCL_CHECK_THREADS
+EGG_TCL_LIB_REQS
+EGG_TCL_LUSH
+
+#checkpoint
+AC_CACHE_SAVE 
+# ---------- end of (what used to be) robey's Tcl thingies
+
+EGG_SUBST_VERSION
+EGG_SUBST_MOD_UPDIR
+EGG_CATCH_MAKEFILE_REBUILD
+
+AC_CONFIG_FILES([Makefile src/Makefile src/compat/Makefile src/mod/Makefile])
+AC_OUTPUT
+

+ 105 - 0
autotools/depcomp

@@ -0,0 +1,105 @@
+#! /bin/sh
+
+# depcomp - compile a program generating dependencies as side-effects
+# Copyright 1999, 2000 Free Software Foundation, Inc.
+
+if test -z "$depmode" || test -z "$source" || test -z "$object"; then
+  echo "depcomp: Variables source, object and depmode must be set" 1>&2
+  exit 1
+fi
+
+if test -z "$depfile"; then
+   base=`echo "$object" | sed -e 's,^.*/,,' -e 's,\.\([^.]*\)$,.P\1,'`
+   dir=`echo "$object" | sed 's,/.*$,/,'`
+   if test "$dir" = "$object"; then
+      dir=
+   fi
+   depfile="$dir.deps/$base"
+fi
+
+tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`}
+
+rm -f "$tmpdepfile"
+
+# Some modes work just like other modes, but use different flags.  We
+# parameterize here, but still list the modes in the big case below,
+# to make depend.m4 easier to write.  Note that we *cannot* use a case
+# here, because this file can only contain one case statement.
+
+case "$depmode" in
+gcc3)
+## gcc 3 implements dependency tracking that does exactly what
+## we want.  Yay!  Note: for some reason libtool 1.4 doesn't like
+## it if -MD -MP comes after the -MF stuff.  Hmm.
+  if test -z "$MM"; then
+   "$@" -MT "$object" -MD -MP -MF "$tmpdepfile"
+  else
+   "$@" -MM "$object" -MD -MP -MF "$tmpdepfile"
+  fi
+  stat=$?
+  if test $stat -eq 0; then :
+  else
+    rm -f "$tmpdepfile"
+    exit $stat
+  fi
+  mv "$tmpdepfile" "$depfile"
+  ;;
+
+gcc)
+## There are various ways to get dependency output from gcc.  Here's
+## why we pick this rather obscure method:
+## - Don't want to use -MD because we'd like the dependencies to end
+##   up in a subdir.  Having to rename by hand is ugly.
+##   (We might end up doing this anyway to support other compilers.)
+## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like
+##   -MM, not -M (despite what the docs say).
+## - Using -M directly means running the compiler twice (even worse
+##   than renaming).
+  if test -z "$gccflag"; then
+    gccflag=-MD,
+  fi
+  "$@" -Wp,"$gccflag$tmpdepfile"
+  stat=$?
+  if test $stat -eq 0; then :
+  else
+    rm -f "$tmpdepfile"
+    exit $stat
+  fi
+  rm -f "$depfile"
+  echo "$object : \\" > "$depfile"
+  alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
+## The second -e expression handles DOS-style file names with drive letters.
+  sed -e 's/^[^:]*: / /' \
+      -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile"
+## This next piece of magic avoids the `deleted header file' problem.
+## The problem is that when a header file which appears in a .P file
+## is deleted, the dependency causes make to die (because there is
+## typically no way to rebuild the header).  We avoid this by adding
+## dummy dependencies for each header file.  Too bad gcc doesn't do
+## this for us directly.
+  tr ' ' '
+' < "$tmpdepfile" |
+## Some versions of gcc put a space before the `:'.  On the theory
+## that the space means something, we add a space to the output as
+## well.
+## Some versions of the HPUX 10.20 sed can't process this invocation
+## correctly.  Breaking it into two sed invocations is a workaround.
+    sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
+  rm -f "$tmpdepfile"
+  ;;
+
+#nosideeffect)
+  # This comment above is used by automake to tell side-effect
+  # dependency tracking mechanisms from slower ones.
+
+none)
+  exec "$@"
+  ;;
+
+*)
+  echo "Unknown depmode $depmode" 1>&2
+  exit 1
+  ;;
+esac
+
+exit 0

+ 15 - 147
src/Makefile.in

@@ -4,6 +4,7 @@ SHELL = @SHELL@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
 srcdir = @srcdir@
 srcdir = @srcdir@
 VPATH = @srcdir@
 VPATH = @srcdir@
+depcomp = /bin/sh $(top_srcdir)/autotools/depcomp
 
 
 @SET_MAKE@
 @SET_MAKE@
 
 
@@ -62,20 +63,14 @@ $(EGGEXEC): stringfix ../$(EGGEXEC)
 clean:
 clean:
 	@rm -f .depend *.o *~ _*.c
 	@rm -f .depend *.o *~ _*.c
 
 
-depleaf:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DLEAF -MM $(srcdir)/*.c > .depend
-
-dephub:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DHUB -MM $(srcdir)/*.c > .depend
-
 
 
 build_msg:
 build_msg:
 	@echo "[*] Compiling core components"
 	@echo "[*] Compiling core components"
 
 
 
 
 main.o: stringfix
 main.o: stringfix
-	@./stringfix main.c _main.c || cp -f main.c _main.c
 	@echo -e "Compiling: \033[1mmain\033[0m"
 	@echo -e "Compiling: \033[1mmain\033[0m"
+	@./stringfix main.c _main.c || cp -f main.c _main.c
 	@$(CC) $(CFLAGS) -I$(top_srcdir) $(CPPFLAGS) '-DCCFLAGS="$(CC) $(CFLAGS) $(CPPFLAGS)"' \
 	@$(CC) $(CFLAGS) -I$(top_srcdir) $(CPPFLAGS) '-DCCFLAGS="$(CC) $(CFLAGS) $(CPPFLAGS)"' \
 	'-DLDFLAGS="$(LD)"' '-DSTRIPFLAGS="$(STRIP)"' -c $(srcdir)/_main.c -o main.o
 	'-DLDFLAGS="$(LD)"' '-DSTRIPFLAGS="$(STRIP)"' -c $(srcdir)/_main.c -o main.o
 
 
@@ -87,151 +82,24 @@ eggdrop.h:
 	@echo "You do not have the eggdrop source!"
 	@echo "You do not have the eggdrop source!"
 	@exit 1
 	@exit 1
 
 
+include ./.deps/includes
+
 .SUFFIXES:
 .SUFFIXES:
 .SUFFIXES: .c .h .o
 .SUFFIXES: .c .h .o
 
 
-
 .c.o: stringfix
 .c.o: stringfix
-	@./stringfix $< _$< || cp -f $< _$<
 	@echo -e "Compiling: \033[1m`basename $< .c`\033[0m"
 	@echo -e "Compiling: \033[1m`basename $< .c`\033[0m"
-	@$(CC) $(CFLAGS) $(CPPFLAGS) -c _$< -o `basename $< .c`.o
+	@./stringfix $< _$< || cp -f $< _$<
+	@source='$<' object='$@' depfile='.deps/$*.Po' tmpdepfile='.deps/$*.TPo' depmode=gcc3 $(depcomp) \
+	$(CC) $(CFLAGS) $(CPPFLAGS) -c _$<  -o `basename $< .c`.o
+
+#        $(COMPILE) -c `test -f '$<' || echo '$(srcdir)/'`$<
+
+
+# source='xmlwrite.c' object='xmlwrite.lo' libtool=yes \
+# depfile='.deps/xmlwrite.Plo' tmpdepfile='.deps/xmlwrite.TPlo' \
+# depmode=gcc3 /bin/sh ../../acconfig/depcomp \
 
 
-#safety hash
-auth.o: auth.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h chan.h users.h compat/compat.h compat/inet_aton.h \
- compat/inet_ntop.h ../src/main.h compat/snprintf.h  compat/memset.h \
- compat/memcpy.h compat/strcasecmp.h compat/strftime.h
-bg.o: bg.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h users.h \
- compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h compat/snprintf.h \
- compat/memset.h compat/memcpy.h compat/strcasecmp.h compat/strftime.h
-botcmd.o: botcmd.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h \
- proto.h ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h \
- users.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h tandem.h modules.h mod/modvals.h core_binds.c core_binds.h
-botmsg.o: botmsg.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h \
- proto.h ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h \
- users.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h tandem.h core_binds.c core_binds.h
-botnet.o: botnet.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h \
- proto.h ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h \
- users.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h tandem.h core_binds.c core_binds.h
-chanprog.o: chanprog.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h \
- proto.h ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h \
- users.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h modules.h mod/modvals.h
-cmds.o: cmds.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h users.h \
- compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h compat/snprintf.h \
- compat/memset.h compat/memcpy.h compat/strcasecmp.h compat/strftime.h \
- tandem.h modules.h mod/modvals.h help.h traffic.h core_binds.c core_binds.h
-config.o: config.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h chan.h users.h compat/compat.h compat/inet_aton.h \
- compat/inet_ntop.h ../src/main.h compat/snprintf.h  compat/memset.h \
- compat/memcpy.h compat/strcasecmp.h compat/strftime.h
-core_binds.o: core_binds.c stringfix main.h ../config.h salt.h eggdrop.h proto.h \
- ../lush.h misc_file.h compat/compat.h compat/inet_aton.h \
- compat/inet_ntop.h ../src/main.h compat/snprintf.h  compat/memset.h \
- compat/memcpy.h compat/strcasecmp.h compat/strftime.h
-crypt.o: crypt.c stringfix main.h ../config.h salt.h eggdrop.h proto.h \
- ../lush.h misc_file.h compat/compat.h compat/inet_aton.h \
- compat/inet_ntop.h ../src/main.h compat/snprintf.h  compat/memset.h \
- compat/memcpy.h compat/strcasecmp.h compat/strftime.h
-dcc.o: dcc.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h users.h \
- compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h compat/snprintf.h \
- compat/memset.h compat/memcpy.h compat/strcasecmp.h compat/strftime.h \
- modules.h mod/modvals.h tandem.h core_binds.c core_binds.h
-dccutil.o: dccutil.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h \
- proto.h ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h \
- users.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h modules.h mod/modvals.h tandem.h core_binds.c core_binds.o
-debug.o: debug.c stringfix main.h ../config.h conf.h eggdrop.h \
- proto.h ../lush.h misc_file.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h
-dns.o: dns.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h users.h \
- compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h compat/snprintf.h \
- compat/memset.h compat/memcpy.h compat/strcasecmp.h compat/strftime.h \
- dns.h
-egg_timer.o: egg_timer.c egg_timer.h  stringfix main.h ../config.h salt.h eggdrop.h proto.h \
- ../lush.h misc_file.h compat/compat.h compat/inet_aton.h \
- compat/inet_ntop.h ../src/main.h compat/snprintf.h  compat/memset.h \
- compat/memcpy.h compat/strcasecmp.h compat/strftime.h
-flags.o: flags.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h users.h \
- compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h compat/snprintf.h \
- compat/memset.h compat/memcpy.h compat/strcasecmp.h compat/strftime.h
-main.o: main.c stringfix main.h build.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h users.h \
- compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h compat/snprintf.h \
- compat/memset.h compat/memcpy.h compat/strcasecmp.h compat/strftime.h \
- modules.h mod/modvals.h tandem.h  egg_timer.h egg_timer.c traffic.h
-match.o: match.c stringfix ./main.h
-mem.o: mem.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h users.h \
- compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h compat/snprintf.h \
- compat/memset.h compat/memcpy.h compat/strcasecmp.h compat/strftime.h \
- mod/modvals.h
-misc.o: misc.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h users.h \
- compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h compat/snprintf.h \
- compat/memset.h compat/memcpy.h compat/strcasecmp.h compat/strftime.h \
- stat.h 
-misc_file.o: misc_file.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h \
- proto.h ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h \
- users.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h stat.h
-modules.o: modules.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h \
- proto.h ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h \
- users.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h modules.h mod/modvals.h tandem.h core_binds.c core_binds.h
-net.o: net.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h users.h \
- compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h compat/snprintf.h \
- compat/memset.h compat/memcpy.h compat/strcasecmp.h compat/strftime.h \
- egg_timer.h egg_timer.c traffic.h
-rfc1459.o: rfc1459.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h \
- proto.h ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h \
- users.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h
-settings.o: settings.c stringfix main.h ../config.h conf.h eggdrop.h \
- proto.h ../lush.h misc_file.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h
-tcl.o: tcl.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h users.h \
- compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h compat/snprintf.h \
- compat/memset.h compat/memcpy.h compat/strcasecmp.h compat/strftime.h
-tclhash.o: tclhash.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h \
- proto.h ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h \
- users.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h match.c egg_timer.h egg_timer.c
-userent.o: userent.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h \
- proto.h ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h \
- users.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h
-userrec.o: userrec.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h \
- proto.h ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h \
- users.h compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h \
- compat/snprintf.h compat/memset.h compat/memcpy.h compat/strcasecmp.h \
- compat/strftime.h modules.h mod/modvals.h tandem.h core_binds.c core_binds.o
-users.o: users.c stringfix main.h ../config.h conf.h lang.h eggdrop.h flags.h proto.h \
- ../lush.h misc_file.h cmdt.h tclegg.h tclhash.h chan.h users.h \
- compat/compat.h compat/inet_aton.h compat/inet_ntop.h ../src/main.h compat/snprintf.h \
- compat/memset.h compat/memcpy.h compat/strcasecmp.h compat/strftime.h \
- modules.h mod/modvals.h tandem.h
 
 
 #safety hash
 #safety hash
+

+ 6 - 70
src/compat/Makefile.in

@@ -4,6 +4,7 @@ SHELL = @SHELL@
 top_srcdir = @top_srcdir@
 top_srcdir = @top_srcdir@
 srcdir = @srcdir@
 srcdir = @srcdir@
 VPATH = @srcdir@
 VPATH = @srcdir@
+depcomp = /bin/sh $(top_srcdir)/autotools/depcomp
 
 
 @SET_MAKE@
 @SET_MAKE@
 
 
@@ -21,85 +22,20 @@ doofus:
 	@echo ""
 	@echo ""
 	@cd ../.. && $(MAKE)
 	@cd ../.. && $(MAKE)
 
 
-depleaf:
-	@$(CC) $(CFLAGS) -I../.. -I$(top_srcdir) -I$(top_srcdir)/src $(CPPFLAGS) -DHUB -MM $(srcdir)/*.c > .depend
-
-dephub:
-	@$(CC) $(CFLAGS) -I../.. -I$(top_srcdir) -I$(top_srcdir)/src $(CPPFLAGS) -DHUB -MM $(srcdir)/*.c > .depend
-
 clean:
 clean:
 	@rm -f .depend *.o *~
 	@rm -f .depend *.o *~
 
 
 compat: $(OBJS)
 compat: $(OBJS)
 
 
+include ./.deps/includes
+
 .SUFFIXES:
 .SUFFIXES:
 .SUFFIXES: .c .o .h
 .SUFFIXES: .c .o .h
 
 
 .c.o:
 .c.o:
 	@echo -e "Compiling: \033[1m`basename $< .c`\033[0m"
 	@echo -e "Compiling: \033[1m`basename $< .c`\033[0m"
-	@$(CC) $(CFLAGS) -I../.. -I$(top_srcdir) -I$(top_srcdir)/src $(CPPFLAGS) -c $<
+	@source='$<' object='$@' depfile='.deps/$*.Po' tmpdepfile='.deps/$*.TPo' depmode=gcc3 $(depcomp) \
+	$(CC) $(CFLAGS) -I../.. -I$(top_srcdir) -I$(top_srcdir)/src $(CPPFLAGS) -c $< 
 
 
-#safety hash
-gnu_strftime.o: ./gnu_strftime.c
-inet_aton.o: ./inet_aton.c ../../src/main.h ../../src/conf.h ../../config.h \
- ../../src/lang.h ../../src/eggdrop.h ../../src/flags.h \
- ../../src/proto.h ../../lush.h ../../src/misc_file.h ../../src/cmdt.h \
- ../../src/tclegg.h ../../src/tclhash.h ../../src/chan.h \
- ../../src/users.h ../../src/compat/compat.h \
- ../../src/compat/inet_aton.h ../../src/compat/snprintf.h \
- ../../src/compat/memset.h ../../src/compat/memcpy.h \
- ../../src/compat/strcasecmp.h ../../src/compat/strftime.h inet_aton.h \
- ../../src/compat/inet_ntop.h
- inet_ntop.o: ./inet_ntop.c ../../src/main.h ../../src/conf.h ../../config.h \
- ../../src/lang.h ../../src/eggdrop.h ../../src/flags.h \
- ../../src/proto.h ../../lush.h ../../src/misc_file.h ../../src/cmdt.h \
- ../../src/tclegg.h ../../src/tclhash.h ../../src/chan.h \
- ../../src/users.h ../../src/compat/compat.h \
- ../../src/compat/inet_ntop.h ../../src/compat/snprintf.h \
- ../../src/compat/memset.h ../../src/compat/memcpy.h \
- ../../src/compat/strcasecmp.h ../../src/compat/strftime.h inet_ntop.h \
- ../../src/compat/inet_aton.h
-memcpy.o: ./memcpy.c ../../src/main.h ../../src/conf.h ../../config.h ../../src/lang.h \
- ../../src/eggdrop.h ../../src/flags.h ../../src/proto.h ../../lush.h \
- ../../src/misc_file.h ../../src/cmdt.h ../../src/tclegg.h \
- ../../src/tclhash.h ../../src/chan.h ../../src/users.h \
- ../../src/compat/compat.h ../../src/compat/inet_aton.h \
- ../../src/compat/snprintf.h ../../src/compat/memset.h \
- ../../src/compat/memcpy.h ../../src/compat/strcasecmp.h \
- ../../src/compat/strftime.h memcpy.h  ../../src/compat/inet_ntop.h
-memset.o: ./memset.c ../../src/main.h ../../src/conf.h ../../config.h ../../src/lang.h \
- ../../src/eggdrop.h ../../src/flags.h ../../src/proto.h ../../lush.h \
- ../../src/misc_file.h ../../src/cmdt.h ../../src/tclegg.h \
- ../../src/tclhash.h ../../src/chan.h ../../src/users.h \
- ../../src/compat/compat.h ../../src/compat/inet_aton.h \
- ../../src/compat/snprintf.h ../../src/compat/memset.h \
- ../../src/compat/memcpy.h ../../src/compat/strcasecmp.h \
- ../../src/compat/strftime.h memset.h  ../../src/compat/inet_ntop.h
-snprintf.o: ./snprintf.c ../../src/main.h ../../src/conf.h ../../config.h \
- ../../src/lang.h ../../src/eggdrop.h ../../src/flags.h \
- ../../src/proto.h ../../lush.h ../../src/misc_file.h ../../src/cmdt.h \
- ../../src/tclegg.h ../../src/tclhash.h ../../src/chan.h \
- ../../src/users.h ../../src/compat/compat.h \
- ../../src/compat/inet_aton.h ../../src/compat/snprintf.h \
- ../../src/compat/memset.h ../../src/compat/memcpy.h \
- ../../src/compat/strcasecmp.h   ../../src/compat/inet_ntop.h \
- ../../src/compat/strftime.h snprintf.h
-strcasecmp.o: ./strcasecmp.c ../../src/main.h ../../src/conf.h ../../config.h \
- ../../src/lang.h ../../src/eggdrop.h ../../src/flags.h \
- ../../src/proto.h ../../lush.h ../../src/misc_file.h ../../src/cmdt.h \
- ../../src/tclegg.h ../../src/tclhash.h ../../src/chan.h \
- ../../src/users.h ../../src/compat/compat.h \
- ../../src/compat/inet_aton.h ../../src/compat/snprintf.h \
- ../../src/compat/memset.h ../../src/compat/memcpy.h \
- ../../src/compat/strcasecmp.h   ../../src/compat/inet_ntop.h \
- ../../src/compat/strftime.h memcpy.h
-strftime.o: ./strftime.c ../../src/main.h ../../src/conf.h ../../config.h \
- ../../src/lang.h ../../src/eggdrop.h ../../src/flags.h \
- ../../src/proto.h ../../lush.h ../../src/misc_file.h ../../src/cmdt.h \
- ../../src/tclegg.h ../../src/tclhash.h ../../src/chan.h \
- ../../src/users.h ../../src/compat/compat.h \
- ../../src/compat/inet_aton.h ../../src/compat/snprintf.h \
- ../../src/compat/memset.h ../../src/compat/memcpy.h \
- ../../src/compat/strcasecmp.h   ../../src/compat/inet_ntop.h \
- ../../src/compat/strftime.h strftime.h
 
 
+#safety hash

+ 0 - 18
src/mod/Makefile.in

@@ -54,24 +54,6 @@ build_msg:
 	fi; \
 	fi; \
 	cd $*.mod && $(MAKE_MOD) 'VPATH=$(MOD_UPDIR)$(srcdir)/$*.mod' 'srcdir=$(MOD_UPDIR)$(srcdir)/$*.mod' static;
 	cd $*.mod && $(MAKE_MOD) 'VPATH=$(MOD_UPDIR)$(srcdir)/$*.mod' 'srcdir=$(MOD_UPDIR)$(srcdir)/$*.mod' static;
 
 
-depleaf:
-	@for i in $(mods); do \
-		if test ! -d $$i; then mkdir $$i; fi; \
-		if test ! -r $$i/Makefile; then \
-			cp $(srcdir)/$$i/Makefile $$i/Makefile; \
-		fi; \
-		(cd $$i && $(MAKE_MOD) "VPATH=$(MOD_UPDIR)$(srcdir)/$$i" "srcdir=$(MOD_UPDIR)$(srcdir)/$$i" depleaf); \
-	done
-
-dephub:
-	@for i in $(mods); do \
-		if test ! -d $$i; then mkdir $$i; fi; \
-		if test ! -r $$i/Makefile; then \
-			cp $(srcdir)/$$i/Makefile $$i/Makefile; \
-		fi; \
-		(cd $$i && $(MAKE_MOD) "VPATH=$(MOD_UPDIR)$(srcdir)/$$i" "srcdir=$(MOD_UPDIR)$(srcdir)/$$i" dephub); \
-	done
-
 config:
 config:
 	@for i in $(mods); do \
 	@for i in $(mods); do \
 		if test -f $(srcdir)/$$i/configure; then \
 		if test -f $(srcdir)/$$i/configure; then \

+ 4 - 22
src/mod/channels.mod/Makefile

@@ -1,7 +1,7 @@
 # Makefile for src/mod/channels.mod/
 # Makefile for src/mod/channels.mod/
 
 
 srcdir = .
 srcdir = .
-
+depcomp = /bin/sh ../../../autotools/depcomp
 
 
 doofus:
 doofus:
 	@echo ""
 	@echo ""
@@ -13,32 +13,14 @@ static: ../channels.o
 
 
 ../channels.o:
 ../channels.o:
 	@echo -e "Compiling: \033[1mchannels\033[0m"
 	@echo -e "Compiling: \033[1mchannels\033[0m"
-	@$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/channels.c
+	@source='channels.c' object='$@' depfile='.deps/channels.Po' tmpdepfile='.deps/channels.TPo' depmode=gcc3 $(depcomp) \
+	$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/channels.c
 	@rm -f ../channels.o
 	@rm -f ../channels.o
 	@mv channels.o ../
 	@mv channels.o ../
 
 
-depleaf:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DLEAF -MM $(srcdir)/channels.c > .depend
-
-dephub:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DHUB -MM $(srcdir)/channels.c > .depend
 
 
 clean:
 clean:
 	@rm -f .depend *.o *~
 	@rm -f .depend *.o *~
+
 distclean: clean
 distclean: clean
 
 
-#safety hash
-../channels.o: .././channels.mod/channels.c ../../../src/mod/module.h \
- ../../../src/main.h ../../../config.h ../../../src/conf.h \
- ../../../src/lang.h \
- ../../../src/eggdrop.h ../../../src/flags.h ../../../src/proto.h \
- ../../../lush.h ../../../src/misc_file.h ../../../src/cmdt.h \
- ../../../src/tclegg.h ../../../src/tclhash.h ../../../src/chan.h \
- ../../../src/users.h ../../../src/compat/compat.h ../../../src/compat/inet_ntop.h \
- ../../../src/compat/inet_aton.h ../../../src/compat/snprintf.h \
- ../../../src/compat/memset.h ../../../src/compat/memcpy.h \
- ../../../src/compat/strcasecmp.h ../../../src/compat/strftime.h \
- ../../../src/mod/modvals.h ../../../src/tandem.h \
- ../channels.mod/channels.h ../channels.mod/cmdschan.c \
- ../channels.mod/tclchan.c ../channels.mod/userchan.c \
- ../channels.mod/udefchan.c

+ 1 - 1
src/mod/channels.mod/channels.c

@@ -8,7 +8,7 @@
 #define MAKING_CHANNELS
 #define MAKING_CHANNELS
 #include <sys/stat.h>
 #include <sys/stat.h>
 #include "src/mod/module.h"
 #include "src/mod/module.h"
-#include "irc.mod/irc.h"
+#include "src/mod/irc.mod/irc.h"
 
 
 static Function *global = NULL, *irc_funcs = NULL;
 static Function *global = NULL, *irc_funcs = NULL;
 
 

+ 4 - 21
src/mod/compress.mod/Makefile

@@ -1,6 +1,7 @@
 # Makefile for src/mod/compress.mod/
 # Makefile for src/mod/compress.mod/
 
 
 srcdir = .
 srcdir = .
+depcomp = /bin/sh ../../../autotools/depcomp
 
 
 
 
 doofus:
 doofus:
@@ -13,31 +14,13 @@ static: ../compress.o
 
 
 ../compress.o:
 ../compress.o:
 	@echo -e "Compiling: \033[1mcompress\033[0m"
 	@echo -e "Compiling: \033[1mcompress\033[0m"
-	@$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/compress.c
+	@source='compress.c' object='$@' depfile='.deps/compress.Po' tmpdepfile='.deps/compress.TPo' depmode=gcc3 $(depcomp) \
+	$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/compress.c
 	@rm -f ../compress.o
 	@rm -f ../compress.o
 	@mv compress.o ../
 	@mv compress.o ../
 
 
-depleaf:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DLEAF -MM $(srcdir)/compress.c > .depend
-
-dephub:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DHUB -MM $(srcdir)/compress.c > .depend
-
 clean:
 clean:
 	@rm -f .depend *.o *~
 	@rm -f .depend *.o *~
+
 distclean: clean
 distclean: clean
 
 
-#safety hash
-../compress.o: .././compress.mod/compress.c ../../../src/mod/module.h \
- ../../../src/main.h ../../../config.h ../../../src/conf.h \
- ../../../src/lang.h \
- ../../../src/eggdrop.h ../../../src/flags.h ../../../src/proto.h \
- ../../../lush.h ../../../src/misc_file.h ../../../src/cmdt.h \
- ../../../src/tclegg.h ../../../src/tclhash.h ../../../src/chan.h \
- ../../../src/users.h ../../../src/compat/compat.h ../../../src/compat/inet_ntop.h \
- ../../../src/compat/inet_aton.h ../../../src/compat/snprintf.h \
- ../../../src/compat/memset.h ../../../src/compat/memcpy.h \
- ../../../src/compat/strcasecmp.h ../../../src/compat/strftime.h \
- ../../../src/mod/modvals.h ../../../src/tandem.h \
- ../../../src/mod/share.mod/share.h \
- ../compress.mod/compress.h 

+ 1 - 1
src/mod/compress.mod/compress.c

@@ -32,7 +32,7 @@
 #include <errno.h>
 #include <errno.h>
 
 
 #include "src/mod/module.h"
 #include "src/mod/module.h"
-#include "share.mod/share.h"
+#include "src/mod/share.mod/share.h"
 
 
 #ifdef HAVE_MMAP
 #ifdef HAVE_MMAP
 #  include <sys/types.h>
 #  include <sys/types.h>

+ 4 - 21
src/mod/console.mod/Makefile

@@ -1,6 +1,7 @@
 # Makefile for src/mod/console.mod/
 # Makefile for src/mod/console.mod/
 
 
 srcdir = .
 srcdir = .
+depcomp = /bin/sh ../../../autotools/depcomp
 
 
 
 
 doofus:
 doofus:
@@ -13,30 +14,12 @@ static: ../console.o
 
 
 ../console.o:
 ../console.o:
 	@echo -e "Compiling: \033[1mconsole\033[0m"
 	@echo -e "Compiling: \033[1mconsole\033[0m"
-	@$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/console.c
+	@source='console.c' object='$@' depfile='.deps/console.Po' tmpdepfile='.deps/console.TPo' depmode=gcc3 $(depcomp) \
+	$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/console.c
 	@rm -f ../console.o
 	@rm -f ../console.o
 	@mv console.o ../
 	@mv console.o ../
 
 
-depleaf:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DLEAF -MM $(srcdir)/console.c > .depend
-
-dephub:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DHUB -MM $(srcdir)/console.c > .depend
-
 clean:
 clean:
 	@rm -f .depend *.o *~
 	@rm -f .depend *.o *~
-distclean: clean
 
 
-#safety hash
-../console.o: .././console.mod/console.c ../../../src/mod/module.h \
- ../../../src/main.h ../../../config.h ../../../src/conf.h \
- ../../../src/lang.h \
- ../../../src/eggdrop.h ../../../src/flags.h ../../../src/proto.h \
- ../../../lush.h ../../../src/misc_file.h ../../../src/cmdt.h \
- ../../../src/tclegg.h ../../../src/tclhash.h ../../../src/chan.h \
- ../../../src/users.h ../../../src/compat/compat.h ../../../src/compat/inet_ntop.h \
- ../../../src/compat/inet_aton.h ../../../src/compat/snprintf.h \
- ../../../src/compat/memset.h ../../../src/compat/memcpy.h \
- ../../../src/compat/strcasecmp.h ../../../src/compat/strftime.h \
- ../../../src/mod/modvals.h ../../../src/tandem.h \
- ../console.mod/console.h
+distclean: clean

+ 4 - 21
src/mod/ctcp.mod/Makefile

@@ -1,6 +1,7 @@
 # Makefile for src/mod/ctcp.mod/
 # Makefile for src/mod/ctcp.mod/
 
 
 srcdir = .
 srcdir = .
+depcomp = /bin/sh ../../../autotools/depcomp
 
 
 
 
 doofus:
 doofus:
@@ -13,30 +14,12 @@ static: ../ctcp.o
 
 
 ../ctcp.o:
 ../ctcp.o:
 	@echo -e "Compiling: \033[1mctcp\033[0m"
 	@echo -e "Compiling: \033[1mctcp\033[0m"
-	@$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/ctcp.c
+	@source='ctcp.c' object='$@' depfile='.deps/ctcp.Po' tmpdepfile='.deps/ctcp.TPo' depmode=gcc3 $(depcomp) \
+	$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/ctcp.c
 	@rm -f ../ctcp.o
 	@rm -f ../ctcp.o
 	@mv ctcp.o ../
 	@mv ctcp.o ../
 
 
-depleaf:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DLEAF -MM $(srcdir)/ctcp.c > .depend
-
-dephub:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DHUB -MM $(srcdir)/ctcp.c > .depend
-
 clean:
 clean:
 	@rm -f .depend *.o *~
 	@rm -f .depend *.o *~
-distclean: clean
 
 
-#safety hash
-../ctcp.o: .././ctcp.mod/ctcp.c ../ctcp.mod/ctcp.h \
- ../../../src/mod/module.h \
- ../../../src/main.h ../../../config.h ../../../src/conf.h \
- ../../../src/lang.h ../../../src/eggdrop.h ../../../src/flags.h \
- ../../../src/proto.h ../../../lush.h ../../../src/misc_file.h \
- ../../../src/cmdt.h ../../../src/tclegg.h ../../../src/tclhash.h \
- ../../../src/chan.h ../../../src/users.h ../../../src/compat/compat.h ../../../src/compat/inet_ntop.h  \
- ../../../src/compat/inet_aton.h ../../../src/compat/snprintf.h \
- ../../../src/compat/memset.h ../../../src/compat/memcpy.h \
- ../../../src/compat/strcasecmp.h ../../../src/compat/strftime.h \
- ../../../src/mod/modvals.h ../../../src/tandem.h \
- ../../../src/mod/server.mod/server.h
+distclean: clean

+ 1 - 16
src/mod/dns.mod/Makefile.in

@@ -16,12 +16,10 @@ static: ../dns.o
 
 
 ../dns.o:
 ../dns.o:
 	@echo -e "Compiling: \033[1mdns\033[0m"
 	@echo -e "Compiling: \033[1mdns\033[0m"
-	@$(CC) $(CFLAGS) $(CPPFLAGS) $(RESINCLUDE) -DMAKING_MODS -c $(srcdir)/dns.c
+	@$(CC) $(CFLAGS) $(CPPFLAGS) $(RESINCLUDE) -DMAKING_MODS -c -MT ../dns.o -MD -MP -MF $(srcdir)/.deps/dns.Po $(srcdir)/dns.c
 	@rm -f ../dns.o
 	@rm -f ../dns.o
 	@mv dns.o ../
 	@mv dns.o ../
 
 
-depend:
-	@$(CC) $(CFLAGS) $(CPPFLAGS) -MM $(srcdir)/dns.c > .depend
 
 
 clean:
 clean:
 	@rm -f .depend *.o *~
 	@rm -f .depend *.o *~
@@ -29,16 +27,3 @@ clean:
 distclean: clean
 distclean: clean
 	@rm -f Makefile config.cache config.log config.status
 	@rm -f Makefile config.cache config.log config.status
 
 
-#safety hash
-../dns.o: .././dns.mod/dns.c ../../../src/mod/module.h \
- ../../../src/main.h ../../../config.h ../../../src/conf.h \
- ../../../src/lang.h \
- ../../../src/eggdrop.h ../../../src/flags.h ../../../src/proto.h \
- ../../../lush.h ../../../src/misc_file.h ../../../src/cmdt.h \
- ../../../src/tclegg.h ../../../src/tclhash.h ../../../src/chan.h \
- ../../../src/users.h ../../../src/compat/compat.h ../../../src/compat/inet_ntop.h \
- ../../../src/compat/inet_aton.h ../../../src/compat/snprintf.h \
- ../../../src/compat/memset.h ../../../src/compat/memcpy.h \
- ../../../src/compat/strcasecmp.h ../../../src/compat/strftime.h \
- ../../../src/mod/modvals.h ../../../src/tandem.h ../dns.mod/dns.h \
- ../dns.mod/coredns.c

+ 4 - 22
src/mod/irc.mod/Makefile

@@ -1,6 +1,7 @@
 # Makefile for src/mod/irc.mod/
 # Makefile for src/mod/irc.mod/
 
 
 srcdir = .
 srcdir = .
+depcomp = /bin/sh ../../../autotools/depcomp
 
 
 
 
 doofus:
 doofus:
@@ -13,33 +14,14 @@ static: ../irc.o
 
 
 ../irc.o:
 ../irc.o:
 	@echo -e "Compiling: \033[1mirc\033[0m"
 	@echo -e "Compiling: \033[1mirc\033[0m"
-	@$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/irc.c
+	@source='irc.c' object='$@' depfile='.deps/irc.Po' tmpdepfile='.deps/irc.TPo' depmode=gcc3 $(depcomp) \
+	$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/irc.c
 	@rm -f ../irc.o
 	@rm -f ../irc.o
 	@mv irc.o ../
 	@mv irc.o ../
 
 
 
 
-depleaf:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DLEAF -MM $(srcdir)/irc.c > .depend
-
-dephub:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DHUB -MM $(srcdir)/irc.c > .depend
-
 clean:
 clean:
 	@rm -f .depend *.o *~
 	@rm -f .depend *.o *~
+
 distclean: clean
 distclean: clean
 
 
-#safety hash
-../irc.o: .././irc.mod/irc.c ../../../src/mod/module.h \
- ../../../src/main.h ../../../config.h ../../../src/conf.h \
- ../../../src/lang.h \
- ../../../src/eggdrop.h ../../../src/flags.h ../../../src/proto.h \
- ../../../lush.h ../../../src/misc_file.h ../../../src/cmdt.h \
- ../../../src/tclegg.h ../../../src/tclhash.h ../../../src/chan.h \
- ../../../src/users.h ../../../src/compat/compat.h ../../../src/compat/inet_ntop.h \
- ../../../src/compat/inet_aton.h ../../../src/compat/snprintf.h \
- ../../../src/compat/memset.h ../../../src/compat/memcpy.h \
- ../../../src/compat/strcasecmp.h ../../../src/compat/strftime.h \
- ../../../src/mod/modvals.h ../../../src/tandem.h ../irc.mod/irc.h \
- ../../../src/mod/server.mod/server.h \
- ../../../src/mod/channels.mod/channels.h ../irc.mod/chan.c \
- ../irc.mod/mode.c ../irc.mod/cmdsirc.c ../irc.mod/msgcmds.c 

+ 2 - 2
src/mod/irc.mod/irc.c

@@ -9,9 +9,9 @@
 #define MAKING_IRC
 #define MAKING_IRC
 #include "src/mod/module.h"
 #include "src/mod/module.h"
 #include "irc.h"
 #include "irc.h"
-#include "server.mod/server.h"
+#include "src/mod/server.mod/server.h"
 #undef serv
 #undef serv
-#include "channels.mod/channels.h"
+#include "src/mod/channels.mod/channels.h"
 
 
 #define OP_BOTS (CFG_OPBOTS.gdata ? atoi(CFG_OPBOTS.gdata) : 1)
 #define OP_BOTS (CFG_OPBOTS.gdata ? atoi(CFG_OPBOTS.gdata) : 1)
 #define IN_BOTS (CFG_INBOTS.gdata ? atoi(CFG_INBOTS.gdata) : 1)
 #define IN_BOTS (CFG_INBOTS.gdata ? atoi(CFG_INBOTS.gdata) : 1)

+ 4 - 20
src/mod/notes.mod/Makefile

@@ -1,6 +1,7 @@
 # Makefile for src/mod/notes.mod
 # Makefile for src/mod/notes.mod
 
 
 srcdir = .
 srcdir = .
+depcomp = /bin/sh ../../../autotools/depcomp
 
 
 
 
 doofus:
 doofus:
@@ -13,30 +14,13 @@ static: ../notes.o
 
 
 ../notes.o:
 ../notes.o:
 	@echo -e "Compiling: \033[1mnotes\033[0m"
 	@echo -e "Compiling: \033[1mnotes\033[0m"
-	@$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/notes.c
+	@source='notes.c' object='$@' depfile='.deps/notes.Po' tmpdepfile='.deps/notes.TPo' depmode=gcc3 $(depcomp) \
+	$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/notes.c
 	@rm -f ../notes.o
 	@rm -f ../notes.o
 	@mv notes.o ../
 	@mv notes.o ../
 
 
-depleaf:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DLEAF -MM $(srcdir)/notes.c > .depend
-
-dephub:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DHUB -MM $(srcdir)/notes.c > .depend
-
 clean:
 clean:
 	@rm -f .depend *.o *~
 	@rm -f .depend *.o *~
+
 distclean: clean
 distclean: clean
 
 
-#safety hash
-../notes.o: .././notes.mod/notes.c ../../../src/mod/module.h \
- ../../../src/main.h ../../../config.h ../../../src/conf.h \
- ../../../src/lang.h \
- ../../../src/eggdrop.h ../../../src/flags.h ../../../src/proto.h \
- ../../../lush.h ../../../src/misc_file.h ../../../src/cmdt.h \
- ../../../src/tclegg.h ../../../src/tclhash.h ../../../src/chan.h \
- ../../../src/users.h ../../../src/compat/compat.h ../../../src/compat/inet_ntop.h \
- ../../../src/compat/inet_aton.h ../../../src/compat/snprintf.h \
- ../../../src/compat/memset.h ../../../src/compat/memcpy.h \
- ../../../src/compat/strcasecmp.h ../../../src/compat/strftime.h \
- ../../../src/mod/modvals.h ../../../src/tandem.h ../notes.mod/notes.h \
- ../notes.mod/cmdsnote.c

+ 4 - 22
src/mod/server.mod/Makefile

@@ -1,6 +1,7 @@
 # Makefile for src/mod/server.mod/
 # Makefile for src/mod/server.mod/
 
 
 srcdir = .
 srcdir = .
+depcomp = /bin/sh ../../../autotools/depcomp
 
 
 
 
 doofus:
 doofus:
@@ -13,31 +14,12 @@ static: ../server.o
 
 
 ../server.o:
 ../server.o:
 	@echo -e "Compiling: \033[1mserver\033[0m"
 	@echo -e "Compiling: \033[1mserver\033[0m"
-	@$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/server.c
+	@source='server.c' object='$@' depfile='.deps/server.Po' tmpdepfile='.deps/server.TPo' depmode=gcc3 $(depcomp) \
+	$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/server.c
 	@rm -f ../server.o
 	@rm -f ../server.o
 	@mv server.o ../
 	@mv server.o ../
 
 
-depleaf:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DLEAF -MM $(srcdir)/server.c > .depend
-
-dephub:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DHUB -MM $(srcdir)/server.c > .depend
-
 clean:
 clean:
 	@rm -f .depend *.o *~
 	@rm -f .depend *.o *~
-distclean: clean
 
 
-#safety hash
-../server.o: .././server.mod/server.c ../../../src/mod/module.h \
- ../../../src/main.h ../../../config.h ../../../src/conf.h \
- ../../../src/lang.h \
- ../../../src/eggdrop.h ../../../src/flags.h ../../../src/proto.h \
- ../../../lush.h ../../../src/misc_file.h ../../../src/cmdt.h \
- ../../../src/tclegg.h ../../../src/tclhash.h ../../../src/chan.h \
- ../../../src/users.h ../../../src/compat/compat.h ../../../src/compat/inet_ntop.h \
- ../../../src/compat/inet_aton.h ../../../src/compat/snprintf.h \
- ../../../src/compat/memset.h ../../../src/compat/memcpy.h \
- ../../../src/compat/strcasecmp.h ../../../src/compat/strftime.h \
- ../../../src/mod/modvals.h ../../../src/tandem.h \
- ../server.mod/server.h ../server.mod/servmsg.c \
- ../server.mod/cmdsserv.c
+distclean: clean

+ 4 - 23
src/mod/share.mod/Makefile

@@ -1,6 +1,7 @@
 # Makefile for src/mod/share.mod/
 # Makefile for src/mod/share.mod/
 
 
 srcdir = .
 srcdir = .
+depcomp = /bin/sh ../../../autotools/depcomp
 
 
 
 
 doofus:
 doofus:
@@ -13,33 +14,13 @@ static: ../share.o
 
 
 ../share.o:
 ../share.o:
 	@echo -e "Compiling: \033[1mshare\033[0m"
 	@echo -e "Compiling: \033[1mshare\033[0m"
-	@$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/share.c
+	@source='share.c' object='$@' depfile='.deps/share.Po' tmpdepfile='.deps/share.TPo' depmode=gcc3 $(depcomp) \
+	$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/share.c
 	@rm -f ../share.o
 	@rm -f ../share.o
 	@mv share.o ../
 	@mv share.o ../
 
 
-depleaf:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DLEAF -MM $(srcdir)/share.c > .depend
-
-dephub:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DHUB -MM $(srcdir)/share.c > .depend
-
 clean:
 clean:
 	@rm -f .depend *.o *~
 	@rm -f .depend *.o *~
+
 distclean: clean
 distclean: clean
 
 
-#safety hash
-../share.o: .././share.mod/share.c ../../../src/mod/module.h \
- ../../../src/main.h ../../../config.h ../../../src/conf.h \
- ../../../src/lang.h \
- ../../../src/eggdrop.h ../../../src/flags.h ../../../src/proto.h \
- ../../../lush.h ../../../src/misc_file.h ../../../src/cmdt.h \
- ../../../src/tclegg.h ../../../src/tclhash.h ../../../src/chan.h \
- ../../../src/users.h ../../../src/compat/compat.h ../../../src/compat/inet_ntop.h \
- ../../../src/compat/inet_aton.h ../../../src/compat/snprintf.h \
- ../../../src/compat/memset.h ../../../src/compat/memcpy.h \
- ../../../src/compat/strcasecmp.h ../../../src/compat/strftime.h \
- ../../../src/mod/modvals.h ../../../src/tandem.h \
- ../../../src/mod/transfer.mod/transfer.h \
- ../../../src/mod/irc.mod/irc.h \
- ../../../src/mod/channels.mod/channels.h ../share.mod/share.h \
- ../share.mod/uf_features.c

+ 2 - 2
src/mod/share.mod/share.c

@@ -14,8 +14,8 @@
 
 
 #include "src/chan.h"
 #include "src/chan.h"
 #include "src/users.h"
 #include "src/users.h"
-#include "transfer.mod/transfer.h"
-#include "channels.mod/channels.h"
+#include "src/mod/transfer.mod/transfer.h"
+#include "src/mod/channels.mod/channels.h"
 #ifdef LEAF
 #ifdef LEAF
 #  include "irc.mod/irc.h"
 #  include "irc.mod/irc.h"
 #endif /* LEAF */
 #endif /* LEAF */

+ 4 - 20
src/mod/transfer.mod/Makefile

@@ -1,6 +1,7 @@
 # Makefile for src/mod/transfer.mod/
 # Makefile for src/mod/transfer.mod/
 
 
 srcdir = .
 srcdir = .
+depcomp = /bin/sh ../../../autotools/depcomp
 
 
 
 
 doofus:
 doofus:
@@ -13,30 +14,13 @@ static: ../transfer.o
 
 
 ../transfer.o:
 ../transfer.o:
 	@echo -e "Compiling: \033[1mtransfer\033[0m"
 	@echo -e "Compiling: \033[1mtransfer\033[0m"
-	@$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/transfer.c
+	@source='transfer.c' object='$@' depfile='.deps/transfer.Po' tmpdepfile='.deps/transfer.TPo' depmode=gcc3 $(depcomp) \
+	$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/transfer.c
 	@rm -f ../transfer.o
 	@rm -f ../transfer.o
 	@mv transfer.o ../
 	@mv transfer.o ../
 
 
-depleaf:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DLEAF -MM $(srcdir)/transfer.c > .depend
-
-dephub:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DHUB -MM $(srcdir)/transfer.c > .depend
-
 clean:
 clean:
 	@rm -f .depend *.o *~
 	@rm -f .depend *.o *~
+
 distclean: clean
 distclean: clean
 
 
-#safety hash
-../transfer.o: .././transfer.mod/transfer.c ../../../src/mod/module.h \
- ../../../src/main.h ../../../config.h ../../../src/conf.h \
- ../../../src/lang.h \
- ../../../src/eggdrop.h ../../../src/flags.h ../../../src/proto.h \
- ../../../lush.h ../../../src/misc_file.h ../../../src/cmdt.h \
- ../../../src/tclegg.h ../../../src/tclhash.h ../../../src/chan.h \
- ../../../src/users.h ../../../src/compat/compat.h ../../../src/compat/inet_ntop.h \
- ../../../src/compat/inet_aton.h ../../../src/compat/snprintf.h \
- ../../../src/compat/memset.h ../../../src/compat/memcpy.h \
- ../../../src/compat/strcasecmp.h ../../../src/compat/strftime.h \
- ../../../src/mod/modvals.h ../../../src/tandem.h \
- ../transfer.mod/transfer.h

+ 4 - 22
src/mod/update.mod/Makefile

@@ -1,6 +1,7 @@
 # Makefile for src/mod/update.mod/
 # Makefile for src/mod/update.mod/
 
 
 srcdir = .
 srcdir = .
+depcomp = /bin/sh ../../../autotools/depcomp
 
 
 
 
 doofus:
 doofus:
@@ -13,32 +14,13 @@ static: ../update.o
 
 
 ../update.o:
 ../update.o:
 	@echo -e "Compiling: \033[1mupdate\033[0m"
 	@echo -e "Compiling: \033[1mupdate\033[0m"
-	@$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/update.c
+	@source='update.c' object='$@' depfile='.deps/update.Po' tmpdepfile='.deps/update.TPo' depmode=gcc3 $(depcomp) \
+	$(CC) $(CFLAGS) $(CPPFLAGS) -DMAKING_MODS -c $(srcdir)/update.c
 	@rm -f ../update.o
 	@rm -f ../update.o
 	@mv update.o ../
 	@mv update.o ../
 
 
-depleaf:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DLEAF -MM $(srcdir)/update.c > .depend
-
-dephub:
-	$(CC) $(CFLAGS) $(CPPFLAGS) -DHUB -MM $(srcdir)/update.c > .depend
-
 clean:
 clean:
 	@rm -f .depend *.o *~
 	@rm -f .depend *.o *~
+
 distclean: clean
 distclean: clean
 
 
-#safety hash
-../update.o: .././update.mod/update.c ../../../src/mod/module.h \
- ../../../src/main.h ../../../config.h ../../../src/conf.h \
- ../../../src/lang.h \
- ../../../src/eggdrop.h ../../../src/flags.h ../../../src/proto.h \
- ../../../lush.h ../../../src/misc_file.h ../../../src/cmdt.h \
- ../../../src/tclegg.h ../../../src/tclhash.h \
- ../../../src/users.h ../../../src/compat/compat.h ../../../src/compat/inet_ntop.h \
- ../../../src/compat/inet_aton.h ../../../src/compat/snprintf.h \
- ../../../src/compat/memset.h ../../../src/compat/memcpy.h \
- ../../../src/compat/strcasecmp.h ../../../src/compat/strftime.h \
- ../../../src/mod/modvals.h ../../../src/tandem.h \
- ../../../src/mod/transfer.mod/transfer.h \
- ../../../src/mod/compress.mod/compress.c \
- ../update.mod/update.h

+ 2 - 2
src/mod/update.mod/update.c

@@ -18,8 +18,8 @@
 #include <unistd.h>
 #include <unistd.h>
 
 
 
 
-#include "transfer.mod/transfer.h"
-#include "compress.mod/compress.h"
+#include "src/mod/transfer.mod/transfer.h"
+#include "src/mod/compress.mod/compress.h"
 
 
 static Function *global = NULL, *transfer_funcs = NULL, *compress_funcs = NULL,
 static Function *global = NULL, *transfer_funcs = NULL, *compress_funcs = NULL,
                 *uncompress_funcs = NULL;
                 *uncompress_funcs = NULL;