diff -Nru mldonkey-3.0.7/config/configure mldonkey-3.1.0/config/configure --- mldonkey-3.0.7/config/configure 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/config/configure 2011-08-08 05:11:57.000000000 +0000 @@ -1,7 +1,7 @@ #! /bin/sh # From configure.in norev. # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.67. +# Generated by GNU Autoconf 2.68. # # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -90,6 +90,7 @@ IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. +as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -215,11 +216,18 @@ # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also # works around shells that cannot unset nonexistent variables. + # Preserve -v and -x to the replacement shell. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV export CONFIG_SHELL - exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} + case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; + esac + exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"} fi if test x$as_have_required = xno; then : @@ -1200,7 +1208,7 @@ $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 - : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} + : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" ;; esac @@ -1409,36 +1417,44 @@ --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] - --disable-multinet allows you to only compile support for eDonkey (incl. Overnet and Kademlia) - --enable-minimum compile MLDonkey with minimum features and Networks (eDonkey, iconv and thread enabled) - --enable-minimum=all disable all optional features and Networks excepting eDonkey - --disable-directconnect allows you to remove support for Direct Connect - --disable-donkey allows you to remove support for eDonkey - --disable-donkeysui allows you to remove support for eMule SecureUserIdent - --disable-bittorrent allows you to remove support for Bittorent - --disable-filetp allows you to remove support for fileTP - --disable-gnutella allows you to remove support for Gnutella - --disable-gnutella2 allows you to remove support for Gnutella2 - --disable-fasttrack allows you to remove support for FastTrack + --disable-multinet disable all networks except eDonkey (with Overnet + and Kademlia) + --enable-minimum enable minimum set of features and networks + (eDonkey, iconv and threads enabled) + --enable-minimum=all enable only eDonkey network and disable all optional + features (not recommended) + --disable-directconnect disable support for Direct Connect + --disable-donkey disable support for eDonkey + --disable-donkeysui disable support for eMule SecureUserIdent + --disable-bittorrent disable support for Bittorent + --disable-filetp disable support for fileTP + --disable-gnutella disable support for Gnutella + --disable-gnutella2 disable support for Gnutella2 + --disable-fasttrack disable support for FastTrack --enable-batch reply YES to all queries in this script --enable-force-ocaml force usage of self-compiled Ocaml - --enable-ocamlver=VER force usage of specific Ocaml version (3.10.1|CVS), - --enable-mingw forces compilation with MINGW on Cygwin - --enable-checks force mldonkey to perform bound checks on array/string access - --enable-profile allows you to profile mlnet using gprof (enables debug) - --enable-debug allows you to compile mlnet with debug symbols - --disable-gui allows you to disable GUI build (default) + --enable-ocamlver=VER force usage of specific Ocaml version (3.10.1|SVN), + --enable-mingw force compilation with MINGW on Cygwin + --enable-checks enable bounds-checking for array/string accesses + --enable-profile compile with gprof profiling support (enables debug) + --enable-debug compile with debugging information + --disable-gui disable GUI build (default) --enable-gui=oldgui|newgui1|newgui2 - allows you to choose a GUI (default: newgui2 - is a GTK2 GUI, other GUIs use GTK1) - --disable-pthread allows you to disable pthread support in mldonkey, hurts performance! + enable GUI (newgui2 uses GTK2 (default), other GUIs + use GTK1) + --disable-pthread disable the use of pthread, hurts performance! --enable-pthread-lib legacy option --disable-iconv disable the use of iconv --disable-gd disable the use of gd --disable-bzip2 disable the use of bzip2 --disable-magic disable the use of libmagic (GNU file) --enable-upnp-natpmp enable the use of libminiupnpc and libnatpmp - --enable-force-upnp-natpmp force local compilation of libminiupnpc and libnatpmp - --enable-local-prefix=DIR allows you to specify where you want temporary tools to be installed (DIR must be absolute) + --enable-force-upnp-natpmp + force local compilation of libminiupnpc and + libnatpmp + --enable-local-prefix=DIR + specify path for temporary tools installation (DIR + must be absolute) --disable-largefile omit support for large files --disable-rpath do not hardcode runtime library paths @@ -1528,7 +1544,7 @@ if $ac_init_version; then cat <<\_ACEOF configure -generated by GNU Autoconf 2.67 +generated by GNU Autoconf 2.68 Copyright (C) 2010 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation @@ -1574,7 +1590,7 @@ ac_retval=1 fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_compile @@ -1611,7 +1627,7 @@ ac_retval=1 fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_cpp @@ -1653,7 +1669,7 @@ ac_retval=$ac_status fi rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_run @@ -1667,7 +1683,7 @@ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if eval "test \"\${$3+set}\"" = set; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -1685,7 +1701,7 @@ eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_compile @@ -1730,7 +1746,7 @@ # interfere with the next link command; also delete a directory that is # left behind by Apple's compiler. We do this before executing the actions. rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_link @@ -1743,7 +1759,7 @@ as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if eval "test \"\${$3+set}\"" = set; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -1798,7 +1814,7 @@ eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_func @@ -1810,10 +1826,10 @@ ac_fn_c_check_header_mongrel () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if eval "test \"\${$3+set}\"" = set; then : + if eval \${$3+:} false; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if eval "test \"\${$3+set}\"" = set; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 fi eval ac_res=\$$3 @@ -1876,7 +1892,7 @@ esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if eval "test \"\${$3+set}\"" = set; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=\$ac_header_compiler" @@ -1885,7 +1901,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_mongrel @@ -1900,7 +1916,7 @@ as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 $as_echo_n "checking whether $as_decl_name is declared... " >&6; } -if eval "test \"\${$3+set}\"" = set; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -1931,7 +1947,7 @@ eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_decl @@ -1968,7 +1984,7 @@ ac_retval=1 fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_cxx_try_compile @@ -1977,7 +1993,7 @@ running configure, to aid debugging if configure makes a mistake. It was created by $as_me, which was -generated by GNU Autoconf 2.67. Invocation command line was +generated by GNU Autoconf 2.68. Invocation command line was $ $0 $@ @@ -2235,7 +2251,7 @@ || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "failed to load site script $ac_site_file -See \`config.log' for more details" "$LINENO" 5 ; } +See \`config.log' for more details" "$LINENO" 5; } fi done @@ -2340,8 +2356,8 @@ # ********** ********** MAJOR_VERSION=3 -MINOR_VERSION=0 -SUB_VERSION=7 # range 0-7 due to eMule limitations +MINOR_VERSION=1 +SUB_VERSION=0 # range 0-7 due to eMule limitations # ********** ********** # ********** check for C compiler ********** @@ -2357,7 +2373,7 @@ set dummy ${ac_tool_prefix}gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -2397,7 +2413,7 @@ set dummy gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : +if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then @@ -2450,7 +2466,7 @@ set dummy ${ac_tool_prefix}cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -2490,7 +2506,7 @@ set dummy cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -2549,7 +2565,7 @@ set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -2593,7 +2609,7 @@ set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : +if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then @@ -2648,7 +2664,7 @@ test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "no acceptable C compiler found in \$PATH -See \`config.log' for more details" "$LINENO" 5 ; } +See \`config.log' for more details" "$LINENO" 5; } # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 @@ -2763,7 +2779,7 @@ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error 77 "C compiler cannot create executables -See \`config.log' for more details" "$LINENO" 5 ; } +See \`config.log' for more details" "$LINENO" 5; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } @@ -2806,7 +2822,7 @@ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details" "$LINENO" 5 ; } +See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest conftest$ac_cv_exeext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 @@ -2865,7 +2881,7 @@ $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot run C compiled programs. If you meant to cross compile, use \`--host'. -See \`config.log' for more details" "$LINENO" 5 ; } +See \`config.log' for more details" "$LINENO" 5; } fi fi fi @@ -2876,7 +2892,7 @@ ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 $as_echo_n "checking for suffix of object files... " >&6; } -if test "${ac_cv_objext+set}" = set; then : +if ${ac_cv_objext+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -2917,7 +2933,7 @@ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of object files: cannot compile -See \`config.log' for more details" "$LINENO" 5 ; } +See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi @@ -2927,7 +2943,7 @@ ac_objext=$OBJEXT { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if test "${ac_cv_c_compiler_gnu+set}" = set; then : +if ${ac_cv_c_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -2964,7 +2980,7 @@ ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } -if test "${ac_cv_prog_cc_g+set}" = set; then : +if ${ac_cv_prog_cc_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_c_werror_flag=$ac_c_werror_flag @@ -3042,7 +3058,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if test "${ac_cv_prog_cc_c89+set}" = set; then : +if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no @@ -3151,7 +3167,7 @@ CPP= fi if test -z "$CPP"; then - if test "${ac_cv_prog_CPP+set}" = set; then : + if ${ac_cv_prog_CPP+:} false; then : $as_echo_n "(cached) " >&6 else # Double quotes because CPP needs to be expanded @@ -3267,7 +3283,7 @@ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details" "$LINENO" 5 ; } +See \`config.log' for more details" "$LINENO" 5; } fi ac_ext=c @@ -3316,7 +3332,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 $as_echo_n "checking build system type... " >&6; } -if test "${ac_cv_build+set}" = set; then : +if ${ac_cv_build+:} false; then : $as_echo_n "(cached) " >&6 else ac_build_alias=$build_alias @@ -3332,7 +3348,7 @@ $as_echo "$ac_cv_build" >&6; } case $ac_cv_build in *-*-*) ;; -*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5 ;; +*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; esac build=$ac_cv_build ac_save_IFS=$IFS; IFS='-' @@ -3350,7 +3366,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 $as_echo_n "checking host system type... " >&6; } -if test "${ac_cv_host+set}" = set; then : +if ${ac_cv_host+:} false; then : $as_echo_n "(cached) " >&6 else if test "x$host_alias" = x; then @@ -3365,7 +3381,7 @@ $as_echo "$ac_cv_host" >&6; } case $ac_cv_host in *-*-*) ;; -*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5 ;; +*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; esac host=$ac_cv_host ac_save_IFS=$IFS; IFS='-' @@ -3496,7 +3512,7 @@ set dummy sed; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_SED+set}" = set; then : +if ${ac_cv_prog_SED+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$SED"; then @@ -3536,7 +3552,7 @@ set dummy grep; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_GREP+set}" = set; then : +if ${ac_cv_prog_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$GREP"; then @@ -3641,7 +3657,7 @@ set dummy svnversion; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_SVNVERSION+set}" = set; then : +if ${ac_cv_prog_SVNVERSION+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$SVNVERSION"; then @@ -3692,7 +3708,7 @@ set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_STAT+set}" = set; then : +if ${ac_cv_prog_STAT+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$STAT"; then @@ -3734,7 +3750,7 @@ set dummy sed; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_SED+set}" = set; then : +if ${ac_cv_prog_SED+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$SED"; then @@ -3772,7 +3788,7 @@ set dummy cut; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CUT+set}" = set; then : +if ${ac_cv_prog_CUT+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CUT"; then @@ -3815,7 +3831,7 @@ set dummy grep; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_GREP+set}" = set; then : +if ${ac_cv_prog_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$GREP"; then @@ -3857,7 +3873,7 @@ set dummy grep; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_GREP+set}" = set; then : +if ${ac_cv_prog_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$GREP"; then @@ -4023,14 +4039,14 @@ ICONV=no fi -#AC_ARG_ENABLE(soulseek, [ --disable-soulseek allows you to remove support for SoulSeek], [SOULSEEK="$enableval"]) -#AC_ARG_ENABLE(opennap, [ --disable-opennap allows you to remove support for Open Napster], [OPEN_NAPSTER="$enableval"]) +#AC_ARG_ENABLE(soulseek, [ --disable-soulseek disable support for SoulSeek], [SOULSEEK="$enableval"]) +#AC_ARG_ENABLE(opennap, [ --disable-opennap disable support for Open Napster], [OPEN_NAPSTER="$enableval"]) # Check whether --enable-directconnect was given. if test "${enable_directconnect+set}" = set; then : enableval=$enable_directconnect; DIRECT_CONNECT="$enableval" fi -#AC_ARG_ENABLE(openft, [ --disable-openft allows you to remove support for OpenFT], [OPENFT="$enableval"]) +#AC_ARG_ENABLE(openft, [ --disable-openft disable support for OpenFT], [OPENFT="$enableval"]) # Check whether --enable-donkey was given. if test "${enable_donkey+set}" = set; then : @@ -4191,7 +4207,7 @@ set dummy ${ac_tool_prefix}ranlib; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_RANLIB+set}" = set; then : +if ${ac_cv_prog_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$RANLIB"; then @@ -4231,7 +4247,7 @@ set dummy ranlib; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then : +if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_RANLIB"; then @@ -4282,7 +4298,7 @@ set dummy gmake; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_GNU_MAKE+set}" = set; then : +if ${ac_cv_prog_GNU_MAKE+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$GNU_MAKE"; then @@ -4319,7 +4335,7 @@ set dummy make; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_GNU_MAKE+set}" = set; then : +if ${ac_cv_prog_GNU_MAKE+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$GNU_MAKE"; then @@ -4373,7 +4389,7 @@ set dummy bzip2; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_COMPRESS+set}" = set; then : +if ${ac_cv_prog_COMPRESS+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$COMPRESS"; then @@ -4410,7 +4426,7 @@ set dummy gzip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_COMPRESS+set}" = set; then : +if ${ac_cv_prog_COMPRESS+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$COMPRESS"; then @@ -4454,7 +4470,7 @@ set dummy perl; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_PERL+set}" = set; then : +if ${ac_cv_path_PERL+:} false; then : $as_echo_n "(cached) " >&6 else case $PERL in @@ -4495,7 +4511,7 @@ set dummy rpmbuild; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_RPMBUILD+set}" = set; then : +if ${ac_cv_prog_RPMBUILD+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$RPMBUILD"; then @@ -4532,7 +4548,7 @@ set dummy rpm; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_RPMBUILD+set}" = set; then : +if ${ac_cv_prog_RPMBUILD+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$RPMBUILD"; then @@ -4570,7 +4586,7 @@ set dummy wget; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_WGET+set}" = set; then : +if ${ac_cv_prog_WGET+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$WGET"; then @@ -4609,7 +4625,7 @@ set dummy wget; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_WGET+set}" = set; then : +if ${ac_cv_path_WGET+:} false; then : $as_echo_n "(cached) " >&6 else case $WGET in @@ -4675,7 +4691,7 @@ set dummy ocamlc.opt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_OCAMLC+set}" = set; then : +if ${ac_cv_path_OCAMLC+:} false; then : $as_echo_n "(cached) " >&6 else case $OCAMLC in @@ -4718,7 +4734,7 @@ set dummy ${ac_tool_prefix}ocamlc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_OCAMLC+set}" = set; then : +if ${ac_cv_prog_OCAMLC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OCAMLC"; then @@ -4758,7 +4774,7 @@ set dummy ocamlc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_OCAMLC+set}" = set; then : +if ${ac_cv_prog_ac_ct_OCAMLC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OCAMLC"; then @@ -4809,7 +4825,7 @@ set dummy camlp4; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_CAMLP4+set}" = set; then : +if ${ac_cv_path_CAMLP4+:} false; then : $as_echo_n "(cached) " >&6 else case $CAMLP4 in @@ -4849,7 +4865,7 @@ BUILD_OCAML=no -if test -z "$OCAMLC" || test -z "$CAMLP4" || test "$REQUIRED_OCAML" = "CVS" ; then +if test -z "$OCAMLC" || test -z "$CAMLP4" || test "$REQUIRED_OCAML" = "SVN" ; then BUILD_OCAML=yes else OCAMLVERSION=`$OCAMLC -v | sed -n -e 's|.*version* *\(.*\)$|\1|p' ` @@ -4881,7 +4897,7 @@ else echo "******** Objective-Caml $REQUIRED_OCAML is required *********" 1>&2; - if test "$WGET" = "" && test "$REQUIRED_OCAML" != "CVS" ; then + if test "$WGET" = "" && test "$REQUIRED_OCAML" != "SVN" ; then echo "******** wget is missing *********" 1>&2; echo "******** cannot download Ocaml *********" 1>&2; exit 1 @@ -4893,13 +4909,12 @@ case "$i" in y* | Y*) cd $PATCH_DIR - if test "$REQUIRED_OCAML" = "CVS" ; then + if test "$REQUIRED_OCAML" = "SVN" ; then rm -rf $BUILD_DIR mkdir -p $BUILD_DIR cd $BUILD_DIR - cvs -d:pserver:anoncvs:""@camlcvs.inria.fr:/caml login - cvs -z3 -d:pserver:anoncvs@camlcvs.inria.fr:/caml co -P ocaml - cd ocaml + svn checkout http://caml.inria.fr/svn/ocaml/trunk + cd trunk else if test ! -f ocaml-"$REQUIRED_OCAML".tar.gz; then echo Downloading ... @@ -4946,8 +4961,8 @@ fi fi cd $BUILD_DIR - if test "$REQUIRED_OCAML" = "CVS" ; then - rm -rf ocaml + if test "$REQUIRED_OCAML" = "SVN" ; then + rm -rf trunk else rm -rf ocaml-"$REQUIRED_OCAML" fi @@ -5001,7 +5016,7 @@ set dummy ocamlopt.opt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_OCAMLOPT+set}" = set; then : +if ${ac_cv_prog_OCAMLOPT+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OCAMLOPT"; then @@ -5038,7 +5053,7 @@ set dummy ocamlopt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_OCAMLOPT+set}" = set; then : +if ${ac_cv_prog_OCAMLOPT+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OCAMLOPT"; then @@ -5076,7 +5091,7 @@ set dummy ocamldep; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_OCAMLDEP+set}" = set; then : +if ${ac_cv_prog_OCAMLDEP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OCAMLDEP"; then @@ -5113,7 +5128,7 @@ set dummy ocamllex.opt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_OCAMLLEX+set}" = set; then : +if ${ac_cv_prog_OCAMLLEX+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OCAMLLEX"; then @@ -5150,7 +5165,7 @@ set dummy ocamllex; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_OCAMLLEX+set}" = set; then : +if ${ac_cv_prog_OCAMLLEX+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OCAMLLEX"; then @@ -5187,7 +5202,7 @@ set dummy ocamlyacc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_OCAMLYACC+set}" = set; then : +if ${ac_cv_prog_OCAMLYACC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OCAMLYACC"; then @@ -5224,7 +5239,7 @@ set dummy ocamldoc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_OCAMLDOC+set}" = set; then : +if ${ac_cv_prog_OCAMLDOC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OCAMLDOC"; then @@ -5261,7 +5276,7 @@ set dummy ocamlmktop; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_OCAMLMKTOP+set}" = set; then : +if ${ac_cv_prog_OCAMLMKTOP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OCAMLMKTOP"; then @@ -5298,7 +5313,7 @@ set dummy camlp4; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CAMLP4+set}" = set; then : +if ${ac_cv_prog_CAMLP4+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CAMLP4"; then @@ -5335,7 +5350,7 @@ set dummy camlp4of; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CAMLP4OF+set}" = set; then : +if ${ac_cv_prog_CAMLP4OF+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CAMLP4OF"; then @@ -5389,7 +5404,7 @@ case "$OCAMLVERSION" in 3.10.1*|3.10.2*|3.1*) ;; *) - if test "$REQUIRED_OCAML" != "CVS" ; then + if test "$REQUIRED_OCAML" != "SVN" ; then echo "******** Version $REQUIRED_OCAML of Objective-Caml is required *********" 1>&2; echo "******* Check http://caml.inria.fr/ ********" 1>&2; exit 1 @@ -5446,7 +5461,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 $as_echo_n "checking for special C compiler options needed for large files... " >&6; } -if test "${ac_cv_sys_largefile_CC+set}" = set; then : +if ${ac_cv_sys_largefile_CC+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_sys_largefile_CC=no @@ -5497,7 +5512,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } -if test "${ac_cv_sys_file_offset_bits+set}" = set; then : +if ${ac_cv_sys_file_offset_bits+:} false; then : $as_echo_n "(cached) " >&6 else while :; do @@ -5566,7 +5581,7 @@ if test $ac_cv_sys_file_offset_bits = unknown; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; } -if test "${ac_cv_sys_large_files+set}" = set; then : +if ${ac_cv_sys_large_files+:} false; then : $as_echo_n "(cached) " >&6 else while :; do @@ -5641,7 +5656,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } -if test "${ac_cv_path_GREP+set}" = set; then : +if ${ac_cv_path_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$GREP"; then @@ -5704,7 +5719,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 $as_echo_n "checking for egrep... " >&6; } -if test "${ac_cv_path_EGREP+set}" = set; then : +if ${ac_cv_path_EGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 @@ -5771,7 +5786,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then : +if ${ac_cv_header_stdc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -5900,7 +5915,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } -if test "${ac_cv_c_bigendian+set}" = set; then : +if ${ac_cv_c_bigendian+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_c_bigendian=unknown @@ -6145,7 +6160,7 @@ for ac_header in byteswap.h do : ac_fn_c_check_header_mongrel "$LINENO" "byteswap.h" "ac_cv_header_byteswap_h" "$ac_includes_default" -if test "x$ac_cv_header_byteswap_h" = x""yes; then : +if test "x$ac_cv_header_byteswap_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_BYTESWAP_H 1 _ACEOF @@ -6157,7 +6172,7 @@ for ac_header in sys/utsname.h do : ac_fn_c_check_header_mongrel "$LINENO" "sys/utsname.h" "ac_cv_header_sys_utsname_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_utsname_h" = x""yes; then : +if test "x$ac_cv_header_sys_utsname_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_SYS_UTSNAME_H 1 _ACEOF @@ -6169,7 +6184,7 @@ for ac_header in arpa/inet.h do : ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default" -if test "x$ac_cv_header_arpa_inet_h" = x""yes; then : +if test "x$ac_cv_header_arpa_inet_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_ARPA_INET_H 1 _ACEOF @@ -6209,7 +6224,7 @@ for ac_header in sys/poll.h do : ac_fn_c_check_header_mongrel "$LINENO" "sys/poll.h" "ac_cv_header_sys_poll_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_poll_h" = x""yes; then : +if test "x$ac_cv_header_sys_poll_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_SYS_POLL_H 1 _ACEOF @@ -6221,7 +6236,7 @@ for ac_func in poll do : ac_fn_c_check_func "$LINENO" "poll" "ac_cv_func_poll" -if test "x$ac_cv_func_poll" = x""yes; then : +if test "x$ac_cv_func_poll" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_POLL 1 _ACEOF @@ -6233,7 +6248,7 @@ for ac_header in sys/vfs.h do : ac_fn_c_check_header_mongrel "$LINENO" "sys/vfs.h" "ac_cv_header_sys_vfs_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_vfs_h" = x""yes; then : +if test "x$ac_cv_header_sys_vfs_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_SYS_VFS_H 1 _ACEOF @@ -6245,7 +6260,7 @@ for ac_header in sys/statvfs.h do : ac_fn_c_check_header_mongrel "$LINENO" "sys/statvfs.h" "ac_cv_header_sys_statvfs_h" "$ac_includes_default" -if test "x$ac_cv_header_sys_statvfs_h" = x""yes; then : +if test "x$ac_cv_header_sys_statvfs_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_SYS_STATVFS_H 1 _ACEOF @@ -6280,7 +6295,7 @@ echo "----- checking zlib (required)" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflate in -lz" >&5 $as_echo_n "checking for inflate in -lz... " >&6; } -if test "${ac_cv_lib_z_inflate+set}" = set; then : +if ${ac_cv_lib_z_inflate+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -6314,7 +6329,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflate" >&5 $as_echo "$ac_cv_lib_z_inflate" >&6; } -if test "x$ac_cv_lib_z_inflate" = x""yes; then : +if test "x$ac_cv_lib_z_inflate" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBZ 1 _ACEOF @@ -6328,7 +6343,7 @@ for ac_header in zlib.h do : ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default" -if test "x$ac_cv_header_zlib_h" = x""yes; then : +if test "x$ac_cv_header_zlib_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_ZLIB_H 1 _ACEOF @@ -6341,7 +6356,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for zlibVersion in -lz" >&5 $as_echo_n "checking for zlibVersion in -lz... " >&6; } -if test "${ac_cv_lib_z_zlibVersion+set}" = set; then : +if ${ac_cv_lib_z_zlibVersion+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -6375,7 +6390,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_zlibVersion" >&5 $as_echo "$ac_cv_lib_z_zlibVersion" >&6; } -if test "x$ac_cv_lib_z_zlibVersion" = x""yes; then : +if test "x$ac_cv_lib_z_zlibVersion" = xyes; then : $as_echo "#define HAVE_ZLIBVERSION 1" >>confdefs.h fi @@ -6386,13 +6401,13 @@ for ac_header in bzlib.h do : ac_fn_c_check_header_mongrel "$LINENO" "bzlib.h" "ac_cv_header_bzlib_h" "$ac_includes_default" -if test "x$ac_cv_header_bzlib_h" = x""yes; then : +if test "x$ac_cv_header_bzlib_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_BZLIB_H 1 _ACEOF { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BZ2_bzReadOpen in -lbz2" >&5 $as_echo_n "checking for BZ2_bzReadOpen in -lbz2... " >&6; } -if test "${ac_cv_lib_bz2_BZ2_bzReadOpen+set}" = set; then : +if ${ac_cv_lib_bz2_BZ2_bzReadOpen+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -6426,7 +6441,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bz2_BZ2_bzReadOpen" >&5 $as_echo "$ac_cv_lib_bz2_BZ2_bzReadOpen" >&6; } -if test "x$ac_cv_lib_bz2_BZ2_bzReadOpen" = x""yes; then : +if test "x$ac_cv_lib_bz2_BZ2_bzReadOpen" = xyes; then : BZIP2=yes else BZIP2=no @@ -6443,7 +6458,7 @@ if test "$BZIP2" = "yes"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BZ2_bzlibVersion in -lbz2" >&5 $as_echo_n "checking for BZ2_bzlibVersion in -lbz2... " >&6; } -if test "${ac_cv_lib_bz2_BZ2_bzlibVersion+set}" = set; then : +if ${ac_cv_lib_bz2_BZ2_bzlibVersion+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -6477,7 +6492,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bz2_BZ2_bzlibVersion" >&5 $as_echo "$ac_cv_lib_bz2_BZ2_bzlibVersion" >&6; } -if test "x$ac_cv_lib_bz2_BZ2_bzlibVersion" = x""yes; then : +if test "x$ac_cv_lib_bz2_BZ2_bzlibVersion" = xyes; then : $as_echo "#define HAVE_BZLIBVERSION 1" >>confdefs.h fi @@ -6515,13 +6530,13 @@ for ac_header in miniupnpc/miniupnpc.h do : ac_fn_c_check_header_mongrel "$LINENO" "miniupnpc/miniupnpc.h" "ac_cv_header_miniupnpc_miniupnpc_h" "$ac_includes_default" -if test "x$ac_cv_header_miniupnpc_miniupnpc_h" = x""yes; then : +if test "x$ac_cv_header_miniupnpc_miniupnpc_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_MINIUPNPC_MINIUPNPC_H 1 _ACEOF { $as_echo "$as_me:${as_lineno-$LINENO}: checking for upnpDiscover in -lminiupnpc" >&5 $as_echo_n "checking for upnpDiscover in -lminiupnpc... " >&6; } -if test "${ac_cv_lib_miniupnpc_upnpDiscover+set}" = set; then : +if ${ac_cv_lib_miniupnpc_upnpDiscover+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -6555,7 +6570,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_miniupnpc_upnpDiscover" >&5 $as_echo "$ac_cv_lib_miniupnpc_upnpDiscover" >&6; } -if test "x$ac_cv_lib_miniupnpc_upnpDiscover" = x""yes; then : +if test "x$ac_cv_lib_miniupnpc_upnpDiscover" = xyes; then : UPNP_NATPMP=yes else UPNP_NATPMP=no @@ -6574,13 +6589,13 @@ for ac_header in natpmp.h do : ac_fn_c_check_header_mongrel "$LINENO" "natpmp.h" "ac_cv_header_natpmp_h" "$ac_includes_default" -if test "x$ac_cv_header_natpmp_h" = x""yes; then : +if test "x$ac_cv_header_natpmp_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_NATPMP_H 1 _ACEOF { $as_echo "$as_me:${as_lineno-$LINENO}: checking for initnatpmp in -lnatpmp" >&5 $as_echo_n "checking for initnatpmp in -lnatpmp... " >&6; } -if test "${ac_cv_lib_natpmp_initnatpmp+set}" = set; then : +if ${ac_cv_lib_natpmp_initnatpmp+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -6614,7 +6629,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_natpmp_initnatpmp" >&5 $as_echo "$ac_cv_lib_natpmp_initnatpmp" >&6; } -if test "x$ac_cv_lib_natpmp_initnatpmp" = x""yes; then : +if test "x$ac_cv_lib_natpmp_initnatpmp" = xyes; then : UPNP_NATPMP=yes else UPNP_NATPMP=no @@ -6641,13 +6656,13 @@ for ac_header in magic.h do : ac_fn_c_check_header_mongrel "$LINENO" "magic.h" "ac_cv_header_magic_h" "$ac_includes_default" -if test "x$ac_cv_header_magic_h" = x""yes; then : +if test "x$ac_cv_header_magic_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_MAGIC_H 1 _ACEOF { $as_echo "$as_me:${as_lineno-$LINENO}: checking for magic_file in -lmagic" >&5 $as_echo_n "checking for magic_file in -lmagic... " >&6; } -if test "${ac_cv_lib_magic_magic_file+set}" = set; then : +if ${ac_cv_lib_magic_magic_file+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -6681,10 +6696,10 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_magic_magic_file" >&5 $as_echo "$ac_cv_lib_magic_magic_file" >&6; } -if test "x$ac_cv_lib_magic_magic_file" = x""yes; then : +if test "x$ac_cv_lib_magic_magic_file" = xyes; then : ac_fn_c_check_decl "$LINENO" "MAGIC_ERROR" "ac_cv_have_decl_MAGIC_ERROR" "#include " -if test "x$ac_cv_have_decl_MAGIC_ERROR" = x""yes; then : +if test "x$ac_cv_have_decl_MAGIC_ERROR" = xyes; then : MAGIC=yes else MAGIC=no @@ -6723,7 +6738,7 @@ set dummy gdlib-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_GDLIBCONFIG+set}" = set; then : +if ${ac_cv_prog_GDLIBCONFIG+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$GDLIBCONFIG"; then @@ -6791,7 +6806,7 @@ for ac_header in gd.h do : ac_fn_c_check_header_mongrel "$LINENO" "gd.h" "ac_cv_header_gd_h" "$ac_includes_default" -if test "x$ac_cv_header_gd_h" = x""yes; then : +if test "x$ac_cv_header_gd_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_GD_H 1 _ACEOF @@ -6834,7 +6849,7 @@ $as_echo "$as_me: not found, trying another method" >&6;} { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gdImageCreate in -lgd" >&5 $as_echo_n "checking for gdImageCreate in -lgd... " >&6; } -if test "${ac_cv_lib_gd_gdImageCreate+set}" = set; then : +if ${ac_cv_lib_gd_gdImageCreate+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -6868,7 +6883,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImageCreate" >&5 $as_echo "$ac_cv_lib_gd_gdImageCreate" >&6; } -if test "x$ac_cv_lib_gd_gdImageCreate" = x""yes; then : +if test "x$ac_cv_lib_gd_gdImageCreate" = xyes; then : LIBGD=yes else LIBGD=no @@ -6887,7 +6902,7 @@ set dummy libpng-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_PNGLIBCONFIG+set}" = set; then : +if ${ac_cv_prog_PNGLIBCONFIG+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$PNGLIBCONFIG"; then @@ -6931,7 +6946,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_create_read_struct in -lpng" >&5 $as_echo_n "checking for png_create_read_struct in -lpng... " >&6; } -if test "${ac_cv_lib_png_png_create_read_struct_+set}" = set; then : +if ${ac_cv_lib_png_png_create_read_struct_+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -6965,7 +6980,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_create_read_struct_" >&5 $as_echo "$ac_cv_lib_png_png_create_read_struct_" >&6; } -if test "x$ac_cv_lib_png_png_create_read_struct_" = x""yes; then : +if test "x$ac_cv_lib_png_png_create_read_struct_" = xyes; then : LIBPNG=yes fi @@ -7009,7 +7024,7 @@ $as_echo "$as_me: not found, trying another method" >&6;} { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gdImagePng in -lgd" >&5 $as_echo_n "checking for gdImagePng in -lgd... " >&6; } -if test "${ac_cv_lib_gd_gdImagePng+set}" = set; then : +if ${ac_cv_lib_gd_gdImagePng+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -7043,7 +7058,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImagePng" >&5 $as_echo "$ac_cv_lib_gd_gdImagePng" >&6; } -if test "x$ac_cv_lib_gd_gdImagePng" = x""yes; then : +if test "x$ac_cv_lib_gd_gdImagePng" = xyes; then : LIBGD_PNG=yes else LIBGD_PNG=no @@ -7060,7 +7075,7 @@ $as_echo "yes" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_access_version_number in -lpng" >&5 $as_echo_n "checking for png_access_version_number in -lpng... " >&6; } -if test "${ac_cv_lib_png_png_access_version_number+set}" = set; then : +if ${ac_cv_lib_png_png_access_version_number+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -7094,7 +7109,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_access_version_number" >&5 $as_echo "$ac_cv_lib_png_png_access_version_number" >&6; } -if test "x$ac_cv_lib_png_png_access_version_number" = x""yes; then : +if test "x$ac_cv_lib_png_png_access_version_number" = xyes; then : $as_echo "#define HAVE_PNGVERSION 1" >>confdefs.h fi @@ -7111,7 +7126,7 @@ LIBJPEG=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_CreateCompress in -ljpeg" >&5 $as_echo_n "checking for jpeg_CreateCompress in -ljpeg... " >&6; } -if test "${ac_cv_lib_jpeg_jpeg_CreateCompress+set}" = set; then : +if ${ac_cv_lib_jpeg_jpeg_CreateCompress+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -7145,7 +7160,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_CreateCompress" >&5 $as_echo "$ac_cv_lib_jpeg_jpeg_CreateCompress" >&6; } -if test "x$ac_cv_lib_jpeg_jpeg_CreateCompress" = x""yes; then : +if test "x$ac_cv_lib_jpeg_jpeg_CreateCompress" = xyes; then : LIBJPEG=yes fi @@ -7185,7 +7200,7 @@ $as_echo "$as_me: not found, trying another method" >&6;} { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gdImageJpeg in -lgd" >&5 $as_echo_n "checking for gdImageJpeg in -lgd... " >&6; } -if test "${ac_cv_lib_gd_gdImageJpeg+set}" = set; then : +if ${ac_cv_lib_gd_gdImageJpeg+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -7219,7 +7234,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImageJpeg" >&5 $as_echo "$ac_cv_lib_gd_gdImageJpeg" >&6; } -if test "x$ac_cv_lib_gd_gdImageJpeg" = x""yes; then : +if test "x$ac_cv_lib_gd_gdImageJpeg" = xyes; then : LIBGD_JPG=yes else LIBGD_JPG=no @@ -7335,7 +7350,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 $as_echo_n "checking for non-GNU ld... " >&6; } fi -if test "${acl_cv_path_LD+set}" = set; then : +if ${acl_cv_path_LD+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$LD"; then @@ -7372,7 +7387,7 @@ test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } -if test "${acl_cv_prog_gnu_ld+set}" = set; then : +if ${acl_cv_prog_gnu_ld+:} false; then : $as_echo_n "(cached) " >&6 else # I'd rather use --version here, but apparently some GNU ld's only accept -v. @@ -7392,7 +7407,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5 $as_echo_n "checking for shared library run path origin... " >&6; } -if test "${acl_cv_rpath+set}" = set; then : +if ${acl_cv_rpath+:} false; then : $as_echo_n "(cached) " >&6 else @@ -7835,7 +7850,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5 $as_echo_n "checking for iconv... " >&6; } -if test "${am_cv_func_iconv+set}" = set; then : +if ${am_cv_func_iconv+:} false; then : $as_echo_n "(cached) " >&6 else @@ -7910,7 +7925,7 @@ if test "$am_cv_func_iconv" = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5 $as_echo_n "checking for iconv declaration... " >&6; } - if test "${am_cv_proto_iconv+set}" = set; then : + if ${am_cv_proto_iconv+:} false; then : $as_echo_n "(cached) " >&6 else @@ -7968,7 +7983,7 @@ for ac_func in locale_charset do : ac_fn_c_check_func "$LINENO" "locale_charset" "ac_cv_func_locale_charset" -if test "x$ac_cv_func_locale_charset" = x""yes; then : +if test "x$ac_cv_func_locale_charset" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LOCALE_CHARSET 1 _ACEOF @@ -7998,7 +8013,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for locale_charset in -lcharset" >&5 $as_echo_n "checking for locale_charset in -lcharset... " >&6; } -if test "${ac_cv_lib_charset_locale_charset+set}" = set; then : +if ${ac_cv_lib_charset_locale_charset+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -8032,7 +8047,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_charset_locale_charset" >&5 $as_echo "$ac_cv_lib_charset_locale_charset" >&6; } -if test "x$ac_cv_lib_charset_locale_charset" = x""yes; then : +if test "x$ac_cv_lib_charset_locale_charset" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBCHARSET 1 _ACEOF @@ -8044,7 +8059,7 @@ for ac_header in libcharset.h do : ac_fn_c_check_header_mongrel "$LINENO" "libcharset.h" "ac_cv_header_libcharset_h" "$ac_includes_default" -if test "x$ac_cv_header_libcharset_h" = x""yes; then : +if test "x$ac_cv_header_libcharset_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBCHARSET_H 1 _ACEOF @@ -8056,7 +8071,7 @@ for ac_header in langinfo.h do : ac_fn_c_check_header_mongrel "$LINENO" "langinfo.h" "ac_cv_header_langinfo_h" "$ac_includes_default" -if test "x$ac_cv_header_langinfo_h" = x""yes; then : +if test "x$ac_cv_header_langinfo_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LANGINFO_H 1 _ACEOF @@ -8068,7 +8083,7 @@ for ac_header in locale.h do : ac_fn_c_check_header_mongrel "$LINENO" "locale.h" "ac_cv_header_locale_h" "$ac_includes_default" -if test "x$ac_cv_header_locale_h" = x""yes; then : +if test "x$ac_cv_header_locale_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LOCALE_H 1 _ACEOF @@ -8214,7 +8229,7 @@ set dummy pthread-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_acx_pthread_config+set}" = set; then : +if ${ac_cv_prog_acx_pthread_config+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$acx_pthread_config"; then @@ -8389,7 +8404,7 @@ set dummy cc_r; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then : +if ${ac_cv_prog_PTHREAD_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$PTHREAD_CC"; then @@ -8460,7 +8475,7 @@ for ac_header in linux/limits.h do : ac_fn_c_check_header_mongrel "$LINENO" "linux/limits.h" "ac_cv_header_linux_limits_h" "$ac_includes_default" -if test "x$ac_cv_header_linux_limits_h" = x""yes; then : +if test "x$ac_cv_header_linux_limits_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LINUX_LIMITS_H 1 _ACEOF @@ -8470,7 +8485,7 @@ OLD_CPPFLAGS=$CPPFLAGS CPPFLAGS="-I /usr/src/linux/include" ac_fn_c_check_header_mongrel "$LINENO" "linux/types.h" "ac_cv_header_linux_types_h" "$ac_includes_default" -if test "x$ac_cv_header_linux_types_h" = x""yes; then : +if test "x$ac_cv_header_linux_types_h" = xyes; then : CONFIG_INCLUDES="-I /usr/src/linux/include" fi @@ -8484,7 +8499,7 @@ for ac_header in gnu/libc-version.h do : ac_fn_c_check_header_mongrel "$LINENO" "gnu/libc-version.h" "ac_cv_header_gnu_libc_version_h" "$ac_includes_default" -if test "x$ac_cv_header_gnu_libc_version_h" = x""yes; then : +if test "x$ac_cv_header_gnu_libc_version_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_GNU_LIBC_VERSION_H 1 _ACEOF @@ -8564,7 +8579,7 @@ set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CXX+set}" = set; then : +if ${ac_cv_prog_CXX+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CXX"; then @@ -8608,7 +8623,7 @@ set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then : +if ${ac_cv_prog_ac_ct_CXX+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CXX"; then @@ -8686,7 +8701,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } -if test "${ac_cv_cxx_compiler_gnu+set}" = set; then : +if ${ac_cv_cxx_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -8723,7 +8738,7 @@ ac_save_CXXFLAGS=$CXXFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 $as_echo_n "checking whether $CXX accepts -g... " >&6; } -if test "${ac_cv_prog_cxx_g+set}" = set; then : +if ${ac_cv_prog_cxx_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_cxx_werror_flag=$ac_cxx_werror_flag @@ -8811,7 +8826,7 @@ set dummy ${ac_tool_prefix}$CXX; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_NEWCXX+set}" = set; then : +if ${ac_cv_prog_NEWCXX+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$NEWCXX"; then @@ -8851,7 +8866,7 @@ set dummy $CXX; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_NEWCXX+set}" = set; then : +if ${ac_cv_prog_ac_ct_NEWCXX+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_NEWCXX"; then @@ -8913,7 +8928,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} accepts -fno-omit-frame-pointer" >&5 $as_echo_n "checking whether ${CXX} accepts -fno-omit-frame-pointer... " >&6; } -if test "${ac_cv_no_omit_frame_pointer+set}" = set; then : +if ${ac_cv_no_omit_frame_pointer+:} false; then : $as_echo_n "(cached) " >&6 else echo 'void f(){}' > conftest.cpp @@ -8939,7 +8954,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} accepts -mno-omit-leaf-frame-pointer" >&5 $as_echo_n "checking whether ${CXX} accepts -mno-omit-leaf-frame-pointer... " >&6; } -if test "${ac_cv_no_omit_leaf_frame_pointer+set}" = set; then : +if ${ac_cv_no_omit_leaf_frame_pointer+:} false; then : $as_echo_n "(cached) " >&6 else echo 'void f(){}' > conftest.cpp @@ -9173,7 +9188,7 @@ set dummy gtk-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_GTK_CONFIG+set}" = set; then : +if ${ac_cv_prog_GTK_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$GTK_CONFIG"; then @@ -9510,10 +9525,21 @@ :end' >>confcache if diff "$cache_file" confcache >/dev/null 2>&1; then :; else if test -w "$cache_file"; then - test "x$cache_file" != "x/dev/null" && + if test "x$cache_file" != "x/dev/null"; then { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 $as_echo "$as_me: updating cache $cache_file" >&6;} - cat confcache >$cache_file + if test ! -f "$cache_file" || test -h "$cache_file"; then + cat confcache >"$cache_file" + else + case $cache_file in #( + */* | ?:*) + mv -f confcache "$cache_file"$$ && + mv -f "$cache_file"$$ "$cache_file" ;; #( + *) + mv -f confcache "$cache_file" ;; + esac + fi + fi else { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} @@ -9546,7 +9572,7 @@ -: ${CONFIG_STATUS=./config.status} +: "${CONFIG_STATUS=./config.status}" ac_write_fail=0 ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" @@ -9647,6 +9673,7 @@ IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. +as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -9954,7 +9981,7 @@ # values after options handling. ac_log=" This file was extended by $as_me, which was -generated by GNU Autoconf 2.67. Invocation command line was +generated by GNU Autoconf 2.68. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS @@ -10016,7 +10043,7 @@ ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ config.status -configured by $0, generated by GNU Autoconf 2.67, +configured by $0, generated by GNU Autoconf 2.68, with options \\"\$ac_cs_config\\" Copyright (C) 2010 Free Software Foundation, Inc. @@ -10149,7 +10176,7 @@ "../packages/rpm/Makefile") CONFIG_FILES="$CONFIG_FILES ../packages/rpm/Makefile" ;; "../packages/slackware/mldonkey.options") CONFIG_FILES="$CONFIG_FILES ../packages/slackware/mldonkey.options" ;; - *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5 ;; + *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; esac done @@ -10171,9 +10198,10 @@ # after its creation but before its name has been assigned to `$tmp'. $debug || { - tmp= + tmp= ac_tmp= trap 'exit_status=$? - { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status + : "${ac_tmp:=$tmp}" + { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status ' 0 trap 'as_fn_exit 1' 1 2 13 15 } @@ -10181,12 +10209,13 @@ { tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && - test -n "$tmp" && test -d "$tmp" + test -d "$tmp" } || { tmp=./conf$$-$RANDOM (umask 077 && mkdir "$tmp") } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 +ac_tmp=$tmp # Set up the scripts for CONFIG_FILES section. # No need to generate them if there are no CONFIG_FILES. @@ -10208,7 +10237,7 @@ ac_cs_awk_cr=$ac_cr fi -echo 'BEGIN {' >"$tmp/subs1.awk" && +echo 'BEGIN {' >"$ac_tmp/subs1.awk" && _ACEOF @@ -10236,7 +10265,7 @@ rm -f conf$$subs.sh cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -cat >>"\$tmp/subs1.awk" <<\\_ACAWK && +cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && _ACEOF sed -n ' h @@ -10284,7 +10313,7 @@ rm -f conf$$subs.awk cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 _ACAWK -cat >>"\$tmp/subs1.awk" <<_ACAWK && +cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && for (key in S) S_is_set[key] = 1 FS = "" @@ -10316,7 +10345,7 @@ sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" else cat -fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \ +fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 _ACEOF @@ -10350,7 +10379,7 @@ # No need to generate them if there are no CONFIG_HEADERS. # This happens for instance with `./config.status Makefile'. if test -n "$CONFIG_HEADERS"; then -cat >"$tmp/defines.awk" <<\_ACAWK || +cat >"$ac_tmp/defines.awk" <<\_ACAWK || BEGIN { _ACEOF @@ -10362,8 +10391,8 @@ # handling of long lines. ac_delim='%!_!# ' for ac_last_try in false false :; do - ac_t=`sed -n "/$ac_delim/p" confdefs.h` - if test -z "$ac_t"; then + ac_tt=`sed -n "/$ac_delim/p" confdefs.h` + if test -z "$ac_tt"; then break elif $ac_last_try; then as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 @@ -10464,7 +10493,7 @@ esac case $ac_mode$ac_tag in :[FHL]*:*);; - :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5 ;; + :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac @@ -10483,7 +10512,7 @@ for ac_f do case $ac_f in - -) ac_f="$tmp/stdin";; + -) ac_f="$ac_tmp/stdin";; *) # Look for the file first in the build tree, then in the source tree # (if the path is not absolute). The absolute path cannot be DOS-style, # because $ac_f cannot contain `:'. @@ -10492,7 +10521,7 @@ [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || - as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5 ;; + as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; esac case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac as_fn_append ac_file_inputs " '$ac_f'" @@ -10518,8 +10547,8 @@ esac case $ac_tag in - *:-:* | *:-) cat >"$tmp/stdin" \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; + *:-:* | *:-) cat >"$ac_tmp/stdin" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; esac ;; esac @@ -10644,21 +10673,22 @@ s&@abs_top_builddir@&$ac_abs_top_builddir&;t t $ac_datarootdir_hack " -eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \ - || as_fn_error $? "could not create $ac_file" "$LINENO" 5 +eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ + >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && - { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && - { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && + { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && + { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ + "$ac_tmp/out"`; test -z "$ac_out"; } && { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined" >&5 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined" >&2;} - rm -f "$tmp/stdin" + rm -f "$ac_tmp/stdin" case $ac_file in - -) cat "$tmp/out" && rm -f "$tmp/out";; - *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; + -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; + *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; esac \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; @@ -10669,20 +10699,20 @@ if test x"$ac_file" != x-; then { $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" - } >"$tmp/config.h" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" + } >"$ac_tmp/config.h" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 - if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then + if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 $as_echo "$as_me: $ac_file is unchanged" >&6;} else rm -f "$ac_file" - mv "$tmp/config.h" "$ac_file" \ + mv "$ac_tmp/config.h" "$ac_file" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 fi else $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \ + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ || as_fn_error $? "could not create -" "$LINENO" 5 fi ;; diff -Nru mldonkey-3.0.7/config/configure.in mldonkey-3.1.0/config/configure.in --- mldonkey-3.0.7/config/configure.in 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/config/configure.in 2011-08-07 10:25:14.000000000 +0000 @@ -21,8 +21,8 @@ # ********** ********** MAJOR_VERSION=3 -MINOR_VERSION=0 -SUB_VERSION=7 # range 0-7 due to eMule limitations +MINOR_VERSION=1 +SUB_VERSION=0 # range 0-7 due to eMule limitations # ********** ********** # ********** check for C compiler ********** @@ -343,9 +343,15 @@ # ********** Network and Feature configure switches and dependency ********** # ********** ********** -AC_ARG_ENABLE(multinet, [ --disable-multinet allows you to only compile support for eDonkey (incl. Overnet and Kademlia)], [MULTINET="$enableval"]) -AC_ARG_ENABLE(minimum, [ --enable-minimum compile MLDonkey with minimum features and Networks (eDonkey, iconv and thread enabled)], [MINIMUM="$enableval"]) -AC_ARG_ENABLE(minimum, [ --enable-minimum=all disable all optional features and Networks excepting eDonkey], [MINIMUM="$enableval"]) +AC_ARG_ENABLE(multinet, + AS_HELP_STRING([--disable-multinet], [disable all networks except eDonkey (with Overnet and Kademlia)]), + [MULTINET="$enableval"]) +AC_ARG_ENABLE(minimum, + AS_HELP_STRING([--enable-minimum], [enable minimum set of features and networks (eDonkey, iconv and threads enabled)]), + [MINIMUM="$enableval"]) +AC_ARG_ENABLE(minimum, + AS_HELP_STRING([--enable-minimum=all], [enable only eDonkey network and disable all optional features (not recommended)]), + [MINIMUM="$enableval"]) if [ test ! "$MULTINET" = "yes" ] || [ test "$MINIMUM" = "yes" ] || [ test "$MINIMUM" = "all" ]; then GNUTELLA=no @@ -366,36 +372,70 @@ ICONV=no fi -#AC_ARG_ENABLE(soulseek, [ --disable-soulseek allows you to remove support for SoulSeek], [SOULSEEK="$enableval"]) -#AC_ARG_ENABLE(opennap, [ --disable-opennap allows you to remove support for Open Napster], [OPEN_NAPSTER="$enableval"]) -AC_ARG_ENABLE(directconnect, [ --disable-directconnect allows you to remove support for Direct Connect], [DIRECT_CONNECT="$enableval"]) -#AC_ARG_ENABLE(openft, [ --disable-openft allows you to remove support for OpenFT], [OPENFT="$enableval"]) - -AC_ARG_ENABLE(donkey, [ --disable-donkey allows you to remove support for eDonkey], [DONKEY="$enableval"]) -AC_ARG_ENABLE(donkeysui, [ --disable-donkeysui allows you to remove support for eMule SecureUserIdent], [DONKEY_SUI="$enableval"]) -AC_ARG_ENABLE(bittorrent, [ --disable-bittorrent allows you to remove support for Bittorent], [BITTORRENT="$enableval"]) -AC_ARG_ENABLE(filetp, [ --disable-filetp allows you to remove support for fileTP], [FILETP="$enableval"]) -AC_ARG_ENABLE(gnutella, [ --disable-gnutella allows you to remove support for Gnutella], [GNUTELLA="$enableval"]) -AC_ARG_ENABLE(gnutella2, [ --disable-gnutella2 allows you to remove support for Gnutella2], [GNUTELLA2="$enableval"]) -AC_ARG_ENABLE(fasttrack, [ --disable-fasttrack allows you to remove support for FastTrack], [FASTTRACK="$enableval"]) - -AC_ARG_ENABLE(batch, [ --enable-batch reply YES to all queries in this script], [BATCH="$enableval"]) -AC_ARG_ENABLE(force-ocaml, [ --enable-force-ocaml force usage of self-compiled Ocaml], [FORCE_OCAML="$enableval"]) -AC_ARG_ENABLE(ocamlver, [ --enable-ocamlver=VER force usage of specific Ocaml version (3.10.1|CVS), ], [REQUIRED_OCAML="$enableval"]) -AC_ARG_ENABLE(mingw, [ --enable-mingw forces compilation with MINGW on Cygwin], [FORCE_MINGW="$enableval"]) -AC_ARG_ENABLE(checks, [ --enable-checks force mldonkey to perform bound checks on array/string access], [CHECKBOUNDS="$enableval"]) +#AC_ARG_ENABLE(soulseek, [ --disable-soulseek disable support for SoulSeek], [SOULSEEK="$enableval"]) +#AC_ARG_ENABLE(opennap, [ --disable-opennap disable support for Open Napster], [OPEN_NAPSTER="$enableval"]) +AC_ARG_ENABLE(directconnect, + AS_HELP_STRING([--disable-directconnect], [disable support for Direct Connect]), + [DIRECT_CONNECT="$enableval"]) +#AC_ARG_ENABLE(openft, [ --disable-openft disable support for OpenFT], [OPENFT="$enableval"]) + +AC_ARG_ENABLE(donkey, + AS_HELP_STRING([--disable-donkey], [disable support for eDonkey]), + [DONKEY="$enableval"]) +AC_ARG_ENABLE(donkeysui, + AS_HELP_STRING([--disable-donkeysui], [disable support for eMule SecureUserIdent]), + [DONKEY_SUI="$enableval"]) +AC_ARG_ENABLE(bittorrent, + AS_HELP_STRING([--disable-bittorrent], [disable support for Bittorent]), + [BITTORRENT="$enableval"]) +AC_ARG_ENABLE(filetp, + AS_HELP_STRING([--disable-filetp], [disable support for fileTP]), + [FILETP="$enableval"]) +AC_ARG_ENABLE(gnutella, + AS_HELP_STRING([--disable-gnutella], [disable support for Gnutella]), + [GNUTELLA="$enableval"]) +AC_ARG_ENABLE(gnutella2, + AS_HELP_STRING([--disable-gnutella2], [disable support for Gnutella2]), + [GNUTELLA2="$enableval"]) +AC_ARG_ENABLE(fasttrack, + AS_HELP_STRING([--disable-fasttrack], [disable support for FastTrack]), + [FASTTRACK="$enableval"]) + +AC_ARG_ENABLE(batch, + AS_HELP_STRING([--enable-batch], [reply YES to all queries in this script]), + [BATCH="$enableval"]) +AC_ARG_ENABLE(force-ocaml, + AS_HELP_STRING([--enable-force-ocaml], [force usage of self-compiled Ocaml]), + [FORCE_OCAML="$enableval"]) +AC_ARG_ENABLE(ocamlver, + AS_HELP_STRING([--enable-ocamlver=VER], [force usage of specific Ocaml version (3.10.1|SVN), ]), + [REQUIRED_OCAML="$enableval"]) +AC_ARG_ENABLE(mingw, + AS_HELP_STRING([--enable-mingw], [force compilation with MINGW on Cygwin]), + [FORCE_MINGW="$enableval"]) +AC_ARG_ENABLE(checks, + AS_HELP_STRING([--enable-checks], [enable bounds-checking for array/string accesses]), + [CHECKBOUNDS="$enableval"]) if test "$CHECKBOUNDS" = "yes"; then CHECKBOUNDS=true fi -AC_ARG_ENABLE(profile, [ --enable-profile allows you to profile mlnet using gprof (enables debug)], [PROFILE="$enableval"]) -AC_ARG_ENABLE(debug, [ --enable-debug allows you to compile mlnet with debug symbols], [DEBUG="$enableval"]) +AC_ARG_ENABLE(profile, + AS_HELP_STRING([--enable-profile], [compile with gprof profiling support (enables debug)]), + [PROFILE="$enableval"]) +AC_ARG_ENABLE(debug, + AS_HELP_STRING([--enable-debug], [compile with debugging information]), + [DEBUG="$enableval"]) if test "$PROFILE" = "yes"; then DEBUG="yes" fi -AC_ARG_ENABLE(gui, [ --disable-gui allows you to disable GUI build (default)], [GUI="$enableval"]) -AC_ARG_ENABLE(gui, [ --enable-gui=oldgui|newgui1|newgui2 - allows you to choose a GUI (default: newgui2 - is a GTK2 GUI, other GUIs use GTK1)], [GUI="$enableval"]) +AC_ARG_ENABLE(gui, + AS_HELP_STRING([--disable-gui], [disable GUI build (default)]), + [GUI="$enableval"]) +AC_ARG_ENABLE(gui, + AS_HELP_STRING([--enable-gui=oldgui|newgui1|newgui2], + [enable GUI (newgui2 uses GTK2 (default), other GUIs use GTK1)]), + [GUI="$enableval"]) if test "$GUI" = "yes"; then GUI=newgui2 fi @@ -407,14 +447,30 @@ fi fi -AC_ARG_ENABLE(pthread, [ --disable-pthread allows you to disable pthread support in mldonkey, hurts performance!], [USE_PTHREAD="$enableval"]) -AC_ARG_ENABLE(pthread-lib, [ --enable-pthread-lib legacy option], [USE_PTHREAD="$enableval"]) -AC_ARG_ENABLE(iconv, [ --disable-iconv disable the use of iconv], [ICONV="$enableval"]) -AC_ARG_ENABLE(gd, [ --disable-gd disable the use of gd], [GD="$enableval"]) -AC_ARG_ENABLE(bzip2, [ --disable-bzip2 disable the use of bzip2], [BZIP2="$enableval"]) -AC_ARG_ENABLE(magic, [ --disable-magic disable the use of libmagic (GNU file)], [MAGIC="$enableval"]) -AC_ARG_ENABLE(upnp-natpmp, [ --enable-upnp-natpmp enable the use of libminiupnpc and libnatpmp], [UPNP_NATPMP="$enableval"]) -AC_ARG_ENABLE(force-upnp-natpmp, [ --enable-force-upnp-natpmp force local compilation of libminiupnpc and libnatpmp], [UPNP_NATPMP_FORCE="$enableval"]) +AC_ARG_ENABLE(pthread, + AS_HELP_STRING([--disable-pthread], [disable the use of pthread, hurts performance!]), + [USE_PTHREAD="$enableval"]) +AC_ARG_ENABLE(pthread-lib, + AS_HELP_STRING([--enable-pthread-lib], [legacy option]), + [USE_PTHREAD="$enableval"]) +AC_ARG_ENABLE(iconv, + AS_HELP_STRING([--disable-iconv], [disable the use of iconv]), + [ICONV="$enableval"]) +AC_ARG_ENABLE(gd, + AS_HELP_STRING([--disable-gd], [disable the use of gd]), + [GD="$enableval"]) +AC_ARG_ENABLE(bzip2, + AS_HELP_STRING([--disable-bzip2], [disable the use of bzip2]), + [BZIP2="$enableval"]) +AC_ARG_ENABLE(magic, + AS_HELP_STRING([--disable-magic], [disable the use of libmagic (GNU file)]), + [MAGIC="$enableval"]) +AC_ARG_ENABLE(upnp-natpmp, + AS_HELP_STRING([--enable-upnp-natpmp], [enable the use of libminiupnpc and libnatpmp]), + [UPNP_NATPMP="$enableval"]) +AC_ARG_ENABLE(force-upnp-natpmp, + AS_HELP_STRING([--enable-force-upnp-natpmp], [force local compilation of libminiupnpc and libnatpmp]), + [UPNP_NATPMP_FORCE="$enableval"]) if test "$FORCE_MINGW" = "yes"; then CC="$CC -mno-cygwin" @@ -481,7 +537,9 @@ LOCAL_DIR=$PATCH_DIR/local BUILD_DIR=$PATCH_DIR/build -AC_ARG_ENABLE(local-prefix, [ --enable-local-prefix=DIR allows you to specify where you want temporary tools to be installed (DIR must be absolute)], [LOCAL_DIR="$enableval"]) +AC_ARG_ENABLE(local-prefix, + AS_HELP_STRING([--enable-local-prefix=DIR], [specify path for temporary tools installation (DIR must be absolute)]), + [LOCAL_DIR="$enableval"]) LOCAL=$LOCAL_DIR LOCAL_OCAML=$LOCAL_DIR/bin @@ -491,7 +549,7 @@ AC_PATH_PROG(CAMLP4, camlp4,"",[$LOCAL_DIR/bin:$PATH]) BUILD_OCAML=no -if [ test -z "$OCAMLC" ] || [ test -z "$CAMLP4" ] || [ test "$REQUIRED_OCAML" = "CVS" ]; then +if [ test -z "$OCAMLC" ] || [ test -z "$CAMLP4" ] || [ test "$REQUIRED_OCAML" = "SVN" ]; then BUILD_OCAML=yes else OCAMLVERSION=`$OCAMLC -v | sed -n -e 's|.*version* *\(.*\)$|\1|p' ` @@ -523,7 +581,7 @@ else echo "******** Objective-Caml $REQUIRED_OCAML is required *********" 1>&2; - if [ test "$WGET" = "" ] && [ test "$REQUIRED_OCAML" != "CVS" ]; then + if [ test "$WGET" = "" ] && [ test "$REQUIRED_OCAML" != "SVN" ]; then echo "******** wget is missing *********" 1>&2; echo "******** cannot download Ocaml *********" 1>&2; exit 1 @@ -535,13 +593,12 @@ case "$i" in y* | Y*) cd $PATCH_DIR - if [ test "$REQUIRED_OCAML" = "CVS" ]; then + if [ test "$REQUIRED_OCAML" = "SVN" ]; then rm -rf $BUILD_DIR mkdir -p $BUILD_DIR cd $BUILD_DIR - cvs -d:pserver:anoncvs:""@camlcvs.inria.fr:/caml login - cvs -z3 -d:pserver:anoncvs@camlcvs.inria.fr:/caml co -P ocaml - cd ocaml + svn checkout http://caml.inria.fr/svn/ocaml/trunk + cd trunk else if test ! -f ocaml-"$REQUIRED_OCAML".tar.gz; then echo Downloading ... @@ -588,8 +645,8 @@ fi fi cd $BUILD_DIR - if [ test "$REQUIRED_OCAML" = "CVS" ]; then - rm -rf ocaml + if [ test "$REQUIRED_OCAML" = "SVN" ]; then + rm -rf trunk else rm -rf ocaml-"$REQUIRED_OCAML" fi @@ -669,7 +726,7 @@ case "$OCAMLVERSION" in 3.10.1*|3.10.2*|3.1*) ;; *) - if [ test "$REQUIRED_OCAML" != "CVS" ]; then + if [ test "$REQUIRED_OCAML" != "SVN" ]; then echo "******** Version $REQUIRED_OCAML of Objective-Caml is required *********" 1>&2; echo "******* Check http://caml.inria.fr/ ********" 1>&2; exit 1 diff -Nru mldonkey-3.0.7/config/Makefile.in mldonkey-3.1.0/config/Makefile.in --- mldonkey-3.0.7/config/Makefile.in 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/config/Makefile.in 2011-01-23 15:20:25.000000000 +0000 @@ -28,8 +28,8 @@ NO_STATIC_LIBS_opt= NO_CMXA= -LIBS_byte=-custom bigarray.cma unix.cma str.cma -LIBS_opt= bigarray.cmxa unix.cmxa str.cmxa +LIBS_byte=-custom bigarray.cma unix.cma str.cma nums.cma +LIBS_opt= bigarray.cmxa unix.cmxa str.cmxa nums.cmxa BIGARRAY_LIBS_opt=bigarray.cmxa BIGARRAY_LIBS_byte=bigarray.cma @@ -152,9 +152,9 @@ $(CDK)/heap.ml \ $(CDK)/printexc2.ml $(CDK)/genlex2.ml \ $(CDK)/filepath.ml $(CDK)/string2.ml \ - $(CDK)/filename2.ml $(CDK)/list2.ml $(CDK)/hashtbl2.ml \ + $(CDK)/filename2.ml $(CDK)/array2.ml $(CDK)/hashtbl2.ml \ $(CDK)/unix2.ml $(CDK)/file.ml \ - $(CDK)/heap_c.c $(CDK)/array2.ml + $(CDK)/heap_c.c $(CDK)/list2.ml EXTLIB_SRCS += $(EXTLIB)/IO.ml @@ -450,6 +450,8 @@ $(SRC_BITTORRENT)/bTUdpTracker.ml \ $(SRC_BITTORRENT)/bTProtocol.ml \ $(SRC_BITTORRENT)/bTTorrent.ml \ + $(SRC_BITTORRENT)/kademlia.ml \ + $(SRC_BITTORRENT)/bT_DHT.ml \ $(SRC_BITTORRENT)/bTGlobals.ml \ $(SRC_BITTORRENT)/bTComplexOptions.ml \ $(SRC_BITTORRENT)/bTStats.ml \ @@ -536,6 +538,11 @@ $(COMMON_SRCS) $(COMMON_CLIENT_SRCS) $(BITSTRING_SRCS) $(BITTORRENT_SRCS) \ tools/make_torrent.ml +BT_DHT_NODE_SRCS = \ + $(EXTLIB_SRCS) $(CDK_SRCS) $(LIB_SRCS) $(NET_SRCS) \ + $(SRC_BITTORRENT)/bencode.ml $(SRC_BITTORRENT)/kademlia.ml $(SRC_BITTORRENT)/bT_DHT.ml \ + tools/bt_dht_node.ml + GET_RANGE_SRCS = \ $(EXTLIB_SRCS) $(CDK_SRCS) $(LIB_SRCS) $(NET_SRCS) $(MP3TAG_SRCS) \ tools/get_range.ml @@ -1359,6 +1366,7 @@ EXPAND(MLD_HASH,mld_hash) EXPAND(OCAMLPP,ocamlpp) EXPAND(MAKE_TORRENT,make_torrent,NO,NO,NO,NO,MAGIC,BITSTRING,UPNP_NATPMP) +EXPAND(BT_DHT_NODE,bt_dht_node,NO,NO,NO,NO,NO,BITSTRING,UPNP_NATPMP) EXPAND(SUBCONV,subconv) EXPAND(MLSPLIT,mlsplit) EXPAND(CONTESTER,contester,CRYPT) @@ -1462,8 +1470,8 @@ rm -f mlfiletp mlfiletp+gui mlfiletp.exe rm -f mldc mldc+gui mldc.exe rm -f mlfasttrack mlfasttrack+gui mlfasttrack.exe - rm -f svg_converter svg_converter.byte mld_hash make_torrent copysources get_range subconv testrss - rm -f svg_converter.exe mld_hash.exe make_torrent.exe copysources.exe get_range.exe subconv.exe testrss.exe + rm -f svg_converter svg_converter.byte mld_hash make_torrent bt_dht_node copysources get_range subconv testrss + rm -f svg_converter.exe mld_hash.exe make_torrent.exe bt_dht_node.exe copysources.exe get_range.exe subconv.exe testrss.exe rm -f tests tests.exe (for i in $(SUBDIRS); do \ rm -f $$i/*.cm? $$i/*.o $$i/*.annot ; \ @@ -1573,16 +1581,16 @@ cd $(LOCAL)/ocamlopt-$(REQUIRED_OCAML); $(MAKE) ifeq ("$(BITTORRENT)", "yes") -MAKE_TORRENT=make_torrent -MAKE_TORRENT_BYTE=$(MAKE_TORRENT).byte -MAKE_TORRENT_STATIC=$(MAKE_TORRENT).static -MAKE_TORRENT_BYTE_STATIC=$(MAKE_TORRENT_BYTE).static +BT_UTILS=make_torrent bt_dht_node +BT_UTILS_BYTE=$(foreach x, $(BT_UTILS), $(x).byte) +BT_UTILS_STATIC=$(foreach x, $(BT_UTILS), $(x).static) +BT_UTILS_BYTE_STATIC=$(foreach x, $(BT_UTILS), $(x).byte.static) endif -utils.byte: mld_hash.byte $(MAKE_TORRENT_BYTE) copysources.byte get_range.byte subconv.byte -utils.opt: svg_converter mld_hash $(MAKE_TORRENT) copysources get_range subconv -utils.opt.static: svg_converter mld_hash.static $(MAKE_TORRENT_STATIC) copysources.static get_range.static subconv.static -utils.byte.static: mld_hash.byte.static $(MAKE_TORRENT_BYTE_STATIC) copysources.byte.static get_range.byte.static subconv.byte.static +utils.byte: mld_hash.byte $(BT_UTILS_BYTE) copysources.byte get_range.byte subconv.byte +utils.opt: svg_converter mld_hash $(BT_UTILS) copysources get_range subconv +utils.opt.static: svg_converter mld_hash.static $(BT_UTILS_STATIC) copysources.static get_range.static subconv.static +utils.byte.static: mld_hash.byte.static $(BT_UTILS_BYTE_STATIC) copysources.byte.static get_range.byte.static subconv.byte.static utils.static: if test "$(TARGET_TYPE)" = "byte"; then \ $(MAKE) utils.byte.static; \ @@ -1675,10 +1683,10 @@ mv $(DISDIR).tar mldonkey-$(CURRENT_VERSION).static.$(MD4ARCH)-`uname -s | sed "s/\//_/"`$(GLIBC_VERSION_ARCH).tar $(COMPRESS) mldonkey-$(CURRENT_VERSION).static.$(MD4ARCH)-`uname -s | sed "s/\//_/"`$(GLIBC_VERSION_ARCH).tar -release.utils.shared: mld_hash $(MAKE_TORRENT) +release.utils.shared: mld_hash $(BT_UTILS) rm -rf mldonkey-* mkdir -p $(DISDIR) - for i in "mld_hash $(MAKE_TORRENT)"; do \ + for i in "mld_hash $(BT_UTILS)"; do \ cp -f $$i $(DISDIR)/$$i && \ if [ "$(SYSTEM)" != "macos" ]; then \ strip $(DISDIR)/$$i; \ @@ -1689,12 +1697,12 @@ mv $(DISDIR).tar mldonkey-tools-$(CURRENT_VERSION).shared.$(MD4ARCH)-`uname -s | sed "s/\//_/"`$(GLIBC_VERSION_ARCH).tar $(COMPRESS) mldonkey-tools-$(CURRENT_VERSION).shared.$(MD4ARCH)-`uname -s | sed "s/\//_/"`$(GLIBC_VERSION_ARCH).tar -release.utils.static: mld_hash.static $(MAKE_TORRENT_STATIC) +release.utils.static: mld_hash.static $(BT_UTILS_STATIC) rm -rf mldonkey-* mkdir -p $(DISDIR) cp -f mld_hash.static $(DISDIR)/mld_hash && strip $(DISDIR)/mld_hash ifeq ("$(BITTORRENT)", "yes") - cp -f make_torrent.static $(DISDIR)/make_torrent && strip $(DISDIR)/make_torrent + for i in "$(BT_UTILS_STATIC)"; do cp -f $$i $(DISDIR)/$$i && strip $(DISDIR)/$$i; done endif mv $(DISDIR) $(DISDIR)-$(CURRENT_VERSION) tar cf $(DISDIR).tar $(DISDIR)-$(CURRENT_VERSION) diff -Nru mldonkey-3.0.7/debian/changelog mldonkey-3.1.0/debian/changelog --- mldonkey-3.0.7/debian/changelog 2011-05-07 13:42:07.000000000 +0000 +++ mldonkey-3.1.0/debian/changelog 2011-09-14 22:04:12.000000000 +0000 @@ -1,3 +1,18 @@ +mldonkey (3.1.0-2) unstable; urgency=low + + * Remove /var/lib/mldonkey on purge + + -- Stéphane Glondu Thu, 15 Sep 2011 00:04:12 +0200 + +mldonkey (3.1.0-1) unstable; urgency=low + + * New upstream release (Closes: #637646) + - remove Add-a-constructor-to-NullNameValuePairs-in-CryptoPP..patch + (applied upstream) + * Remove /var/lib/mldonkey/downloads.ini on purge + + -- Stéphane Glondu Thu, 08 Sep 2011 20:33:21 +0200 + mldonkey (3.0.7-2) unstable; urgency=low * Fix FTBFS with g++ 4.6 (Closes: #625051) diff -Nru mldonkey-3.0.7/debian/mldonkey-server.postrm mldonkey-3.1.0/debian/mldonkey-server.postrm --- mldonkey-3.0.7/debian/mldonkey-server.postrm 2011-05-07 13:23:23.000000000 +0000 +++ mldonkey-3.1.0/debian/mldonkey-server.postrm 2011-09-14 22:01:35.000000000 +0000 @@ -28,6 +28,7 @@ ucf --purge "$CONF" fi + rm -rf /var/lib/mldonkey rm -rf /var/log/mldonkey rm -rf /var/run/mldonkey diff -Nru mldonkey-3.0.7/debian/patches/0001-Use-usr-bin-see-as-default-previewer.patch mldonkey-3.1.0/debian/patches/0001-Use-usr-bin-see-as-default-previewer.patch --- mldonkey-3.0.7/debian/patches/0001-Use-usr-bin-see-as-default-previewer.patch 2011-05-07 13:23:23.000000000 +0000 +++ mldonkey-3.1.0/debian/patches/0001-Use-usr-bin-see-as-default-previewer.patch 2011-09-14 22:01:03.000000000 +0000 @@ -8,10 +8,10 @@ 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/src/daemon/common/commonOptions.ml b/src/daemon/common/commonOptions.ml -index d390ebb..4ded0e4 100644 +index b3ddb6c..e3a2e64 100644 --- a/src/daemon/common/commonOptions.ml +++ b/src/daemon/common/commonOptions.ml -@@ -1387,7 +1387,7 @@ let hdd_send_warning_interval = define_option current_section ["hdd_send_warning +@@ -1386,7 +1386,7 @@ let hdd_send_warning_interval = define_option current_section ["hdd_send_warning let previewer = define_expert_option current_section ["previewer"] "Name of program used for preview (first arg is local filename, second arg is name of file as searched on eDonkey" diff -Nru mldonkey-3.0.7/debian/patches/0004-Add-a-constructor-to-NullNameValuePairs-in-CryptoPP..patch mldonkey-3.1.0/debian/patches/0004-Add-a-constructor-to-NullNameValuePairs-in-CryptoPP..patch --- mldonkey-3.0.7/debian/patches/0004-Add-a-constructor-to-NullNameValuePairs-in-CryptoPP..patch 2011-05-07 13:24:05.000000000 +0000 +++ mldonkey-3.1.0/debian/patches/0004-Add-a-constructor-to-NullNameValuePairs-in-CryptoPP..patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,25 +0,0 @@ -From: Stephane Glondu -Date: Sat, 7 May 2011 15:19:41 +0200 -Subject: Add a constructor to NullNameValuePairs in CryptoPP.h - -Fixes FTBFS with g++ 4.6. - -Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=625051 -Signed-off-by: Stephane Glondu ---- - src/utils/lib/CryptoPP.h | 1 + - 1 files changed, 1 insertions(+), 0 deletions(-) - -diff --git a/src/utils/lib/CryptoPP.h b/src/utils/lib/CryptoPP.h -index 775a898..af1621b 100644 ---- a/src/utils/lib/CryptoPP.h -+++ b/src/utils/lib/CryptoPP.h -@@ -695,6 +695,7 @@ class CRYPTOPP_DLL NullNameValuePairs : public NameValuePairs - { - public: - bool GetVoidValue(const char* /* name */, const std::type_info& /* valueType */, void* /* pValue */) const {return false;} -+ NullNameValuePairs() {} - }; - - //! _ --- diff -Nru mldonkey-3.0.7/debian/patches/series mldonkey-3.1.0/debian/patches/series --- mldonkey-3.0.7/debian/patches/series 2011-05-07 13:24:05.000000000 +0000 +++ mldonkey-3.1.0/debian/patches/series 2011-09-14 22:01:03.000000000 +0000 @@ -1,4 +1,3 @@ 0001-Use-usr-bin-see-as-default-previewer.patch 0002-Remove-bashisms.patch 0003-Fix-tiger-tree-corruption.patch -0004-Add-a-constructor-to-NullNameValuePairs-in-CryptoPP..patch diff -Nru mldonkey-3.0.7/debian/xml-man/mldonkey_files.xml mldonkey-3.1.0/debian/xml-man/mldonkey_files.xml --- mldonkey-3.0.7/debian/xml-man/mldonkey_files.xml 2011-05-07 13:23:23.000000000 +0000 +++ mldonkey-3.1.0/debian/xml-man/mldonkey_files.xml 2011-09-14 22:01:03.000000000 +0000 @@ -67,7 +67,7 @@ This manual page was written for the &debian; distribution because the original program is &debian; specific. - This script was written by the debian developper to permit smoother + This script was written by the debian developer to permit smoother transition to mldonkey without fasttrack support. MLDonkey suffer from a fasttrack file GPL-problematic. The support of fasttrack has been removed from the upstream source. diff -Nru mldonkey-3.0.7/debian/xml-man/mldonkey_options.xml mldonkey-3.1.0/debian/xml-man/mldonkey_options.xml --- mldonkey-3.0.7/debian/xml-man/mldonkey_options.xml 2011-05-07 13:23:23.000000000 +0000 +++ mldonkey-3.1.0/debian/xml-man/mldonkey_options.xml 2011-09-14 22:01:03.000000000 +0000 @@ -62,7 +62,7 @@ This manual page was written for the &debian; distribution because the original program is &debian; specific. - This script was written by the debian developper to enable easy + This script was written by the debian developer to enable easy configuration through debconf of mlnet server. There is two way of using it : fetching a variable or setting variable. diff -Nru mldonkey-3.0.7/debian/xml-man/mldonkey_users.xml mldonkey-3.1.0/debian/xml-man/mldonkey_users.xml --- mldonkey-3.0.7/debian/xml-man/mldonkey_users.xml 2011-05-07 13:23:23.000000000 +0000 +++ mldonkey-3.1.0/debian/xml-man/mldonkey_users.xml 2011-09-14 22:01:03.000000000 +0000 @@ -71,7 +71,7 @@ This manual page was written for the &debian; distribution because the original program is &debian; specific. - This script was written by the debian developper to enable easy + This script was written by the debian developer to enable easy user management configuration of mlnet server. diff -Nru mldonkey-3.0.7/distrib/ChangeLog mldonkey-3.1.0/distrib/ChangeLog --- mldonkey-3.0.7/distrib/ChangeLog 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/distrib/ChangeLog 2011-08-07 10:25:14.000000000 +0000 @@ -14,6 +14,57 @@ ChangeLog ========= +2011/08/07: version 3.1.0 = tag release-3-1-0 + +2011/07/24 +7499: BT/DHT: fix logging in tools/bt_dht_node.ml + +2011/07/16 +7573: http: better error reporting (ygrek) +7529: configure: better help strings (ygrek) + +2011/05/07 +7541: BT: better UI for subfile selection (ygrek) +- remove debug prefix from set_subfile_prio command +- do not reload page when toggling subfiles (ajax) +7540: CryptoPP: Fix compile error with g++ 4.6 (glondu) +- fixes Debian bug 625051 + +2011/03/28 +7518: Configure: Ocaml VCS moved to SVN +- replace --enable-ocamlver=CVS with --enable-ocamlver=SVN to compile SVN trunk +7517: http: fix XSS in error handler (ygrek) +7495: Fix compilation of Ocaml 3.11.* with recent binutils (ecc, glondu) + +2011/03/20 +7506: BT/DHT: show stats, choose random port (ygrek) + +2011/03/14 +7501: Options: Disable Overnet by default and remove contact.dat from web_infos + +2011/03/13 +7456: Mail: Multiple mail addresses for admin (ygrek) +7500: Diskinfo: Recognize BTRFS + +2011/03/10 +7499: BT/DHT: fix logging (ygrek) +7498: BT/DHT: make token more robust against broken nodes (ygrek) +7497: HTML: mark not saved values in options (ygrek) +7496: BT: stop asking users to submit unknown client ids (ygrek) +7495: Fix compilation of Ocaml 3.12.0 with recent binutils (ecc, glondu) +7494: GTK2 GUI: fix too obtrusive splash window (bugmenot, ygrek) +7493: BT: open DHT port by UPnP (tathar) + +2011/01/31 +7448: BT: support for partial download (jave, pango & ygrek) +- partial files are not committed, location in temp dir is shown so that users + can easily locate downloaded subfiles + +2011/01/23 +7442: BT: DHT support (ygrek) +- new options BT-dht_port, BT-use_trackers, BT-dht_bootstrap_nodes +- new verbosity level "dht" +------------------------------------------------------------------------------- 2011/01/22: version 3.0.7 = tag release-3-0-7 2011/01/06 diff -Nru mldonkey-3.0.7/docs/http-1.1.txt mldonkey-3.1.0/docs/http-1.1.txt --- mldonkey-3.0.7/docs/http-1.1.txt 1970-01-01 00:00:00.000000000 +0000 +++ mldonkey-3.1.0/docs/http-1.1.txt 2005-05-19 03:08:10.000000000 +0000 @@ -0,0 +1 @@ +Get that document here: http://www.w3.org/Protocols/rfc2616/rfc2616.html \ No newline at end of file diff -Nru mldonkey-3.0.7/docs/uri-res.txt mldonkey-3.1.0/docs/uri-res.txt --- mldonkey-3.0.7/docs/uri-res.txt 1970-01-01 00:00:00.000000000 +0000 +++ mldonkey-3.1.0/docs/uri-res.txt 2003-04-02 05:52:24.000000000 +0000 @@ -0,0 +1,507 @@ + + + + + + +Network Working Group R. Daniel +Request for Comments: 2169 Los Alamos National Laboratory +Category: Experimental June 1997 + + + A Trivial Convention for using HTTP in URN Resolution + +Status of this Memo +=================== + + This memo defines an Experimental Protocol for the Internet + community. This memo does not specify an Internet standard of any + kind. Discussion and suggestions for improvement are requested. + Distribution of this memo is unlimited. + +Abstract: +========= + + The Uniform Resource Names Working Group (URN-WG) was formed to + specify persistent, location-independent names for network accessible + resources, as well as resolution mechanisms to retrieve the resources + given such a name. At this time the URN-WG is considering one + particular resolution mechanism, the NAPTR proposal [1]. That + proposal specifies how a client may find a "resolver" for a URN. A + resolver is a database that can provide information about the + resource identified by a URN, such as the resource's location, a + bibliographic description, or even the resource itself. The protocol + used for the client to communicate with the resolver is not specified + in the NAPTR proposal. Instead, the NAPTR resource record provides a + field that indicates the "resolution protocol" and "resolution + service requests" offered by the resolver. + + This document specifies the "THTTP" resolution protocol - a trivial + convention for encoding resolution service requests and responses as + HTTP 1.0 or 1.1 requests and responses. The primary goal of THTTP is + to be simple to implement so that existing HTTP servers may easily + add support for URN resolution. We expect that the databases used by + early resolvers will be useful when more sophisticated resolution + protocols are developed later. + +1.0 Introduction: +================== + + The NAPTR specification[1] defined a new DNS resource record which + may be used to discover resolvers for Uniform Resource Identifiers. + That resource record provides the "services" field to specify the + "resolution protocol" spoken by the resolver, as well as the + "resolution services" it offers. Resolution protocols mentioned in + + + +Daniel Experimental [Page 1] + +RFC 2169 HTTP in URN Resolution June 1997 + + + that specification are Z3950, THTTP, RCDS, HDL, and RWHOIS. (That + list is expected to grow over time). The NAPTR specification also + lists a variety of resolution services, such as N2L (given a URN, + return a URL); N2R (Given a URN, return the named resource), etc. + + This document specifies the "THTTP" (Trivial HTTP) resolution + protocol. THTTP is a simple convention for encoding resolution + service requests and responses as HTTP 1.0 or 1.1 requests and + responses. The primary goal of THTTP is to have a URN resolution + protocol that can easily be added to existing HTTP daemons. Other + resolution protocols are expected to arise over time, so this + document serves a secondary purpose of illustrating the information + that needs to be specified for a URN resolution protocol. One of the + resolution protocols we expect to be developed is an extension of + HTTP with new methods for the resolution services. Therefore, we use + "THTTP" as the identifier for this protocol to leave "HTTP" for later + developments. + + The reader is assumed to be familiar with the HTTP/1.0 [2] and 1.1 + [3] specifications. Implementors of this specification should be + familiar with CGI scripts, or server-specific interfaces, for + database lookups. + +2.0 General Approach: +===================== + + The general approach used to encode resolution service requests in + THTTP is quite simple: + + GET /uri-res/? HTTP/1.0 + + For example, if we have the URN "urn:foo:12345-54321" and want a URL, + we would send the request: + + GET /uri-res/N2L?urn:foo:12345-54321 HTTP/1.0 + + The request could also be encoded as an HTTP 1.1 request. This would + look like: + + GET /uri-res/N2L?urn:foo:12345-54321 HTTP/1.1 + Host: + + Responses from the HTTP server follow standard HTTP practice. Status + codes, such as 200 (OK) or 404 (Not Found) shall be returned. The + normal rules for determining cachability, negotiating formats, etc. + apply. + + + + + +Daniel Experimental [Page 2] + +RFC 2169 HTTP in URN Resolution June 1997 + + + Handling these requests on the server side is easy to implement using + CGI or other, server-specific, extension mechanisms. CGI scripts + will see the incoming URI in the QUERY_STRING environment variable. + Any %encoded characters in the URN will remain in their %encoded + state in that string. The script can take the URN, look it up in a + database, and return the requested information. + + One caveat should be kept in mind. The URN syntax document [4] + discusses the notion of lexical equivalance and requires that + resolvers return identical results for URNs that are lexically + equivalent. Implementors of this specification must be careful to + obey that rule. For example, the two requests below MUST return + identical results, since the URNs are lexically equivalent. + GET /uri-res/N2L?urn:cid:foo@huh.com HTTP/1.0 + GET /uri-res/N2L?URN:CID:foo@huh.com HTTP/1.0 + +3.0 Service-specific details: +============================= + + This section goes through the various resolution services established + in the URN services document [5] and states how to encode each of + them, how the results should be returned, and any special status + codes that are likely to arise. + + Unless stated otherwise, the THTTP requests are formed according to + the simple convention above, either for HTTP/1.0 or HTTP/1.1. The + response is assumed to be an entity with normal headers and body + unless stated otherwise. (N2L is the only request that need not + return a body). + +3.1 N2L (URN to URL): +---------------------- + + The request is encoded as above. The URL MUST be returned in a + Location: header for the convienience of the user in the most common + case of wanting the resource. If the lookup is successful, a 30X + status line SHOULD be returned. HTTP/1.1 clients should be sent the + 303 status code. HTTP/1.0 clients should be sent the 302 (Moved + temporarily) status code unless the resolver has particular reasons + for using 301 (moved permanently) or 304 (not modified) codes. + + Note that access controls may be applied to this, or any other, + resolution service request. Therefore the 401 (unauthorized) and 403 + (forbidden) status codes are legal responses. The server may wish to + provide a body in the response to explain the reason for refusing + access, and/or to provide alternate information about the resource, + such as the price it will cost to obtain the resource's URL. + + + + +Daniel Experimental [Page 3] + +RFC 2169 HTTP in URN Resolution June 1997 + + +3.2 N2Ls (URN to URLs): +------------------------ + + The request is encoded as above. The result is a list of 0 or more + URLs. The Internet Media Type (aka ContentType) of the result may be + negotiated using standard HTTP mechanisms if desired. At a minimum + the resolver should support the text/uri-list media type. (See + Appendix A for the definition of this media type). That media type is + suitable for machine-processing of the list of URLs. Resolvers may + also return the results as text/html, text/plain, or any other media + type they deem suitable. + + No matter what the particular media type, the result MUST be a list + of the URLs which may be used to obtain an instance of the resource + identified by the URN. All URIs shall be encoded according to the URI + specification [6]. + + If the client has requested the result be returned as text/html or + application/html, the result should be a valid HTML docment + containing the fragment: + + where the strings ...url n... are replaced by the n'th URL in the + list. + +3.3 N2R (URN to Resource): +--------------------------- + + The request is encoded as above. The resource is returned using + standard HTTP mechanisms. The request may be modified using the + Accept: header as in normal HTTP to specify that the result be given + in a preferred Internet Media Type. + +3.4 N2Rs (URN to Resources): +----------------------------- + + This resolution service returns multiple instances of a resource, for + example, GIF and JPEG versions of an image. The judgment about the + resources being "the same" resides with the naming authority that + issued the URN. + + The request is encoded as above. The result shall be a MIME + multipart/alternative message with the alternative versions of the + resource in seperate body parts. If there is only one version of the + resource identified by the URN, it MAY be returned without the + + + +Daniel Experimental [Page 4] + +RFC 2169 HTTP in URN Resolution June 1997 + + + multipart/alternative wrapper. Resolver software SHOULD look at the + Accept: header, if any, and only return versions of the resource that + are acceptable according to that header. + +3.5 N2C (URN to URC): +---------------------- + + URCs (Uniform Resource Characteristics) are descriptions of other + resources. This request allows us to obtain a description of the + resource identified by a URN, as opposed to the resource itself. The + description might be a bibliographic citation, a digital signature, a + revision history, etc. This document does not specify the content of + any response to a URC request. That content is expected to vary from + one resolver to another. + + The format of any response to a N2C request MUST be communicated + using the ContentType header, as is standard HTTP practice. The + Accept: header SHOULD be honored. + +3.6 N2Ns (URN to URNs): +------------------------ + + While URNs are supposed to identify one and only one resource, that + does not mean that a resource may have one and only one URN. For + example, consider a resource that has something like "current- + weather-map" for one URN and "weather-map-for-datetime-x" for another + URN. The N2Ns service request lets us obtain lists of URNs that are + believed equivalent at the time of the request. As the weathermap + example shows, some of the equivalances will be transitory, so the + standard HTTP mechanisms for communicating cachability MUST be + honored. + + The request is encoded as above. The result is a list of all the + URNs, known to the resolver, which identify the same resource as the + input URN. The result shall be encoded as for the N2Ls request above + (text/uri-list unless specified otherwise by an Accept: header). + +3.7 L2Ns (URL to URNs): +---------------------- + + The request is encoded as above. The response is a list of any URNs + known to be assigned to the resource at the given URL. The result + shall be encoded as for the N2Ls and N2Ns requests. + + + + + + + + +Daniel Experimental [Page 5] + +RFC 2169 HTTP in URN Resolution June 1997 + + +3.8 L2Ls (URL to URLs): +------------------------ + + The request is encoded as described above. The result is a list of + all the URLs that the resolver knows are associated with the resource + located by the given URL. This is encoded as for the N2Ls, N2Ns, and + L2Ns requests. + +3.9 L2C (URL to URC): +---------------------- + + The request is encoded as above, the response is the same as for the + N2C request. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Daniel Experimental [Page 6] + +RFC 2169 HTTP in URN Resolution June 1997 + + +Appendix A: The text/uri-list Internet Media Type +================================================= +[This appendix will be augmented or replaced by the registration of the +text/uri-list IMT once that registration has been performed]. + + Several of the resolution service requests, such as N2Ls, N2Ns, L2Ns, + L2Ls, result in a list of URIs being returned to the client. The + text/uri-list Internet Media Type is defined to provide a simple + format for the automatic processing of such lists of URIs. + + The format of text/uri-list resources is: + + 1) Any lines beginning with the '#' character are comment lines + and are ignored during processing. (Note that '#' is a character + that may appear in URIs, so it only denotes a comment when it is the + first character on a line). + 2) The remaining non-comment lines MUST be URIs (URNs or URLs), encoded + according to the URI specification RFC[6]. Each URI shall appear on + one and only one line. + 3) As for all text/* formats, lines are terminated with a CR LF pair, + although clients should be liberal in accepting lines with only + one of those characters. + + In applications where one URI has been mapped to a list of URIs, such + as in response to the N2Ls request, the first line of the text/uri- + list response SHOULD be a comment giving the original URI. + + An example of such a result for the N2L request is shown below in + figure 1. + + # urn:cid:foo@huh.org + http://www.huh.org/cid/foo.html + http://www.huh.org/cid/foo.pdf + ftp://ftp.foo.org/cid/foo.txt + + Figure 1: Example of the text/uri-list format + +Appendix B: n2l.pl script +========================== + + This is a simple CGI script for the N2L resolution service. It + assumes the presence of a DBM database to store the URN to URL + mappings. This script does not specify standard behavior, it is + provided merely as a courtesy for implementors. In fact, this script + does not process incoming Accept: headers, nor does it generate + status codes. Such behavior should be part of a real script for any + of the resolution services. + + + + +Daniel Experimental [Page 7] + +RFC 2169 HTTP in URN Resolution June 1997 + + + #!/bin/perl + # N2L - performs urn to url resolution + + $n2l_File = "...filename for DBM database..."; + + + $urn = $ENV{'QUERY_STRING'} ; + + # Sanity check on the URN. Minimum length of a valid URN is + # 7 characters - "urn:", a 1-character Namespace ID, ":", and + # a 1-character namespace-specific string. More elaborate + # sanity checks should be part of a real resolver script. + if(length($urn)<7) + { + $error=1; + } + + if(!$error) + { + # Convert lexically equivalent versions of a URI into + # a canonical version for DB lookups. + $urn =~ s/^urn:([^:]*):(.*)$/sprintf("urn:%s:%s", lc $1, $2)/ie; + + dbmopen(%lu,$n2l_File,0444); + if($lu{$urn}) + { + $url=$lu{$urn}; + print STDOUT "Location: $url\n\n"; + }else{ + $error=2; + } + dbmclose(%lu); + } + + if($error) + { + print "Content-Type: text/html \n\n"; + print "\n"; + print "URN Resolution: N2L\n"; + print "\n"; + print "

URN to URL resolution failed for the URN:

\n"; + print "

$urn

\n"; + print "\n"; + print "\n"; + } + + exit; + + + + +Daniel Experimental [Page 8] + +RFC 2169 HTTP in URN Resolution June 1997 + + +References: +=========== + + [1] Daniel, Ron and Michael Mealling, RFC 2168, "Resolution of Uniform + Resource Identifiers using the Domain Name System", June 1997. + + [2] Berners-Lee, T, R. Fielding, H. Frystyk, RFC 1945, "Hypertext + Transfer Protocol -- HTTP/1.0", T. Berners-Lee, May 1996. + + [3] Fielding, R., J. Gettys, J.C. Mogul, H. Frystyk, T. Berners-Lee, + RFC 2068, "Hypertext Transfer Protocol -- HTTP/1.1", Jan. 1997. + + [4] Moats, R., RFC 2141, "URN Syntax", May 1997. + + [5] URN-WG. "URN Resolution Services". Work In Progress. + + [6] Berners-Lee, T., RFC 1630, "Universal Resource Identifiers in WWW: + A Unifying Syntax for the Expression of Names and Addresses of + Objects on the Network as used in the World-Wide Web", June 1994. + +Security Considerations +======================= + + Communications with a resolver may be of a sensitive nature. Some + resolvers will hold information that should only be released to + authorized users. The results from resolvers may be the target of + spoofing, especially once electronic commerce transactions are common + and there is money to be made by directing users to pirate + repositories rather than repositories which pay royalties to + rightsholders. Resolution requests may be of interest to traffic + analysts. The requests may also be subject to spoofing. + + The requests and responses in this draft are amenable to encoding, + signing, and authentication in the manner of any other HTTP traffic. + +Author Contact Information: +=========================== + + Advanced Computing Lab, MS B287 + Los Alamos National Laboratory + Los Alamos, NM, USA, 87545 + voice: +1 505 665 0597 + fax: +1 505 665 4939 + email: rdaniel@lanl.gov + + + + + + + +Daniel Experimental [Page 9] + diff -Nru mldonkey-3.0.7/docs/uri.txt mldonkey-3.1.0/docs/uri.txt --- mldonkey-3.0.7/docs/uri.txt 1970-01-01 00:00:00.000000000 +0000 +++ mldonkey-3.1.0/docs/uri.txt 2005-05-19 03:08:10.000000000 +0000 @@ -0,0 +1 @@ +Get that document here: http://www.faqs.org/rfcs/rfc2396.html \ No newline at end of file diff -Nru mldonkey-3.0.7/Makefile mldonkey-3.1.0/Makefile --- mldonkey-3.0.7/Makefile 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/Makefile 2011-08-08 05:11:57.000000000 +0000 @@ -28,8 +28,8 @@ NO_STATIC_LIBS_opt= NO_CMXA= -LIBS_byte=-custom bigarray.cma unix.cma str.cma -LIBS_opt= bigarray.cmxa unix.cmxa str.cmxa +LIBS_byte=-custom bigarray.cma unix.cma str.cma nums.cma +LIBS_opt= bigarray.cmxa unix.cmxa str.cmxa nums.cmxa BIGARRAY_LIBS_opt=bigarray.cmxa BIGARRAY_LIBS_byte=bigarray.cma @@ -152,9 +152,9 @@ $(CDK)/heap.ml \ $(CDK)/printexc2.ml $(CDK)/genlex2.ml \ $(CDK)/filepath.ml $(CDK)/string2.ml \ - $(CDK)/filename2.ml $(CDK)/list2.ml $(CDK)/hashtbl2.ml \ + $(CDK)/filename2.ml $(CDK)/array2.ml $(CDK)/hashtbl2.ml \ $(CDK)/unix2.ml $(CDK)/file.ml \ - $(CDK)/heap_c.c $(CDK)/array2.ml + $(CDK)/heap_c.c $(CDK)/list2.ml EXTLIB_SRCS += $(EXTLIB)/IO.ml @@ -450,6 +450,8 @@ $(SRC_BITTORRENT)/bTUdpTracker.ml \ $(SRC_BITTORRENT)/bTProtocol.ml \ $(SRC_BITTORRENT)/bTTorrent.ml \ + $(SRC_BITTORRENT)/kademlia.ml \ + $(SRC_BITTORRENT)/bT_DHT.ml \ $(SRC_BITTORRENT)/bTGlobals.ml \ $(SRC_BITTORRENT)/bTComplexOptions.ml \ $(SRC_BITTORRENT)/bTStats.ml \ @@ -536,6 +538,11 @@ $(COMMON_SRCS) $(COMMON_CLIENT_SRCS) $(BITSTRING_SRCS) $(BITTORRENT_SRCS) \ tools/make_torrent.ml +BT_DHT_NODE_SRCS = \ + $(EXTLIB_SRCS) $(CDK_SRCS) $(LIB_SRCS) $(NET_SRCS) \ + $(SRC_BITTORRENT)/bencode.ml $(SRC_BITTORRENT)/kademlia.ml $(SRC_BITTORRENT)/bT_DHT.ml \ + tools/bt_dht_node.ml + GET_RANGE_SRCS = \ $(EXTLIB_SRCS) $(CDK_SRCS) $(LIB_SRCS) $(NET_SRCS) $(MP3TAG_SRCS) \ tools/get_range.ml @@ -3905,6 +3912,69 @@ -I build $(MAKE_TORRENT_CMAS) $(MAKE_TORRENT_CMOS) +BT_DHT_NODE_ZOG := $(filter %.zog, $(BT_DHT_NODE_SRCS)) +BT_DHT_NODE_MLL := $(filter %.mll, $(BT_DHT_NODE_SRCS)) +BT_DHT_NODE_MLY := $(filter %.mly, $(BT_DHT_NODE_SRCS)) +BT_DHT_NODE_ML4 := $(filter %.ml4, $(BT_DHT_NODE_SRCS)) +BT_DHT_NODE_MLC4 := $(filter %.mlc4, $(BT_DHT_NODE_SRCS)) +BT_DHT_NODE_MLT := $(filter %.mlt, $(BT_DHT_NODE_SRCS)) +BT_DHT_NODE_MLP := $(filter %.mlcpp, $(BT_DHT_NODE_SRCS)) +BT_DHT_NODE_ML := $(filter %.ml %.mll %.zog %.mly %.ml4 %.mlc4 %.mlt %.mlcpp, $(BT_DHT_NODE_SRCS)) +BT_DHT_NODE_C := $(filter %.c %.cc, $(BT_DHT_NODE_SRCS)) +BT_DHT_NODE_CMOS=$(foreach file, $(BT_DHT_NODE_ML), $(basename $(file)).cmo) +BT_DHT_NODE_CMXS=$(foreach file, $(BT_DHT_NODE_ML), $(basename $(file)).cmx) +BT_DHT_NODE_OBJS=$(foreach file, $(BT_DHT_NODE_C), $(basename $(file)).o) + +BT_DHT_NODE_CMXAS := $(foreach file, $(BT_DHT_NODE_CMXA), build/$(basename $(file)).cmxa) +BT_DHT_NODE_CMAS=$(foreach file, $(BT_DHT_NODE_CMXA), build/$(basename $(file)).cma) + +TMPSOURCES += $(BT_DHT_NODE_ML4:.ml4=.ml) $(BT_DHT_NODE_MLC4:.mlc4=.ml) $(BT_DHT_NODE_MLT:.mlt=.ml) $(BT_DHT_NODE_MLP:.mlcpp=.ml) $(BT_DHT_NODE_MLL:.mll=.ml) $(BT_DHT_NODE_MLY:.mly=.ml) $(BT_DHT_NODE_MLY:.mly=.mli) $(BT_DHT_NODE_ZOG:.zog=.ml) + +bt_dht_node: $(BT_DHT_NODE_OBJS) $(BT_DHT_NODE_CMXS) $(BT_DHT_NODE_CMXAS) + $(OCAMLOPT) -linkall -o $@ \ + $(BT_DHT_NODE_OBJS) $(LIBS_opt) $(LIBS_flags) \ + $(NO_LIBS_opt) $(NO_LIBS_flags) \ + $(NO_LIBS_opt) $(NO_LIBS_flags) \ + $(NO_LIBS_opt) $(NO_LIBS_flags) \ + $(NO_LIBS_opt) $(NO_LIBS_flags) \ + $(BITSTRING_LIBS_opt) $(BITSTRING_LIBS_flags) \ + $(UPNP_NATPMP_LIBS_opt) $(UPNP_NATPMP_LIBS_flags) \ + -I build $(BT_DHT_NODE_CMXAS) $(BT_DHT_NODE_CMXS) + +bt_dht_node.byte: $(BT_DHT_NODE_OBJS) $(BT_DHT_NODE_CMOS) $(BT_DHT_NODE_CMAS) + $(OCAMLC) -linkall -o $@ \ + $(BT_DHT_NODE_OBJS) $(LIBS_byte) $(LIBS_flags) \ + $(NO_LIBS_byte) $(NO_LIBS_flags) \ + $(NO_LIBS_byte) $(NO_LIBS_flags) \ + $(NO_LIBS_byte) $(NO_LIBS_flags) \ + $(NO_LIBS_byte) $(NO_LIBS_flags) \ + $(BITSTRING_LIBS_byte) $(BITSTRING_LIBS_flags) \ + $(UPNP_NATPMP_LIBS_byte) $(UPNP_NATPMP_LIBS_flags) \ + -I build $(BT_DHT_NODE_CMAS) $(BT_DHT_NODE_CMOS) + +bt_dht_node.static: $(BT_DHT_NODE_OBJS) $(BT_DHT_NODE_CMXS) $(BT_DHT_NODE_CMXAS) + $(OCAMLOPT) -linkall -ccopt -static -o $@ \ + $(BT_DHT_NODE_OBJS) $(LIBS_opt) $(LIBS_flags) \ + $(NO_LIBS_flags) $(NO_STATIC_LIBS_opt) \ + $(NO_LIBS_flags) $(NO_STATIC_LIBS_opt) \ + $(NO_LIBS_flags) $(NO_STATIC_LIBS_opt) \ + $(NO_LIBS_flags) $(NO_STATIC_LIBS_opt) \ + $(BITSTRING_LIBS_flags) $(BITSTRING_STATIC_LIBS_opt) \ + $(UPNP_NATPMP_LIBS_flags) $(UPNP_NATPMP_STATIC_LIBS_opt) \ + -I build $(BT_DHT_NODE_CMXAS) $(BT_DHT_NODE_CMXS) + +bt_dht_node.byte.static: $(BT_DHT_NODE_OBJS) $(BT_DHT_NODE_CMOS) $(BT_DHT_NODE_CMAS) + $(OCAMLC) -linkall -ccopt -static -o $@ \ + $(BT_DHT_NODE_OBJS) $(LIBS_byte) $(LIBS_flags) \ + $(NO_LIBS_flags) $(NO_STATIC_LIBS_opt) \ + $(NO_LIBS_flags) $(NO_STATIC_LIBS_opt) \ + $(NO_LIBS_flags) $(NO_STATIC_LIBS_opt) \ + $(NO_LIBS_flags) $(NO_STATIC_LIBS_opt) \ + $(BITSTRING_LIBS_flags) $(BITSTRING_STATIC_LIBS_opt) \ + $(UPNP_NATPMP_LIBS_flags) $(UPNP_NATPMP_STATIC_LIBS_opt) \ + -I build $(BT_DHT_NODE_CMAS) $(BT_DHT_NODE_CMOS) + + SUBCONV_ZOG := $(filter %.zog, $(SUBCONV_SRCS)) SUBCONV_MLL := $(filter %.mll, $(SUBCONV_SRCS)) SUBCONV_MLY := $(filter %.mly, $(SUBCONV_SRCS)) @@ -4999,8 +5069,8 @@ rm -f mlfiletp mlfiletp+gui mlfiletp.exe rm -f mldc mldc+gui mldc.exe rm -f mlfasttrack mlfasttrack+gui mlfasttrack.exe - rm -f svg_converter svg_converter.byte mld_hash make_torrent copysources get_range subconv testrss - rm -f svg_converter.exe mld_hash.exe make_torrent.exe copysources.exe get_range.exe subconv.exe testrss.exe + rm -f svg_converter svg_converter.byte mld_hash make_torrent bt_dht_node copysources get_range subconv testrss + rm -f svg_converter.exe mld_hash.exe make_torrent.exe bt_dht_node.exe copysources.exe get_range.exe subconv.exe testrss.exe rm -f tests tests.exe (for i in $(SUBDIRS); do \ rm -f $$i/*.cm? $$i/*.o $$i/*.annot ; \ @@ -5110,16 +5180,16 @@ cd $(LOCAL)/ocamlopt-$(REQUIRED_OCAML); $(MAKE) ifeq ("$(BITTORRENT)", "yes") -MAKE_TORRENT=make_torrent -MAKE_TORRENT_BYTE=$(MAKE_TORRENT).byte -MAKE_TORRENT_STATIC=$(MAKE_TORRENT).static -MAKE_TORRENT_BYTE_STATIC=$(MAKE_TORRENT_BYTE).static +BT_UTILS=make_torrent bt_dht_node +BT_UTILS_BYTE=$(foreach x, $(BT_UTILS), $(x).byte) +BT_UTILS_STATIC=$(foreach x, $(BT_UTILS), $(x).static) +BT_UTILS_BYTE_STATIC=$(foreach x, $(BT_UTILS), $(x).byte.static) endif -utils.byte: mld_hash.byte $(MAKE_TORRENT_BYTE) copysources.byte get_range.byte subconv.byte -utils.opt: svg_converter mld_hash $(MAKE_TORRENT) copysources get_range subconv -utils.opt.static: svg_converter mld_hash.static $(MAKE_TORRENT_STATIC) copysources.static get_range.static subconv.static -utils.byte.static: mld_hash.byte.static $(MAKE_TORRENT_BYTE_STATIC) copysources.byte.static get_range.byte.static subconv.byte.static +utils.byte: mld_hash.byte $(BT_UTILS_BYTE) copysources.byte get_range.byte subconv.byte +utils.opt: svg_converter mld_hash $(BT_UTILS) copysources get_range subconv +utils.opt.static: svg_converter mld_hash.static $(BT_UTILS_STATIC) copysources.static get_range.static subconv.static +utils.byte.static: mld_hash.byte.static $(BT_UTILS_BYTE_STATIC) copysources.byte.static get_range.byte.static subconv.byte.static utils.static: if test "$(TARGET_TYPE)" = "byte"; then \ $(MAKE) utils.byte.static; \ @@ -5212,10 +5282,10 @@ mv $(DISDIR).tar mldonkey-$(CURRENT_VERSION).static.$(MD4ARCH)-`uname -s | sed "s/\//_/"`$(GLIBC_VERSION_ARCH).tar $(COMPRESS) mldonkey-$(CURRENT_VERSION).static.$(MD4ARCH)-`uname -s | sed "s/\//_/"`$(GLIBC_VERSION_ARCH).tar -release.utils.shared: mld_hash $(MAKE_TORRENT) +release.utils.shared: mld_hash $(BT_UTILS) rm -rf mldonkey-* mkdir -p $(DISDIR) - for i in "mld_hash $(MAKE_TORRENT)"; do \ + for i in "mld_hash $(BT_UTILS)"; do \ cp -f $$i $(DISDIR)/$$i && \ if [ "$(SYSTEM)" != "macos" ]; then \ strip $(DISDIR)/$$i; \ @@ -5226,12 +5296,12 @@ mv $(DISDIR).tar mldonkey-tools-$(CURRENT_VERSION).shared.$(MD4ARCH)-`uname -s | sed "s/\//_/"`$(GLIBC_VERSION_ARCH).tar $(COMPRESS) mldonkey-tools-$(CURRENT_VERSION).shared.$(MD4ARCH)-`uname -s | sed "s/\//_/"`$(GLIBC_VERSION_ARCH).tar -release.utils.static: mld_hash.static $(MAKE_TORRENT_STATIC) +release.utils.static: mld_hash.static $(BT_UTILS_STATIC) rm -rf mldonkey-* mkdir -p $(DISDIR) cp -f mld_hash.static $(DISDIR)/mld_hash && strip $(DISDIR)/mld_hash ifeq ("$(BITTORRENT)", "yes") - cp -f make_torrent.static $(DISDIR)/make_torrent && strip $(DISDIR)/make_torrent + for i in "$(BT_UTILS_STATIC)"; do cp -f $$i $(DISDIR)/$$i && strip $(DISDIR)/$$i; done endif mv $(DISDIR) $(DISDIR)-$(CURRENT_VERSION) tar cf $(DISDIR).tar $(DISDIR)-$(CURRENT_VERSION) diff -Nru mldonkey-3.0.7/patches/ocaml-3.11.0.patch mldonkey-3.1.0/patches/ocaml-3.11.0.patch --- mldonkey-3.0.7/patches/ocaml-3.11.0.patch 1970-01-01 00:00:00.000000000 +0000 +++ mldonkey-3.1.0/patches/ocaml-3.11.0.patch 2011-03-28 18:17:24.000000000 +0000 @@ -0,0 +1,66 @@ +From: Stephane Glondu +Date: Tue, 8 Mar 2011 21:17:40 +0100 +Subject: [PATCH] Fix ocamlopt w.r.t. binutils 2.21 +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Bug: http://caml.inria.fr/mantis/view.php?id=5237 +Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=617404 +Authors: Eric Cooper, spiralvoice +Reviewed-by: Stéphane Glondu +--- + asmcomp/amd64/emit.mlp | 13 +++++++------ + asmcomp/i386/emit.mlp | 6 +++--- + 2 files changed, 10 insertions(+), 9 deletions(-) + +diff --git a/asmcomp/amd64/emit.mlp b/asmcomp/amd64/emit.mlp +index 4a3f844..525c6e6 100644 +--- a/asmcomp/amd64/emit.mlp ++++ b/asmcomp/amd64/emit.mlp +@@ -679,17 +679,18 @@ let fundecl fundecl = + emit_all true fundecl.fun_body; + List.iter emit_call_gc !call_gc_sites; + emit_call_bound_errors (); ++ begin match Config.system with ++ "linux" | "gnu" -> ++ ` .type {emit_symbol fundecl.fun_name},@function\n`; ++ ` .size {emit_symbol fundecl.fun_name},.-{emit_symbol fundecl.fun_name}\n` ++ | _ -> () ++ end; + if !float_constants <> [] then begin + if macosx + then ` .literal8\n` + else ` .section .rodata.cst8,\"a\",@progbits\n`; + List.iter emit_float_constant !float_constants +- end; +- match Config.system with +- "linux" | "gnu" -> +- ` .type {emit_symbol fundecl.fun_name},@function\n`; +- ` .size {emit_symbol fundecl.fun_name},.-{emit_symbol fundecl.fun_name}\n` +- | _ -> () ++ end + + (* Emission of data *) + +diff --git a/asmcomp/i386/emit.mlp b/asmcomp/i386/emit.mlp +index 2992f29..0b1252c 100644 +--- a/asmcomp/i386/emit.mlp ++++ b/asmcomp/i386/emit.mlp +@@ -905,12 +905,12 @@ let fundecl fundecl = + emit_all true fundecl.fun_body; + List.iter emit_call_gc !call_gc_sites; + emit_call_bound_errors (); +- List.iter emit_float_constant !float_constants; +- match Config.system with ++ begin match Config.system with + "linux_elf" | "bsd_elf" | "gnu" -> + ` .type {emit_symbol fundecl.fun_name},@function\n`; + ` .size {emit_symbol fundecl.fun_name},.-{emit_symbol fundecl.fun_name}\n` +- | _ -> () ++ | _ -> () end; ++ List.iter emit_float_constant !float_constants + + + (* Emission of data *) +-- diff -Nru mldonkey-3.0.7/patches/ocaml-3.11.1.patch mldonkey-3.1.0/patches/ocaml-3.11.1.patch --- mldonkey-3.0.7/patches/ocaml-3.11.1.patch 1970-01-01 00:00:00.000000000 +0000 +++ mldonkey-3.1.0/patches/ocaml-3.11.1.patch 2011-03-28 18:17:24.000000000 +0000 @@ -0,0 +1,66 @@ +From: Stephane Glondu +Date: Tue, 8 Mar 2011 21:17:40 +0100 +Subject: [PATCH] Fix ocamlopt w.r.t. binutils 2.21 +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Bug: http://caml.inria.fr/mantis/view.php?id=5237 +Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=617404 +Authors: Eric Cooper, spiralvoice +Reviewed-by: Stéphane Glondu +--- + asmcomp/amd64/emit.mlp | 13 +++++++------ + asmcomp/i386/emit.mlp | 6 +++--- + 2 files changed, 10 insertions(+), 9 deletions(-) + +diff --git a/asmcomp/amd64/emit.mlp b/asmcomp/amd64/emit.mlp +index 4a3f844..525c6e6 100644 +--- a/asmcomp/amd64/emit.mlp ++++ b/asmcomp/amd64/emit.mlp +@@ -679,17 +679,18 @@ let fundecl fundecl = + emit_all true fundecl.fun_body; + List.iter emit_call_gc !call_gc_sites; + emit_call_bound_errors (); ++ begin match Config.system with ++ "linux" | "gnu" -> ++ ` .type {emit_symbol fundecl.fun_name},@function\n`; ++ ` .size {emit_symbol fundecl.fun_name},.-{emit_symbol fundecl.fun_name}\n` ++ | _ -> () ++ end; + if !float_constants <> [] then begin + if macosx + then ` .literal8\n` + else ` .section .rodata.cst8,\"a\",@progbits\n`; + List.iter emit_float_constant !float_constants +- end; +- match Config.system with +- "linux" | "gnu" -> +- ` .type {emit_symbol fundecl.fun_name},@function\n`; +- ` .size {emit_symbol fundecl.fun_name},.-{emit_symbol fundecl.fun_name}\n` +- | _ -> () ++ end + + (* Emission of data *) + +diff --git a/asmcomp/i386/emit.mlp b/asmcomp/i386/emit.mlp +index 2992f29..0b1252c 100644 +--- a/asmcomp/i386/emit.mlp ++++ b/asmcomp/i386/emit.mlp +@@ -905,12 +905,12 @@ let fundecl fundecl = + emit_all true fundecl.fun_body; + List.iter emit_call_gc !call_gc_sites; + emit_call_bound_errors (); +- List.iter emit_float_constant !float_constants; +- match Config.system with ++ begin match Config.system with + "linux_elf" | "bsd_elf" | "gnu" -> + ` .type {emit_symbol fundecl.fun_name},@function\n`; + ` .size {emit_symbol fundecl.fun_name},.-{emit_symbol fundecl.fun_name}\n` +- | _ -> () ++ | _ -> () end; ++ List.iter emit_float_constant !float_constants + + + (* Emission of data *) +-- diff -Nru mldonkey-3.0.7/patches/ocaml-3.11.2.patch mldonkey-3.1.0/patches/ocaml-3.11.2.patch --- mldonkey-3.0.7/patches/ocaml-3.11.2.patch 1970-01-01 00:00:00.000000000 +0000 +++ mldonkey-3.1.0/patches/ocaml-3.11.2.patch 2011-03-28 18:17:24.000000000 +0000 @@ -0,0 +1,66 @@ +From: Stephane Glondu +Date: Tue, 8 Mar 2011 21:17:40 +0100 +Subject: [PATCH] Fix ocamlopt w.r.t. binutils 2.21 +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Bug: http://caml.inria.fr/mantis/view.php?id=5237 +Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=617404 +Authors: Eric Cooper, spiralvoice +Reviewed-by: Stéphane Glondu +--- + asmcomp/amd64/emit.mlp | 13 +++++++------ + asmcomp/i386/emit.mlp | 6 +++--- + 2 files changed, 10 insertions(+), 9 deletions(-) + +diff --git a/asmcomp/amd64/emit.mlp b/asmcomp/amd64/emit.mlp +index 4a3f844..525c6e6 100644 +--- a/asmcomp/amd64/emit.mlp ++++ b/asmcomp/amd64/emit.mlp +@@ -679,17 +679,18 @@ let fundecl fundecl = + emit_all true fundecl.fun_body; + List.iter emit_call_gc !call_gc_sites; + emit_call_bound_errors (); ++ begin match Config.system with ++ "linux" | "gnu" -> ++ ` .type {emit_symbol fundecl.fun_name},@function\n`; ++ ` .size {emit_symbol fundecl.fun_name},.-{emit_symbol fundecl.fun_name}\n` ++ | _ -> () ++ end; + if !float_constants <> [] then begin + if macosx + then ` .literal8\n` + else ` .section .rodata.cst8,\"a\",@progbits\n`; + List.iter emit_float_constant !float_constants +- end; +- match Config.system with +- "linux" | "gnu" -> +- ` .type {emit_symbol fundecl.fun_name},@function\n`; +- ` .size {emit_symbol fundecl.fun_name},.-{emit_symbol fundecl.fun_name}\n` +- | _ -> () ++ end + + (* Emission of data *) + +diff --git a/asmcomp/i386/emit.mlp b/asmcomp/i386/emit.mlp +index 2992f29..0b1252c 100644 +--- a/asmcomp/i386/emit.mlp ++++ b/asmcomp/i386/emit.mlp +@@ -905,12 +905,12 @@ let fundecl fundecl = + emit_all true fundecl.fun_body; + List.iter emit_call_gc !call_gc_sites; + emit_call_bound_errors (); +- List.iter emit_float_constant !float_constants; +- match Config.system with ++ begin match Config.system with + "linux_elf" | "bsd_elf" | "gnu" -> + ` .type {emit_symbol fundecl.fun_name},@function\n`; + ` .size {emit_symbol fundecl.fun_name},.-{emit_symbol fundecl.fun_name}\n` +- | _ -> () ++ | _ -> () end; ++ List.iter emit_float_constant !float_constants + + + (* Emission of data *) +-- diff -Nru mldonkey-3.0.7/patches/ocaml-3.12.0.patch mldonkey-3.1.0/patches/ocaml-3.12.0.patch --- mldonkey-3.0.7/patches/ocaml-3.12.0.patch 1970-01-01 00:00:00.000000000 +0000 +++ mldonkey-3.1.0/patches/ocaml-3.12.0.patch 2011-03-10 19:18:37.000000000 +0000 @@ -0,0 +1,66 @@ +From: Stephane Glondu +Date: Tue, 8 Mar 2011 21:17:40 +0100 +Subject: [PATCH] Fix ocamlopt w.r.t. binutils 2.21 +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Bug: http://caml.inria.fr/mantis/view.php?id=5237 +Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=617404 +Authors: Eric Cooper, spiralvoice +Reviewed-by: Stéphane Glondu +--- + asmcomp/amd64/emit.mlp | 13 +++++++------ + asmcomp/i386/emit.mlp | 6 +++--- + 2 files changed, 10 insertions(+), 9 deletions(-) + +diff --git a/asmcomp/amd64/emit.mlp b/asmcomp/amd64/emit.mlp +index 4a3f844..525c6e6 100644 +--- a/asmcomp/amd64/emit.mlp ++++ b/asmcomp/amd64/emit.mlp +@@ -679,17 +679,18 @@ let fundecl fundecl = + emit_all true fundecl.fun_body; + List.iter emit_call_gc !call_gc_sites; + emit_call_bound_errors (); ++ begin match Config.system with ++ "linux" | "gnu" -> ++ ` .type {emit_symbol fundecl.fun_name},@function\n`; ++ ` .size {emit_symbol fundecl.fun_name},.-{emit_symbol fundecl.fun_name}\n` ++ | _ -> () ++ end; + if !float_constants <> [] then begin + if macosx + then ` .literal8\n` + else ` .section .rodata.cst8,\"a\",@progbits\n`; + List.iter emit_float_constant !float_constants +- end; +- match Config.system with +- "linux" | "gnu" -> +- ` .type {emit_symbol fundecl.fun_name},@function\n`; +- ` .size {emit_symbol fundecl.fun_name},.-{emit_symbol fundecl.fun_name}\n` +- | _ -> () ++ end + + (* Emission of data *) + +diff --git a/asmcomp/i386/emit.mlp b/asmcomp/i386/emit.mlp +index 2992f29..0b1252c 100644 +--- a/asmcomp/i386/emit.mlp ++++ b/asmcomp/i386/emit.mlp +@@ -905,12 +905,12 @@ let fundecl fundecl = + emit_all true fundecl.fun_body; + List.iter emit_call_gc !call_gc_sites; + emit_call_bound_errors (); +- List.iter emit_float_constant !float_constants; +- match Config.system with ++ begin match Config.system with + "linux_elf" | "bsd_elf" | "gnu" -> + ` .type {emit_symbol fundecl.fun_name},@function\n`; + ` .size {emit_symbol fundecl.fun_name},.-{emit_symbol fundecl.fun_name}\n` +- | _ -> () ++ | _ -> () end; ++ List.iter emit_float_constant !float_constants + + + (* Emission of data *) +-- diff -Nru mldonkey-3.0.7/src/daemon/common/commonFile.ml mldonkey-3.1.0/src/daemon/common/commonFile.ml --- mldonkey-3.0.7/src/daemon/common/commonFile.ml 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/src/daemon/common/commonFile.ml 2011-01-31 17:17:04.000000000 +0000 @@ -700,6 +700,23 @@ let buf = o.conn_buf in let srcs = file_all_sources file in + let chunks_counts chunks = + let tc = VerificationBitmap.length chunks in + let c0 = ref 0 in + let c1 = ref 0 in + let c2 = ref 0 in + let c3 = ref 0 in + + VerificationBitmap.iteri (fun _ c -> + match c with + | VerificationBitmap.State_missing -> incr c0 + | VerificationBitmap.State_partial -> incr c1 + | VerificationBitmap.State_complete -> incr c2 + | VerificationBitmap.State_verified -> incr c3 + ) chunks; + Printf.sprintf "%d = %d + %d + %d + %d" tc !c0 !c1 !c2 !c3 + in + if use_html_mods o then begin html_mods_cntr_init (); @@ -807,35 +824,21 @@ Printf.bprintf buf "\\\\" (html_mods_cntr ()); - (match info.G.file_chunks with + begin match info.G.file_chunks with | None -> () | Some chunks -> - let tt = "0=Missing, 1=Partial, 2=Complete, 3=Verified" in - let tc = VerificationBitmap.length chunks in - let c0 = ref 0 in - let c1 = ref 0 in - let c2 = ref 0 in - let c3 = ref 0 in - - VerificationBitmap.iteri (fun _ c -> - match c with - | VerificationBitmap.State_missing -> incr c0 - | VerificationBitmap.State_partial -> incr c1 - | VerificationBitmap.State_complete -> incr c2 - | VerificationBitmap.State_verified -> incr c3 - ) chunks; - - let header = Printf.sprintf "%d (%d+%d+%d+%d): " tc !c0 !c1 !c2 !c3 in + let tt = "Total = Missing + Partial + Complete + Verified" in + let summary = chunks_counts chunks in html_mods_td buf [ (tt, "sr br", "Chunks"); (tt, "sr", - header ^ if !!html_vd_chunk_graph then + summary ^ if !!html_vd_chunk_graph then colored_chunks chunks else VerificationBitmap.to_string chunks ) ] - ); + end; Printf.bprintf buf "\\\\" (html_mods_cntr ()); html_mods_td buf [ @@ -874,10 +877,9 @@ (match file_group file with Some group -> Printf.sprintf "%s" group.group_name | None -> "private"); - Printf.bprintf buf "Chunks: [%-s]\n" (match info.G.file_chunks with - | None -> "" - | Some chunks -> VerificationBitmap.to_string chunks); + | None -> () + | Some chunks -> Printf.bprintf buf "Chunks: %s\n" (chunks_counts chunks)); (match impl.impl_file_probable_name with None -> () | Some filename -> diff -Nru mldonkey-3.0.7/src/daemon/common/commonInteractive.ml mldonkey-3.1.0/src/daemon/common/commonInteractive.ml --- mldonkey-3.0.7/src/daemon/common/commonInteractive.ml 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/src/daemon/common/commonInteractive.ml 2011-03-13 17:51:02.000000000 +0000 @@ -114,12 +114,14 @@ if full then Hashtbl.replace last_sent_dir_warning dir current_time; CommonEvent.add_event (Console_message_event (Printf.sprintf "\nWARNING: %s %s, %s\n" dir status line1)); - if !!mail <> "" then + match String2.tokens !!mail with + | [] -> () + | mails -> let module M = Mailer in let subject = Printf.sprintf "[mldonkey@%s] AUTOMATED WARNING: %s %s" (Unix.gethostname ()) dir status in let mail = { - M.mail_to = !!mail; - M.mail_from = !!mail; + M.mail_to = mails; + M.mail_from = List.hd mails; M.mail_subject = subject; M.mail_body = line1; M.smtp_login = !!smtp_login; @@ -207,7 +209,7 @@ ("USER_MAIL", ( if (file_owner file).user_mail <> "" then (file_owner file).user_mail else - if !!mail <> "" then !!mail else "")); + match String2.tokens !!mail with [] -> "" | x::_ -> x)); ("FILE_GROUP_CNT", string_of_int (fst (file_group_info))); ] @ snd (file_group_info)) @@ -330,7 +332,8 @@ let mail_for_completed_file file = let usermail = (file_owner file).user_mail in - if (!!mail <> "" || usermail <> "") && !!smtp_server <> "" && !!smtp_port <> 0 then begin + let mail = String2.tokens !!mail in + if (mail <> [] || usermail <> "") && !!smtp_server <> "" && !!smtp_port <> 0 then begin let module M = Mailer in let info = file_info file in let line1 = "mldonkey has completed the download of:\r\n\r\n" in @@ -379,7 +382,7 @@ let send_mail address admin = let mail = { M.mail_to = address; - M.mail_from = address; + M.mail_from = List.hd address; M.mail_subject = subject; M.mail_body = line1 ^ line2 ^ line3 ^ line4 ^ line5 ^ (if admin then line6 else "") ^ line7; M.smtp_login = !!smtp_login; @@ -387,8 +390,8 @@ } in M.sendmail !!smtp_server !!smtp_port !!add_mail_brackets mail in - if !!mail <> "" then send_mail !!mail true; (* Multiuser ToDo: this mail is for the admin user, optional? *) - if usermail <> "" && usermail <> !!mail then (try send_mail usermail false with Not_found -> ()) + if mail <> [] then send_mail mail true; (* Multiuser ToDo: this mail is for the admin user, optional? *) + if usermail <> "" && [usermail] <> mail then (try send_mail [usermail] false with Not_found -> ()) end let file_completed (file : file) = @@ -588,7 +591,7 @@ ("USER_MAIL", ( if (file_owner file).user_mail <> "" then (file_owner file).user_mail else - if !!mail <> "" then !!mail else "")); + match String2.tokens !!mail with [] -> "" | x::_ -> x)); ("FILE_GROUP_CNT", string_of_int (fst (file_group_info))); ] @ snd (file_group_info)) diff -Nru mldonkey-3.0.7/src/daemon/common/commonMessages.ml mldonkey-3.1.0/src/daemon/common/commonMessages.ml --- mldonkey-3.0.7/src/daemon/common/commonMessages.ml 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/src/daemon/common/commonMessages.ml 2011-05-07 18:59:56.000000000 +0000 @@ -101,6 +101,7 @@ input.but { background: @color_input_button@; } +input.changed { border: 2px solid red; } a:link, a:active, a:visited { text-decoration: none; font-family: verdana; @@ -612,6 +613,40 @@ } } +function track_changed(obj) +{ + if (obj.value != obj.defaultValue) + obj.className += \" changed\"; + else + obj.className = obj.className.replace(/\\bchanged\\b/,''); +} + +function xhr_ok_handler(f) { + return function() { +// alert(this.readyState); + if (this.readyState != 4) return; + if (this.status == 200) { f(this.responseText); } + } +} + +function xhr_get(url,f) { +var client = new XMLHttpRequest(); +client.onreadystatechange = xhr_ok_handler(f); +client.open(\"GET\", url); +client.send(); +} + +function toggle_priority(o,file,sub) +{ + return function(prio) { + var p = \"0\"; + if (prio == \"0\") p = \"1\"; + o.onclick = function() { + xhr_get(\"submit?api=set_subfile_prio+\"+file+\"+\"+p+\"+\"+sub, toggle_priority(o,file,sub)); }; + o.innerText = \"priority \"+prio; + } +} + //--> " diff -Nru mldonkey-3.0.7/src/daemon/common/commonOptions.ml mldonkey-3.1.0/src/daemon/common/commonOptions.ml --- mldonkey-3.0.7/src/daemon/common/commonOptions.ml 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/src/daemon/common/commonOptions.ml 2011-03-14 18:57:26.000000000 +0000 @@ -578,7 +578,8 @@ act : debug activity bw : debug bandwidth geo : debug GeoIP - unexp : debug unexpected messages" + unexp : debug unexpected messages + dht : debug DHT" string_option "" @@ -1053,8 +1054,6 @@ "http://www.bluetack.co.uk/config/level1.gz"); ("server.met", 0, "http://www.gruk.org/server.met.gz"); - ("contact.dat", 168, - "http://download.overnet.org/contact.dat"); ("geoip.dat", 0, "http://www.maxmind.com/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz"); ("nodes.gzip", 0, @@ -1177,19 +1176,19 @@ string_option "" let mail = define_option current_section ["mail"] - "Your e-mail if you want to receive mails when downloads are completed" + (_s"Email address to receive notifications when downloads are completed or disk is full (leave empty to disable, separate multiple addresses with space)") string_option "" let add_mail_brackets = define_option current_section ["add_mail_brackets"] - "Set to false if your mail server cannot handle angle-brackets around addresses (RFC 5321)" + (_s"Set to false if your mail server cannot handle angle-brackets around addresses (RFC 5321)") bool_option true let filename_in_subject = define_option current_section ["filename_in_subject"] - "Send filename in mail subject" + (_s"Send filename in mail subject") bool_option true let url_in_mail = define_option current_section ["url_in_mail"] - "Put a prefix for the filename here which shows up in the notification mail" + (_s"Put a prefix for the filename here which shows up in the notification mail") string_option "" @@ -1666,7 +1665,7 @@ let options_version = define_expert_option current_section ["options_version"] ~internal: true "(internal option)" - int_option 21 + int_option 22 let max_comments_per_file = define_expert_option current_section ["max_comments_per_file"] "Maximum number of comments per file" @@ -1766,14 +1765,13 @@ match name with | "mldc" -> enable_directconnect =:= true | "mlgnut" -> enable_gnutella =:= true - | "mldonkey" -> enable_donkey =:= true; enable_overnet =:= true + | "mldonkey" -> enable_donkey =:= true; | "mlslsk" -> enable_soulseek =:= true | "mlbt" -> enable_bittorrent =:= true | "mlnap" -> enable_opennap =:= true | _ -> (* default *) enable_donkey =:= true; - enable_overnet =:= true; enable_bittorrent =:= true let win_message = @@ -1909,6 +1907,7 @@ let verbose_user_commands = ref false let verbose_geoip = ref false let verbose_unexpected_messages = ref false +let verbose_dht = ref (ref false) let set_all v = verbose_msg_clients := v; @@ -1938,7 +1937,8 @@ verbose_activity := v; verbose_user_commands := v; Geoip.verbose := v; - verbose_unexpected_messages := v + verbose_unexpected_messages := v; + !verbose_dht := v let _ = option_hook verbosity (fun _ -> @@ -1975,6 +1975,7 @@ | "unexp" -> verbose_unexpected_messages := true | "com" -> verbose_user_commands := true | "geo" -> Geoip.verbose := true + | "dht" -> !verbose_dht := true | "all" -> @@ -2264,4 +2265,9 @@ "http://www.maxmind.com/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz"; update 21 + | 21 -> + web_infos_remove "http://download.overnet.org/contact.dat"; + enable_overnet =:= false; + update 22 + | _ -> () diff -Nru mldonkey-3.0.7/src/daemon/common/commonSwarming.ml mldonkey-3.1.0/src/daemon/common/commonSwarming.ml --- mldonkey-3.0.7/src/daemon/common/commonSwarming.ml 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/src/daemon/common/commonSwarming.ml 2011-01-31 17:17:04.000000000 +0000 @@ -143,6 +143,9 @@ mutable s_strategy : swarming_strategy; mutable s_verified_bitmap : VerificationBitmap.t; + mutable s_priorities_bitmap : string; + mutable s_priorities_intervals : (int64 * int) list; + (* beginning, priority *) mutable s_disk_allocated : Bitv.t; mutable s_availability : int array; mutable s_nuploading : int array; @@ -579,6 +582,8 @@ s_networks = []; s_strategy = AdvancedStrategy; s_verified_bitmap = VB.create 0 VB.State_missing; + s_priorities_bitmap = ""; + s_priorities_intervals = [(zero, 1)]; s_disk_allocated = Bitv.create 0 false; s_blocks = [||]; s_block_pos = [||]; @@ -586,10 +591,93 @@ s_nuploading = [||]; } +let insert_prio_interval intervals last_end (new_start,new_end,new_prio) = + assert (new_start < new_end); + assert (new_end <= last_end); + let rec insert_end prev_prio = function + | [] -> if new_end = last_end then [] else if new_prio <> prev_prio then [new_end, prev_prio] else [] + | (pos,prio as this) :: tail -> + match Int64.compare pos new_end with + | -1 -> insert_end prio tail (* eat it *) + | 1 -> + if new_prio <> prev_prio then + (new_end, prev_prio) :: this :: tail + else + this :: tail + | 0 -> + assert (prio <> prev_prio); + if new_prio <> prio then this :: tail else tail + | _ -> assert false + in + let rec insert prev_prio = function (* not tail rec ! *) + | [] -> + if new_prio <> prev_prio then + (new_start, new_prio) :: insert_end prev_prio [] + else + insert_end prev_prio [] + | (pos, prio as this) :: tail -> + match Int64.compare pos new_start with + | -1 -> this :: insert prio tail (* leave current and continue searching *) + | 1 -> + if new_prio <> prev_prio then + (new_start, new_prio) :: insert_end prev_prio (this::tail) (* mark new interval and search interval end *) + else + insert_end prev_prio (this::tail) (* start of new interval gets merged with previous interval *) + | 0 -> + assert (prio <> prev_prio); (* invariant *) + if new_prio <> prev_prio then + (new_start, new_prio) :: insert_end prio tail + else + insert_end prio tail + | _ -> assert false + in + insert (-1) intervals + +let rec validate_intervals limit = function + | (p1,prio1)::((p2,prio2)::_ as tail) when prio1 <> prio2 && p1 < p2 -> validate_intervals limit tail + | [p,_] when p < limit -> true + | _ -> false + +let priority_zero = Char.chr 0 + +let swarmer_recompute_priorities_bitmap s = + String.fill s.s_priorities_bitmap 0 + (String.length s.s_priorities_bitmap) priority_zero; + let mark interval_begin interval_end priority = + if interval_end > interval_begin && s.s_size >= interval_end && interval_begin >= 0L then + if priority = 0 then + () (* do not mark - zero blocks will not overwrite boundaries of non-zero blocks *) + else + begin + let i_begin = compute_block_num s interval_begin in + let i_end = compute_block_num s (Int64.pred interval_end) in + let priochar = Char.chr (max 0 (min priority 255)) in + (* String.fill s.s_priorities_bitmap i_begin (i_end - i_begin + 1) priochar *) + for i = i_begin to i_end do + s.s_priorities_bitmap.[i] <- priochar + done + end + else + lprintf_nl "WARNING: recompute_priorities %Ld %Ld %Ld" interval_begin interval_end s.s_size + in + let rec loop = function + | (i_begin, priority) :: ((i_end,_) :: _ as tail) -> mark i_begin i_end priority; loop tail + | [i_begin, priority] -> mark i_begin s.s_size priority + | [] -> lprintf_nl "WARNING: recompute_priorities []" + in + loop s.s_priorities_intervals + +(* Intervals with fixed byte positions are needed to recompute priorities bitmap + after merge, cause priobitmap depends on block size *) +let swarmer_set_interval s (p1,p2,prio as new_interval) = + if !verbose then + lprintf_nl "swarmer_set_interval %S %Ld (%Ld,%Ld,%u)" s.s_filename s.s_size p1 p2 prio; + s.s_priorities_intervals <- insert_prio_interval s.s_priorities_intervals s.s_size new_interval; + swarmer_recompute_priorities_bitmap s + (** if a swarmer is already associated with that [file_name], return it; Otherwise create a new one with default values, that will be fixed by the first frontend association *) - let create_swarmer file_name file_size = try HS.find swarmers_by_name @@ -619,6 +707,8 @@ s_strategy = AdvancedStrategy; s_verified_bitmap = VB.create nblocks VB.State_missing; + s_priorities_bitmap = String.make nblocks priority_zero; + s_priorities_intervals = [(zero, 1)]; (* JAVE init all prios to 1, thus all chunks will be downloaded as usual *) s_disk_allocated = Bitv.create ndiskblocks false; s_blocks = Array.create nblocks EmptyBlock ; s_block_pos = Array.create nblocks zero; @@ -627,6 +717,7 @@ (* s_last_seen = Array.create nblocks 0; *) } in + swarmer_recompute_priorities_bitmap s; HS.add swarmers_by_name s; s @@ -749,6 +840,7 @@ s.s_blocks <- Array.create nblocks EmptyBlock; s.s_verified_bitmap <- VB.create nblocks VB.State_missing; + s.s_priorities_bitmap <- String.make nblocks priority_zero; s.s_block_pos <- Array.create nblocks zero; s.s_availability <- Array.create nblocks 0; (* not preserved ? *) s.s_nuploading <- Array.create nblocks 0; (* not preserved ? *) @@ -783,7 +875,9 @@ iter (i+1) tail in - iter 0 blocks + iter 0 blocks; + swarmer_recompute_priorities_bitmap s + (** Associate a(n additional) frontend to a swarmer *) @@ -1950,7 +2044,7 @@ up.up_npartial <- n-1; let t = up.up_t in let s = t.t_s in - (* priority bitmap <> 0 here ? *) + if s.s_priorities_bitmap.[b] = priority_zero then iter_partial up else let chunk = t.t_chunk_of_block.(b) in match s.s_blocks.(b) with | CompleteBlock | VerifiedBlock -> @@ -1976,7 +2070,7 @@ up.up_ncomplete <- n-1; let t = up.up_t in let s = t.t_s in - (* priority bitmap <> 0 here ? *) + if s.s_priorities_bitmap.[b] = priority_zero then iter_complete up else let chunk = t.t_chunk_of_block.(b) in match s.s_blocks.(b) with | CompleteBlock | VerifiedBlock -> @@ -2124,8 +2218,10 @@ else acc) 0 t.t_blocks_of_chunk.(chunk)) (t.t_num, i)) ) 0 s.s_networks) i in +(* let preview_beginning = 9000000L in let preview_end = (s.s_size ** 98L) // 100L in +*) (* sources_per_chunk was initially for edonkey only *) let data_per_source = 9728000L // (Int64.of_int !!sources_per_chunk) in @@ -2145,9 +2241,7 @@ { choice_num = n; choice_block = b; - choice_user_priority = (* priority bitmap here instead ? *) - if block_begin < preview_beginning then 3 else - if block_end > preview_end then 2 else 1; + choice_user_priority = Char.code s.s_priorities_bitmap.[b]; choice_remaining = remaining; choice_preallocated = is_fully_preallocated t block_begin block_end; choice_unselected_remaining = unselected_remaining; @@ -2296,7 +2390,8 @@ Array2.subarray_fold_lefti (fun ((current_chunk_num, current_chunk_blocks_indexes, best_choices, specimen) as acc) n b -> - if not (should_download_block s b) then acc + if s.s_priorities_bitmap.[b] = priority_zero || + not (should_download_block s b) then acc else let chunk_num = t.t_chunk_of_block.(b) in if chunk_num = current_chunk_num then @@ -2361,7 +2456,8 @@ if probably_buggy then begin lprintf_nl "Probably buggy choice (%d):" chunk; Array2.subarray_fold_lefti (fun () n b -> - if should_download_block s b then + if s.s_priorities_bitmap.[b] <> priority_zero && + should_download_block s b then let this_choice = create_choice n b in if List.mem n blocks then lprintf "** " else if List.exists (List.mem n) best_choices then @@ -2640,7 +2736,8 @@ let block = up.up_complete_blocks.(i) in if not (List.exists (fun b -> b.up_block.block_num = block ) up.up_blocks) then - if should_download_block s block then (* priority bitmap <> 0 here ? *) + if s.s_priorities_bitmap.[block] <> priority_zero && + should_download_block s block then let partial_found = match s.s_blocks.(block) with | EmptyBlock -> true | CompleteBlock | VerifiedBlock -> false @@ -2977,7 +3074,7 @@ | List [v1;v2] | SmallList [v1;v2] -> (value_to_int64 v1, value_to_int64 v2) | _ -> - failwith "Options: Not an int32 pair" + failwith "Options: Not an int64 pair" (*************************************************************************) (* *) @@ -3240,6 +3337,13 @@ module SwarmerOption = struct + let value_to_priority_interval v = + match v with + | List [v1;p] | SmallList [v1;p] -> + (value_to_int64 v1, value_to_int p) + | _ -> + failwith "Options: Not a priority interval" + let value_to_swarmer v = match v with | Module assocs -> @@ -3266,6 +3370,16 @@ List.iter (fun bsize -> split_blocks s bsize ) block_sizes; + let intervals = + try + get_value "file_priorities_intervals" (value_to_list value_to_priority_interval) + with Not_found -> [(zero, 1)] + in + if validate_intervals s.s_size intervals then + s.s_priorities_intervals <- intervals + else + lprintf_nl "Failed to validate priority intervals, using default. File %s" file_name; + swarmer_recompute_priorities_bitmap s; s | _ -> assert false @@ -3278,6 +3392,10 @@ (Bitv.to_string s.s_disk_allocated)); ("file_chunk_sizes", list_to_value int64_to_value (List.map (fun t -> t.t_chunk_size) s.s_networks)); + ("file_priorities_intervals", List + (List.map + (fun (i_begin, priority) -> SmallList [int64_to_value i_begin; int_to_value priority]) + s.s_priorities_intervals)); ("file_download_random", bool_to_value (match s.s_strategy with | AdvancedStrategy -> true @@ -3428,6 +3546,24 @@ Printf.bprintf buf " Storage: %d bytes\n" !storage; ) +(* functions for priority bitmask *) + +let file_swarmer f = + HS.find swarmers_by_name { dummy_swarmer with s_filename = file_disk_name f } + +(* +(** set the priority bitmask for each chunk in a file *) +let set_swarmer_chunk_priorities f priobitmap = + let s = file_swarmer f in + if String.length priobitmap = VB.length s.s_verified_bitmap then + s.s_priorities_bitmap <- priobitmap +*) + +(** get the priority bitmask for a file (do not mutate the string directly, use swarmer_set_interval) *) +let get_swarmer_block_priorities s = s.s_priorities_bitmap +let get_swarmer_block_verified s = s.s_verified_bitmap +let get_swarmer_priorities_intervals s = s.s_priorities_intervals + (* using compute_block_num outside of swarming code is probably broken, networks supports are aware of chunks, not blocks maybe other block-related functions should be censored in the same @@ -3435,4 +3571,4 @@ tag block numbers are chunk numbers so they're not inadvertedly mistaken for each other ? *) -let compute_block_num = () +(* let compute_block_num = () *) diff -Nru mldonkey-3.0.7/src/daemon/common/commonTypes.ml mldonkey-3.1.0/src/daemon/common/commonTypes.ml --- mldonkey-3.0.7/src/daemon/common/commonTypes.ml 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/src/daemon/common/commonTypes.ml 2011-01-23 15:20:26.000000000 +0000 @@ -87,7 +87,6 @@ exception Illegal_urn of string exception Torrent_started of string exception Torrent_already_exists of string -exception Torrent_can_not_be_used of string let uid_of_string s = let s = String.lowercase s in diff -Nru mldonkey-3.0.7/src/daemon/common/commonWeb.ml mldonkey-3.1.0/src/daemon/common/commonWeb.ml --- mldonkey-3.0.7/src/daemon/common/commonWeb.ml 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/src/daemon/common/commonWeb.ml 2011-07-16 08:59:27.000000000 +0000 @@ -150,8 +150,8 @@ end ) (fun c -> - match c with - | x when x > 0 && (x < 200 || x > 299) -> begin + match c with + | `HTTP x when (x < 200 || x > 299) -> begin (* use local version if wget fail and file exists *) let file = Filename.concat "web_infos" (Filename.basename r.H.req_url.Url.short_file) in (* mark this job downloaded *) @@ -185,7 +185,7 @@ lprintf_nl (_b "local file %s not found, HTTP request failed (error %d)") file x; w.state <- None end - | _ -> () + | _ -> () ) with e -> w.state <- None; diff -Nru mldonkey-3.0.7/src/daemon/driver/driverCommands.ml mldonkey-3.1.0/src/daemon/driver/driverCommands.ml --- mldonkey-3.0.7/src/daemon/driver/driverCommands.ml 2011-02-12 15:31:11.000000000 +0000 +++ mldonkey-3.1.0/src/daemon/driver/driverCommands.ml 2011-05-07 18:59:56.000000000 +0000 @@ -50,6 +50,8 @@ open Gettext open Autoconf +module VB = VerificationBitmap + let log_prefix = "[dCmd]" let lprintf_nl fmt = @@ -160,7 +162,7 @@ o.option_value (if o.option_value="true" then "false" else "true") else Printf.bprintf buf "\\" + type=text name=value onchange=\\\"track_changed(this)\\\" size=20 value=\\\"%s\\\"\\>" o.option_value; end; Printf.bprintf buf "\\\\\\%s\\" (shorten o.option_default 40); @@ -201,7 +203,7 @@ \\\\\\
\\ \\ %s \\\\ - \\ + \\ \\\\ \\ " o.option_name o.option_name o.option_value @@ -3205,11 +3207,12 @@ \\\\Display all files\\\\ \\\\Verify chunks\\\\ \\\\Preview\\\\ + \\\\Debug\\\\ \\\\Reload\\\\ \\\\ \\\\ \\\\ - \\\\" num num + \\\\" num num num else begin Printf.bprintf buf "\\Display all files\\ "; Printf.bprintf buf "\\Verify chunks\\ " num; @@ -3867,6 +3870,97 @@ register_commands "Driver/Xpert" [ +(* + "debug_set_download_prio", Arg_two + (fun arg priostring o -> + let num = int_of_string arg in + let file = file_find num in + CommonSwarming.set_swarmer_chunk_priorities file priostring; + "set prio" + + ), ":\t\t\t\t\tset block download priorities for a file. 0=never download, >0=download largest prio first"; +*) + + "debug_get_download_prio", Arg_one + (fun arg o -> + let buf = o.conn_buf in + let pr fmt = Printf.bprintf buf fmt in + let num = int_of_string arg in + let file = file_find num in + let swarmer = CommonSwarming.file_swarmer file in + let prio = CommonSwarming.get_swarmer_block_priorities swarmer in + let downloaded = CommonSwarming.get_swarmer_block_verified swarmer in + pr "\\"; + pr "priorities: "; + String.iter (fun c -> + let c = max 0 (min 9 (Char.code c)) in + let c = Char.chr (c + Char.code '0') in + Buffer.add_char buf c) prio; + pr "\n"; + pr "downloaded: %s\n" (VB.to_string downloaded); + + Unix32.subfile_tree_map (file_fd file) + begin fun fname start length current_length -> + let stop = if length <> 0L then (start ++ length -- 1L) else start in + let blockstart = try CommonSwarming.compute_block_num swarmer start with _ -> 0 in + let blockend = try CommonSwarming.compute_block_num swarmer stop with _ -> 0 in + pr "sf:%5Ld ef:%5Ld l:%Ld cl:%Ld > sc:%5d ec:%5d filename:%-30s \n" + start + stop + length + current_length + blockstart + blockend + fname; + (*make a chunk downloaded status string for a subfile*) + (try + for i = blockstart to blockend do + Buffer.add_char buf (VB.state_to_char (VB.get downloaded i)); + done; + pr "\n"; + with _ -> ()) + end; + pr "\\"; + ""; + ), ":\t\t\t\t\tget file block priorities for a file, and show subfile completion status"; + + "set_subfile_prio", Arg_multiple + (fun args o -> + match args with + | filenum :: priochar :: subfilestart :: q -> + let filenum = int_of_string filenum in + let priochar = int_of_string priochar in + let subfilestart = int_of_string subfilestart in + let subfileend = + match q with + | subfileend :: _ -> int_of_string subfileend + | _ -> subfilestart in + let file = file_find filenum in + let swarmer = CommonSwarming.file_swarmer file in +(* + let priostring = + CommonSwarming.get_swarmer_chunk_priorities file in +*) + let subfile1 = Unix32.find_file_index (file_fd file) subfilestart in + let subfile2 = Unix32.find_file_index (file_fd file) subfileend in + let subfile_pos = function (_,y,_) -> y in + let subfile_len = function (_,_,y) -> y in + let start = subfile_pos subfile1 in + let stop = + subfile_pos subfile2 ++ subfile_len subfile2 +(* -- if subfile_len subfile2 > 0L then 1L else 0L *) + in +(* + Printf.bprintf buf "file %s\nstart %Ld stop %Ld prio %u\n" + swarmer.CommonSwarming.s_filename start stop priochar; +*) + CommonSwarming.swarmer_set_interval swarmer (start,stop,priochar); + (* show file *) +(* execute_command !CommonNetwork.network_commands o "vd" [string_of_int filenum]; *) + string_of_int priochar + | _ -> bad_number_of_args "" "" + ), "set_subfile_prio <1st subfile (0-based)> "; + "reload_messages", Arg_none (fun o -> CommonMessages.load_message_file (); "\\